Dear all,
I am trying to run a code and I got an error which I think it is related to some sort of missmatch between the root compiler and the cluster compiler… The copy paste of the terminal window is like this…
The modules I load are the following:
ml GCC/11.2.0 OpenMPI/4.1.1 ROOT/6.24.06 CMake/3.22.1
Is there anyone who was facing the same problem and knows how to deal with it?
Thanks a lot!
Robert
(baobab)-[amarinei@login2 sFGD_unpacking]$ cd build/
(baobab)-[amarinei@login2 build]$ cmake ..
Looking for Root...
-- found in /opt/ebsofts/ROOT/6.24.06-foss-2021b/bin/root
-- version : 6.24/06
-- C flags :
-- CXX flags : -Wall -O3 -std=c++14 -m64 -stdlib=libc++
-- Linker flags :
-- src ...
-- examples ...
-- Configuring done
-- Generating done
-- Build files have been written to: /home/amarinei/Year1_PhD/TPC/MPPC_array/Scripts/sFGD_unpacking/build
(baobab)-[amarinei@login2 build]$ make
Scanning dependencies of target SuperFGDUnpack
Consolidate compiler generated dependencies of target SuperFGDUnpack
[ 4%] Building CXX object src/CMakeFiles/SuperFGDUnpack.dir/Event.cc.o
c++: error: unrecognized command-line option '-stdlib=libc++'
make[2]: *** [src/CMakeFiles/SuperFGDUnpack.dir/Event.cc.o] Error 1
make[1]: *** [src/CMakeFiles/SuperFGDUnpack.dir/all] Error 2
make: *** [all] Error 2
(baobab)-[amarinei@login2 build]$
Hi, it is working for me. I copied the directory sFGD_unpacking
from your home directory and removed everything from the build
directory except the file FindROOT.cmake
. Then I was able to compile:
(baobab)-[sagon@login2 build]$ cmake ..
Looking for Root...
-- found in /opt/ebsofts/ROOT/6.24.06-foss-2021b/bin/root
-- version : 6.24/06
-- C flags :
-- CXX flags :
-- Linker flags :
-- src ...
-- examples ...
-- Configuring done
-- Generating done
-- Build files have been written to: /home/sagon/tests/sFGD_unpacking/build
(baobab)-[sagon@login2 build]$ make -j 4
[ 4%] Generating EventDictionary.cxx, libEventStructure_rdict.pcm, libEventStructure.rootmap
Scanning dependencies of target SuperFGDUnpack
[ 18%] Building CXX object src/CMakeFiles/SuperFGDUnpack.dir/Hit.cc.o
[ 22%] Building CXX object src/CMakeFiles/SuperFGDUnpack.dir/Event.cc.o
[ 22%] Building CXX object src/CMakeFiles/SuperFGDUnpack.dir/MDdataFile.cpp.o
[ 22%] Building CXX object src/CMakeFiles/SuperFGDUnpack.dir/MDargumentHandler.cpp.o
[ 27%] Building CXX object src/CMakeFiles/SuperFGDUnpack.dir/MDdataWordBM.cpp.o
[ 31%] Building CXX object src/CMakeFiles/SuperFGDUnpack.dir/MDexception.cpp.o
[ 40%] Building CXX object src/CMakeFiles/SuperFGDUnpack.dir/MDfragmentBM.cpp.o
[ 40%] Building CXX object src/CMakeFiles/SuperFGDUnpack.dir/MDpartEventBM.cpp.o
[ 45%] Building C object src/CMakeFiles/SuperFGDUnpack.dir/aa.c.o
[ 50%] Building CXX object src/CMakeFiles/SuperFGDUnpack.dir/EventDictionary.cxx.o
[ 54%] Linking CXX shared library ../../lib/libSuperFGDUnpack.so
gmake[3]: warning: jobserver unavailable: using -j1. Add `+' to parent make rule.
Consolidate compiler generated dependencies of target SuperFGDUnpack
[ 54%] Built target SuperFGDUnpack
[ 59%] Building CXX object macros/CMakeFiles/unpack.dir/Unpack.cpp.o
[ 63%] Linking CXX executable ../../bin/unpack
[ 63%] Built target unpack
[ 68%] Building CXX object macros/CMakeFiles/CreatePlots.dir/CreatePlots.cpp.o
[ 72%] Linking CXX executable ../../bin/CreatePlots
[ 72%] Built target CreatePlots
[ 77%] Building CXX object macros/CMakeFiles/CreateEvents.dir/CreateEvents.cpp.o
[ 81%] Linking CXX executable ../../bin/CreateEvents
[ 81%] Built target CreateEvents
[ 86%] Building CXX object macros/CMakeFiles/CreateEventsTPC.dir/CreateEventsTPC.cpp.o
[ 90%] Linking CXX executable ../../bin/CreateEventsTPC
[ 90%] Built target CreateEventsTPC
[ 95%] Building CXX object macros/CMakeFiles/EventPlots.dir/EventPlots.cpp.o
[100%] Linking CXX executable ../../bin/EventPlots
[100%] Built target EventPlots
Install the project...
-- Install configuration: ""
-- Installing: /home/sagon/tests/sFGD_unpacking/lib/libEventStructure_rdict.pcm
-- Installing: /home/sagon/tests/sFGD_unpacking/lib/libEventStructure.rootmap
-- Installing: /home/sagon/tests/sFGD_unpacking/lib/EventDictionary.cxx
Built target SuperFGDUnpack
Consolidate compiler generated dependencies of target CreatePlots
Consolidate compiler generated dependencies of target unpack
Consolidate compiler generated dependencies of target CreateEventsTPC
Consolidate compiler generated dependencies of target CreateEvents
Built target CreatePlots
Built target unpack
Built target CreateEvents
Built target CreateEventsTPC
Consolidate compiler generated dependencies of target EventPlots
Built target EventPlots