summaryrefslogtreecommitdiffstats
path: root/Modules/Compiler
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2020-03-12 13:05:07 (GMT)
committerBrad King <brad.king@kitware.com>2020-03-13 13:55:36 (GMT)
commit9728839b9e0d9a12f3c70c6f221f3f6482894ce0 (patch)
tree8552a524b8847950f5532435b24dd6ba904867e6 /Modules/Compiler
parent5932f0be4f36f97fcd3ab61a559379a2a1291371 (diff)
downloadCMake-9728839b9e0d9a12f3c70c6f221f3f6482894ce0.zip
CMake-9728839b9e0d9a12f3c70c6f221f3f6482894ce0.tar.gz
CMake-9728839b9e0d9a12f3c70c6f221f3f6482894ce0.tar.bz2
ASM: Fix executable link lines with GNU 'as' tool as CMAKE_ASM_COMPILER
The GNU `as` tool does not know how to drive linking like the C compiler does. When using `as` as the compiler, use the linker directly.
Diffstat (limited to 'Modules/Compiler')
-rw-r--r--Modules/Compiler/GNU-ASM.cmake2
1 files changed, 2 insertions, 0 deletions
diff --git a/Modules/Compiler/GNU-ASM.cmake b/Modules/Compiler/GNU-ASM.cmake
index ac241ed..4aa680f 100644
--- a/Modules/Compiler/GNU-ASM.cmake
+++ b/Modules/Compiler/GNU-ASM.cmake
@@ -7,4 +7,6 @@ __compiler_gnu(ASM)
if(CMAKE_ASM${ASM_DIALECT}_COMPILER_ID_VENDOR_MATCH STREQUAL "GNU assembler")
set(CMAKE_DEPFILE_FLAGS_ASM${ASM_DIALECT} "--MD <DEPFILE>")
+ set(CMAKE_ASM${ASM_DIALECT}_LINK_EXECUTABLE
+ "<CMAKE_LINKER> <FLAGS> <CMAKE_ASM${ASM_DIALECT}_LINK_FLAGS> <LINK_FLAGS> <OBJECTS> -o <TARGET> <LINK_LIBRARIES>")
endif()