Makefile: Generate map file

This commit is contained in:
Sebastian Huber
2013-10-10 09:31:18 +02:00
parent ab415f95a9
commit ed2ce44cd9
2 changed files with 9 additions and 8 deletions

View File

@@ -310,6 +310,7 @@ class TestMakefileFragementComposer(MakefileFragmentComposer):
testDFiles = testPrefix + '_D_FILES'
testDir = 'testsuite/' + self.testName
testExe = testDir + '/' + self.testName + '.exe'
testMap = testDir + '/' + self.testName + '.map'
makefileFragment = '\n' + testPrefix + ' = ' + testExe + '\n' \
+ testOFiles + ' =\n' \
+ testDFiles + ' =\n'
@@ -317,7 +318,7 @@ class TestMakefileFragementComposer(MakefileFragmentComposer):
makefileFragment = makefileFragment + testOFiles + ' += ' + testDir + '/' + fileFragment + '.o\n' \
+ testDFiles + ' += ' + testDir + '/' + fileFragment + '.d\n'
makefileFragment = makefileFragment + '$(' + testPrefix + '): $(' + testOFiles + ') $(LIB)\n' \
'\t$(LINK.c) $^ -lm -o $@\n' \
'\t$(LINK.c) -Wl,-Map,' + testMap + ' $^ -lm -o $@\n' \
'TESTS += $(' + testPrefix + ')\n' \
'O_FILES += $(' + testOFiles + ')\n' \
'D_FILES += $(' + testDFiles + ')\n'