papilo/papilo-shared.patch
2024-06-19 08:58:50 -06:00

29 lines
1.1 KiB
Diff

--- papilo-2.2.1/CMakeLists.txt.orig 2024-06-07 12:08:24.745855052 -0600
+++ papilo-2.2.1/CMakeLists.txt 2024-06-07 12:09:20.649152731 -0600
@@ -28,8 +28,6 @@ include(GNUInstallDirs)
# path to e.g. findGMP module
list(APPEND CMAKE_MODULE_PATH ${PROJECT_SOURCE_DIR}/cmake/Modules/)
-set(CMAKE_CXX_VISIBILITY_PRESET hidden)
-set(CMAKE_VISIBILITY_INLINES_HIDDEN 1)
set(CMAKE_POSITION_INDEPENDENT_CODE ON)
# disable fused floating point contraction to enhance reproducibility across compilers and architectures
@@ -224,7 +222,7 @@ if(NOT MSVC)
endif()
set(PAPILO_USE_STANDARD_HASHMAP 1)
-add_library(papilo-core STATIC
+add_library(papilo-core SHARED
src/papilo/core/VariableDomains.cpp
src/papilo/core/SparseStorage.cpp
src/papilo/core/ConstraintMatrix.cpp
@@ -259,6 +257,7 @@ add_library(papilo-core STATIC
function(setLibProperties targetname outputname)
set_target_properties(${targetname} PROPERTIES
OUTPUT_NAME ${outputname}
+ POSITION_INDEPENDENT_CODE ON VERSION 0.0.0 SOVERSION 0
MACOSX_RPATH "${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_LIBDIR}")
endfunction(setLibProperties)
if(MSVC)