From 7232af85c9ad30b24f78d3220d460e7d3f548609 Mon Sep 17 00:00:00 2001 From: Russel Winder Date: Sun, 30 Aug 2009 09:44:10 +0100 Subject: [PATCH] Remove the explicit path by correcting the dependencies. --- containers/posix/test0/SConscript | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/containers/posix/test0/SConscript b/containers/posix/test0/SConscript index 1173c69..e20c65d 100644 --- a/containers/posix/test0/SConscript +++ b/containers/posix/test0/SConscript @@ -23,11 +23,8 @@ taskName = 'test0' def createTestExecLinkerScript(target, source, env): with open(target[0].path, 'w') as outFile: - #### - #### TODO: Remove this dependency on the hardwired path. - #### - with open('containers/posix/test0/linker.lds.in') as templateFile: - outFile.write(templateFile.read().replace('__PHYSICAL_BASE_FILE_NAME_MARKER__', source[0].path)) + with open(source[0].path) as templateFile: + outFile.write(templateFile.read().replace('__PHYSICAL_BASE_FILE_NAME_MARKER__', source[1].path)) def createTestExecS(target, source, env): with open(target[0].path, 'w') as outFile: @@ -41,7 +38,7 @@ def createTestExecS(target, source, env): testTaskEnvironment = environment.Clone() testTaskEnvironment.Append(CPPPATH=['#' + testTaskEnvironment['posixServicesDirectory'] +'/libposix/include/posix']) -testExecLinkerScript = Command('#build/' + testTaskEnvironment['posixServicesDirectory'] +'/' + taskName + '/test_exec_linker.lds', testTaskEnvironment['physicalBaseLinkerScript'], createTestExecLinkerScript) +testExecLinkerScript = Command('#build/' + testTaskEnvironment['posixServicesDirectory'] +'/' + taskName + '/test_exec_linker.lds', ['linker.lds.in', testTaskEnvironment['physicalBaseLinkerScript']], createTestExecLinkerScript) testExecEnvironment = testTaskEnvironment.Clone() testExecEnvironment.Append(LINKFLAGS=['-T' + testExecLinkerScript[0].path]) testExec = testExecEnvironment.Program('test_exec', Glob('src/test_exec/*.[cS]'))