COMMAND "${CMAKE_LINKER}" -v
ERROR_VARIABLE stderr
)
- set(LLVM_LINKER_DETECTED ON)
+ set(LLVM_LINKER_DETECTED YES)
if("${stderr}" MATCHES "PROJECT:ld64")
- set(LLVM_LINKER_IS_LD64 ON)
+ set(LLVM_LINKER_IS_LD64 YES)
message(STATUS "Linker detection: ld64")
else()
- set(LLVM_LINKER_DETECTED OFF)
+ set(LLVM_LINKER_DETECTED NO)
message(STATUS "Linker detection: unknown")
endif()
elseif(NOT WIN32)
OUTPUT_VARIABLE stdout
ERROR_VARIABLE stderr
)
- set(LLVM_LINKER_DETECTED ON)
+ set(LLVM_LINKER_DETECTED YES)
if("${stdout}" MATCHES "GNU gold")
- set(LLVM_LINKER_IS_GOLD ON)
+ set(LLVM_LINKER_IS_GOLD YES)
message(STATUS "Linker detection: GNU Gold")
elseif("${stdout}" MATCHES "^LLD")
- set(LLVM_LINKER_IS_LLD ON)
+ set(LLVM_LINKER_IS_LLD YES)
message(STATUS "Linker detection: LLD")
elseif("${stdout}" MATCHES "GNU ld")
- set(LLVM_LINKER_IS_GNULD ON)
+ set(LLVM_LINKER_IS_GNULD YES)
message(STATUS "Linker detection: GNU ld")
elseif("${stderr}" MATCHES "Solaris Link Editors" OR
"${stdout}" MATCHES "Solaris Link Editors")
- set(LLVM_LINKER_IS_SOLARISLD ON)
+ set(LLVM_LINKER_IS_SOLARISLD YES)
message(STATUS "Linker detection: Solaris ld")
else()
- set(LLVM_LINKER_DETECTED OFF)
+ set(LLVM_LINKER_DETECTED NO)
message(STATUS "Linker detection: unknown")
endif()
endif()