Skip to content

Commit 25ff621

Browse files
committed
cmake: linker: ld: Use "-Map <mapfile>" for legacy compatibility
The build system currently generates mapfiles by invoking ld with the "-Map=<mapfile>" command line argument. This variant of the flag was introduced in GNU binutils 2.20. To enable compatibility with legacy versions of the GNU ld, the argument has been replaced with the "-Map <mapfile>" variant. Signed-off-by: Joel Holdsworth <jholdsworth@nvidia.com>
1 parent 491bbcf commit 25ff621

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

cmake/linker/ld/target.cmake

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -129,7 +129,7 @@ function(toolchain_ld_link_elf)
129129
${TOOLCHAIN_LD_LINK_ELF_LINKER_SCRIPT}
130130
${TOOLCHAIN_LD_LINK_ELF_LIBRARIES_POST_SCRIPT}
131131

132-
${LINKERFLAGPREFIX},-Map=${TOOLCHAIN_LD_LINK_ELF_OUTPUT_MAP}
132+
${LINKERFLAGPREFIX},-Map,${TOOLCHAIN_LD_LINK_ELF_OUTPUT_MAP}
133133
${LINKERFLAGPREFIX},--whole-archive
134134
${WHOLE_ARCHIVE_LIBS}
135135
${LINKERFLAGPREFIX},--no-whole-archive

0 commit comments

Comments
 (0)