2019-06-21 13:08:51 +08:00
|
|
|
diff --git a/libhdf5/CMakeLists.txt b/libhdf5/CMakeLists.txt
|
|
|
|
index f3c7bbc..34fc2ab 100644
|
|
|
|
--- a/libhdf5/CMakeLists.txt
|
|
|
|
+++ b/libhdf5/CMakeLists.txt
|
2019-08-08 04:40:33 +08:00
|
|
|
@@ -20,3 +20,9 @@ add_library(netcdfhdf5 OBJECT ${libnchdf5_SOURCES})
|
2019-06-21 13:08:51 +08:00
|
|
|
|
|
|
|
# Remember to package this file for CMake builds.
|
|
|
|
ADD_EXTRA_DIST(${libnchdf5_SOURCES} CMakeLists.txt)
|
|
|
|
+
|
2019-08-08 04:40:33 +08:00
|
|
|
+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)
|
2019-06-21 13:08:51 +08:00
|
|
|
+endif()
|