From f1e7081cc28b3af0077af71605df7320aa1b9312 Mon Sep 17 00:00:00 2001 From: Allen Byrne <50328838+byrnHDF@users.noreply.github.com> Date: Mon, 20 Mar 2023 17:41:53 -0500 Subject: Add Option to not build gif tools and remove javadoc option (#2611) * Add Option to not build gif tools and remove javadoc option * Remove old option * Fix CMake command format --- configure.ac | 40 +++++++++++++++++++++---------------- hl/CMakeLists.txt | 10 +--------- hl/Makefile.am | 4 ---- hl/tools/CMakeLists.txt | 8 +++++++- hl/tools/Makefile.am | 8 +++++++- hl/tools/h5watch/CMakeTests.cmake | 2 +- java/src/hdf/hdf5lib/CMakeLists.txt | 12 ----------- release_docs/INSTALL_CMake.txt | 1 + release_docs/RELEASE.txt | 18 +++++++++++++++++ 9 files changed, 58 insertions(+), 45 deletions(-) diff --git a/configure.ac b/configure.ac index 4a320b3..a649d3d 100644 --- a/configure.ac +++ b/configure.ac @@ -846,6 +846,7 @@ AC_LANG_POP(C++) ## library is disabled. AC_SUBST([HDF5_HL]) AC_SUBST([HDF5_HL_TOOLS]) +AC_SUBST([HDF5_HL_GIF_TOOLS]) ## The high-level library and high-level tools are enabled unless the build mode ## is clean. @@ -886,22 +887,6 @@ else AC_MSG_RESULT([no]) fi -AC_MSG_CHECKING([if the high-level tools are enabled]) -AC_ARG_ENABLE([hltools], - [AS_HELP_STRING([--enable-hltools], - [Enable the high-level tools. - [default=yes] - ])], - [HDF5_HL_TOOLS=$enableval]) - -if test "X${HDF5_HL}" = "Xyes" -a "X-$HDF5_HL_TOOLS" = "X-yes"; then - AC_MSG_RESULT([yes]) - HL_TOOLS="tools" -else - AC_MSG_RESULT([no]) -fi - - ## ---------------------------------------------------------------------- ## Check which archiving tool to use. This needs to be done before ## the LT_INIT macro. @@ -1161,6 +1146,27 @@ AC_ARG_ENABLE([tools], AC_MSG_RESULT([$HDF5_TOOLS]) ## ---------------------------------------------------------------------- +## Check if they would like to disable building the high-level GIF +## tools (they have unfixed CVE issues) +## + +AC_MSG_CHECKING([if the high-level GIF tools are enabled]) +AC_ARG_ENABLE([hlgiftools], + [AS_HELP_STRING([--enable-hlgiftools], + [Enable the high-level GIF tools. NOTE: These have unfixed CVE issues! + [default=no] + ])], + [HDF5_HL_GIF_TOOLS=$enableval]) + +if test "X-$HDF5_TOOLS" = "X-yes" -a "X-$HDF5_HL" = "X-yes" -a "X-$HDF5_HL_GIF_TOOLS" = "X-yes"; then + AC_MSG_RESULT([yes]) +else + AC_MSG_RESULT([no]) + HDF5_HL_GIF_TOOLS="no" +fi + + +## ---------------------------------------------------------------------- ## Check if they would like to enable building doxygen files ## @@ -3881,7 +3887,7 @@ AM_CONDITIONAL([BUILD_HDF5_HL_CONDITIONAL], [test "X$HDF5_HL" = "Xyes"]) AM_CONDITIONAL([BUILD_TESTS_CONDITIONAL], [test "X$HDF5_TESTS" = "Xyes"]) AM_CONDITIONAL([BUILD_TESTS_PARALLEL_CONDITIONAL], [test -n "$TESTPARALLEL"]) AM_CONDITIONAL([BUILD_TOOLS_CONDITIONAL], [test "X$HDF5_TOOLS" = "Xyes"]) -AM_CONDITIONAL([BUILD_TOOLS_HL_CONDITIONAL], [test "X$HDF5_HL_TOOLS" = "Xyes"]) +AM_CONDITIONAL([BUILD_TOOLS_HL_GIF_CONDITIONAL], [test "X$HDF5_HL_GIF_TOOLS" = "Xyes"]) AM_CONDITIONAL([BUILD_DOXYGEN_CONDITIONAL], [test "X$HDF5_DOXYGEN" = "Xyes"]) ## ---------------------------------------------------------------------- diff --git a/hl/CMakeLists.txt b/hl/CMakeLists.txt index 5061c6c..ad92906 100644 --- a/hl/CMakeLists.txt +++ b/hl/CMakeLists.txt @@ -9,15 +9,7 @@ add_subdirectory (src) # Build HDF5 Tools if (HDF5_BUILD_TOOLS) - #----------------------------------------------------------------------------- - #-- Option to build the High level Tools - #----------------------------------------------------------------------------- - if (EXISTS "${HDF5_HL_SOURCE_DIR}/tools" AND IS_DIRECTORY "${HDF5_HL_SOURCE_DIR}/tools") - option (HDF5_BUILD_HL_TOOLS "Build HDF5 HL Tools" ON) - if (HDF5_BUILD_HL_TOOLS) - add_subdirectory (tools) - endif () - endif () + add_subdirectory (tools) endif () #-- Add High Level Examples diff --git a/hl/Makefile.am b/hl/Makefile.am index 3cf8778..5660b9b 100644 --- a/hl/Makefile.am +++ b/hl/Makefile.am @@ -36,14 +36,10 @@ else TEST_DIR = endif if BUILD_TOOLS_CONDITIONAL -if BUILD_TOOLS_HL_CONDITIONAL TOOLS_DIR = tools else TOOLS_DIR = endif -else - TOOLS_DIR = -endif ## Don't recurse into any subdirectories if HDF5 is not configured to ## use the HL library diff --git a/hl/tools/CMakeLists.txt b/hl/tools/CMakeLists.txt index fd9b6d9..a0bd744 100644 --- a/hl/tools/CMakeLists.txt +++ b/hl/tools/CMakeLists.txt @@ -1,6 +1,12 @@ cmake_minimum_required (VERSION 3.12) project (HDF5_HL_TOOLS C) -add_subdirectory (gif2h5) +#----------------------------------------------------------------------------- +#-- Option to build the High level GIF Tools +#----------------------------------------------------------------------------- +option (HDF5_BUILD_HL_GIF_TOOLS "Build HDF5 HL GIF Tools" OFF) +if (HDF5_BUILD_HL_GIF_TOOLS) + add_subdirectory (gif2h5) +endif () add_subdirectory (h5watch) diff --git a/hl/tools/Makefile.am b/hl/tools/Makefile.am index 6687f40..9f93f67 100644 --- a/hl/tools/Makefile.am +++ b/hl/tools/Makefile.am @@ -18,7 +18,13 @@ include $(top_srcdir)/config/commence.am +if BUILD_TOOLS_HL_GIF_CONDITIONAL + TOOLS_GIF_DIR = gif2h5 +else + TOOLS_GIF_DIR = +endif + # All subdirectories -SUBDIRS=gif2h5 h5watch +SUBDIRS=h5watch $(TOOLS_GIF_DIR) include $(top_srcdir)/config/conclude.am diff --git a/hl/tools/h5watch/CMakeTests.cmake b/hl/tools/h5watch/CMakeTests.cmake index 32b2b95..fe0d52a 100644 --- a/hl/tools/h5watch/CMakeTests.cmake +++ b/hl/tools/h5watch/CMakeTests.cmake @@ -189,7 +189,7 @@ set (last_test "H5WATCH-clearall-objects") add_test (NAME H5WATCH-h5watchgentest COMMAND ${CMAKE_CROSSCOMPILING_EMULATOR} $) set_tests_properties (H5WATCH-h5watchgentest PROPERTIES WORKING_DIRECTORY "${PROJECT_BINARY_DIR}/testfiles" - DEPENDS "H5WATCH-clearall-objects" + DEPENDS H5WATCH-clearall-objects ) set_tests_properties (H5WATCH-h5watchgentest PROPERTIES FIXTURES_SETUP gen_test_watch) set_tests_properties (H5WATCH-h5watchgentest PROPERTIES FIXTURES_REQUIRED swmr_vfd_check_compat) diff --git a/java/src/hdf/hdf5lib/CMakeLists.txt b/java/src/hdf/hdf5lib/CMakeLists.txt index a313b76..b881cf7 100644 --- a/java/src/hdf/hdf5lib/CMakeLists.txt +++ b/java/src/hdf/hdf5lib/CMakeLists.txt @@ -132,15 +132,3 @@ set_target_properties (${HDF5_JAVA_HDF5_LIB_TARGET} PROPERTIES FOLDER libraries/ if (HDF5_ENABLE_FORMATTERS) clang_format (HDF5_JAVA_SRC_FORMAT ${HDF5_JAVA_HDF_HDF5_CALLBACKS_SOURCES} ${HDF5_JAVA_HDF_HDF5_EXCEPTIONS_SOURCES} ${HDF5_JAVA_HDF_HDF5_STRUCTS_SOURCES} ${HDF5_JAVA_HDF_HDF5_SOURCES}) endif () - -create_javadoc(hdf5_java_doc - FILES ${HDF5_JAVADOC_HDF_HDF5_CALLBACKS_SOURCES} ${HDF5_JAVADOC_HDF_HDF5_EXCEPTIONS_SOURCES} ${HDF5_JAVADOC_HDF_HDF5_STRUCTS_SOURCES} ${HDF5_JAVADOC_HDF_HDF5_SOURCES} - OVERVIEW ${HDF5_JAVA_HDF5_SRC_DIR}/overview.html - CLASSPATH ${CMAKE_JAVA_INCLUDE_PATH} - WINDOWTITLE "HDF5 Java" - DOCTITLE "

HDF5 Java Wrapper

" - INSTALLPATH ${HDF5_INSTALL_DOC_DIR} - AUTHOR TRUE - USE TRUE - VERSION TRUE -) diff --git a/release_docs/INSTALL_CMake.txt b/release_docs/INSTALL_CMake.txt index 54068e2..2208e5e 100644 --- a/release_docs/INSTALL_CMake.txt +++ b/release_docs/INSTALL_CMake.txt @@ -773,6 +773,7 @@ HDF5_BUILD_JAVA "Build JAVA support" OFF HDF5_BUILD_HL_LIB "Build HIGH Level HDF5 Library" ON HDF5_BUILD_TOOLS "Build HDF5 Tools" ON HDF5_BUILD_HL_TOOLS "Build HIGH Level HDF5 Tools" ON +HDF5_BUILD_HL_GIF_TOOLS "Build HIGH Level HDF5 GIF Tools" OFF ---------------- HDF5 Folder Build Options --------------------- Defaults relative to $ diff --git a/release_docs/RELEASE.txt b/release_docs/RELEASE.txt index 1beee82..62d09b2 100644 --- a/release_docs/RELEASE.txt +++ b/release_docs/RELEASE.txt @@ -314,6 +314,24 @@ Bug Fixes since HDF5-1.10.9 release (ADB - 2023/02/16 GH-1546,GH-2259) + - Remove Javadoc generation + + The use of doxygen now supersedes the requirement to build javadocs. We do not + have the resources to continue to support two documentation methods and have + chosen doxygen as our standard. + + (ADB - 2022/12/19) + + - Change the default for building the high-level tools + + The gif2hdf5 and hdf2gif high-level tools are deprecated and will be removed + in a future release. The default build setting for them have been changed from enabled + to disabled. A user can enable the build of these tools if needed. + autotools: --enable-hlgiftools + cmake: HDF5_BUILD_HL_GIF_TOOLS=ON + + (ADB - 2022/12/16) + - Change the settings of the *pc files to use the correct format The pkg-config files generated by CMake uses incorrect syntax for the 'Requires' -- cgit v0.12