Skip to content

Commit

Permalink
Merge branch 'next-run-id' into uuid-run-id
Browse files Browse the repository at this point in the history
* next-run-id:
  Note removing support for HDF5 in changelog
  Better notation for indexing zShift
  Update note on zShift in grid-files section of manual
  Print error for HDF5 macros when running bout-v5-macro-upgrader.py
  Support macros being removed in bout-v5-macro-upgrader.py
  Remove HDF5 support
  • Loading branch information
ZedThree committed Feb 4, 2021
2 parents 4047181 + 3c3a3d5 commit e193ac6
Show file tree
Hide file tree
Showing 57 changed files with 65 additions and 4,682 deletions.
5 changes: 1 addition & 4 deletions .github/workflows/clang-tidy-review.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,6 @@ jobs:
libnetcdf-dev
libnetcdf-c++4-dev
netcdf-bin
hdf5-tools
libhdf5-mpi-dev
openmpi-bin
libopenmpi-dev
petsc-dev
Expand All @@ -39,7 +37,6 @@ jobs:
-DBOUT_ENABLE_OPENMP=ON \
-DBOUT_USE_PETSC=ON \
-DBOUT_USE_SLEPC=ON \
-DBOUT_USE_HDF5=ON \
-DBOUT_USE_SUNDIALS=ON \
-DBOUT_BUILD_EXAMPLES=ON \
-DCMAKE_EXPORT_COMPILE_COMMANDS=On
Expand All @@ -49,6 +46,6 @@ jobs:
id: review
with:
build_dir: build
apt_packages: "libfftw3-dev,libnetcdf-c++4-dev,libhdf5-mpi-dev,libopenmpi-dev,petsc-dev,slepc-dev,liblapack-dev,libparpack2-dev,libsundials-dev"
apt_packages: "libfftw3-dev,libnetcdf-c++4-dev,libopenmpi-dev,petsc-dev,slepc-dev,liblapack-dev,libparpack2-dev,libsundials-dev"
clang_tidy_checks: '-*,performance-*,readability-*,bugprone-*,clang-analyzer-*,cppcoreguidelines-*,mpi-*,misc-*,-readability-magic-numbers,-cppcoreguidelines-avoid-magic-numbers'

8 changes: 0 additions & 8 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,6 @@ jobs:
os: ubuntu-18.04
configure_options: "--with-petsc
--with-slepc
--with-hdf5
--with-sundials=/home/runner/local"
script_flags: "-uim"

Expand All @@ -44,7 +43,6 @@ jobs:
--disable-backtrace
--with-petsc
--with-slepc
--with-hdf5
--with-sundials=/home/runner/local"
script_flags: "-uim -t shared -t python"

Expand All @@ -54,7 +52,6 @@ jobs:
--enable-sigfpe
--enable-debug
--enable-track
--with-hdf5
--with-petsc
--with-slepc
--with-sundials=/home/runner/local"
Expand All @@ -66,7 +63,6 @@ jobs:
--enable-openmp
--with-petsc
--with-slepc
--with-hdf5
--with-sundials=/home/runner/local"
script_flags: "-uim"
omp_num_threads: 2
Expand All @@ -77,7 +73,6 @@ jobs:
-DBOUT_ENABLE_OPENMP=ON
-DBOUT_USE_PETSC=ON
-DBOUT_USE_SLEPC=ON
-DBOUT_USE_HDF5=ON
-DBOUT_USE_SUNDIALS=ON
-DSUNDIALS_ROOT=/home/runner/local"
omp_num_threads: 2
Expand All @@ -89,7 +84,6 @@ jobs:
--enable-debug
--enable-track
--with-lapack
--with-hdf5
--with-petsc
--with-slepc
--with-sundials=/home/runner/local"
Expand All @@ -114,14 +108,12 @@ jobs:
libnetcdf-dev
libnetcdf-c++4-dev
netcdf-bin
hdf5-tools
python3
python3-pip
python3-pytest
python3-numpy
python3-scipy
lcov
libhdf5-mpi-dev
openmpi-bin
libopenmpi-dev
petsc-dev
Expand Down
2 changes: 1 addition & 1 deletion .travis_fedora.sh
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ then
cat /etc/os-release
# Ignore weak depencies
echo "install_weak_deps=False" >> /etc/dnf/dnf.conf
time dnf -y install dnf-plugins-core {petsc,hdf5}-${mpi}-devel /usr/lib/rpm/redhat/redhat-hardened-cc1 python3-h5py
time dnf -y install dnf-plugins-core petsc-${mpi}-devel /usr/lib/rpm/redhat/redhat-hardened-cc1 python3-h5py
# Allow to override packages - see #2073
time dnf copr enable -y davidsch/fixes4bout || :
time dnf -y upgrade
Expand Down
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,8 @@
- `PhysicsModel` expects the options `datadir` and `dump_format` to
have been set; this is only a problem if you don't call
`BoutInitialise`. [\#2062](https://github.com/boutproject/BOUT-dev/pull/2062)
- Support for reading/writing HDF5 files has been removed ahead of completely
refactoring the I/O systems. [\#2208](https://github.com/boutproject/BOUT-dev/pull/2208)


## [v4.3.2](https://github.com/boutproject/BOUT-dev/tree/v4.3.2) (2020-10-19)
Expand Down
12 changes: 0 additions & 12 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -166,8 +166,6 @@ set(BOUT_SOURCES
./src/fileio/formatfactory.cxx
./src/fileio/formatfactory.hxx
./src/fileio/impls/emptyformat.hxx
./src/fileio/impls/hdf5/h5_format.cxx
./src/fileio/impls/hdf5/h5_format.hxx
./src/fileio/impls/netcdf/nc_format.cxx
./src/fileio/impls/netcdf/nc_format.hxx
./src/fileio/impls/netcdf4/ncxx4.cxx
Expand Down Expand Up @@ -518,15 +516,6 @@ endif()
message(STATUS "NetCDF support: ${BOUT_USE_NETCDF}")
set(BOUT_HAS_NETCDF ${BOUT_USE_NETCDF})

option(BOUT_USE_HDF5 "Enable support for HDF5 output" OFF)
if (BOUT_USE_HDF5)
find_package(HDF5 REQUIRED COMPONENTS CXX)
target_link_libraries(bout++ PUBLIC "${HDF5_CXX_LIBRARIES}")
target_include_directories(bout++ PUBLIC "${HDF5_CXX_INCLUDE_DIRS}")
endif()
message(STATUS "HDF5 support: ${BOUT_USE_HDF5}")
set(BOUT_HAS_HDF5 ${BOUT_USE_HDF5})

option(BOUT_USE_FFTW "Enable support for FFTW" ON)
if (BOUT_USE_FFTW)
find_package(FFTW REQUIRED)
Expand Down Expand Up @@ -873,7 +862,6 @@ message("
SLEPc support : ${BOUT_HAS_SLEPC}
SUNDIALS support : ${BOUT_HAS_SUNDIALS}
NetCDF support : ${BOUT_HAS_NETCDF}
HDF5 support : ${BOUT_HAS_HDF5}
FFTW support : ${BOUT_HAS_FFTW}
LAPACK support : ${BOUT_HAS_LAPACK}
OpenMP support : ${BOUT_USE_OPENMP}
Expand Down
4 changes: 1 addition & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -62,9 +62,7 @@ BOUT++ needs the following:
* A C++14 compiler
* MPI
* Either NetCDF or HDF5
Note that some of the tests require NetCDF rather than HDF5
* NetCDF
BOUT++ has the following optional dependencies:
Expand Down
3 changes: 0 additions & 3 deletions autoconf_build_defines.hxx.in
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,6 @@
/* NLS support */
#undef BOUT_HAS_GETTEXT

/* HDF5 support */
#undef BOUT_HAS_HDF5

/* IDA support */
#undef BOUT_HAS_IDA

Expand Down
7 changes: 0 additions & 7 deletions bin/bout-config.in
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,6 @@ pythonpath="@PYTHONCONFIGPATH@"
has_netcdf="@BOUT_HAS_NETCDF@"
has_legacy_netcdf="@BOUT_HAS_LEGACY_NETCDF@"
has_pnetcdf="@BOUT_HAS_PNETCDF@"
has_hdf5="@BOUT_HAS_HDF5@"
has_pvode="@BOUT_HAS_PVODE@"
has_cvode="@BOUT_HAS_CVODE@"
has_ida="@BOUT_HAS_IDA@"
Expand Down Expand Up @@ -71,7 +70,6 @@ Available values for OPTION include:
--has-netcdf NetCDF file support
--has-legacy-netcdf Legacy NetCDF file support
--has-pnetcdf Parallel NetCDF file support
--has-hdf5 HDF5 file support
--has-pvode PVODE solver support
--has-cvode SUNDIALS CVODE solver support
--has-ida SUNDIALS IDA solver support
Expand Down Expand Up @@ -107,7 +105,6 @@ all()
echo " --has-netcdf -> $has_netcdf"
echo " --has-legacy-netcdf -> $has_legacy_netcdf"
echo " --has-pnetcdf -> $has_pnetcdf"
echo " --has-hdf5 -> $has_hdf5"
echo " --has-pvode -> $has_pvode"
echo " --has-cvode -> $has_cvode"
echo " --has-ida -> $has_ida"
Expand Down Expand Up @@ -200,10 +197,6 @@ while test $# -gt 0; do
echo $has_pnetcdf
;;

--has-hdf5)
echo $has_hdf5
;;

--has-pvode)
echo $has_pvode
;;
Expand Down
18 changes: 13 additions & 5 deletions bin/bout-v5-macro-upgrader.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,8 @@
# List of macros, their replacements and what header to find them
# in. Each element should be a dict with "old", "new" and "headers"
# keys, with "old" and "new" values being strings, and "headers" being a
# list of strings
# list of strings. "new" can also be None if the macro has been removed, which
# will cause an error to be printed if the macro is found.
MACRO_REPLACEMENTS = [
{
"old": "REVISION",
Expand Down Expand Up @@ -63,8 +64,8 @@
},
{
"old": "HAS_HDF5",
"new": "BOUT_HAS_HDF5",
"headers": "bout/build_config.hxx",
"new": None,
"headers": [],
"macro": True,
"always_defined": True,
},
Expand Down Expand Up @@ -140,8 +141,8 @@
},
{
"old": "HDF5",
"new": "BOUT_HAS_HDF5",
"headers": "bout/build_config.hxx",
"new": None,
"headers": [],
"macro": True,
"always_defined": True,
},
Expand Down Expand Up @@ -297,6 +298,13 @@ def apply_fixes(replacements, source):
modified = copy.deepcopy(source)

for replacement in replacements:
if replacement["new"] is None:
print(
"'%s' has been removed, please delete from your code"
% replacement["old"]
)
continue

modified = fix_include_version_header(
replacement["old"], replacement["headers"], modified
)
Expand Down
6 changes: 0 additions & 6 deletions bout++Config.cmake.in
Original file line number Diff line number Diff line change
Expand Up @@ -58,9 +58,6 @@ endif()
if(EXISTS "@netCDFCxx_ROOT@")
set(netCDFCxx_ROOT "@netCDFCxx_ROOT@")
endif()
if(EXISTS "@HDF5F_ROOT@")
set(HDF5F_ROOT "@HDF5F_ROOT@")
endif()
if(EXISTS "@PVODE_ROOT@")
set(PVODE_ROOT "@PVODE_ROOT@")
endif()
Expand All @@ -85,9 +82,6 @@ endif()
if (BOUT_HAS_NETCDF)
find_dependency(netCDFCxx @netCDFCxx_VERSION@)
endif()
if (BOUT_HAS_HDF5)
find_dependency(HDF5 @HDF5_VERSION@)
endif()
if (BOUT_HAS_PVODE)
find_dependency(PVODE @PVODE_VERSION@)
endif()
Expand Down
1 change: 0 additions & 1 deletion cmake_build_defines.hxx.in
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@
#cmakedefine01 BOUT_HAS_CVODE
#cmakedefine01 BOUT_HAS_FFTW
#cmakedefine01 BOUT_HAS_GETTEXT
#cmakedefine01 BOUT_HAS_HDF5
#cmakedefine01 BOUT_HAS_IDA
#cmakedefine01 BOUT_HAS_LAPACK
#cmakedefine01 BOUT_HAS_NETCDF
Expand Down
Loading

0 comments on commit e193ac6

Please sign in to comment.