Problem compiling 6.38.00 on Fedora 42


Hi,

Today I downloaded the fresh ROOT 6.38.00 sources from the root site, and failed to compile with standard compilers on Fedora 42:

[ 65%] Building CXX object main/CMakeFiles/genreflex.dir/src/rootcling.cxx.o
In file included from input_line_10:6:
/home/lewhoo/software/root/root-6.38.00/include/ROOT/RVec.hxx:516:49: error: use of undeclared identifier 'R__HARDWARE_INTERFERENCE_SIZE'
   static constexpr std::size_t cacheLineSize = R__HARDWARE_INTERFERENCE_SIZE;
                                                ^
/home/lewhoo/software/root/root-6.38.00/include/ROOT/RVec.hxx:516:33: error: constexpr variable 'cacheLineSize' must be initialized by a constant expression
   static constexpr std::size_t cacheLineSize = R__HARDWARE_INTERFERENCE_SIZE;
                                ^
                                              = 0
/home/lewhoo/software/root/root-6.38.00/include/ROOT/RVec.hxx:500:31: error: array is too large (18446744039349813248 elements)
   alignas(T) char InlineElts[N * sizeof(T)]{};
                              ^~~~~~~~~~~~~
/home/lewhoo/software/root/root-6.38.00/include/ROOT/RVec.hxx:1148:74: note: in instantiation of template class 'ROOT::Internal::VecOps::SmallVectorStorage<ROOT::VecOps::RVec<unsigned long>, 536870911>' requested here
class R__CLING_PTRCHECK(off) RVecN : public Detail::VecOps::RVecImpl<T>, Internal::VecOps::SmallVectorStorage<T, N> {
                                                                         ^
/home/lewhoo/software/root/root-6.38.00/include/ROOT/RVec.hxx:1526:44: note: in instantiation of template class 'ROOT::VecOps::RVecN<ROOT::VecOps::RVec<unsigned long>, 536870911>' requested here
class R__CLING_PTRCHECK(off) RVec : public RVecN<T, Internal::VecOps::RVecInlineStorageSize<T>::value> {
                                           ^
/home/lewhoo/software/root/root-6.38.00/include/ROOT/RVec.hxx:2603:32: note: in instantiation of template class 'ROOT::VecOps::RVec<ROOT::VecOps::RVec<unsigned long> >' requested here
inline RVec<RVec<std::size_t>> Combinations(const std::size_t size1, const std::size_t size2)
                               ^
/home/lewhoo/software/root/root-6.38.00/include/ROOT/RVec.hxx:1235:10: error: using declaration refers into 'Internal::VecOps::SmallVectorTemplateCommon<RVec<unsigned long> >::', which is not a base class of 'RVecN<ROOT::VecOps::RVec<unsigned long>, 536870911>'
   using Internal::VecOps::SmallVectorTemplateCommon<T>::begin;
         ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/home/lewhoo/software/root/root-6.38.00/include/ROOT/RVec.hxx:1526:44: note: in instantiation of template class 'ROOT::VecOps::RVecN<ROOT::VecOps::RVec<unsigned long>, 536870911>' requested here
class R__CLING_PTRCHECK(off) RVec : public RVecN<T, Internal::VecOps::RVecInlineStorageSize<T>::value> {
                                           ^
/home/lewhoo/software/root/root-6.38.00/include/ROOT/RVec.hxx:2603:32: note: in instantiation of template class 'ROOT::VecOps::RVec<ROOT::VecOps::RVec<unsigned long> >' requested here
inline RVec<RVec<std::size_t>> Combinations(const std::size_t size1, const std::size_t size2)
                               ^
/home/lewhoo/software/root/root-6.38.00/include/ROOT/RVec.hxx:1236:10: error: using declaration refers into 'Internal::VecOps::SmallVectorTemplateCommon<RVec<unsigned long> >::', which is not a base class of 'RVecN<ROOT::VecOps::RVec<unsigned long>, 536870911>'
   using Internal::VecOps::SmallVectorTemplateCommon<T>::size;
         ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/home/lewhoo/software/root/root-6.38.00/include/ROOT/RVec.hxx:2607:5: error: no viable overloaded operator[] for type 'RVec<RVec<size_type> >' (aka 'RVec<RVec<unsigned long> >')
   r[0].resize(size1*size2);
   ~^~
/home/lewhoo/software/root/root-6.38.00/include/ROOT/RVec.hxx:1592:9: note: candidate template ignored: could not match 'RVec<V>' against 'int'
   RVec operator[](const RVec<V> &conds) const
        ^
/home/lewhoo/software/root/root-6.38.00/include/ROOT/RVec.hxx:2608:5: error: no viable overloaded operator[] for type 'RVec<RVec<size_type> >' (aka 'RVec<RVec<unsigned long> >')
   r[1].resize(size1*size2);
   ~^~
/home/lewhoo/software/root/root-6.38.00/include/ROOT/RVec.hxx:1592:9: note: candidate template ignored: could not match 'RVec<V>' against 'int'
   RVec operator[](const RVec<V> &conds) const
        ^
/home/lewhoo/software/root/root-6.38.00/include/ROOT/RVec.hxx:2612:11: error: no viable overloaded operator[] for type 'RVec<RVec<size_type> >' (aka 'RVec<RVec<unsigned long> >')
         r[0][c] = i;
         ~^~
/home/lewhoo/software/root/root-6.38.00/include/ROOT/RVec.hxx:1592:9: note: candidate template ignored: could not match 'RVec<V>' against 'int'
   RVec operator[](const RVec<V> &conds) const
        ^
/home/lewhoo/software/root/root-6.38.00/include/ROOT/RVec.hxx:2613:11: error: no viable overloaded operator[] for type 'RVec<RVec<size_type> >' (aka 'RVec<RVec<unsigned long> >')
         r[1][c] = j;
         ~^~
/home/lewhoo/software/root/root-6.38.00/include/ROOT/RVec.hxx:1592:9: note: candidate template ignored: could not match 'RVec<V>' against 'int'
   RVec operator[](const RVec<V> &conds) const
        ^
/home/lewhoo/software/root/root-6.38.00/include/ROOT/RVec.hxx:1543:33: error: type 'SuperClass' (aka 'RVecN<ROOT::VecOps::RVec<unsigned long>, Internal::VecOps::RVecInlineStorageSize<RVec<unsigned long> >::value>') is not a direct or virtual base of 'ROOT::VecOps::RVec<ROOT::VecOps::RVec<unsigned long> >'
   explicit RVec(size_t Size) : SuperClass(Size) {}
                                ^~~~~~~~~~
/home/lewhoo/software/root/root-6.38.00/include/ROOT/RVec.hxx:2606:26: note: in instantiation of member function 'ROOT::VecOps::RVec<ROOT::VecOps::RVec<unsigned long> >::RVec' requested here
   RVec<RVec<size_type>> r(2);
                         ^
/home/lewhoo/software/root/root-6.38.00/include/ROOT/RVec.hxx:1562:23: error: type 'SuperClass' (aka 'RVecN<ROOT::VecOps::RVec<unsigned long>, Internal::VecOps::RVecInlineStorageSize<RVec<unsigned long> >::value>') is not a direct or virtual base of 'ROOT::VecOps::RVec<ROOT::VecOps::RVec<unsigned long> >'
   RVec(RVec &&RHS) : SuperClass(std::move(RHS)) {}
                      ^~~~~~~~~~
/home/lewhoo/software/root/root-6.38.00/include/ROOT/RVec.hxx:2617:11: note: in instantiation of member function 'ROOT::VecOps::RVec<ROOT::VecOps::RVec<unsigned long> >::RVec' requested here
   return r;
          ^
[ 65%] Linking CXX executable ../bin/genreflex
Error: /home/lewhoo/software/root/root-6.38.00/bin/rootcling: compilation failure (/home/lewhoo/software/root/root-6.38.00/lib/libROOTVecOpscab6621e6e_dictUmbrella.h)
gmake[2]: *** [math/vecops/CMakeFiles/G__ROOTVecOps.dir/build.make:81: math/vecops/G__ROOTVecOps.cxx] Error 1
gmake[1]: *** [CMakeFiles/Makefile2:54579: math/vecops/CMakeFiles/G__ROOTVecOps.dir/all] Error 2
gmake[1]: *** Waiting for unfinished jobs....

any ideas? Thanks!

May be @moneta or @jonas have an idea about this problem.

Dear @LeWhoo ,

Thanks for reaching out to the forum! Can you provide us more information about your situation?

  • Are you building ROOT sources from scratch, in a completely new directory, without any other ROOT installation present in the same environment?
  • What is the cmake command you are using?
  • What is the compiler and what its version?

Cheers,

Vincenzo

Hello,

Apologied for the naive question, but are you sure it’s Fedora 42 providing gcc15? That is actually one of the platforms of ROOT’s CI for the 636, 6.38 and main branches, which all work fine.

Cheers,
D

Thank you for your inspiration. The problem is fixed now, but I am not sure which one of the two fixed it:

  1. compiling in an environment with empty $ROOTSYS (on the first attempt it was pointing to my previous compiled version, as always)
  2. rebooting the system

Not sure about (1), because before I always compiled in an environment with older ROOT present, and it worked. (2) was unfortunately necessary, because during the recompile attempt my machine hung due to low memory (not necessarily compilation related - can’t be sure).

Replying to another question: on my Fedora 42 the GCC version is 15.2.1.