Skip to content

Commit

Permalink
CMake no longer builds the C++ library by default (#555)
Browse files Browse the repository at this point in the history
* Committing clang-format changes

* CMake no longer builds C++ library by default

Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
  • Loading branch information
derobins and github-actions[bot] authored Apr 20, 2021
1 parent d3384b2 commit fc5c567
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 2 deletions.
2 changes: 1 addition & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -1106,7 +1106,7 @@ endif ()
# Option to build HDF5 C++ Library
#-----------------------------------------------------------------------------
if (EXISTS "${HDF5_SOURCE_DIR}/c++" AND IS_DIRECTORY "${HDF5_SOURCE_DIR}/c++")
option (HDF5_BUILD_CPP_LIB "Build HDF5 C++ Library" ON)
option (HDF5_BUILD_CPP_LIB "Build HDF5 C++ Library" OFF)
if (HDF5_BUILD_CPP_LIB)
# check for unsupported options
if (HDF5_ENABLE_PARALLEL)
Expand Down
2 changes: 2 additions & 0 deletions config/cmake/cacheinit.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,8 @@ set (HDF_PACKAGE_EXT "" CACHE STRING "Name of HDF package extension" FORCE)

set (HDF_PACKAGE_NAMESPACE "hdf5::" CACHE STRING "Name for HDF package namespace (can be empty)" FORCE)

set (HDF5_BUILD_CPP_LIB ON CACHE BOOL "Build C++ support" FORCE)

set (HDF5_BUILD_FORTRAN ON CACHE BOOL "Build FORTRAN support" FORCE)

set (HDF5_INSTALL_MOD_FORTRAN "NO" CACHE STRING "Copy FORTRAN mod files to include directory (NO SHARED STATIC)" FORCE)
Expand Down
2 changes: 1 addition & 1 deletion release_docs/INSTALL_CMake.txt
Original file line number Diff line number Diff line change
Expand Up @@ -734,7 +734,7 @@ BUILD_STATIC_EXECS "Build Static Executables" OFF
BUILD_TESTING "Build HDF5 Unit Testing" ON

---------------- HDF5 Build Options ---------------------
HDF5_BUILD_CPP_LIB "Build HDF5 C++ Library" ON
HDF5_BUILD_CPP_LIB "Build HDF5 C++ Library" OFF
HDF5_BUILD_EXAMPLES "Build HDF5 Library Examples" ON
HDF5_BUILD_FORTRAN "Build FORTRAN support" OFF
HDF5_BUILD_JAVA "Build JAVA support" OFF
Expand Down
7 changes: 7 additions & 0 deletions release_docs/RELEASE.txt
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,13 @@ New Features

Configuration:
-------------
- CMake no longer builds the C++ library by default

HDF5_BUILD_CPP_LIB now defaults to OFF, which is in line with the
Autotools build defaults.

(DER - 2021/04/20)

- Removal of pre-VS2015 work-arounds

HDF5 now requires Visual Studio 2015 or greater, so old work-around
Expand Down

0 comments on commit fc5c567

Please sign in to comment.