Skip to content

Commit

Permalink
Merge pull request #448 from potassco/revert-447-fix/hide-symbols
Browse files Browse the repository at this point in the history
Revert "Hide more symbols in ELF shared libs"
  • Loading branch information
rkaminsk authored Aug 12, 2023
2 parents 488f3b7 + a074343 commit ec2c706
Show file tree
Hide file tree
Showing 3 changed files with 0 additions and 19 deletions.
11 changes: 0 additions & 11 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@ if (NOT CMAKE_BUILD_TYPE AND NOT CMAKE_CONFIGURATION_TYPES)
set(CMAKE_BUILD_TYPE "Release")
endif()

include(CheckCXXSourceCompiles)
include(GNUInstallDirs)
include(CMakeDependentOption)
list(APPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/cmake")
Expand Down Expand Up @@ -240,16 +239,6 @@ if (POLICY CMP0063 AND (CLINGO_BUILD_SHARED OR Python_Development_FOUND OR LUA_F
set(CMAKE_C_VISIBILITY_PRESET hidden)
endif()

# Test support for -Wl,--version-script as a linker flag
if (CLINGO_BUILD_SHARED AND UNIX AND NOT APPLE)
file(WRITE "${CMAKE_CURRENT_BINARY_DIR}/version.map" "{global: f; local: *;};")
set(CMAKE_REQUIRED_FLAGS_SAVE ${CMAKE_REQUIRED_FLAGS})
set(CMAKE_REQUIRED_FLAGS ${CMAKE_REQUIRED_FLAGS} "-Wl,--version-script='${CMAKE_CURRENT_BINARY_DIR}/version.map'")
check_cxx_source_compiles("void f(){} int main(){}" CLINGO_USE_VERSION_SCRIPT)
set(CMAKE_REQUIRED_FLAGS ${CMAKE_REQUIRED_FLAGS_SAVE})
file(REMOVE "${CMAKE_CURRENT_BINARY_DIR}/version.map")
endif()

enable_testing()

if (CLINGO_USE_LIB)
Expand Down
4 changes: 0 additions & 4 deletions libclingo/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -58,10 +58,6 @@ target_include_directories(libclingo
"$<INSTALL_INTERFACE:${CMAKE_INSTALL_INCLUDEDIR}>")
target_compile_definitions(libclingo ${clingo_private_scope_} CLINGO_BUILD_LIBRARY)

if (CLINGO_USE_VERSION_SCRIPT)
set_target_properties(libclingo PROPERTIES LINK_FLAGS "-Wl,--version-script='${CMAKE_CURRENT_SOURCE_DIR}/clingo.map'")
endif()

if (NOT CLINGO_BUILD_SHARED)
target_compile_definitions(libclingo PUBLIC CLINGO_NO_VISIBILITY)
endif()
Expand Down
4 changes: 0 additions & 4 deletions libclingo/clingo.map

This file was deleted.

0 comments on commit ec2c706

Please sign in to comment.