mirror of
https://github.com/cemu-project/vcpkg.git
synced 2025-02-22 18:47:09 +01:00
[hdf5] Mark linked libraries as private
This commit is contained in:
parent
601b167610
commit
2c9cf2a520
@ -1,4 +1,4 @@
|
||||
Source: hdf5
|
||||
Version: 1.10.0-patch1
|
||||
Version: 1.10.0-patch1-1
|
||||
Description: HDF5 is a data model, library, and file format for storing and managing data
|
||||
Build-Depends: zlib, szip, msmpi
|
29
ports/hdf5/link-libraries-private.patch
Normal file
29
ports/hdf5/link-libraries-private.patch
Normal file
@ -0,0 +1,29 @@
|
||||
diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
|
||||
index a63cc3a..aea963d 100644
|
||||
--- a/src/CMakeLists.txt
|
||||
+++ b/src/CMakeLists.txt
|
||||
@@ -900,12 +900,12 @@ if (BUILD_SHARED_LIBS)
|
||||
set (shared_gen_SRCS ${HDF5_BINARY_DIR}/shared/H5Tinit.c ${HDF5_BINARY_DIR}/shared/H5lib_settings.c)
|
||||
add_library (${HDF5_LIBSH_TARGET} SHARED ${common_SRCS} ${shared_gen_SRCS} ${H5_PUBLIC_HEADERS} ${H5_PRIVATE_HEADERS} ${H5_GENERATED_HEADERS})
|
||||
TARGET_C_PROPERTIES (${HDF5_LIBSH_TARGET} SHARED " " " ")
|
||||
- target_link_libraries (${HDF5_LIBSH_TARGET} ${LINK_SHARED_LIBS})
|
||||
+ target_link_libraries (${HDF5_LIBSH_TARGET} PRIVATE ${LINK_SHARED_LIBS})
|
||||
if (NOT WIN32)
|
||||
- target_link_libraries (${HDF5_LIBSH_TARGET} dl)
|
||||
+ target_link_libraries (${HDF5_LIBSH_TARGET} PRIVATE dl)
|
||||
endif (NOT WIN32)
|
||||
if (H5_HAVE_PARALLEL AND MPI_C_FOUND)
|
||||
- target_link_libraries (${HDF5_LIBSH_TARGET} ${MPI_C_LIBRARIES})
|
||||
+ target_link_libraries (${HDF5_LIBSH_TARGET} PRIVATE ${MPI_C_LIBRARIES})
|
||||
endif (H5_HAVE_PARALLEL AND MPI_C_FOUND)
|
||||
set_global_variable (HDF5_LIBRARIES_TO_EXPORT "${HDF5_LIBRARIES_TO_EXPORT};${HDF5_LIBSH_TARGET}")
|
||||
H5_SET_LIB_OPTIONS (${HDF5_LIBSH_TARGET} ${HDF5_LIB_NAME} SHARED ${HDF5_PACKAGE_SOVERSION})
|
||||
@@ -920,7 +920,7 @@ if (BUILD_SHARED_LIBS)
|
||||
APPEND PROPERTY COMPILE_DEFINITIONS
|
||||
"H5_HAVE_THREADSAFE"
|
||||
)
|
||||
- target_link_libraries (${HDF5_LIBSH_TARGET} Threads::Threads)
|
||||
+ target_link_libraries (${HDF5_LIBSH_TARGET} PRIVATE Threads::Threads)
|
||||
endif (HDF5_ENABLE_THREADSAFE)
|
||||
|
||||
if (HDF5_ENABLE_DEBUG_APIS)
|
@ -27,6 +27,7 @@ vcpkg_apply_patches(
|
||||
PATCHES
|
||||
${CMAKE_CURRENT_LIST_DIR}/use-szip-config.patch
|
||||
${CMAKE_CURRENT_LIST_DIR}/disable-static-libs.patch
|
||||
${CMAKE_CURRENT_LIST_DIR}/link-libraries-private.patch
|
||||
)
|
||||
|
||||
set(DISABLE_STATIC_LIBS OFF)
|
||||
|
Loading…
x
Reference in New Issue
Block a user