aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/Transforms/Utils/Local.cpp
diff options
context:
space:
mode:
authorMartin Storsjö <martin@martin.st>2020-11-12 11:09:38 +0200
committerMartin Storsjö <martin@martin.st>2021-03-11 15:21:48 +0200
commit8368e4d54c459fe173d76277f17c632478e91add (patch)
tree4159111522ec873490da236e99bbc51ae6cc4a38 /llvm/lib/Transforms/Utils/Local.cpp
parentbc5e9ec2dccdd18f840a09fe63c196ae25ad99d5 (diff)
downloadllvm-8368e4d54c459fe173d76277f17c632478e91add.zip
llvm-8368e4d54c459fe173d76277f17c632478e91add.tar.gz
llvm-8368e4d54c459fe173d76277f17c632478e91add.tar.bz2
[compiler-rt] Set CMAKE_TRY_COMPILE_TARGET_TYPE to STATIC_LIBRARY when building builtins standalone
When building builtins, the toolchain might not yet be at a stage when linking a test application works yet, as builtins aren't available. Therefore set CMAKE_TRY_COMPILE_TARGET_TYPE to STATIC_LIBRARY, to avoid failing the compiler sanity check. Setting CMAKE_TRY_COMPILE_TARGET_TYPE to STATIC_LIBRARY has the risk of making checks for library availability succeed falsely (e.g. indicating that libs would be available that really aren't, as the tests don't do any linking), but the builtins library doesn't try to link against any external libraries (and only produces static libraries anyway), so it should be safe here. This avoids having to set CMAKE_C_COMPILER_WORKS when bootstrapping a cross toolchain, when building the builtins. Differential Revision: https://reviews.llvm.org/D91334
Diffstat (limited to 'llvm/lib/Transforms/Utils/Local.cpp')
0 files changed, 0 insertions, 0 deletions