summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAllen Byrne <byrn@hdfgroup.org>2017-09-20 14:10:10 (GMT)
committerAllen Byrne <byrn@hdfgroup.org>2017-09-20 14:10:10 (GMT)
commita38741646fd9a218f9f8ea03d337d20b6cf12a05 (patch)
tree40dca311594df939d454847161255b4732f0c1f4
parent8a2d4c8094ce96747b3d0f024b8ad45d0a1e920a (diff)
parent0a9bc574e8d40b51c0c1c16501d3a0365e08df91 (diff)
downloadhdf5-a38741646fd9a218f9f8ea03d337d20b6cf12a05.zip
hdf5-a38741646fd9a218f9f8ea03d337d20b6cf12a05.tar.gz
hdf5-a38741646fd9a218f9f8ea03d337d20b6cf12a05.tar.bz2
Merge pull request #676 in HDFFV/hdf5 from ~BYRN/hdf5_adb:develop to develop
* commit '0a9bc574e8d40b51c0c1c16501d3a0365e08df91': Fix find package process
-rw-r--r--config/cmake/hdf5-config.cmake.in16
1 files changed, 14 insertions, 2 deletions
diff --git a/config/cmake/hdf5-config.cmake.in b/config/cmake/hdf5-config.cmake.in
index 904c083..712dc05 100644
--- a/config/cmake/hdf5-config.cmake.in
+++ b/config/cmake/hdf5-config.cmake.in
@@ -158,9 +158,17 @@ foreach (libtype IN LISTS ${HDF5_PACKAGE_NAME}_LIB_TYPE)
set (hdf5_comp2 "hdf5_hl_f90cstub")
set (hdf5_comp "hdf5_hl_fortran")
endif ()
- list (FIND ${HDF5_PACKAGE_NAME}_EXPORT_LIBRARIES "${hdf5_comp}-${libtype}" HAVE_COMP)
+ if (${comp} STREQUAL "Java")
+ list (FIND ${HDF5_PACKAGE_NAME}_EXPORT_LIBRARIES "${hdf5_comp}" HAVE_COMP)
+ else ()
+ list (FIND ${HDF5_PACKAGE_NAME}_EXPORT_LIBRARIES "${hdf5_comp}-${libtype}" HAVE_COMP)
+ endif ()
if (${HAVE_COMP} LESS 0)
- set (${HDF5_PACKAGE_NAME}_${libtype}_${comp}_FOUND 0)
+ if (${comp} STREQUAL "Java")
+ set (${HDF5_PACKAGE_NAME}_${comp}_FOUND 0)
+ else ()
+ set (${HDF5_PACKAGE_NAME}_${libtype}_${comp}_FOUND 0)
+ endif ()
else ()
if (hdf5_comp2)
list (FIND ${HDF5_PACKAGE_NAME}_EXPORT_LIBRARIES "${hdf5_comp2}-${libtype}" HAVE_COMP2)
@@ -171,6 +179,10 @@ foreach (libtype IN LISTS ${HDF5_PACKAGE_NAME}_LIB_TYPE)
string(TOUPPER ${HDF5_PACKAGE_NAME}_${comp}_${libtype}_LIBRARY COMP_LIBRARY)
set (${COMP_LIBRARY} ${${COMP_LIBRARY}} @HDF5_PACKAGE@::${hdf5_comp2}-${libtype} @HDF5_PACKAGE@::${hdf5_comp}-${libtype})
endif ()
+ elseif (${comp} STREQUAL "Java")
+ set (${HDF5_PACKAGE_NAME}_${comp}_FOUND 1)
+ string(TOUPPER ${HDF5_PACKAGE_NAME}_${comp}_LIBRARY COMP_LIBRARY)
+ set (${COMP_LIBRARY} ${${COMP_LIBRARY}} hdf5::${hdf5_comp})
else ()
set (${HDF5_PACKAGE_NAME}_${libtype}_${comp}_FOUND 1)
string(TOUPPER ${HDF5_PACKAGE_NAME}_${comp}_${libtype}_LIBRARY COMP_LIBRARY)