Skip to content
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

Allow SKIP_EXAMPLE build Update CMakeLists.txt - default is still build example #861

Closed
wants to merge 7 commits into from
Closed
Changes from 1 commit
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
Prev Previous commit
Update CMakeLists.txt
  • Loading branch information
danoli3 authored Dec 1, 2023
commit 90221fd99d58babd967d814b5249fdfb73b8dcf2
18 changes: 14 additions & 4 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -127,12 +127,22 @@ if(BUILD_STATIC_LIBS)
endif()

if(NOT CYGWIN)
set_target_properties(zlib zlibstatic PROPERTIES OUTPUT_NAME z)
if(NOT APPLE)
set_target_properties(zlib PROPERTIES LINK_FLAGS "-Wl,--version-script,\"${CMAKE_CURRENT_SOURCE_DIR}/zlib.map\"")
if(BUILD_SHARED_LIBS)
set_target_properties(zlib PROPERTIES OUTPUT_NAME z)
if(NOT APPLE)
set_target_properties(zlib PROPERTIES LINK_FLAGS "-Wl,--version-script,\"${CMAKE_CURRENT_SOURCE_DIR}/zlib.map\"")
endif()
endif()
if(BUILD_STATIC_LIBS)
set_target_properties(zlibstatic PROPERTIES OUTPUT_NAME z)
if(NOT APPLE)
set_target_properties(zlibstatic PROPERTIES LINK_FLAGS "-Wl,--version-script,\"${CMAKE_CURRENT_SOURCE_DIR}/zlib.map\"")
endif()
endif()
elseif(BUILD_SHARED_LIBS AND WIN32)
set_target_properties(zlib PROPERTIES SUFFIX "1.dll")
if(BUILD_SHARED_LIBS)
set_target_properties(zlib PROPERTIES SUFFIX "1.dll")
endif()
endif()

if(NOT SKIP_INSTALL_LIBRARIES AND NOT SKIP_INSTALL_ALL)
Expand Down