Skip to content

Commit

Permalink
Fix cmake build on AIX.
Browse files Browse the repository at this point in the history
The --version-script linker option is not supported by the linker on AIX systems
  • Loading branch information
gastush authored and madler committed Jan 18, 2024
1 parent 2526346 commit ade6825
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -185,7 +185,7 @@ endif()
if(UNIX)
# On unix-like platforms the library is almost always called libz
set_target_properties(zlib zlibstatic PROPERTIES OUTPUT_NAME z)
if(NOT APPLE)
if(NOT APPLE AND NOT(CMAKE_SYSTEM_NAME STREQUAL AIX))
set_target_properties(zlib PROPERTIES LINK_FLAGS "-Wl,--version-script,\"${CMAKE_CURRENT_SOURCE_DIR}/zlib.map\"")
endif()
elseif(BUILD_SHARED_LIBS AND WIN32)
Expand Down

0 comments on commit ade6825

Please sign in to comment.