aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlexander Neumann <30894796+Neumann-A@users.noreply.github.com>2019-08-07 22:40:33 +0200
committerCurtis J Bezault <curtbezault@gmail.com>2019-08-07 16:40:33 -0400
commitc89dcc15a9b93b022990c972b7e0beb8d20b6629 (patch)
treed595e73ac452417b5d4a20c61802ad65c02ce549
parent8157d8503c2c346d0e09d3405609aeefefb64012 (diff)
downloadvcpkg-c89dcc15a9b93b022990c972b7e0beb8d20b6629.tar.gz
vcpkg-c89dcc15a9b93b022990c972b7e0beb8d20b6629.zip
[netcdf-c] correctly fix hdf5 linkage (#7578)
-rw-r--r--ports/netcdf-c/CONTROL2
-rw-r--r--ports/netcdf-c/hdf5_3.patch8
2 files changed, 6 insertions, 4 deletions
diff --git a/ports/netcdf-c/CONTROL b/ports/netcdf-c/CONTROL
index 684c54ba6..f69dc61ad 100644
--- a/ports/netcdf-c/CONTROL
+++ b/ports/netcdf-c/CONTROL
@@ -1,5 +1,5 @@
Source: netcdf-c
-Version: 4.7.0-3
+Version: 4.7.0-4
Build-Depends: hdf5, curl
Homepage: https://github.com/Unidata/netcdf-c
Description: a set of self-describing, machine-independent data formats that support the creation, access, and sharing of array-oriented scientific data.
diff --git a/ports/netcdf-c/hdf5_3.patch b/ports/netcdf-c/hdf5_3.patch
index ba9a168c8..502a8ea99 100644
--- a/ports/netcdf-c/hdf5_3.patch
+++ b/ports/netcdf-c/hdf5_3.patch
@@ -2,11 +2,13 @@ diff --git a/libhdf5/CMakeLists.txt b/libhdf5/CMakeLists.txt
index f3c7bbc..34fc2ab 100644
--- a/libhdf5/CMakeLists.txt
+++ b/libhdf5/CMakeLists.txt
-@@ -20,3 +20,7 @@ add_library(netcdfhdf5 OBJECT ${libnchdf5_SOURCES})
+@@ -20,3 +20,9 @@ add_library(netcdfhdf5 OBJECT ${libnchdf5_SOURCES})
# Remember to package this file for CMake builds.
ADD_EXTRA_DIST(${libnchdf5_SOURCES} CMakeLists.txt)
+
-+if(BUILD_SHARED_LIBS)
-+target_link_libraries(netcdfhdf5 PRIVATE hdf5::hdf5-shared hdf5::hdf5-static hdf5::hdf5_hl-shared hdf5::hdf5_hl-static)
++if(HDF5_BUILD_SHARED_LIBS)
++ target_link_libraries(netcdfhdf5 PRIVATE hdf5::hdf5-shared hdf5::hdf5_hl-shared)
++else()
++ target_link_libraries(netcdfhdf5 PRIVATE hdf5::hdf5-static hdf5::hdf5_hl-static)
+endif()