Dear all,
I am totally new to Fenics and I am having troubles with the installation. I am on OS Sonoma 14.1, and I am trying to install Dolfinx . I followed the build procedure for C++ shown here:
cd dolfinx-main/cpp; mkdir build; cd build; cmake ..
and I get the following output error:
[...]
CMake Error at CMakeLists.txt:334 (message):
Found serial HDF5 build, MPI HDF5 build required, try setting HDF5_DIR or
HDF5_ROOT
I installed hdf5 1.14 by downloading the .tar.gz, then
./configure --enable-parallel --enable-shared
make
sudo make install
If I remove --enable-parallel , --enable-shared or both, I get the same error.
Hello,
I am not sure what is the right folder to set to /path/to/hdf5. It may be /Applications/hdf5-1.14.3/hdf5/ or /Applications/hdf5-1.14.3/hdf5/bin/? Here is what is inside these folders:
% ls /Applications/hdf5-1.14.3/hdf5/ bin include lib share
Anyway, I removed the build folder, then did
export HDF5_ROOT=/Applications/hdf5-1.14.3/hdf5/bin; mkdir build; cd build; cmake ..
but I still get the same error message. I also get the same error message if I replace /Applications/hdf5-1.14.3/hdf5/bin with /Applications/hdf5-1.14.3/hdf5/
Hello,
I used the one without bin, here is the output given by ccmake :
$ccmake ..
Page 1 of 1
BUILD_SHARED_LIBS ON
Basix_DIR /usr/local/lib/cmake/basix
Boost_INCLUDE_DIR /opt/homebrew/include
Boost_TIMER_LIBRARY_RELEASE /opt/homebrew/lib/libboost_timer-mt.dylib
CMAKE_BUILD_TYPE RelWithDebInfo
CMAKE_INSTALL_PREFIX /usr/local
CMAKE_INSTALL_RPATH_USE_LINK_P ON
CMAKE_OSX_ARCHITECTURES
CMAKE_OSX_DEPLOYMENT_TARGET 14.1
CMAKE_OSX_SYSROOT /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX14.2.sdk
DOLFINX_ENABLE_ADIOS2 ON
DOLFINX_ENABLE_KAHIP OFF
DOLFINX_ENABLE_PARMETIS ON
DOLFINX_ENABLE_SCOTCH ON
DOLFINX_ENABLE_SLEPC ON
DOLFINX_SKIP_BUILD_TESTS OFF
DOLFINX_UFCX_PYTHON ON
DOXYGEN_DOLFINX_VERSION 0.8.0.0
GIT_FOUND /opt/homebrew/bin/git
HDF5_C_LIBRARY_dl /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX14.2.sdk/usr/lib/libdl.tbd
HDF5_C_LIBRARY_hdf5 /Applications/hdf5-1.14.3/hdf5/lib/libhdf5.dylib
HDF5_C_LIBRARY_m /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX14.2.sdk/usr/lib/libm.tbd
HDF5_C_LIBRARY_z /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX14.2.sdk/usr/lib/libz.tbd
_REQUIRE_ADIOS2 OFF
_REQUIRE_KAHIP OFF
_REQUIRE_PARMETIS OFF
_REQUIRE_SCOTCH OFF
_REQUIRE_SLEPC OFF
_UFCX_HEADER _UFCX_HEADER-NOTFOUND
pugixml_DIR /opt/homebrew/lib/cmake/pugixml
I don’t see any HDF5_ROOT though, I don’t understand …
which seems to confirm that hdf5 was taken from the path you provided.
However, are you sure that it is actually the path were you installed your custom hdf5 version? I am no mac user, but it seems odd that
basix and dolfinx would get installed in /usr/local when you build them manually, which would make me think that also your custom hdf5 installation was installed in /usr/local
so I guess that my custom installation of hdf5 was installed in /Applications/hdf5-1.14.3/hdf5/.
Now if I do export HDF5_ROOT=/Applications/hdf5-1.14.3/hdf5/ and
install hdft with ./configure; make; make install,
run cmake .. in /Applications/dolfinx-main/cpp/build
I get the error message of the original post.
However, if I
install hdf5 with ./configure --enable-parallel --enable-shared; make; make install
run cmake .. in /Applications/dolfinx-main/cpp/build
I get another error message Could NOT find UFCx (missing: UFCX_INCLUDE_DIRS UFCX_SIGNATURE UFCX_VERSION) (Required is at least version "0.7"). Let alone the new error message, this means that adding the flags to configure fixed the issue with hdf5?