ornladios / ADIOS2

Next generation of ADIOS developed in the Exascale Computing Program
https://adios2.readthedocs.io/en/latest/index.html
Apache License 2.0
269 stars 126 forks source link

fabric.h not found error during compilation #3711

Open richardyorke opened 1 year ago

richardyorke commented 1 year ago

We ask the community to always report bugs. Please open a new issue if some other comes up in the conversation. It will help us stay on topic and manage tasks more efficiently.

Describe the bug fabric.h is not being found and is indeed not present at the given path in the error message. I have installed libfabric.

To Reproduce [ryorke@vld255:~/adios2-build]$ cmake ../ADIOS2/ -- Could NOT find Blosc2 (missing: BLOSC2_LIBRARY BLOSC2_INCLUDE_DIR) (Required is at least version "2.4") -- Could NOT find ZFP (missing: ZFP_DIR) -- Could NOT find SZ (missing: SZ_LIBRARY ZSTD_LIBRARY SZ_INCLUDE_DIR) -- Could NOT find mgard (missing: mgard_DIR) -- Could NOT find PNG: Found unsuitable version "1.5.13", but required is at least "1.6.0" (found /usr/lib64/libpng.so) -- Found MPI: TRUE (found version "3.1") found components: C Fortran CXX -- Could NOT find ZeroMQ (missing: ZeroMQ_LIBRARY ZeroMQ_INCLUDE_DIR) (Required is at least version "4.1") -- Checking for module 'dspaces' -- No package 'dspaces' found -- Could NOT find DataSpaces (missing: DATASPACES_VERSION DATASPACES_INCLUDE_DIR DATASPACES_LIBRARIES) (Required is at least version "2.1.1") -- Could NOT find IME (missing: IME_LIBRARY IME_INCLUDE_DIR) -- Could NOT find Python (missing: Python_INCLUDE_DIRS Python_LIBRARIES Python_NumPy_INCLUDE_DIRS Development NumPy Development.Module Development.Embed) (found suitable version "3.6.8", minimum required is "3") -- Found LIBFABRIC: /home/h06/ryorke/libfabric/lib/libfabric.so (Required is at least version "1.6") -- Checking for module 'cray-drc' -- No package 'cray-drc' found -- Could NOT find CrayDRC (missing: CrayDRC_LIBRARIES) -- Checking for module 'ucx' -- No package 'ucx' found -- Could NOT find UCX (missing: UCX_LIBRARIES) (Required is at least version "1.9.0") -- Could NOT find DAOS (missing: DAOS_LIBRARY DFS_LIBRARY DAOS_INCLUDE_DIR) -- Could NOT find Sodium (missing: sodium_LIBRARY_RELEASE sodium_LIBRARY_DEBUG sodium_INCLUDE_DIR) -- Checking for O_DIRECT

-- ADIOS2 ThirdParty: Configuring KWSys CMake Deprecation Warning at thirdparty/KWSys/adios2sys/CMakeLists.txt:91 (cmake_minimum_required): Compatibility with CMake < 3.5 will be removed from a future version of CMake.

Update the VERSION argument value or use a ... suffix to tell CMake that the project does not need compatibility with older versions.

-- ADIOS2 ThirdParty: Configuring perfstubs

-- ADIOS2 ThirdParty: Configuring GTest

-- ADIOS2 ThirdParty: Configuring pugixml

-- ADIOS2 ThirdParty: Configuring nlohmann_json

-- ADIOS2 ThirdParty: Configuring yaml-cpp

-- ADIOS2 ThirdParty: Configuring atl CMake Deprecation Warning at thirdparty/atl/atl/CMakeLists.txt:1 (cmake_minimum_required): Compatibility with CMake < 3.5 will be removed from a future version of CMake.

Update the VERSION argument value or use a ... suffix to tell CMake that the project does not need compatibility with older versions.

-- Found atl: /home/h06/ryorke/adios2-build/thirdparty/atl/atl/atl-config.cmake (found version "2.2.1")

-- ADIOS2 ThirdParty: Configuring dill CMake Deprecation Warning at thirdparty/dill/dill/CMakeLists.txt:1 (cmake_minimum_required): Compatibility with CMake < 3.5 will be removed from a future version of CMake.

Update the VERSION argument value or use a ... suffix to tell CMake that the project does not need compatibility with older versions.

-- Enabling emulation -- Clear cache defined is 1 -- Found dill: /home/h06/ryorke/adios2-build/thirdparty/dill/dill/dill-config.cmake (found version "3.0.0")

-- ADIOS2 ThirdParty: Configuring ffs CMake Deprecation Warning at thirdparty/ffs/ffs/CMakeLists.txt:1 (cmake_minimum_required): Compatibility with CMake < 3.5 will be removed from a future version of CMake.

Update the VERSION argument value or use a ... suffix to tell CMake that the project does not need compatibility with older versions.

-- Found dill: /home/h06/ryorke/adios2-build/thirdparty/dill/dill/dill-config.cmake (found suitable version "3.0.0", minimum required is "3.0.0") -- Found atl: /home/h06/ryorke/adios2-build/thirdparty/atl/atl/atl-config.cmake (found suitable version "2.2.1", minimum required is "2.2.1") -- Found atl: /home/h06/ryorke/adios2-build/thirdparty/atl/atl/atl-config.cmake (found version "2.2.1") -- Found ffs: /home/h06/ryorke/adios2-build/thirdparty/ffs/ffs/ffs-config.cmake (found version "3.0.0")

-- ADIOS2 ThirdParty: Configuring enet CMake Deprecation Warning at thirdparty/enet/enet/CMakeLists.txt:1 (cmake_minimum_required): Compatibility with CMake < 3.5 will be removed from a future version of CMake.

Update the VERSION argument value or use a ... suffix to tell CMake that the project does not need compatibility with older versions.

-- ADIOS2 ThirdParty: Configuring EVPath CMake Deprecation Warning at thirdparty/EVPath/EVPath/CMakeLists.txt:1 (cmake_minimum_required): Compatibility with CMake < 3.5 will be removed from a future version of CMake.

Update the VERSION argument value or use a ... suffix to tell CMake that the project does not need compatibility with older versions.

-- Found atl: /home/h06/ryorke/adios2-build/thirdparty/atl/atl/atl-config.cmake (found suitable version "2.2.1", minimum required is "2.2.1") -- Found ffs: /home/h06/ryorke/adios2-build/thirdparty/ffs/ffs/ffs-config.cmake (found suitable version "3.0.0", minimum required is "3.0.0") -- Found enet: /home/h06/ryorke/adios2-build/thirdparty/enet/enet/enet-config.cmake (found suitable version "1.3.14", minimum required is "1.3.13")

-- Found MPI: TRUE (found version "3.1") found components: C CMake Warning (dev) at testing/adios2/engine/staging-common/TestSupp.cmake:59 (find_package): Policy CMP0148 is not set: The FindPythonInterp and FindPythonLibs modules are removed. Run "cmake --help-policy CMP0148" for policy details. Use the cmake_policy command to set the policy and suppress this warning.

Call Stack (most recent call first): testing/adios2/engine/staging-common/CMakeLists.txt:99 (include) This warning is for project developers. Use -Wno-dev to suppress it.

ADIOS2 build configuration: ADIOS Version: 2.9.0.214 C++ Compiler : GNU 4.8.5 /usr/bin/c++

Fortran Compiler : GNU 4.8.5 /usr/bin/f95

Installation prefix: /usr/local bin: bin lib: lib64 include: include cmake: lib64/cmake/adios2 python: lib64/python3.6/site-packages

Features: Library Type: shared Build Type: Release Testing: ON Examples: ON Build Options: BP5 : ON DataMan : OFF DataSpaces: OFF HDF5 : ON HDF5_VOL : OFF MHS : ON SST : ON Fortran : ON MPI : ON Python : OFF Blosc2 : OFF BZip2 : ON LIBPRESSIO: OFF MGARD : OFF PNG : OFF SZ : OFF ZFP : OFF DAOS : OFF IME : OFF O_DIRECT : ON Sodium : OFF Catalyst : OFF SysVShMem : ON UCX : OFF ZeroMQ : OFF Profiling : ON Endian_Reverse: OFF AWSSDK : OFF GPU_Support: OFF CUDA : OFF Kokkos : OFF Kokkos_CUDA: OFF Kokkos_HIP: OFF Kokkos_SYCL: OFF RDMA Transport for Staging: Available -- Configuring done (6.0s) -- Generating done (11.4s) -- Build files have been written to: /home/h06/ryorke/adios2-build [ryorke@vld255:~/adios2-build]$ make [ 0%] Building C object thirdparty/KWSys/adios2sys/CMakeFiles/adios2sys_objects.dir/EncodingC.c.o [ 0%] Building CXX object thirdparty/KWSys/adios2sys/CMakeFiles/adios2sys_objects.dir/Directory.cxx.o [ 0%] Building CXX object thirdparty/KWSys/adios2sys/CMakeFiles/adios2sys_objects.dir/DynamicLoader.cxx.o [ 1%] Building CXX object thirdparty/KWSys/adios2sys/CMakeFiles/adios2sys_objects.dir/EncodingCXX.cxx.o [ 1%] Building CXX object thirdparty/KWSys/adios2sys/CMakeFiles/adios2sys_objects.dir/RegularExpression.cxx.o [ 1%] Building CXX object thirdparty/KWSys/adios2sys/CMakeFiles/adios2sys_objects.dir/SystemTools.cxx.o [ 1%] Building CXX object thirdparty/KWSys/adios2sys/CMakeFiles/adios2sys_objects.dir/CommandLineArguments.cxx.o [ 1%] Building CXX object thirdparty/KWSys/adios2sys/CMakeFiles/adios2sys_objects.dir/FStream.cxx.o [ 1%] Building CXX object thirdparty/KWSys/adios2sys/CMakeFiles/adios2sys_objects.dir/Status.cxx.o [ 1%] Built target adios2sys_objects [ 1%] Building C object thirdparty/perfstubs/perfstubs/CMakeFiles/perfstubs.dir/perfstubs_api/timer.c.o [ 1%] Linking C shared library ../../../lib64/libadios2_perfstubs.so [ 1%] Built target perfstubs [ 1%] Building C object thirdparty/atl/atl/CMakeFiles/atl.dir/atom.c.o [ 1%] Building C object thirdparty/atl/atl/CMakeFiles/atl.dir/attr.c.o [ 1%] Building C object thirdparty/atl/atl/CMakeFiles/atl.dir/lookup3.c.o [ 1%] Building C object thirdparty/atl/atl/CMakeFiles/atl.dir/tclHash.c.o [ 1%] Linking C shared library ../../../lib64/libadios2_atl.so [ 1%] Built target atl [ 1%] Generating dill_x86_64.c [ 1%] Generating dill.h, dill.c [ 1%] Generating dill_virtual.c [ 1%] Building C object thirdparty/dill/dill/CMakeFiles/dill.dir/dill_util.c.o [ 1%] Building C object thirdparty/dill/dill/CMakeFiles/dill.dir/dill_pkg.c.o [ 1%] Building C object thirdparty/dill/dill/CMakeFiles/dill.dir/dill_cplus.c.o [ 2%] Building C object thirdparty/dill/dill/CMakeFiles/dill.dir/dill_virtual.c.o [ 2%] Building C object thirdparty/dill/dill/CMakeFiles/dill.dir/virtual.c.o [ 2%] Building C object thirdparty/dill/dill/CMakeFiles/dill.dir/dill.c.o [ 2%] Building C object thirdparty/dill/dill/CMakeFiles/dill.dir/vm.c.o [ 2%] Building C object thirdparty/dill/dill/CMakeFiles/dill.dir/x86_64_disassembler.c.o [ 2%] Building C object thirdparty/dill/dill/CMakeFiles/dill.dir/dill_x86_64.c.o [ 2%] Building C object thirdparty/dill/dill/CMakeFiles/dill.dir/x86_64.c.o [ 2%] Building C object thirdparty/dill/dill/CMakeFiles/dill.dir/x86_64_rt.c.o [ 2%] Linking C shared library ../../../lib64/libadios2_dill.so [ 2%] Built target dill [ 3%] [FLEX][CODScanner] Building scanner with flex 2.5.37 [ 3%] Generating cod_node.c Done [ 3%] Built target docs [ 4%] [BISON][CODParser] Building parser with bison 3.0.4 [ 4%] Building C object thirdparty/ffs/ffs/CMakeFiles/ffs.dir/ffs/ffs.c.o [ 4%] Building C object thirdparty/ffs/ffs/CMakeFiles/ffs.dir/ffs/ffs_formats.c.o [ 4%] Building C object thirdparty/ffs/ffs/CMakeFiles/ffs.dir/ffs/ffs_conv.c.o [ 4%] Building C object thirdparty/ffs/ffs/CMakeFiles/ffs.dir/ffs/ffs_gen.c.o [ 4%] Building C object thirdparty/ffs/ffs/CMakeFiles/ffs.dir/ffs/ffs_file.c.o [ 4%] Building C object thirdparty/ffs/ffs/CMakeFiles/ffs.dir/ffs/evol.c.o [ 4%] Building C object thirdparty/ffs/ffs/CMakeFiles/ffs.dir/ffs/ffs_marshal.c.o [ 5%] Building C object thirdparty/ffs/ffs/CMakeFiles/ffs.dir/version.c.o [ 5%] Building C object thirdparty/ffs/ffs/CMakeFiles/ffs.dir/fm/fm_formats.c.o [ 5%] Building C object thirdparty/ffs/ffs/CMakeFiles/ffs.dir/fm/fm_dump.c.o [ 5%] Building C object thirdparty/ffs/ffs/CMakeFiles/ffs.dir/fm/lookup3.c.o [ 5%] Building C object thirdparty/ffs/ffs/CMakeFiles/ffs.dir/fm/string_conversion.c.o [ 5%] Building C object thirdparty/ffs/ffs/CMakeFiles/ffs.dir/fm/fm_get.c.o [ 5%] Building C object thirdparty/ffs/ffs/CMakeFiles/ffs.dir/fm/xml.c.o [ 5%] Building C object thirdparty/ffs/ffs/CMakeFiles/ffs.dir/fm/server_acts.c.o [ 5%] Building C object thirdparty/ffs/ffs/CMakeFiles/ffs.dir/fm/unix_io.c.o [ 6%] Building C object thirdparty/ffs/ffs/CMakeFiles/ffs.dir/cod/cg.c.o [ 6%] Building C object thirdparty/ffs/ffs/CMakeFiles/ffs.dir/cod/standard.c.o [ 6%] Building C object thirdparty/ffs/ffs/CMakeFiles/ffs.dir/cod.tab.c.o [ 6%] Building C object thirdparty/ffs/ffs/CMakeFiles/ffs.dir/cod_node.c.o [ 6%] Linking C shared library ../../../lib64/libadios2_ffs.so [ 6%] Built target ffs [ 6%] Building C object thirdparty/enet/enet/CMakeFiles/enet.dir/callbacks.c.o [ 6%] Building C object thirdparty/enet/enet/CMakeFiles/enet.dir/compress.c.o [ 6%] Building C object thirdparty/enet/enet/CMakeFiles/enet.dir/host.c.o [ 6%] Building C object thirdparty/enet/enet/CMakeFiles/enet.dir/list.c.o [ 6%] Building C object thirdparty/enet/enet/CMakeFiles/enet.dir/packet.c.o [ 6%] Building C object thirdparty/enet/enet/CMakeFiles/enet.dir/peer.c.o [ 6%] Building C object thirdparty/enet/enet/CMakeFiles/enet.dir/protocol.c.o [ 6%] Building C object thirdparty/enet/enet/CMakeFiles/enet.dir/unix.c.o [ 7%] Linking C shared library ../../../lib64/libadios2_enet.so [ 7%] Built target enet [ 7%] Generating cm_interface.c, revp.c, revpath.h done [ 7%] Building C object thirdparty/EVPath/EVPath/CMakeFiles/EVPath.dir/cm.c.o [ 7%] Building C object thirdparty/EVPath/EVPath/CMakeFiles/EVPath.dir/cm_control.c.o [ 7%] Building C object thirdparty/EVPath/EVPath/CMakeFiles/EVPath.dir/cm_formats.c.o [ 7%] Building C object thirdparty/EVPath/EVPath/CMakeFiles/EVPath.dir/cm_util.c.o [ 8%] Building C object thirdparty/EVPath/EVPath/CMakeFiles/EVPath.dir/cm_transport.c.o [ 8%] Building C object thirdparty/EVPath/EVPath/CMakeFiles/EVPath.dir/cm_lock.c.o [ 8%] Building C object thirdparty/EVPath/EVPath/CMakeFiles/EVPath.dir/cm_perf.c.o [ 8%] Building C object thirdparty/EVPath/EVPath/CMakeFiles/EVPath.dir/cm_pbio.c.o [ 8%] Building C object thirdparty/EVPath/EVPath/CMakeFiles/EVPath.dir/cm_interface.c.o [ 8%] Building C object thirdparty/EVPath/EVPath/CMakeFiles/EVPath.dir/version.c.o [ 8%] Building C object thirdparty/EVPath/EVPath/CMakeFiles/EVPath.dir/cm_threadio.c.o [ 8%] Building C object thirdparty/EVPath/EVPath/CMakeFiles/EVPath.dir/cm_evol.c.o [ 8%] Building C object thirdparty/EVPath/EVPath/CMakeFiles/EVPath.dir/evp.c.o [ 9%] Building C object thirdparty/EVPath/EVPath/CMakeFiles/EVPath.dir/response.c.o [ 9%] Building C object thirdparty/EVPath/EVPath/CMakeFiles/EVPath.dir/metrics.c.o [ 9%] Building C object thirdparty/EVPath/EVPath/CMakeFiles/EVPath.dir/dlloader.c.o [ 9%] Building C object thirdparty/EVPath/EVPath/CMakeFiles/EVPath.dir/ip_config.c.o [ 9%] Building C object thirdparty/EVPath/EVPath/CMakeFiles/EVPath.dir/chr_time.c.o [ 9%] Building C object thirdparty/EVPath/EVPath/CMakeFiles/EVPath.dir/revp.c.o [ 9%] Building C object thirdparty/EVPath/EVPath/CMakeFiles/EVPath.dir/evp_compat.c.o [ 9%] Building C object thirdparty/EVPath/EVPath/CMakeFiles/EVPath.dir/thin_server.c.o [ 9%] Building C object thirdparty/EVPath/EVPath/CMakeFiles/EVPath.dir/evp_threads.c.o [ 9%] Building C object thirdparty/EVPath/EVPath/CMakeFiles/EVPath.dir/ev_dfg.c.o [ 10%] Linking C shared library ../../../lib64/libadios2_evpath.so [ 10%] Built target EVPath [ 10%] Building C object thirdparty/EVPath/EVPath/CMakeFiles/cmselect.dir/cmselect.c.o [ 10%] Linking C shared module lib64/adios2_evpath_modules/libadios2_cmselect.so [ 10%] Built target cmselect [ 10%] Building C object thirdparty/EVPath/EVPath/CMakeFiles/cmsockets.dir/cmsockets.c.o [ 10%] Building C object thirdparty/EVPath/EVPath/CMakeFiles/cmsockets.dir/ip_config.c.o [ 10%] Linking C shared module lib64/adios2_evpath_modules/libadios2_cmsockets.so [ 10%] Built target cmsockets [ 10%] Building C object thirdparty/EVPath/EVPath/CMakeFiles/cmudp.dir/cmudp.c.o [ 10%] Linking C shared module lib64/adios2_evpath_modules/libadios2_cmudp.so [ 10%] Built target cmudp [ 11%] Building C object thirdparty/EVPath/EVPath/CMakeFiles/cmmulticast.dir/cmmulticast.c.o [ 11%] Linking C shared module lib64/adios2_evpath_modules/libadios2_cmmulticast.so [ 11%] Built target cmmulticast [ 11%] Building C object thirdparty/EVPath/EVPath/CMakeFiles/cmepoll.dir/cmepoll.c.o [ 11%] Linking C shared module lib64/adios2_evpath_modules/libadios2_cmepoll.so [ 11%] Built target cmepoll [ 11%] Building C object thirdparty/EVPath/EVPath/CMakeFiles/cmenet.dir/cmenet.c.o [ 11%] Building C object thirdparty/EVPath/EVPath/CMakeFiles/cmenet.dir/ip_config.c.o [ 11%] Linking C shared module lib64/adios2_evpath_modules/libadios2_cmenet.so [ 11%] Built target cmenet [ 12%] Building C object thirdparty/EVPath/EVPath/CMakeFiles/cmzplenet.dir/cmzplenet.c.o [ 12%] Building C object thirdparty/EVPath/EVPath/CMakeFiles/cmzplenet.dir/ip_config.c.o [ 12%] Linking C shared module lib64/adios2_evpath_modules/libadios2_cmzplenet.so [ 12%] Built target cmzplenet [ 12%] Building C object thirdparty/EVPath/EVPath/CMakeFiles/cmfabric.dir/cmfabric.c.o /home/h06/ryorke/ADIOS2/thirdparty/EVPath/EVPath/cmfabric.c:57:25: fatal error: rdma/fabric.h: No such file or directory

include <rdma/fabric.h>

                     ^

compilation terminated. make[2]: [thirdparty/EVPath/EVPath/CMakeFiles/cmfabric.dir/cmfabric.c.o] Error 1 make[1]: [thirdparty/EVPath/EVPath/CMakeFiles/cmfabric.dir/all] Error 2 make: *** [all] Error 2

Expected behavior ADIOS compiles successfully.

Desktop (please complete the following information): OS/Platform: Red Hat 4.8.5-44 Build: gcc (GCC) 4.8.5 20150623]

Additional context Add any other context about the problem here.

Following up Was the issue fixed? Please report back.

eisenhauer commented 1 year ago

This is odd. Can I ask what version of libfabric that you installed? And which version of cmake? I haven't seen this particular problem before, but libfabric is looked for in two places in the ADIOS software stack: in ADIOS itself and in a thirdparty subcomponent called EVPath. This is failing because the libfabric installation is not as EVPath expects it for some reason, but EVPath finding libfabric is not useful or necessary for ADIOS (which is going to do its own thing with RDMA). Because of that, ADIOS runs the EVPath Cmake with EVPATH_NO_RDMA set to ON, which should prevent EVPath from using libfabric (or trying to build the file that is failing to compile).

I notice you're also getting some CMake warnings that I've seen in the last couple of days after installing the newest CMake. I'm wondering if these things might be related. @caitlinross or @vicentebolea , could you take a look?

richardyorke commented 1 year ago

Hi, libfabric is 1.21.1 and cmake is 3.27.0.

Yes, I have looked within the EVPath directory and there is no fabric.h file there. Once I established that, I tried installing libfabric.

eisenhauer commented 1 year ago

So this happened when libfabric wasn't installed too?

richardyorke commented 1 year ago

Yes, installing libfabric did not change the error message from how it was before it was installed.

eisenhauer commented 1 year ago

I wouldn't have expected installing libfabric to improve things. The problem seems to be that EVPath/cmfabric.c is being compiled when it shouldn't be. It should be excluded by CMake both with and without libfabric. While I've seen odd compatibility errors with the newest CMake, I haven't seen this. Hopefully @caitlinross or @vicentebolea can advise.

vicentebolea commented 1 year ago

I cannot seem to reproduce this issue with fabric.h with the latest cmake (3.27.1) with or without libfabric-devel. hmm. @richardyorke is this error also appearing in a fresh build?

On another note I will take care of the cmake warnings.

richardyorke commented 1 year ago

Yes, I have tried to rebuild ADIOS2 from new and the issue reoccurs. I will try with an older version of cmake. Is there a version that you recommend?

eisenhauer commented 1 year ago

An older version of CMake is a good idea. If you go back a year or so (~3.23 or 3.22) would probably be sufficient. This sequence in the ADIOS build hasn't changed for 4-5 years, so we're likely looking for some external cause, either a change in CMake or something odder about your build environment.

richardyorke commented 1 year ago

OK, I will try cmake-3.23. What does ADIOS2 require to build? I will check my environment to see if its requirements are present or sufficiently up-to-date.

eisenhauer commented 1 year ago

It depends. Basic build just requires cmake, make, perl, and c and C++ compilers (I may have forgotten something there, but not much more.). If you're building for a cluster, you'll want to add MPI, libfabric or UCX (experimental) so you can use RDMA, maybe Fortran compiler for those bindings, etc. For jupyter adding python will get you those bindings too. The last bit of CMake output will tell you what features are on or off. Most are set to auto by default so they are built of the dependencies are found but not otherwise.

richardyorke commented 1 year ago

What versions of make, perl, and c and C++ compilers does it require? My system has some quite old versions of those.

eisenhauer commented 1 year ago

As long as the compiler is C++11 capable, it's probably fine. And if it is, then C almost certainly is too. CMake relies on very basic Make, so pretty much anything will work there too. Our perl usage is also very generic, so if it's less than 5 years old it should be fine too.