ADIOS2 icon indicating copy to clipboard operation
ADIOS2 copied to clipboard

Compilation failure with GCC 8.4.1

Open robertu94 opened this issue 2 years ago • 4 comments

Describe the bug When building with spack and gcc 8.4.1, build fails because adios2 includes the <filesystem> after checking the appropriate __cpp_lib_filesystem macro, but doesn't link the corresponding libraries or pass the appropriate standards flag. The current method used in cmake to enforce c++11 doesn't, it ensure at least C++11

To Reproduce spack install adios2%[email protected]

Expected behavior The build succeeds

Desktop (please complete the following information):

  • OS/Platform: Centos 8.5.2111 (Palmetto Cluster at Clemson University)
  • Build [e.g. compiler version gcc 8.4.1, cmake version 3.23, build type: shared ]

Additional context A collaborator at Clemson encountered this failure Build log with failure

Following up N/A

robertu94 avatar May 19 '22 22:05 robertu94

A copy of the file on Github in case slack deletes it logbuild.txt

robertu94 avatar May 19 '22 22:05 robertu94

@robertu94 thanks for reporting this, you're right as adios2 should be compiling strictly with C++11. Pinging @chuckatkins as it seems to be on the CMake side handling gcc8 requiring extra libraries. That should go away in gcc9 if it helps.

williamfgc avatar May 19 '22 22:05 williamfgc

@williamfgc thanks for the quick response. I know that gcc9 fixes the issue, but we were trying to use the system compiler where possible since it simplifies working with MPI.

robertu94 avatar May 19 '22 22:05 robertu94

@robertu94 makes sense, in that case spack should be setup to reuse the system compiler and not build gcc from source. If that's the case, might be worth a shot using gcc9 so you won't get stuck.

williamfgc avatar May 19 '22 22:05 williamfgc