I’m trying to use a STL map container with ROOT objects, for example
Following Phillipe’s instructions on an old forum post, I created the file loader.C
#include <pair>
#ifdef _MAKECINT_
#pragma link C++ class pair<float, TString>+;
#endif
and modified my macro to include
Unfortunately the compilation fails
Info in <TUnixSystem::ACLiC>: creating shared library /Users/Zeplin/Desktop/././loader_C.so
In file included from /Users/Zeplin/Desktop/././tmp_0_k1yGCR.h:32,
from /Users/Zeplin/Desktop/././tmp_0_k1yGCR.cxx:16:
/Users/Zeplin/Desktop/././loader.C:1:16: error: pair: No such file or directory
powerpc-apple-darwin8-g++-4.0.1: /Users/Zeplin/Desktop/././tmp_0_k1yGCR.o: No such file or directory
powerpc-apple-darwin8-g++-4.0.1: no input files
Error in <ACLiC>: Compilation failed!
Error: Can't call map<float,TString,less<float>,allocator<pair<const float,TString> > >::operator[]((int)1) in current scope test.C:13:
Possible candidates are...
(in map<float,TString,less<float>,allocator<pair<const float,TString> > >)
Error: improper lvalue test.C:13:
I’m using ROOT 5.14/00e installed on OS X 10.4 via Fink. Has anyone encountered this problem before?
Thanks.