Compilation error in TTimeStamp

I am working with git commit 4622d426262ca3c3d46112fe8b684fb93b1d0835, and have the following OS/compiler configuration.

OS : Arch Linux, kernel 3.16.3-1
Compiler: gcc version 4.9.1 20140903

I have configured ROOT with the following command:

./configure --enable-roofit --enable-minuit2 --enable-soversion

I obtain the following error during compilation:


bin/rmkdepend -R -fcore/base/src/TTimeStamp.d -Y -w 1000 -- -pipe -m64 -Wshadow -Wall -W -Woverloaded-virtual -fPIC -Iinclude  -std=c++11 -Wno-deprecated-declarations -pthread -Icore/base/src -D__cplusplus -- /home/vincent/programs/sources/root/core/base/src/TTimeStamp.cxx
g++ -O2 -DNDEBUG -pipe -m64 -Wshadow -Wall -W -Woverloaded-virtual -fPIC -Iinclude  -std=c++11 -Wno-deprecated-declarations -pthread -Icore/base/src -o core/base/src/TTimeStamp.o -c /home/vincent/programs/sources/root/core/base/src/TTimeStamp.cxx
/home/vincent/programs/sources/root/core/base/src/TTimeStamp.cxx: In static member function ‘static void TTimeStamp::DumpTMStruct(const tm_t&)’:
/home/vincent/programs/sources/root/core/base/src/TTimeStamp.cxx:819:13: error: ‘const tm_t’ has no member named ‘__tm_gmtoff’
    tmstruct.__tm_gmtoff, tmstruct.__tm_zone);
             ^
/home/vincent/programs/sources/root/core/base/src/TTimeStamp.cxx:819:35: error: ‘const tm_t’ has no member named ‘__tm_zone’
    tmstruct.__tm_gmtoff, tmstruct.__tm_zone);
                                   ^
bin/rmkdepend -R -fcore/base/src/TObjString.d -Y -w 1000 -- -pipe -m64 -Wshadow -Wall -W -Woverloaded-virtual -fPIC -Iinclude  -std=c++11 -Wno-deprecated-declarations -pthread -Icore/base/src -D__cplusplus -- /home/vincent/programs/sources/root/core/base/src/TObjString.cxx
g++ -O2 -DNDEBUG -pipe -m64 -Wshadow -Wall -W -Woverloaded-virtual -fPIC -Iinclude  -std=c++11 -Wno-deprecated-declarations -pthread -Icore/base/src -o core/base/src/TObjString.o -c /home/vincent/programs/sources/root/core/base/src/TObjString.cxx
Makefile:645: recipe for target 'core/base/src/TTimeStamp.o' failed
make: *** [core/base/src/TTimeStamp.o] Error 1
make: *** Waiting for unfinished jobs....

I have tried compiling with make, make -jX (x=2,3,4), and starting from a fresh clone of the repository. Any help would be appreciated.

Hi Leroy,
I had the same problem with gcc-4.9.1-9.fc21.x86_64 and glibc-headers-2.19.90-36.fc21.x86_64

Please try patch file core/base/src/TTimeStamp.cxx in function TTimeStamp::DumpTMStruct line 816:

replace by

Jan

That did the trick. I had a feeling it was due to the BSD update for that, but couldn’t figure out where or what to add to fix it.

Thanks!

FYI, this should be fixed in the next release.

1 Like