Skip to content

Commit 925eaeb

Browse files
committed
Revert "[CMake] Drop libLTO and switch to PIE for Fuchsia toolchain"
This reverts commit a6f621b. We suspect that this patch might be the culprit that is causing every llvm executable to be sigkill'd immediately on Apple Silicon machines. Notably, the only other cache file with CMAKE_POSITION_INDEPENDENT_CODE is Apple's and they have it off.
1 parent ff111a9 commit 925eaeb

File tree

1 file changed

+1
-5
lines changed

1 file changed

+1
-5
lines changed

clang/cmake/caches/Fuchsia-stage2.cmake

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,6 @@ set(LLVM_ENABLE_LIBEDIT OFF CACHE BOOL "")
1414
set(LLVM_ENABLE_LLD ON CACHE BOOL "")
1515
set(LLVM_ENABLE_LTO ON CACHE BOOL "")
1616
set(LLVM_ENABLE_PER_TARGET_RUNTIME_DIR ON CACHE BOOL "")
17-
set(LLVM_ENABLE_PIC OFF CACHE BOOL "")
1817
set(LLVM_ENABLE_PLUGINS OFF CACHE BOOL "")
1918
set(LLVM_ENABLE_TERMINFO OFF CACHE BOOL "")
2019
set(LLVM_ENABLE_UNWIND_TABLES OFF CACHE BOOL "")
@@ -93,7 +92,6 @@ foreach(target aarch64-unknown-linux-gnu;armv7-unknown-linux-gnueabihf;i386-unkn
9392
list(APPEND BUILTIN_TARGETS "${target}")
9493
set(BUILTINS_${target}_CMAKE_SYSTEM_NAME Linux CACHE STRING "")
9594
set(BUILTINS_${target}_CMAKE_BUILD_TYPE RelWithDebInfo CACHE STRING "")
96-
set(BUILTINS_${target}_CMAKE_POSITION_INDEPENDENT_CODE ON CACHE BOOL "")
9795
set(BUILTINS_${target}_CMAKE_C_FLAGS "--target=${target}" CACHE STRING "")
9896
set(BUILTINS_${target}_CMAKE_CXX_FLAGS "--target=${target}" CACHE STRING "")
9997
set(BUILTINS_${target}_CMAKE_ASM_FLAGS "--target=${target}" CACHE STRING "")
@@ -106,7 +104,6 @@ foreach(target aarch64-unknown-linux-gnu;armv7-unknown-linux-gnueabihf;i386-unkn
106104
list(APPEND RUNTIME_TARGETS "${target}")
107105
set(RUNTIMES_${target}_CMAKE_SYSTEM_NAME Linux CACHE STRING "")
108106
set(RUNTIMES_${target}_CMAKE_BUILD_TYPE RelWithDebInfo CACHE STRING "")
109-
set(RUNTIMES_${target}_CMAKE_POSITION_INDEPENDENT_CODE ON CACHE BOOL "")
110107
set(RUNTIMES_${target}_CMAKE_C_FLAGS "--target=${target}" CACHE STRING "")
111108
set(RUNTIMES_${target}_CMAKE_CXX_FLAGS "--target=${target}" CACHE STRING "")
112109
set(RUNTIMES_${target}_CMAKE_ASM_FLAGS "--target=${target}" CACHE STRING "")
@@ -157,7 +154,6 @@ if(FUCHSIA_SDK)
157154
list(APPEND BUILTIN_TARGETS "${target}")
158155
set(BUILTINS_${target}_CMAKE_SYSTEM_NAME Fuchsia CACHE STRING "")
159156
set(BUILTINS_${target}_CMAKE_BUILD_TYPE RelWithDebInfo CACHE STRING "")
160-
set(BUILTINS_${target}_CMAKE_POSITION_INDEPENDENT_CODE ON CACHE BOOL "")
161157
set(BUILTINS_${target}_CMAKE_ASM_FLAGS ${FUCHSIA_${target}_COMPILER_FLAGS} CACHE STRING "")
162158
set(BUILTINS_${target}_CMAKE_C_FLAGS ${FUCHSIA_${target}_COMPILER_FLAGS} CACHE STRING "")
163159
set(BUILTINS_${target}_CMAKE_CXX_FLAGS ${FUCHSIA_${target}_COMPILER_FLAGS} CACHE STRING "")
@@ -173,7 +169,6 @@ if(FUCHSIA_SDK)
173169
set(RUNTIMES_${target}_CMAKE_SYSTEM_NAME Fuchsia CACHE STRING "")
174170
set(RUNTIMES_${target}_CMAKE_BUILD_TYPE RelWithDebInfo CACHE STRING "")
175171
set(RUNTIMES_${target}_CMAKE_BUILD_WITH_INSTALL_RPATH ON CACHE BOOL "")
176-
set(RUNTIMES_${target}_CMAKE_POSITION_INDEPENDENT_CODE ON CACHE BOOL "")
177172
set(RUNTIMES_${target}_CMAKE_ASM_FLAGS ${FUCHSIA_${target}_COMPILER_FLAGS} CACHE STRING "")
178173
set(RUNTIMES_${target}_CMAKE_C_FLAGS ${FUCHSIA_${target}_COMPILER_FLAGS} CACHE STRING "")
179174
set(RUNTIMES_${target}_CMAKE_CXX_FLAGS ${FUCHSIA_${target}_COMPILER_FLAGS} CACHE STRING "")
@@ -293,6 +288,7 @@ set(LLVM_TOOLCHAIN_TOOLS
293288
set(LLVM_DISTRIBUTION_COMPONENTS
294289
clang
295290
lld
291+
LTO
296292
clang-apply-replacements
297293
clang-doc
298294
clang-format

0 commit comments

Comments
 (0)