Skip to content

Commit d954841

Browse files
committed
memap.py: Allow .a extension for Arm Compiler-generated libraries
The most common extension for static libraries is .a and CMake generates it with both GCC and Arm toolchains. Mbed CLI 1 generates .ar files with the Arm Compiler, but since Mbed CLI 2 uses memap.py to generate map files too, both extensions should be permitted. This fixes a warning when building greentea tests: Malformed input found when parsing ARMCC map: _deps/greentea-client-build/libclient_userio.a(greentea_test_env.o) Malformed input found when parsing ARMCC map: _deps/greentea-client-build/libclient_userio.a(greentea_test_env.o) Malformed input found when parsing ARMCC map: _deps/greentea-client-build/libclient_userio.a(greentea_test_env.o) ... which repeats over 30 times per test.
1 parent 4cfbea4 commit d954841

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

tools/memap.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -247,7 +247,7 @@ def parse_mapfile(self, file_desc):
247247
class _ArmccParser(_Parser):
248248
RE = re.compile(
249249
r'^\s+0x(\w{8})\s+0x(\w{8})\s+(\w+)\s+(\w+)\s+(\d+)\s+[*]?.+\s+(.+)$')
250-
RE_OBJECT = re.compile(r'(.+\.(l|ar))\((.+\.o(bj)?)\)')
250+
RE_OBJECT = re.compile(r'(.+\.(l|a|ar))\((.+\.o(bj)?)\)')
251251
OBJECT_EXTENSIONS = (".o", ".obj")
252252

253253
def parse_object_name(self, line):

0 commit comments

Comments
 (0)