Dear experts,
I opened this thread before:
The problem was not solved.
I reinstalled the root from scratch.
Now I have root:
ROOT Version: 6.31/01
Built for macosx64 on Apr 02 2024, 07:12:29
From heads/master@62a7ea31
Yet I am having the same problem with linking the shared libraries.
A simple test case is kept here:
I am making the repository using cmake
on my Mac:
inside the test
repository:
mkdir build
cd build
cmake ../ -DCMAKE_CXX_STANDARD=17
cmake --build . --verbose
This is the verbose message during compilation:
/usr/local/Cellar/cmake/3.25.0/bin/cmake -S/Users/arkasantra/tmp/test -B/Users/arkasantra/tmp/test/build --check-build-system CMakeFiles/Makefile.cmake 0
/usr/local/Cellar/cmake/3.25.0/bin/cmake -E cmake_progress_start /Users/arkasantra/tmp/test/build/CMakeFiles /Users/arkasantra/tmp/test/build//CMakeFiles/progress.marks
/Applications/Xcode.app/Contents/Developer/usr/bin/make -f CMakeFiles/Makefile2 all
/Applications/Xcode.app/Contents/Developer/usr/bin/make -f CMakeFiles/G__LUXESimEventDict.dir/build.make CMakeFiles/G__LUXESimEventDict.dir/depend
[ 33%] Generating G__LUXESimEventDict.cxx, libLUXESimEventDict_rdict.pcm, libLUXESimEventDict.rootmap
/usr/local/Cellar/cmake/3.25.0/bin/cmake -E env DYLD_LIBRARY_PATH=/Users/arkasantra/Root6_Install/lib:/usr/X11R6/lib:/Users/arkasantra/ACTSTracking/build/lib:/Users/arkasantra/opt/anaconda3/lib:/usr/local/lib:/Users/arkasantra/Geant4_Install/lib:/Users/arkasantra/Root6_Install/lib:/Users/arkasantra/Allpix2/version2_Allpix2/allpix-squared/lib:/Users/arkasantra/pythia8311/lib:/Users/arkasantra/ExRootAnalysis:/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/lib:/Users/arkasantra/LHAPDF6_Build/lib:/Users/arkasantra/FastJet3_Build/lib:/Users/arkasantra/YODA_Build/lib:/Users/arkasantra/ACTSTracking/install/lib:/Users/arkasantra/Root6_Install/lib /Users/arkasantra/Root6_Install/bin/rootcling -v2 -f G__LUXESimEventDict.cxx -s /Users/arkasantra/tmp/test/build/libLUXESimEventDict.dylib -rml libLUXESimEventDict.dylib -rmf /Users/arkasantra/tmp/test/build/libLUXESimEventDict.rootmap -compilerI/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX14.4.sdk/usr/include/c++/v1 -compilerI/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/15.0.0/include -compilerI/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX14.4.sdk/usr/include -compilerI/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include -compilerI/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/15.0.0/include -compilerI/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX14.4.sdk/usr/include -compilerI/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include -I/Users/arkasantra/tmp/test -I/Users/arkasantra/tmp/test /Users/arkasantra/tmp/test/dummy.h /Users/arkasantra/tmp/test/LinkDef.h
cd /Users/arkasantra/tmp/test/build && /usr/local/Cellar/cmake/3.25.0/bin/cmake -E cmake_depends "Unix Makefiles" /Users/arkasantra/tmp/test /Users/arkasantra/tmp/test /Users/arkasantra/tmp/test/build /Users/arkasantra/tmp/test/build /Users/arkasantra/tmp/test/build/CMakeFiles/G__LUXESimEventDict.dir/DependInfo.cmake --color=
Dependee "/Users/arkasantra/tmp/test/build/CMakeFiles/G__LUXESimEventDict.dir/DependInfo.cmake" is newer than depender "/Users/arkasantra/tmp/test/build/CMakeFiles/G__LUXESimEventDict.dir/depend.internal".
Dependee "/Users/arkasantra/tmp/test/build/CMakeFiles/CMakeDirectoryInformation.cmake" is newer than depender "/Users/arkasantra/tmp/test/build/CMakeFiles/G__LUXESimEventDict.dir/depend.internal".
Scanning dependencies of target G__LUXESimEventDict
/Applications/Xcode.app/Contents/Developer/usr/bin/make -f CMakeFiles/G__LUXESimEventDict.dir/build.make CMakeFiles/G__LUXESimEventDict.dir/build
[ 66%] Building CXX object CMakeFiles/G__LUXESimEventDict.dir/G__LUXESimEventDict.cxx.o
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/c++ -I/Users/arkasantra/tmp/test -isystem /Users/arkasantra/Root6_Install/include -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX14.4.sdk -fPIC -std=gnu++17 -MD -MT CMakeFiles/G__LUXESimEventDict.dir/G__LUXESimEventDict.cxx.o -MF CMakeFiles/G__LUXESimEventDict.dir/G__LUXESimEventDict.cxx.o.d -o CMakeFiles/G__LUXESimEventDict.dir/G__LUXESimEventDict.cxx.o -c /Users/arkasantra/tmp/test/build/G__LUXESimEventDict.cxx
[ 66%] Built target G__LUXESimEventDict
/Applications/Xcode.app/Contents/Developer/usr/bin/make -f CMakeFiles/LUXESimEventDict.dir/build.make CMakeFiles/LUXESimEventDict.dir/depend
cd /Users/arkasantra/tmp/test/build && /usr/local/Cellar/cmake/3.25.0/bin/cmake -E cmake_depends "Unix Makefiles" /Users/arkasantra/tmp/test /Users/arkasantra/tmp/test /Users/arkasantra/tmp/test/build /Users/arkasantra/tmp/test/build /Users/arkasantra/tmp/test/build/CMakeFiles/LUXESimEventDict.dir/DependInfo.cmake --color=
/Applications/Xcode.app/Contents/Developer/usr/bin/make -f CMakeFiles/LUXESimEventDict.dir/build.make CMakeFiles/LUXESimEventDict.dir/build
[100%] Linking CXX shared library libLUXESimEventDict.dylib
/usr/local/Cellar/cmake/3.25.0/bin/cmake -E cmake_link_script CMakeFiles/LUXESimEventDict.dir/link.txt --verbose=1
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/c++ -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX14.4.sdk -dynamiclib -Wl,-headerpad_max_install_names -L/usr/local/opt/qt@5/lib -o libLUXESimEventDict.dylib -install_name @rpath/libLUXESimEventDict.dylib CMakeFiles/G__LUXESimEventDict.dir/G__LUXESimEventDict.cxx.o
Undefined symbols for architecture x86_64:
"Fatal(char const*, char const*, ...)", referenced from:
ROOT::Detail::TCollectionProxyInfo::Iterators<std::__1::vector<std::__1::tuple<int, double>, std::__1::allocator<std::__1::tuple<int, double>>>, false>::next(void*, void const*) in G__LUXESimEventDict.cxx.o
"TVersionCheck::TVersionCheck(int)", referenced from:
___cxx_global_var_init in G__LUXESimEventDict.cxx.o
"ROOT::AddClassAlternate(char const*, char const*)", referenced from:
ROOT::GenerateInitInstanceLocal(std::__1::vector<std::__1::tuple<int, double>, std::__1::allocator<std::__1::tuple<int, double>>> const*) in G__LUXESimEventDict.cxx.o
ROOT::GenerateInitInstanceLocal(std::__1::map<unsigned long, std::__1::vector<std::__1::tuple<int, double>, std::__1::allocator<std::__1::tuple<int, double>>>, std::__1::less<unsigned long>, std::__1::allocator<std::__1::pair<unsigned long const, std::__1::vector<std::__1::tuple<int, double>, std::__1::allocator<std::__1::tuple<int, double>>>>>> const*) in G__LUXESimEventDict.cxx.o
"ROOT::Class_ShowMembers(TClass*, void const*, TMemberInspector&)", referenced from:
Dummy::ShowMembers(TMemberInspector&) const in G__LUXESimEventDict.cxx.o
"ROOT::TGenericClassInfo::SetNewArray(void* (*)(long, void*))", referenced from:
ROOT::GenerateInitInstanceLocal(Dummy const*) in G__LUXESimEventDict.cxx.o
ROOT::GenerateInitInstanceLocal(std::__1::vector<std::__1::tuple<int, double>, std::__1::allocator<std::__1::tuple<int, double>>> const*) in G__LUXESimEventDict.cxx.o
ROOT::GenerateInitInstanceLocal(std::__1::map<unsigned long, std::__1::vector<std::__1::tuple<int, double>, std::__1::allocator<std::__1::tuple<int, double>>>, std::__1::less<unsigned long>, std::__1::allocator<std::__1::pair<unsigned long const, std::__1::vector<std::__1::tuple<int, double>, std::__1::allocator<std::__1::tuple<int, double>>>>>> const*) in G__LUXESimEventDict.cxx.o
"ROOT::TGenericClassInfo::SetDestructor(void (*)(void*))", referenced from:
ROOT::GenerateInitInstanceLocal(Dummy const*) in G__LUXESimEventDict.cxx.o
ROOT::GenerateInitInstanceLocal(std::__1::vector<std::__1::tuple<int, double>, std::__1::allocator<std::__1::tuple<int, double>>> const*) in G__LUXESimEventDict.cxx.o
ROOT::GenerateInitInstanceLocal(std::__1::map<unsigned long, std::__1::vector<std::__1::tuple<int, double>, std::__1::allocator<std::__1::tuple<int, double>>>, std::__1::less<unsigned long>, std::__1::allocator<std::__1::pair<unsigned long const, std::__1::vector<std::__1::tuple<int, double>, std::__1::allocator<std::__1::tuple<int, double>>>>>> const*) in G__LUXESimEventDict.cxx.o
"ROOT::TGenericClassInfo::AdoptAlternate(ROOT::TClassAlt*)", referenced from:
ROOT::GenerateInitInstanceLocal(std::__1::vector<std::__1::tuple<int, double>, std::__1::allocator<std::__1::tuple<int, double>>> const*) in G__LUXESimEventDict.cxx.o
ROOT::GenerateInitInstanceLocal(std::__1::map<unsigned long, std::__1::vector<std::__1::tuple<int, double>, std::__1::allocator<std::__1::tuple<int, double>>>, std::__1::less<unsigned long>, std::__1::allocator<std::__1::pair<unsigned long const, std::__1::vector<std::__1::tuple<int, double>, std::__1::allocator<std::__1::tuple<int, double>>>>>> const*) in G__LUXESimEventDict.cxx.o
"ROOT::TGenericClassInfo::SetDeleteArray(void (*)(void*))", referenced from:
ROOT::GenerateInitInstanceLocal(Dummy const*) in G__LUXESimEventDict.cxx.o
ROOT::GenerateInitInstanceLocal(std::__1::vector<std::__1::tuple<int, double>, std::__1::allocator<std::__1::tuple<int, double>>> const*) in G__LUXESimEventDict.cxx.o
ROOT::GenerateInitInstanceLocal(std::__1::map<unsigned long, std::__1::vector<std::__1::tuple<int, double>, std::__1::allocator<std::__1::tuple<int, double>>>, std::__1::less<unsigned long>, std::__1::allocator<std::__1::pair<unsigned long const, std::__1::vector<std::__1::tuple<int, double>, std::__1::allocator<std::__1::tuple<int, double>>>>>> const*) in G__LUXESimEventDict.cxx.o
"ROOT::TGenericClassInfo::GetImplFileLine()", referenced from:
Dummy::ImplFileLine() in G__LUXESimEventDict.cxx.o
"ROOT::TGenericClassInfo::GetImplFileName()", referenced from:
Dummy::ImplFileName() in G__LUXESimEventDict.cxx.o
"ROOT::TGenericClassInfo::AdoptCollectionProxyInfo(ROOT::Detail::TCollectionProxyInfo*)", referenced from:
ROOT::GenerateInitInstanceLocal(std::__1::vector<std::__1::tuple<int, double>, std::__1::allocator<std::__1::tuple<int, double>>> const*) in G__LUXESimEventDict.cxx.o
ROOT::GenerateInitInstanceLocal(std::__1::map<unsigned long, std::__1::vector<std::__1::tuple<int, double>, std::__1::allocator<std::__1::tuple<int, double>>>, std::__1::less<unsigned long>, std::__1::allocator<std::__1::pair<unsigned long const, std::__1::vector<std::__1::tuple<int, double>, std::__1::allocator<std::__1::tuple<int, double>>>>>> const*) in G__LUXESimEventDict.cxx.o
"ROOT::TGenericClassInfo::SetNew(void* (*)(void*))", referenced from:
ROOT::GenerateInitInstanceLocal(Dummy const*) in G__LUXESimEventDict.cxx.o
ROOT::GenerateInitInstanceLocal(std::__1::vector<std::__1::tuple<int, double>, std::__1::allocator<std::__1::tuple<int, double>>> const*) in G__LUXESimEventDict.cxx.o
ROOT::GenerateInitInstanceLocal(std::__1::map<unsigned long, std::__1::vector<std::__1::tuple<int, double>, std::__1::allocator<std::__1::tuple<int, double>>>, std::__1::less<unsigned long>, std::__1::allocator<std::__1::pair<unsigned long const, std::__1::vector<std::__1::tuple<int, double>, std::__1::allocator<std::__1::tuple<int, double>>>>>> const*) in G__LUXESimEventDict.cxx.o
"ROOT::TGenericClassInfo::GetClass()", referenced from:
Dummy::Dictionary() in G__LUXESimEventDict.cxx.o
Dummy::Class() in G__LUXESimEventDict.cxx.o
ROOT::vectorlEtuplelEintcOdoublegRsPgR_Dictionary() in G__LUXESimEventDict.cxx.o
ROOT::maplEunsignedsPlongcOvectorlEtuplelEintcOdoublegRsPgRsPgR_Dictionary() in G__LUXESimEventDict.cxx.o
"ROOT::TGenericClassInfo::SetDelete(void (*)(void*))", referenced from:
ROOT::GenerateInitInstanceLocal(Dummy const*) in G__LUXESimEventDict.cxx.o
ROOT::GenerateInitInstanceLocal(std::__1::vector<std::__1::tuple<int, double>, std::__1::allocator<std::__1::tuple<int, double>>> const*) in G__LUXESimEventDict.cxx.o
ROOT::GenerateInitInstanceLocal(std::__1::map<unsigned long, std::__1::vector<std::__1::tuple<int, double>, std::__1::allocator<std::__1::tuple<int, double>>>, std::__1::less<unsigned long>, std::__1::allocator<std::__1::pair<unsigned long const, std::__1::vector<std::__1::tuple<int, double>, std::__1::allocator<std::__1::tuple<int, double>>>>>> const*) in G__LUXESimEventDict.cxx.o
"ROOT::TGenericClassInfo::TGenericClassInfo(char const*, int, char const*, int, std::type_info const&, ROOT::Internal::TInitBehavior const*, TClass* (*)(), TVirtualIsAProxy*, int, int)", referenced from:
ROOT::GenerateInitInstanceLocal(Dummy const*) in G__LUXESimEventDict.cxx.o
ROOT::GenerateInitInstanceLocal(std::__1::vector<std::__1::tuple<int, double>, std::__1::allocator<std::__1::tuple<int, double>>> const*) in G__LUXESimEventDict.cxx.o
ROOT::GenerateInitInstanceLocal(std::__1::map<unsigned long, std::__1::vector<std::__1::tuple<int, double>, std::__1::allocator<std::__1::tuple<int, double>>>, std::__1::less<unsigned long>, std::__1::allocator<std::__1::pair<unsigned long const, std::__1::vector<std::__1::tuple<int, double>, std::__1::allocator<std::__1::tuple<int, double>>>>>> const*) in G__LUXESimEventDict.cxx.o
"ROOT::TGenericClassInfo::~TGenericClassInfo()", referenced from:
ROOT::GenerateInitInstanceLocal(Dummy const*) in G__LUXESimEventDict.cxx.o
ROOT::GenerateInitInstanceLocal(std::__1::vector<std::__1::tuple<int, double>, std::__1::allocator<std::__1::tuple<int, double>>> const*) in G__LUXESimEventDict.cxx.o
ROOT::GenerateInitInstanceLocal(std::__1::map<unsigned long, std::__1::vector<std::__1::tuple<int, double>, std::__1::allocator<std::__1::tuple<int, double>>>, std::__1::less<unsigned long>, std::__1::allocator<std::__1::pair<unsigned long const, std::__1::vector<std::__1::tuple<int, double>, std::__1::allocator<std::__1::tuple<int, double>>>>>> const*) in G__LUXESimEventDict.cxx.o
"ROOT::Internal::DefineBehavior(void*, void*)", referenced from:
ROOT::GenerateInitInstanceLocal(Dummy const*) in G__LUXESimEventDict.cxx.o
ROOT::GenerateInitInstanceLocal(std::__1::vector<std::__1::tuple<int, double>, std::__1::allocator<std::__1::tuple<int, double>>> const*) in G__LUXESimEventDict.cxx.o
ROOT::GenerateInitInstanceLocal(std::__1::map<unsigned long, std::__1::vector<std::__1::tuple<int, double>, std::__1::allocator<std::__1::tuple<int, double>>>, std::__1::less<unsigned long>, std::__1::allocator<std::__1::pair<unsigned long const, std::__1::vector<std::__1::tuple<int, double>, std::__1::allocator<std::__1::tuple<int, double>>>>>> const*) in G__LUXESimEventDict.cxx.o
"ROOT::Internal::HasConsistentHashMember(char const*)", referenced from:
Dummy::CheckTObjectHashConsistency() const in G__LUXESimEventDict.cxx.o
"ROOT::Internal::HasConsistentHashMember(TClass&)", referenced from:
Dummy::CheckTObjectHashConsistency() const in G__LUXESimEventDict.cxx.o
"TROOT::RegisterModule(char const*, char const**, char const**, char const*, char const*, void (*)(), std::__1::vector<std::__1::pair<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>, int>, std::__1::allocator<std::__1::pair<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>, int>>> const&, char const**, bool)", referenced from:
(anonymous namespace)::TriggerDictionaryInitialization_libLUXESimEventDict_Impl() in G__LUXESimEventDict.cxx.o
"TIsAProxy::TIsAProxy(std::type_info const&)", referenced from:
ROOT::GenerateInitInstanceLocal(std::__1::vector<std::__1::tuple<int, double>, std::__1::allocator<std::__1::tuple<int, double>>> const*) in G__LUXESimEventDict.cxx.o
ROOT::GenerateInitInstanceLocal(std::__1::map<unsigned long, std::__1::vector<std::__1::tuple<int, double>, std::__1::allocator<std::__1::tuple<int, double>>>, std::__1::less<unsigned long>, std::__1::allocator<std::__1::pair<unsigned long const, std::__1::vector<std::__1::tuple<int, double>, std::__1::allocator<std::__1::tuple<int, double>>>>>> const*) in G__LUXESimEventDict.cxx.o
"_gInterpreterMutex", referenced from:
Dummy::Class() in G__LUXESimEventDict.cxx.o
"_kAssertMsg", referenced from:
ROOT::Detail::TCollectionProxyInfo::Iterators<std::__1::vector<std::__1::tuple<int, double>, std::__1::allocator<std::__1::tuple<int, double>>>, false>::next(void*, void const*) in G__LUXESimEventDict.cxx.o
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
make[2]: *** [libLUXESimEventDict.dylib] Error 1
make[1]: *** [CMakeFiles/LUXESimEventDict.dir/all] Error 2
make: *** [all] Error 2
I will be grateful if you help me solve this issue.
Thank you,
Arka
_ROOT Version: 6.31/01
_Platform: MacOS (x86_64, Intel i9)
_Compiler: AppleClang 15.0.0.15000309