Linking error with root-6.06.06

Hi,

I recently installed ROOT 6.06.06 in Ubuntu following the instructions given in [url]Memory leak in ROOT::Math::IntegratorMultiDim It works fine.

However, I’m having a problem with some code of my own using ROOT libraries. I’m compiling a class (called RootUtils) into a library, together with the dictionary:

g++ -c -I"../src" -I"/home/adrian/Soft/root-6.06.06/include" -I"/usr/include" -Wall -fPIC -std=c++1y -o ../Linux-x86_64/RootUtils.o -I../Linux-x86_64 ../Linux-x86_64/RootUtils.cc g++ -c -I"../src" -I"/home/adrian/Soft/root-6.06.06/include" -I"/usr/include" -Wall -fPIC -std=c++1y -o ../Linux-x86_64/RootUtilsDict.o -I../Linux-x86_64 ../Linux-x86_64/RootUtilsDict.cc g++ -shared -o ../Linux-x86_64/libRootUtils.so ../Linux-x86_64/RootUtils.o ../Linux-x86_64/RootUtilsDict.o -L/home/adrian/Soft/root-6.06.06/lib -lGui -lCore -lRIO -lNet -lHist -lGraf -lGraf3d -lGpad -lTree -lRint -lPostscript -lMatrix -lPhysics -lMathCore -lThread -lMultiProc -pthread -lm -ldl -rdynamic

Then, when I try to load the resulting library, I get an error:

root [0] gSystem->Load("libRootUtils"); cling::DynamicLibraryManager::loadLibrary(): libRootUtils.so: undefined symbol: _ZN5TROOT14RegisterModuleEPKcPS1_S2_S1_S1_PFvvERKSt6vectorISt4pairINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEiESaISD_EES2_
Any idea?
Thank you,
Adrian

Ah! I think I solved this myself. I added a compiler flag used to compile ROOT:
-D_GLIBCXX_USE_CXX11_ABI=0