Skip to content

[SystemZ/ZOS] Additions to the build system. #74730

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Dec 7, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion llvm/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -581,7 +581,9 @@ set(LLVM_TARGETS_TO_BUILD
${LLVM_EXPERIMENTAL_TARGETS_TO_BUILD})
list(REMOVE_DUPLICATES LLVM_TARGETS_TO_BUILD)

option(LLVM_ENABLE_PIC "Build Position-Independent Code" ON)
if (NOT CMAKE_SYSTEM_NAME MATCHES "OS390")
option(LLVM_ENABLE_PIC "Build Position-Independent Code" ON)
endif()
option(LLVM_ENABLE_MODULES "Compile with C++ modules enabled." OFF)
if(${CMAKE_SYSTEM_NAME} MATCHES "Darwin")
option(LLVM_ENABLE_MODULE_DEBUGGING "Compile with -gmodules." ON)
Expand Down Expand Up @@ -1127,6 +1129,8 @@ if (CMAKE_SYSTEM_NAME MATCHES "OS390")
add_compile_definitions(_XOPEN_SOURCE=600)
add_compile_definitions(_OPEN_SYS) # Needed for process information.
add_compile_definitions(_OPEN_SYS_FILE_EXT) # Needed for EBCDIC I/O.
add_compile_definitions(_EXT) # Needed for file data.
add_compile_definitions("-D_UNIX03_THREADS") # Multithreading support.
endif()

# Build with _FILE_OFFSET_BITS=64 on Solaris to match g++ >= 9.
Expand Down
2 changes: 1 addition & 1 deletion llvm/lib/Transforms/Hello/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ if( NOT LLVM_REQUIRES_RTTI )
endif()
endif()

if(WIN32 OR CYGWIN)
if(WIN32 OR CYGWIN OR ZOS)
set(LLVM_LINK_COMPONENTS Core Support)
endif()

Expand Down
2 changes: 1 addition & 1 deletion llvm/tools/bugpoint-passes/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ if( NOT LLVM_REQUIRES_RTTI )
endif()
endif()

if(WIN32 OR CYGWIN)
if(WIN32 OR CYGWIN OR ZOS)
set(LLVM_LINK_COMPONENTS Core Support)
endif()

Expand Down
3 changes: 3 additions & 0 deletions llvm/tools/llvm-shlib/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,9 @@ if(LLVM_BUILD_LLVM_DYLIB)
if(MSVC)
message(FATAL_ERROR "Generating libLLVM is not supported on MSVC")
endif()
if(ZOS)
message(FATAL_ERROR "Generating libLLVM is not supported on z/OS")
endif()

llvm_map_components_to_libnames(LIB_NAMES ${LLVM_DYLIB_COMPONENTS})

Expand Down