[PATCH] D108473: [cmake] Fix native tooling when cross-compiling on Linux
Shoaib Meenai via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri Aug 20 10:05:41 PDT 2021
This revision was landed with ongoing or failed builds.
This revision was automatically updated to reflect the committed changes.
Closed by commit rGcd1b95014121: [cmake] Fix native tooling when cross-compiling on Linux (authored by smeenai).
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D108473/new/
https://reviews.llvm.org/D108473
Files:
llvm/cmake/config-ix.cmake
Index: llvm/cmake/config-ix.cmake
===================================================================
--- llvm/cmake/config-ix.cmake
+++ llvm/cmake/config-ix.cmake
@@ -692,6 +692,17 @@
endif()
function(llvm_get_host_prefixes_and_suffixes)
+ # Not all platform files will set these variables (relying on them being
+ # implicitly empty if they're unset), so unset the variables before including
+ # the platform file, to prevent any values from the target system leaking.
+ unset(CMAKE_STATIC_LIBRARY_PREFIX)
+ unset(CMAKE_STATIC_LIBRARY_SUFFIX)
+ unset(CMAKE_SHARED_LIBRARY_PREFIX)
+ unset(CMAKE_SHARED_LIBRARY_SUFFIX)
+ unset(CMAKE_IMPORT_LIBRARY_PREFIX)
+ unset(CMAKE_IMPORT_LIBRARY_SUFFIX)
+ unset(CMAKE_EXECUTABLE_SUFFIX)
+ unset(CMAKE_LINK_LIBRARY_SUFFIX)
include(Platform/${CMAKE_HOST_SYSTEM_NAME} OPTIONAL RESULT_VARIABLE _includedFile)
if (_includedFile)
set(LLVM_HOST_STATIC_LIBRARY_PREFIX ${CMAKE_STATIC_LIBRARY_PREFIX} PARENT_SCOPE)
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D108473.367822.patch
Type: text/x-patch
Size: 970 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20210820/bddb78de/attachment.bin>
More information about the llvm-commits
mailing list