summaryrefslogtreecommitdiffstats
path: root/hl
diff options
context:
space:
mode:
Diffstat (limited to 'hl')
-rw-r--r--hl/CMakeLists.txt8
-rw-r--r--hl/c++/examples/CMakeLists.txt4
-rw-r--r--hl/c++/src/CMakeLists.txt31
-rw-r--r--hl/c++/test/CMakeLists.txt4
-rw-r--r--hl/examples/CMakeLists.txt4
-rw-r--r--hl/fortran/examples/CMakeLists.txt6
-rw-r--r--hl/fortran/src/CMakeLists.txt177
-rw-r--r--hl/fortran/test/CMakeLists.txt80
-rw-r--r--hl/fortran/test/CMakeTests.cmake31
-rw-r--r--hl/src/CMakeLists.txt33
-rw-r--r--hl/test/CMakeLists.txt20
-rw-r--r--hl/tools/CMakeLists.txt17
12 files changed, 313 insertions, 102 deletions
diff --git a/hl/CMakeLists.txt b/hl/CMakeLists.txt
index b5d4308..bed8291 100644
--- a/hl/CMakeLists.txt
+++ b/hl/CMakeLists.txt
@@ -6,14 +6,6 @@ PROJECT (HDF5_HL C CXX)
#-----------------------------------------------------------------------------
add_definitions (${HDF_EXTRA_C_FLAGS})
-#-----------------------------------------------------------------------------
-# Shared Libs
-#-----------------------------------------------------------------------------
-if (BUILD_SHARED_LIBS)
- set (HL_BUILT_AS_DYNAMIC_LIB 1)
-else (BUILD_SHARED_LIBS)
- set (HL_BUILT_AS_STATIC_LIB 1)
-endif (BUILD_SHARED_LIBS)
#-----------------------------------------------------------------------------
# List Source files
diff --git a/hl/c++/examples/CMakeLists.txt b/hl/c++/examples/CMakeLists.txt
index e3fc3ae..77a50bf 100644
--- a/hl/c++/examples/CMakeLists.txt
+++ b/hl/c++/examples/CMakeLists.txt
@@ -11,8 +11,8 @@ INCLUDE_DIRECTORIES (${HDF5_HL_CPP_SRC_DIR}/src)
# Add in the examples for the Packet Table codes
# --------------------------------------------------------------------
add_executable (ptExampleFL ${HDF5_HL_CPP_EXAMPLES_SOURCE_DIR}/ptExampleFL.cpp)
-TARGET_NAMING (ptExampleFL ${LIB_TYPE})
-TARGET_C_PROPERTIES (ptExampleFL ${LIB_TYPE} " " " ")
+TARGET_NAMING (ptExampleFL STATIC)
+TARGET_C_PROPERTIES (ptExampleFL STATIC " " " ")
target_link_libraries (
ptExampleFL
${HDF5_HL_CPP_LIB_TARGET}
diff --git a/hl/c++/src/CMakeLists.txt b/hl/c++/src/CMakeLists.txt
index 640cb2d..e37c5ba 100644
--- a/hl/c++/src/CMakeLists.txt
+++ b/hl/c++/src/CMakeLists.txt
@@ -10,19 +10,39 @@ INCLUDE_DIRECTORIES (${HDF5_HL_CPP_SRC_SOURCE_DIR})
set (HDF5_HL_CPP_SRCS ${HDF5_HL_CPP_SRC_SOURCE_DIR}/H5PacketTable.cpp)
set (HDF5_HL_CPP_HDRS ${HDF5_HL_CPP_SRC_SOURCE_DIR}/H5PacketTable.h)
-add_library (${HDF5_HL_CPP_LIB_TARGET} ${LIB_TYPE} ${HDF5_HL_CPP_SRCS})
-TARGET_C_PROPERTIES (${HDF5_HL_CPP_LIB_TARGET} ${LIB_TYPE} " " " ")
+add_library (${HDF5_HL_CPP_LIB_TARGET} STATIC ${HDF5_HL_CPP_SRCS})
+TARGET_C_PROPERTIES (${HDF5_HL_CPP_LIB_TARGET} STATIC " " " ")
target_link_libraries (
${HDF5_HL_CPP_LIB_TARGET}
${HDF5_HL_LIB_TARGET}
${HDF5_LIB_TARGET}
)
set_global_variable (HDF5_LIBRARIES_TO_EXPORT "${HDF5_LIBRARIES_TO_EXPORT};${HDF5_HL_CPP_LIB_TARGET}")
-H5_SET_LIB_OPTIONS (${HDF5_HL_CPP_LIB_TARGET} ${HDF5_HL_CPP_LIB_NAME} ${LIB_TYPE})
+H5_SET_LIB_OPTIONS (${HDF5_HL_CPP_LIB_TARGET} ${HDF5_HL_CPP_LIB_NAME} STATIC)
set_target_properties (${HDF5_HL_CPP_LIB_TARGET} PROPERTIES
FOLDER libraries/hl
INTERFACE_INCLUDE_DIRECTORIES "$<INSTALL_INTERFACE:$<INSTALL_PREFIX>/include>"
)
+set (install_targets ${HDF5_HL_CPP_LIB_TARGET})
+
+if (BUILD_SHARED_LIBS)
+ add_library (${HDF5_HL_CPP_LIBSH_TARGET} SHARED ${HDF5_HL_CPP_SRCS})
+ TARGET_C_PROPERTIES (${HDF5_HL_CPP_LIBSH_TARGET} SHARED " " " ")
+ target_link_libraries (
+ ${HDF5_HL_CPP_LIBSH_TARGET}
+ ${HDF5_HL_LIBSH_TARGET}
+ ${HDF5_LIBSH_TARGET}
+ )
+ set_global_variable (HDF5_LIBRARIES_TO_EXPORT "${HDF5_LIBRARIES_TO_EXPORT};${HDF5_HL_CPP_LIBSH_TARGET}")
+ H5_SET_LIB_OPTIONS (${HDF5_HL_CPP_LIBSH_TARGET} ${HDF5_HL_CPP_LIB_NAME} SHARED)
+ set_target_properties (${HDF5_HL_CPP_LIBSH_TARGET} PROPERTIES
+ FOLDER libraries/hl
+ COMPILE_DEFINITIONS "H5_BUILT_AS_DYNAMIC_LIB"
+ INTERFACE_INCLUDE_DIRECTORIES "$<INSTALL_INTERFACE:$<INSTALL_PREFIX>/include>"
+ INTERFACE_COMPILE_DEFINITIONS H5_BUILT_AS_DYNAMIC_LIB=1
+ )
+ set (install_targets ${install_targets} ${HDF5_HL_CPP_LIBSH_TARGET})
+endif (BUILD_SHARED_LIBS)
#-----------------------------------------------------------------------------
# Add file(s) to CMake Install
@@ -41,16 +61,17 @@ install (
#-----------------------------------------------------------------------------
if (HDF5_EXPORTED_TARGETS)
if (BUILD_SHARED_LIBS)
- INSTALL_TARGET_PDB (${HDF5_HL_CPP_LIB_TARGET} ${HDF5_INSTALL_BIN_DIR} hlcpplibraries)
+ INSTALL_TARGET_PDB (${HDF5_HL_CPP_LIBSH_TARGET} ${HDF5_INSTALL_BIN_DIR} hlcpplibraries)
endif (BUILD_SHARED_LIBS)
install (
TARGETS
- ${HDF5_HL_CPP_LIB_TARGET}
+ ${install_targets}
EXPORT
${HDF5_EXPORTED_TARGETS}
LIBRARY DESTINATION ${HDF5_INSTALL_LIB_DIR} COMPONENT hlcpplibraries
ARCHIVE DESTINATION ${HDF5_INSTALL_LIB_DIR} COMPONENT hlcpplibraries
RUNTIME DESTINATION ${HDF5_INSTALL_BIN_DIR} COMPONENT hlcpplibraries
+ FRAMEWORK DESTINATION ${HDF5_INSTALL_FWRK_DIR} COMPONENT hlcpplibraries
)
endif (HDF5_EXPORTED_TARGETS)
diff --git a/hl/c++/test/CMakeLists.txt b/hl/c++/test/CMakeLists.txt
index ff06b22..de5b363 100644
--- a/hl/c++/test/CMakeLists.txt
+++ b/hl/c++/test/CMakeLists.txt
@@ -16,8 +16,8 @@ INCLUDE_DIRECTORIES (${HDF5_HL_SRC_DIR}/test)
INCLUDE_DIRECTORIES (${HDF5_CPP_SRC_DIR}/src)
add_executable (hl_ptableTest ${HDF5_HL_CPP_TEST_SOURCE_DIR}/ptableTest.cpp)
-TARGET_C_PROPERTIES (hl_ptableTest ${LIB_TYPE} " " " ")
-TARGET_NAMING (hl_ptableTest ${LIB_TYPE})
+TARGET_C_PROPERTIES (hl_ptableTest STATIC " " " ")
+TARGET_NAMING (hl_ptableTest STATIC)
target_link_libraries (
hl_ptableTest
${HDF5_LIB_TARGET}
diff --git a/hl/examples/CMakeLists.txt b/hl/examples/CMakeLists.txt
index e264f75..f5e6f5e 100644
--- a/hl/examples/CMakeLists.txt
+++ b/hl/examples/CMakeLists.txt
@@ -28,8 +28,8 @@ set (examples
foreach (example ${examples})
add_executable (hl_ex_${example} ${HDF5_HL_EXAMPLES_SOURCE_DIR}/${example}.c)
- TARGET_NAMING (hl_ex_${example} ${LIB_TYPE})
- TARGET_C_PROPERTIES (hl_ex_${example} ${LIB_TYPE} " " " ")
+ TARGET_NAMING (hl_ex_${example} STATIC)
+ TARGET_C_PROPERTIES (hl_ex_${example} STATIC " " " ")
target_link_libraries (hl_ex_${example} ${HDF5_HL_LIB_TARGET} ${HDF5_LIB_TARGET})
set_target_properties (hl_ex_${example} PROPERTIES FOLDER examples/hl)
endforeach (example ${examples})
diff --git a/hl/fortran/examples/CMakeLists.txt b/hl/fortran/examples/CMakeLists.txt
index bded2d9..87838a0 100644
--- a/hl/fortran/examples/CMakeLists.txt
+++ b/hl/fortran/examples/CMakeLists.txt
@@ -16,14 +16,14 @@ set (examples
foreach (example ${examples})
add_executable (hl_f90_ex_${example} ${HDF5_HL_F90_EXAMPLES_SOURCE_DIR}/${example}.f90)
- TARGET_NAMING (hl_f90_ex_${example} ${LIB_TYPE})
- TARGET_FORTRAN_PROPERTIES (hl_f90_ex_${example} ${LIB_TYPE} " " " ")
+ TARGET_NAMING (hl_f90_ex_${example} STATIC)
+ TARGET_FORTRAN_PROPERTIES (hl_f90_ex_${example} STATIC " " " ")
target_link_libraries (hl_f90_ex_${example}
${HDF5_HL_F90_LIB_TARGET}
${HDF5_F90_LIB_TARGET}
${HDF5_LIB_TARGET}
)
- target_include_directories (hl_f90_ex_${example} PRIVATE ${CMAKE_Fortran_MODULE_DIRECTORY})
+ target_include_directories (hl_f90_ex_${example} PRIVATE ${CMAKE_Fortran_MODULE_DIRECTORY}/static)
set_target_properties (hl_f90_ex_${example} PROPERTIES LINKER_LANGUAGE Fortran)
set_target_properties (hl_f90_ex_${example} PROPERTIES FOLDER examples/hl/fortran)
diff --git a/hl/fortran/src/CMakeLists.txt b/hl/fortran/src/CMakeLists.txt
index 6e6e44a..9d110a8 100644
--- a/hl/fortran/src/CMakeLists.txt
+++ b/hl/fortran/src/CMakeLists.txt
@@ -2,12 +2,48 @@ cmake_minimum_required (VERSION 3.1.0)
PROJECT(HDF5_HL_F90_SRC C CXX Fortran)
#-----------------------------------------------------------------------------
+# configure def file for shared libs on windows
+if (WIN32)
+ if (BUILD_SHARED_LIBS)
+ if (MSVC)
+ configure_file (${HDF5_HL_F90_SRC_SOURCE_DIR}/hdf5_hl_fortrandll.def.in ${HDF5_HL_F90_SRC_BINARY_DIR}/hdf5_hl_fortrandll.def @ONLY)
+ endif (MSVC)
+ endif (BUILD_SHARED_LIBS)
+endif (WIN32)
+
+#-----------------------------------------------------------------------------
+# Generate the H5LT and H5TB REAL APIs
+#-----------------------------------------------------------------------------
+
+add_executable (H5HL_buildiface
+ ${HDF5_HL_F90_SRC_SOURCE_DIR}/H5HL_buildiface.F90
+ )
+
+if (WIN32 AND MSVC)
+ if (BUILD_SHARED_LIBS)
+ set_target_properties (H5HL_buildiface
+ PROPERTIES
+ COMPILE_FLAGS "/MT"
+ )
+ endif (BUILD_SHARED_LIBS)
+ set_target_properties (H5HL_buildiface
+ PROPERTIES
+ LINK_FLAGS "/SUBSYSTEM:CONSOLE"
+ )
+endif (WIN32 AND MSVC)
+set_target_properties (H5HL_buildiface PROPERTIES
+ LINKER_LANGUAGE Fortran
+ Fortran_MODULE_DIRECTORY ${CMAKE_Fortran_MODULE_DIRECTORY}
+)
+
+#-----------------------------------------------------------------------------
# Setup include Directories
#-----------------------------------------------------------------------------
INCLUDE_DIRECTORIES (
${HDF5_HL_SRC_DIR}/src
${HDF5_F90_SRC_DIR}/src
${HDF5_F90_BINARY_DIR}
+ ${CMAKE_Fortran_MODULE_DIRECTORY}
)
#-----------------------------------------------------------------------------
@@ -24,72 +60,135 @@ set_source_files_properties (${HDF5_HL_F90_C_SRCS} PROPERTIES LANGUAGE C)
set (HDF5_HL_F90_HEADERS ${HDF5_HL_F90_SRC_SOURCE_DIR}/H5LTf90proto.h)
-add_library (${HDF5_HL_F90_C_LIB_TARGET} ${LIB_TYPE} ${HDF5_HL_F90_C_SRCS} ${HDF5_HL_F90_HEADERS})
-TARGET_C_PROPERTIES (${HDF5_HL_F90_C_LIB_TARGET} ${LIB_TYPE} " " " ")
+add_library (${HDF5_HL_F90_C_LIB_TARGET} STATIC ${HDF5_HL_F90_C_SRCS} ${HDF5_HL_F90_HEADERS})
+TARGET_C_PROPERTIES (${HDF5_HL_F90_C_LIB_TARGET} STATIC " " " ")
target_link_libraries (${HDF5_HL_F90_C_LIB_TARGET} ${HDF5_F90_C_LIB_TARGET} ${HDF5_HL_LIB_TARGET})
set_global_variable (HDF5_LIBRARIES_TO_EXPORT "${HDF5_LIBRARIES_TO_EXPORT};${HDF5_HL_F90_C_LIB_TARGET}")
-H5_SET_LIB_OPTIONS (${HDF5_HL_F90_C_LIB_TARGET} ${HDF5_HL_F90_C_LIB_NAME} ${LIB_TYPE})
+H5_SET_LIB_OPTIONS (${HDF5_HL_F90_C_LIB_TARGET} ${HDF5_HL_F90_C_LIB_NAME} STATIC)
set_target_properties (${HDF5_HL_F90_C_LIB_TARGET} PROPERTIES
FOLDER libraries/hl/fortran
LINKER_LANGUAGE C
INTERFACE_INCLUDE_DIRECTORIES "$<INSTALL_INTERFACE:$<INSTALL_PREFIX>/include>"
)
+set (install_targets ${HDF5_HL_F90_C_LIB_TARGET})
+
+if (BUILD_SHARED_LIBS)
+ add_library (${HDF5_HL_F90_C_LIBSH_TARGET} SHARED ${HDF5_HL_F90_C_SRCS} ${HDF5_HL_F90_HEADERS})
+ TARGET_C_PROPERTIES (${HDF5_HL_F90_C_LIBSH_TARGET} SHARED " " " ")
+ target_link_libraries (${HDF5_HL_F90_C_LIBSH_TARGET} ${HDF5_F90_C_LIBSH_TARGET} ${HDF5_HL_LIBSH_TARGET})
+ set_global_variable (HDF5_LIBRARIES_TO_EXPORT "${HDF5_LIBRARIES_TO_EXPORT};${HDF5_HL_F90_C_LIBSH_TARGET}")
+ H5_SET_LIB_OPTIONS (${HDF5_HL_F90_C_LIBSH_TARGET} ${HDF5_HL_F90_C_LIB_NAME} SHARED)
+ set_target_properties (${HDF5_HL_F90_C_LIBSH_TARGET} PROPERTIES
+ FOLDER libraries/hl/fortran
+ LINKER_LANGUAGE C
+ COMPILE_DEFINITIONS "H5_BUILT_AS_DYNAMIC_LIB"
+ INTERFACE_INCLUDE_DIRECTORIES "$<INSTALL_INTERFACE:$<INSTALL_PREFIX>/include>"
+ INTERFACE_COMPILE_DEFINITIONS H5_BUILT_AS_DYNAMIC_LIB=1
+ )
+ set (install_targets ${install_targets} ${HDF5_HL_F90_C_LIBSH_TARGET})
+endif (BUILD_SHARED_LIBS)
#-----------------------------------------------------------------------------
# Fortran Modules
#-----------------------------------------------------------------------------
+set (HDF5_HL_F90_F_BASE_SRCS
+ ${HDF5_HL_F90_SRC_SOURCE_DIR}/H5DSff.F90
+ ${HDF5_HL_F90_SRC_SOURCE_DIR}/H5TBff.F90
+ ${HDF5_HL_F90_SRC_SOURCE_DIR}/H5LTff.F90
+ ${HDF5_HL_F90_SRC_SOURCE_DIR}/H5IMff.F90
+)
set (HDF5_HL_F90_F_SRCS
- ${HDF5_HL_F90_SRC_SOURCE_DIR}/H5DSff.f90
- ${HDF5_HL_F90_SRC_SOURCE_DIR}/H5TBff.f90
- ${HDF5_HL_F90_SRC_SOURCE_DIR}/H5LTff.f90
- ${HDF5_HL_F90_SRC_SOURCE_DIR}/H5IMff.f90
+ ${HDF5_HL_F90_F_BASE_SRCS}
+
+ # generated files
+ ${HDF5_HL_F90_SRC_BINARY_DIR}/H5LTff_gen.F90
+ ${HDF5_HL_F90_SRC_BINARY_DIR}/H5TBff_gen.F90
)
+
set_source_files_properties (${HDF5_HL_F90_F_SRCS} PROPERTIES LANGUAGE Fortran)
-add_library (${HDF5_HL_F90_LIB_TARGET} ${LIB_TYPE} ${HDF5_HL_F90_F_SRCS})
-set (SHARED_LINK_FLAGS " ")
-if (BUILD_SHARED_LIBS)
- if (WIN32)
- set_property (TARGET ${HDF5_HL_F90_LIB_TARGET}
- APPEND PROPERTY COMPILE_DEFINITIONS
- BUILD_HDF5_HL_DLL
- )
- if (MSVC)
- set (SHARED_LINK_FLAGS "/DLL")
- endif (MSVC)
- endif (WIN32)
-endif (BUILD_SHARED_LIBS)
-if (WIN32)
- set_property (TARGET ${HDF5_HL_F90_LIB_TARGET}
- APPEND PROPERTY COMPILE_DEFINITIONS
- HDF5F90_WINDOWS
- )
-endif (WIN32)
-TARGET_FORTRAN_PROPERTIES (${HDF5_HL_F90_LIB_TARGET} ${LIB_TYPE} " " ${SHARED_LINK_FLAGS})
+set_source_files_properties (
+ ${HDF5_HL_F90_SRC_BINARY_DIR}/H5LTff_gen.F90
+ ${HDF5_HL_F90_SRC_BINARY_DIR}/H5TBff_gen.F90
+ PROPERTIES GENERATED TRUE
+)
+
+set (CMD $<TARGET_FILE:H5HL_buildiface>)
+add_custom_target (H5HLgen ALL
+ COMMAND ${CMD}
+#v3.2 BYPRODUCT ${HDF5_HL_F90_SRC_BINARY_DIR}/H5LTff_gen.F90
+#v3.2 ${HDF5_HL_F90_SRC_BINARY_DIR}/H5TBff_gen.F90
+ WORKING_DIRECTORY ${HDF5_HL_F90_SRC_BINARY_DIR}
+ DEPENDS ${HDF5_HL_F90_F_BASE_SRCS}
+)
+
+add_library (${HDF5_HL_F90_LIB_TARGET} STATIC ${HDF5_HL_F90_F_SRCS})
+TARGET_FORTRAN_PROPERTIES (${HDF5_HL_F90_LIB_TARGET} STATIC " " " ")
target_link_libraries (${HDF5_HL_F90_LIB_TARGET} ${HDF5_HL_F90_C_LIB_TARGET} ${HDF5_F90_LIB_TARGET})
set_global_variable (HDF5_LIBRARIES_TO_EXPORT "${HDF5_LIBRARIES_TO_EXPORT};${HDF5_HL_F90_LIB_TARGET}")
-H5_SET_LIB_OPTIONS (${HDF5_HL_F90_LIB_TARGET} ${HDF5_HL_F90_LIB_NAME} ${LIB_TYPE})
+H5_SET_LIB_OPTIONS (${HDF5_HL_F90_LIB_TARGET} ${HDF5_HL_F90_LIB_NAME} STATIC)
set_target_properties (${HDF5_HL_F90_LIB_TARGET} PROPERTIES
FOLDER libraries/hl/fortran
LINKER_LANGUAGE Fortran
INTERFACE_INCLUDE_DIRECTORIES "$<INSTALL_INTERFACE:$<INSTALL_PREFIX>/include>"
- Fortran_MODULE_DIRECTORY ${CMAKE_Fortran_MODULE_DIRECTORY}
+ Fortran_MODULE_DIRECTORY ${CMAKE_Fortran_MODULE_DIRECTORY}/static
)
+if (WIN32)
+ set_property (TARGET ${HDF5_HL_F90_LIB_TARGET}
+ APPEND PROPERTY COMPILE_DEFINITIONS "HDF5F90_WINDOWS"
+ )
+endif (WIN32)
+set (install_targets ${install_targets} ${HDF5_HL_F90_LIB_TARGET})
+
+if (BUILD_SHARED_LIBS)
+ add_library (${HDF5_HL_F90_LIBSH_TARGET} SHARED ${HDF5_HL_F90_F_SRCS})
+ set (SHARED_LINK_FLAGS " ")
+ if (WIN32 AND MSVC)
+ set (SHARED_LINK_FLAGS "/DLL /DEF:${HDF5_HL_F90_SRC_BINARY_DIR}/hdf5_hl_fortrandll.def")
+ endif (WIN32 AND MSVC)
+ TARGET_FORTRAN_PROPERTIES (${HDF5_HL_F90_LIBSH_TARGET} SHARED " " ${SHARED_LINK_FLAGS})
+ target_link_libraries (${HDF5_HL_F90_LIBSH_TARGET} ${HDF5_HL_F90_C_LIBSH_TARGET} ${HDF5_F90_LIBSH_TARGET})
+ set_global_variable (HDF5_LIBRARIES_TO_EXPORT "${HDF5_LIBRARIES_TO_EXPORT};${HDF5_HL_F90_LIBSH_TARGET}")
+ H5_SET_LIB_OPTIONS (${HDF5_HL_F90_LIBSH_TARGET} ${HDF5_HL_F90_LIB_NAME} SHARED)
+ set_target_properties (${HDF5_HL_F90_LIBSH_TARGET} PROPERTIES
+ FOLDER libraries/hl/fortran
+ LINKER_LANGUAGE Fortran
+ INTERFACE_INCLUDE_DIRECTORIES "$<INSTALL_INTERFACE:$<INSTALL_PREFIX>/include>"
+ INTERFACE_COMPILE_DEFINITIONS H5_BUILT_AS_DYNAMIC_LIB=1
+ Fortran_MODULE_DIRECTORY ${CMAKE_Fortran_MODULE_DIRECTORY}/shared
+ )
+ if (WIN32)
+ set_property (TARGET ${HDF5_HL_F90_LIBSH_TARGET}
+ APPEND PROPERTY COMPILE_DEFINITIONS "BUILD_HDF5_HL_DLL;HDF5F90_WINDOWS"
+ )
+ endif (WIN32)
+ set (install_targets ${install_targets} ${HDF5_HL_F90_LIBSH_TARGET})
+endif (BUILD_SHARED_LIBS)
#-----------------------------------------------------------------------------
# Add file(s) to CMake Install
#-----------------------------------------------------------------------------
-if (WIN32)
- set (MOD_BUILD_DIR ${CMAKE_Fortran_MODULE_DIRECTORY}/\${BUILD_TYPE})
-else (WIN32)
- set (MOD_BUILD_DIR ${CMAKE_Fortran_MODULE_DIRECTORY})
-endif (WIN32)
+if (BUILD_SHARED_LIBS)
+ if (WIN32)
+ set (MOD_BUILD_DIR ${CMAKE_Fortran_MODULE_DIRECTORY}/shared/\${BUILD_TYPE})
+ else (WIN32)
+ set (MOD_BUILD_DIR ${CMAKE_Fortran_MODULE_DIRECTORY}/shared)
+ endif (WIN32)
+else (BUILD_SHARED_LIBS)
+ if (WIN32)
+ set (MOD_BUILD_DIR ${CMAKE_Fortran_MODULE_DIRECTORY}/static/\${BUILD_TYPE})
+ else (WIN32)
+ set (MOD_BUILD_DIR ${CMAKE_Fortran_MODULE_DIRECTORY}/static)
+ endif (WIN32)
+endif (BUILD_SHARED_LIBS)
set (mod_files
${MOD_BUILD_DIR}/h5ds.mod
${MOD_BUILD_DIR}/h5tb.mod
+ ${MOD_BUILD_DIR}/h5tb_const.mod
${MOD_BUILD_DIR}/h5lt.mod
+ ${MOD_BUILD_DIR}/h5lt_const.mod
${MOD_BUILD_DIR}/h5im.mod
)
@@ -107,18 +206,18 @@ install (
#-----------------------------------------------------------------------------
if (HDF5_EXPORTED_TARGETS)
if (BUILD_SHARED_LIBS)
- INSTALL_TARGET_PDB (${HDF5_HL_F90_C_LIB_TARGET} ${HDF5_INSTALL_BIN_DIR} hlfortlibraries)
- #INSTALL_TARGET_PDB (${HDF5_HL_F90_LIB_TARGET} ${HDF5_INSTALL_BIN_DIR} hlfortlibraries)
+ INSTALL_TARGET_PDB (${HDF5_HL_F90_C_LIBSH_TARGET} ${HDF5_INSTALL_BIN_DIR} hlfortlibraries)
+ #INSTALL_TARGET_PDB (${HDF5_HL_F90_LIBSH_TARGET} ${HDF5_INSTALL_BIN_DIR} hlfortlibraries)
endif (BUILD_SHARED_LIBS)
-
+
install (
TARGETS
- ${HDF5_HL_F90_C_LIB_TARGET}
- ${HDF5_HL_F90_LIB_TARGET}
+ ${install_targets}
EXPORT
${HDF5_EXPORTED_TARGETS}
LIBRARY DESTINATION ${HDF5_INSTALL_LIB_DIR} COMPONENT hlfortlibraries
ARCHIVE DESTINATION ${HDF5_INSTALL_LIB_DIR} COMPONENT hlfortlibraries
RUNTIME DESTINATION ${HDF5_INSTALL_BIN_DIR} COMPONENT hlfortlibraries
+ FRAMEWORK DESTINATION ${HDF5_INSTALL_FWRK_DIR} COMPONENT hlfortlibraries
)
endif (HDF5_EXPORTED_TARGETS)
diff --git a/hl/fortran/test/CMakeLists.txt b/hl/fortran/test/CMakeLists.txt
index 55fb987..a1d1386 100644
--- a/hl/fortran/test/CMakeLists.txt
+++ b/hl/fortran/test/CMakeLists.txt
@@ -7,39 +7,87 @@ PROJECT (HDF5_HL_FORTRAN_TESTS C CXX Fortran)
INCLUDE_DIRECTORIES (${CMAKE_Fortran_MODULE_DIRECTORY} ${HDF5_F90_BINARY_DIR} ${HDF5_F90_SRC_DIR}/src)
#-- Adding test for hl_f90_tstds
-add_executable (hl_f90_tstds tstds.f90)
-TARGET_NAMING (hl_f90_tstds ${LIB_TYPE})
-TARGET_FORTRAN_PROPERTIES (hl_f90_tstds ${LIB_TYPE} " " " ")
+add_executable (hl_f90_tstds tstds.F90)
+TARGET_NAMING (hl_f90_tstds STATIC)
+TARGET_FORTRAN_PROPERTIES (hl_f90_tstds STATIC " " " ")
target_link_libraries (hl_f90_tstds ${HDF5_HL_F90_LIB_TARGET} ${HDF5_F90_LIB_TARGET})
-target_include_directories (hl_f90_tstds PRIVATE ${CMAKE_Fortran_MODULE_DIRECTORY})
+target_include_directories (hl_f90_tstds PRIVATE ${CMAKE_Fortran_MODULE_DIRECTORY}/static)
set_target_properties (hl_f90_tstds PROPERTIES LINKER_LANGUAGE Fortran)
set_target_properties (hl_f90_tstds PROPERTIES FOLDER test/hl/fortran)
+if (BUILD_SHARED_LIBS)
+ add_executable (hl_f90_tstds-shared tstds.F90)
+ TARGET_NAMING (hl_f90_tstds-shared SHARED)
+ TARGET_FORTRAN_PROPERTIES (hl_f90_tstds-shared SHARED " " " ")
+ target_link_libraries (hl_f90_tstds-shared ${HDF5_HL_F90_LIBSH_TARGET} ${HDF5_F90_LIBSH_TARGET})
+ target_include_directories (hl_f90_tstds-shared PRIVATE ${CMAKE_Fortran_MODULE_DIRECTORY}/shared)
+ set_target_properties (hl_f90_tstds-shared PROPERTIES
+ LINKER_LANGUAGE Fortran
+ FOLDER test/hl/fortran
+ Fortran_MODULE_DIRECTORY ${CMAKE_Fortran_MODULE_DIRECTORY}/shared
+ )
+endif (BUILD_SHARED_LIBS)
#-- Adding test for hl_f90_tstlite
-add_executable (hl_f90_tstlite tstlite.f90)
-TARGET_NAMING (hl_f90_tstlite ${LIB_TYPE})
-TARGET_FORTRAN_PROPERTIES (hl_f90_tstlite ${LIB_TYPE} " " " ")
+add_executable (hl_f90_tstlite tstlite.F90)
+TARGET_NAMING (hl_f90_tstlite STATIC)
+TARGET_FORTRAN_PROPERTIES (hl_f90_tstlite STATIC " " " ")
target_link_libraries (hl_f90_tstlite ${HDF5_HL_F90_LIB_TARGET} ${HDF5_F90_LIB_TARGET})
-target_include_directories (hl_f90_tstlite PRIVATE ${CMAKE_Fortran_MODULE_DIRECTORY})
+target_include_directories (hl_f90_tstlite PRIVATE ${CMAKE_Fortran_MODULE_DIRECTORY}/static)
set_target_properties (hl_f90_tstlite PROPERTIES LINKER_LANGUAGE Fortran)
set_target_properties (hl_f90_tstlite PROPERTIES FOLDER test/hl/fortran)
+if (BUILD_SHARED_LIBS)
+ add_executable (hl_f90_tstlite-shared tstlite.F90)
+ TARGET_NAMING (hl_f90_tstlite-shared SHARED)
+ TARGET_FORTRAN_PROPERTIES (hl_f90_tstlite-shared SHARED " " " ")
+ target_link_libraries (hl_f90_tstlite-shared ${HDF5_HL_F90_LIBSH_TARGET} ${HDF5_F90_LIBSH_TARGET})
+ target_include_directories (hl_f90_tstlite-shared PRIVATE ${CMAKE_Fortran_MODULE_DIRECTORY}/shared)
+ set_target_properties (hl_f90_tstlite-shared PROPERTIES
+ LINKER_LANGUAGE Fortran
+ FOLDER test/hl/fortran
+ Fortran_MODULE_DIRECTORY ${CMAKE_Fortran_MODULE_DIRECTORY}/shared
+ )
+endif (BUILD_SHARED_LIBS)
#-- Adding test for hl_f90_tstimage
-add_executable (hl_f90_tstimage tstimage.f90)
-TARGET_NAMING (hl_f90_tstimage ${LIB_TYPE})
-TARGET_FORTRAN_PROPERTIES (hl_f90_tstimage ${LIB_TYPE} " " " ")
+add_executable (hl_f90_tstimage tstimage.F90)
+TARGET_NAMING (hl_f90_tstimage STATIC)
+TARGET_FORTRAN_PROPERTIES (hl_f90_tstimage STATIC " " " ")
target_link_libraries (hl_f90_tstimage ${HDF5_HL_F90_LIB_TARGET} ${HDF5_F90_LIB_TARGET})
-target_include_directories (hl_f90_tstimage PRIVATE ${CMAKE_Fortran_MODULE_DIRECTORY})
+target_include_directories (hl_f90_tstimage PRIVATE ${CMAKE_Fortran_MODULE_DIRECTORY}/static)
set_target_properties (hl_f90_tstimage PROPERTIES LINKER_LANGUAGE Fortran)
set_target_properties (hl_f90_tstimage PROPERTIES FOLDER test/hl/fortran)
+if (BUILD_SHARED_LIBS)
+ add_executable (hl_f90_tstimage-shared tstimage.F90)
+ TARGET_NAMING (hl_f90_tstimage-shared SHARED)
+ TARGET_FORTRAN_PROPERTIES (hl_f90_tstimage-shared SHARED " " " ")
+ target_link_libraries (hl_f90_tstimage-shared ${HDF5_HL_F90_LIBSH_TARGET} ${HDF5_F90_LIBSH_TARGET})
+ target_include_directories (hl_f90_tstimage-shared PRIVATE ${CMAKE_Fortran_MODULE_DIRECTORY}/shared)
+ set_target_properties (hl_f90_tstimage-shared PROPERTIES
+ LINKER_LANGUAGE Fortran
+ FOLDER test/hl/fortran
+ Fortran_MODULE_DIRECTORY ${CMAKE_Fortran_MODULE_DIRECTORY}/shared
+ )
+endif (BUILD_SHARED_LIBS)
#-- Adding test for hl_f90_tsttable
-add_executable (hl_f90_tsttable tsttable.f90)
-TARGET_NAMING (hl_f90_tsttable ${LIB_TYPE})
-TARGET_FORTRAN_PROPERTIES (hl_f90_tsttable ${LIB_TYPE} " " " ")
+add_executable (hl_f90_tsttable tsttable.F90)
+TARGET_NAMING (hl_f90_tsttable STATIC)
+TARGET_FORTRAN_PROPERTIES (hl_f90_tsttable STATIC " " " ")
target_link_libraries (hl_f90_tsttable ${HDF5_HL_F90_LIB_TARGET} ${HDF5_F90_LIB_TARGET})
-target_include_directories (hl_f90_tsttable PRIVATE ${CMAKE_Fortran_MODULE_DIRECTORY})
+target_include_directories (hl_f90_tsttable PRIVATE ${CMAKE_Fortran_MODULE_DIRECTORY}/static)
set_target_properties (hl_f90_tsttable PROPERTIES LINKER_LANGUAGE Fortran)
set_target_properties (hl_f90_tsttable PROPERTIES FOLDER test/hl/fortran)
+if (BUILD_SHARED_LIBS)
+ add_executable (hl_f90_tsttable-shared tsttable.F90)
+ TARGET_NAMING (hl_f90_tsttable-shared SHARED)
+ TARGET_FORTRAN_PROPERTIES (hl_f90_tsttable-shared SHARED " " " ")
+ target_link_libraries (hl_f90_tsttable-shared ${HDF5_HL_F90_LIBSH_TARGET} ${HDF5_F90_LIBSH_TARGET})
+ target_include_directories (hl_f90_tsttable-shared PRIVATE ${CMAKE_Fortran_MODULE_DIRECTORY}/shared)
+ set_target_properties (hl_f90_tsttable-shared PROPERTIES
+ LINKER_LANGUAGE Fortran
+ FOLDER test/hl/fortran
+ Fortran_MODULE_DIRECTORY ${CMAKE_Fortran_MODULE_DIRECTORY}/shared
+ )
+endif (BUILD_SHARED_LIBS)
include (CMakeTests.cmake)
diff --git a/hl/fortran/test/CMakeTests.cmake b/hl/fortran/test/CMakeTests.cmake
index 3676d24..38181bf 100644
--- a/hl/fortran/test/CMakeTests.cmake
+++ b/hl/fortran/test/CMakeTests.cmake
@@ -31,3 +31,34 @@ set_tests_properties (HL_FORTRAN_f90_tstimage PROPERTIES DEPENDS HL_FORTRAN_test
add_test (NAME HL_FORTRAN_f90_tsttable COMMAND $<TARGET_FILE:hl_f90_tsttable>)
set_tests_properties (HL_FORTRAN_f90_tsttable PROPERTIES DEPENDS HL_FORTRAN_test-clear-objects)
+
+if (BUILD_SHARED_LIBS)
+ add_test (
+ NAME HL_FORTRAN_test-shared-clear-objects
+ COMMAND ${CMAKE_COMMAND}
+ -E remove
+ dsetf1.h5
+ dsetf2.h5
+ dsetf3.h5
+ dsetf4.h5
+ dsetf5.h5
+ f1img.h5
+ f1tab.h5
+ tstds.h5
+ )
+ set_tests_properties (HL_FORTRAN_test-shared-clear-objects
+ PROPERTIES DEPENDS "HL_FORTRAN_f90_tsttable;HL_FORTRAN_f90_tstimage;HL_FORTRAN_f90_tstlite;HL_FORTRAN_f90_tstds"
+ )
+
+ add_test (NAME HL_FORTRAN_f90_tstds-shared COMMAND $<TARGET_FILE:hl_f90_tstds-shared>)
+ set_tests_properties (HL_FORTRAN_f90_tstds-shared PROPERTIES DEPENDS HL_FORTRAN_test-shared-clear-objects)
+
+ add_test (NAME HL_FORTRAN_f90_tstlite-shared COMMAND $<TARGET_FILE:hl_f90_tstlite-shared>)
+ set_tests_properties (HL_FORTRAN_f90_tstlite-shared PROPERTIES DEPENDS HL_FORTRAN_test-shared-clear-objects)
+
+ add_test (NAME HL_FORTRAN_f90_tstimage-shared COMMAND $<TARGET_FILE:hl_f90_tstimage-shared>)
+ set_tests_properties (HL_FORTRAN_f90_tstimage-shared PROPERTIES DEPENDS HL_FORTRAN_test-shared-clear-objects)
+
+ add_test (NAME HL_FORTRAN_f90_tsttable-shared COMMAND $<TARGET_FILE:hl_f90_tsttable-shared>)
+ set_tests_properties (HL_FORTRAN_f90_tsttable-shared PROPERTIES DEPENDS HL_FORTRAN_test-shared-clear-objects)
+endif (BUILD_SHARED_LIBS)
diff --git a/hl/src/CMakeLists.txt b/hl/src/CMakeLists.txt
index 3c24e40..23943f9 100644
--- a/hl/src/CMakeLists.txt
+++ b/hl/src/CMakeLists.txt
@@ -1,12 +1,6 @@
cmake_minimum_required (VERSION 3.1.0)
PROJECT (HDF5_HL_SRC)
-#-----------------------------------------------------------------------------
-# Shared Libs
-#-----------------------------------------------------------------------------
-if (BUILD_SHARED_LIBS)
- set (HL_BUILT_AS_DYNAMIC_LIB 1)
-endif (BUILD_SHARED_LIBS)
#-----------------------------------------------------------------------------
# List Source files
@@ -33,15 +27,31 @@ set (HL_HEADERS
${HDF5_HL_SRC_SOURCE_DIR}/hdf5_hl.h
)
-add_library (${HDF5_HL_LIB_TARGET} ${LIB_TYPE} ${HL_SRCS} ${HL_HEADERS})
-TARGET_C_PROPERTIES (${HDF5_HL_LIB_TARGET} ${LIB_TYPE} " " " ")
+add_library (${HDF5_HL_LIB_TARGET} STATIC ${HL_SRCS} ${HL_HEADERS})
+TARGET_C_PROPERTIES (${HDF5_HL_LIB_TARGET} STATIC " " " ")
target_link_libraries (${HDF5_HL_LIB_TARGET} ${HDF5_LIB_TARGET})
-H5_SET_LIB_OPTIONS (${HDF5_HL_LIB_TARGET} ${HDF5_HL_LIB_NAME} ${LIB_TYPE})
+H5_SET_LIB_OPTIONS (${HDF5_HL_LIB_TARGET} ${HDF5_HL_LIB_NAME} STATIC)
set_target_properties (${HDF5_HL_LIB_TARGET} PROPERTIES
FOLDER libraries/hl
INTERFACE_INCLUDE_DIRECTORIES "$<INSTALL_INTERFACE:$<INSTALL_PREFIX>/include>"
)
set_global_variable (HDF5_LIBRARIES_TO_EXPORT "${HDF5_LIBRARIES_TO_EXPORT};${HDF5_HL_LIB_TARGET}")
+set (install_targets ${HDF5_HL_LIB_TARGET})
+
+if (BUILD_SHARED_LIBS)
+ add_library (${HDF5_HL_LIBSH_TARGET} SHARED ${HL_SRCS} ${HL_HEADERS})
+ TARGET_C_PROPERTIES (${HDF5_HL_LIBSH_TARGET} SHARED " " " ")
+ target_link_libraries (${HDF5_HL_LIBSH_TARGET} ${HDF5_LIBSH_TARGET})
+ H5_SET_LIB_OPTIONS (${HDF5_HL_LIBSH_TARGET} ${HDF5_HL_LIB_NAME} SHARED)
+ set_target_properties (${HDF5_HL_LIBSH_TARGET} PROPERTIES
+ FOLDER libraries/hl
+ COMPILE_DEFINITIONS "H5_BUILT_AS_DYNAMIC_LIB"
+ INTERFACE_INCLUDE_DIRECTORIES "$<INSTALL_INTERFACE:$<INSTALL_PREFIX>/include>"
+ INTERFACE_COMPILE_DEFINITIONS H5_BUILT_AS_DYNAMIC_LIB=1
+ )
+ set_global_variable (HDF5_LIBRARIES_TO_EXPORT "${HDF5_LIBRARIES_TO_EXPORT};${HDF5_HL_LIBSH_TARGET}")
+ set (install_targets ${install_targets} ${HDF5_HL_LIBSH_TARGET})
+endif (BUILD_SHARED_LIBS)
#-----------------------------------------------------------------------------
# Add file(s) to CMake Install
@@ -60,16 +70,17 @@ install (
#-----------------------------------------------------------------------------
if (HDF5_EXPORTED_TARGETS)
if (BUILD_SHARED_LIBS)
- INSTALL_TARGET_PDB (${HDF5_HL_LIB_TARGET} ${HDF5_INSTALL_BIN_DIR} hllibraries)
+ INSTALL_TARGET_PDB (${HDF5_HL_LIBSH_TARGET} ${HDF5_INSTALL_BIN_DIR} hllibraries)
endif (BUILD_SHARED_LIBS)
install (
TARGETS
- ${HDF5_HL_LIB_TARGET}
+ ${install_targets}
EXPORT
${HDF5_EXPORTED_TARGETS}
LIBRARY DESTINATION ${HDF5_INSTALL_LIB_DIR} COMPONENT hllibraries
ARCHIVE DESTINATION ${HDF5_INSTALL_LIB_DIR} COMPONENT hllibraries
RUNTIME DESTINATION ${HDF5_INSTALL_BIN_DIR} COMPONENT hllibraries
+ FRAMEWORK DESTINATION ${HDF5_INSTALL_FWRK_DIR} COMPONENT hllibraries
)
endif (HDF5_EXPORTED_TARGETS)
diff --git a/hl/test/CMakeLists.txt b/hl/test/CMakeLists.txt
index 47383ce..916dcf3 100644
--- a/hl/test/CMakeLists.txt
+++ b/hl/test/CMakeLists.txt
@@ -22,8 +22,8 @@ INCLUDE_DIRECTORIES (${HDF5_TEST_SRC_DIR})
# --------------------------------------------------------------------
MACRO (HL_ADD_EXE hl_name)
add_executable (hl_${hl_name} ${hl_name}.c)
- TARGET_NAMING (hl_${hl_name} ${LIB_TYPE})
- TARGET_C_PROPERTIES (hl_${hl_name} ${LIB_TYPE} " " " ")
+ TARGET_NAMING (hl_${hl_name} STATIC)
+ TARGET_C_PROPERTIES (hl_${hl_name} STATIC " " " ")
target_link_libraries (hl_${hl_name}
${HDF5_HL_LIB_TARGET}
${HDF5_LIB_TARGET}
@@ -32,6 +32,18 @@ MACRO (HL_ADD_EXE hl_name)
set_target_properties (hl_${hl_name} PROPERTIES FOLDER test/hl)
ENDMACRO (HL_ADD_EXE)
+MACRO (HL_ADD_SHEXE hl_name)
+ add_executable (hl_${hl_name} ${hl_name}.c)
+ TARGET_NAMING (hl_${hl_name} SHARED)
+ TARGET_C_PROPERTIES (hl_${hl_name} SHARED " " " ")
+ target_link_libraries (hl_${hl_name}
+ ${HDF5_HL_LIBSH_TARGET}
+ ${HDF5_LIBSH_TARGET}
+ ${HDF5_TEST_LIBSH_TARGET}
+ )
+ set_target_properties (hl_${hl_name} PROPERTIES FOLDER test/hl)
+ENDMACRO (HL_ADD_SHEXE)
+
HL_ADD_EXE (test_ds)
HL_ADD_EXE (test_dset_opt)
HL_ADD_EXE (test_image)
@@ -43,7 +55,7 @@ HL_ADD_EXE (test_table)
# This executable is used to generate test files for the test_ds test.
# It should only be run during development when new test files are needed
# --------------------------------------------------------------------
-if (HDF5_BUILD_GENERATORS AND NOT BUILD_SHARED_LIBS)
+if (HDF5_BUILD_GENERATORS)
add_executable (hl_gen_test_ds gen_test_ds.c)
TARGET_NAMING (hl_gen_test_ds STATIC)
TARGET_C_PROPERTIES (hl_gen_test_ds STATIC " " " ")
@@ -53,6 +65,6 @@ if (HDF5_BUILD_GENERATORS AND NOT BUILD_SHARED_LIBS)
${HDF5_TEST_LIB_TARGET}
)
set_target_properties (hl_gen_test_ds PROPERTIES FOLDER test/hl/gen)
-endif (HDF5_BUILD_GENERATORS AND NOT BUILD_SHARED_LIBS)
+endif (HDF5_BUILD_GENERATORS)
include (CMakeTests.cmake)
diff --git a/hl/tools/CMakeLists.txt b/hl/tools/CMakeLists.txt
index f58a513..73d1f22 100644
--- a/hl/tools/CMakeLists.txt
+++ b/hl/tools/CMakeLists.txt
@@ -18,8 +18,8 @@ INCLUDE_DIRECTORIES (${HDF5_TOOLS_SRC_DIR}/lib)
INCLUDE_DIRECTORIES (${HDF5_HL_TOOLS_SOURCE_DIR}/gif2h5)
add_executable (gif2h5 ${GIF2H5_SRCS})
-TARGET_NAMING (gif2h5 ${LIB_TYPE})
-TARGET_C_PROPERTIES (gif2h5 ${LIB_TYPE} " " " ")
+TARGET_NAMING (gif2h5 STATIC)
+TARGET_C_PROPERTIES (gif2h5 STATIC " " " ")
target_link_libraries (gif2h5 ${HDF5_HL_LIB_TARGET} ${HDF5_LIB_TARGET} ${HDF5_TOOLS_LIB_TARGET})
set_target_properties (gif2h5 PROPERTIES FOLDER tools/hl)
@@ -29,8 +29,8 @@ set (hdf2gif_SRCS
${HDF5_HL_TOOLS_SOURCE_DIR}/gif2h5/hdfgifwr.c
)
add_executable (h52gif ${hdf2gif_SRCS})
-TARGET_NAMING (h52gif ${LIB_TYPE})
-TARGET_C_PROPERTIES (h52gif ${LIB_TYPE} " " " ")
+TARGET_NAMING (h52gif STATIC)
+TARGET_C_PROPERTIES (h52gif STATIC " " " ")
target_link_libraries (h52gif ${HDF5_HL_LIB_TARGET} ${HDF5_LIB_TARGET} ${HDF5_TOOLS_LIB_TARGET})
set_target_properties (h52gif PROPERTIES FOLDER tools/hl)
@@ -40,7 +40,7 @@ if (BUILD_TESTING)
# used in the CMake Build system as we rely on the test files that are
# shipped with HDF5 source archives
# --------------------------------------------------------------------
- if (HDF5_BUILD_GENERATORS AND NOT BUILD_SHARED_LIBS)
+ if (HDF5_BUILD_GENERATORS)
add_executable (hl_h52gifgentest ${HDF5_HL_TOOLS_SOURCE_DIR}/gif2h5/h52gifgentst.c)
TARGET_NAMING (hl_h52gifgentest STATIC)
TARGET_C_PROPERTIES (hl_h52gifgentest STATIC " " " ")
@@ -48,7 +48,7 @@ if (BUILD_TESTING)
set_target_properties (hl_h52gifgentest PROPERTIES FOLDER generator/tools/hl)
# add_test (NAME hl_h52gifgentest COMMAND $<TARGET_FILE:hl_h52gifgentest>)
- endif (HDF5_BUILD_GENERATORS AND NOT BUILD_SHARED_LIBS)
+ endif (HDF5_BUILD_GENERATORS)
include (CMakeTests.cmake)
endif (BUILD_TESTING)
@@ -60,8 +60,5 @@ install (
TARGETS
gif2h5
h52gif
- RUNTIME DESTINATION
- ${HDF5_INSTALL_BIN_DIR}
- COMPONENT
- hltoolsapplications
+ RUNTIME DESTINATION ${HDF5_INSTALL_BIN_DIR} COMPONENT hltoolsapplications
)