Compilation of root-6.20.04 fails with gcc-10.1.0

Hello,

I am having difficulty compiling root-6.20.04 with gcc-10.1.0 on Red Hat Enterprise Linux Server 7.6. Please, let me know if this version of gcc is not supported yet. If it is supported, thank you for any clues on how to fix the problem.

Here is the error I get:

...
[ 76%] Generating G__RooFitCore.cxx, ../../lib/RooFitCore.pcm
In module 'std' imported from input_line_1:1:
.../gcc-10.1.0/lib/gcc/x86_64-pc-linux-gnu/10.1.0/../../../../include/c++/10.1.0/bits/unique_ptr.h:207:12: error: 'std::__uniq_ptr_data<ROOT::Experimental::TTaskGroup, std::default_delete<ROOT::Experimental::TTaskGroup>, true, true>' has different definitions
      in different modules; definition in module 'std.condition_variable' is here
    struct __uniq_ptr_data : __uniq_ptr_impl<_Tp, _Dp>
           ^
.../gcc-10.1.0/lib/gcc/x86_64-pc-linux-gnu/10.1.0/../../../../include/c++/10.1.0/bits/unique_ptr.h:207:12: note: definition in module 'std.condition_variable' is here
Error: Error loading the #pragma extra_include.
gmake[2]: *** [roofit/roofitcore/G__RooFitCore.cxx] Error 1
gmake[1]: *** [roofit/roofitcore/CMakeFiles/G__RooFitCore.dir/all] Error 2
gmake: *** [all] Error 2

Thank you for your help,
Siarhei.

Hello @vaurynovich,

it’s not supported yet, and I’m not sure if it will be supported for 6.20. For the upcoming 6.22 (maybe 6.24), we are working on supporting it, but that’s work in progress.

Maybe @Axel knows more details.

Hello @StephanH,

Thank you very much for your reply! Please, let me know which versions of gcc are supported.

Best,
Siarhei.

Hopefully, anything from gcc4.8 to the latest gcc9. :slight_smile:

Hi Siarhei,
there is a workaround, see the discussion at this post and following:

Hope this helps,
Enrico

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.