Skip to content

Commit f73da64

Browse files
authored
Revert "[compiler-rt] Disable LLVM_ENABLE_PER_TARGET_RUNTIME_DIR=ON on AIX. (#131200)" (#132574)
… This reverts commit 8e773d8.
1 parent f3f0b99 commit f73da64

File tree

3 files changed

+4
-18
lines changed

3 files changed

+4
-18
lines changed

compiler-rt/cmake/base-config-ix.cmake

+1-1
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,7 @@ if(LLVM_ENABLE_PER_TARGET_RUNTIME_DIR AND NOT APPLE)
109109
extend_path(default_install_path "${COMPILER_RT_INSTALL_PATH}" lib)
110110
set(COMPILER_RT_INSTALL_LIBRARY_DIR "${default_install_path}" CACHE PATH
111111
"Path where built compiler-rt libraries should be installed.")
112-
else()
112+
else(LLVM_ENABLE_PER_TARGET_RUNTIME_DIR AND NOT APPLE)
113113
set(COMPILER_RT_OUTPUT_LIBRARY_DIR
114114
${COMPILER_RT_OUTPUT_DIR}/lib/${COMPILER_RT_OS_DIR})
115115
extend_path(default_install_path "${COMPILER_RT_INSTALL_PATH}" "lib/${COMPILER_RT_OS_DIR}")

llvm/CMakeLists.txt

+3-10
Original file line numberDiff line numberDiff line change
@@ -1186,23 +1186,16 @@ endif()
11861186
# Build with _XOPEN_SOURCE on AIX, as stray macros in _ALL_SOURCE mode tend to
11871187
# break things. In this case we need to enable the large-file API as well.
11881188
if (UNIX AND ${CMAKE_SYSTEM_NAME} MATCHES "AIX")
1189-
add_compile_definitions(_XOPEN_SOURCE=700)
1190-
add_compile_definitions(_LARGE_FILE_API)
1191-
add_compile_options(-pthread)
1189+
add_compile_definitions(_XOPEN_SOURCE=700)
1190+
add_compile_definitions(_LARGE_FILE_API)
1191+
add_compile_options(-pthread)
11921192

11931193
# Modules should be built with -shared -Wl,-G, so we can use runtime linking
11941194
# with plugins.
11951195
string(APPEND CMAKE_MODULE_LINKER_FLAGS " -shared -Wl,-G")
11961196

11971197
# Also set the correct flags for building shared libraries.
11981198
string(APPEND CMAKE_SHARED_LINKER_FLAGS " -shared")
1199-
1200-
# Set LLVM_ENABLE_PER_TARGET_RUNTIME_DIR=OFF as AIX doesn't support it
1201-
if (LLVM_ENABLE_PER_TARGET_RUNTIME_DIR)
1202-
message(WARNING
1203-
"LLVM_ENABLE_PER_TARGET_RUNTIME_DIR=ON is not supported on AIX. LLVM_ENABLE_PER_TARGET_RUNTIME_DIR is set to OFF.")
1204-
set(LLVM_ENABLE_PER_TARGET_RUNTIME_DIR OFF CACHE BOOL "" FORCE)
1205-
endif()
12061199
endif()
12071200

12081201
# Build with _XOPEN_SOURCE on z/OS.

runtimes/CMakeLists.txt

-7
Original file line numberDiff line numberDiff line change
@@ -223,13 +223,6 @@ endif()
223223
# This can be used to detect whether we're in the runtimes build.
224224
set(LLVM_RUNTIMES_BUILD ON)
225225

226-
if (LLVM_ENABLE_PER_TARGET_RUNTIME_DIR AND UNIX AND ${CMAKE_SYSTEM_NAME} MATCHES "AIX")
227-
# Set LLVM_ENABLE_PER_TARGET_RUNTIME_DIR=OFF as AIX doesn't support it
228-
message(WARNING
229-
"LLVM_ENABLE_PER_TARGET_RUNTIME_DIR=ON is not supported on AIX. LLVM_ENABLE_PER_TARGET_RUNTIME_DIR is set to OFF.")
230-
set(LLVM_ENABLE_PER_TARGET_RUNTIME_DIR OFF CACHE BOOL "" FORCE)
231-
endif()
232-
233226
foreach(entry ${runtimes})
234227
get_filename_component(projName ${entry} NAME)
235228

0 commit comments

Comments
 (0)