Failing to find TMVA shared lib in Mac OS X 10.9 and ROOT 34

hi all

sorry if this is not the right forum of if the topic has been discussed already. i just upgraded my local ROOT build on my Apple laptop to ROOT 5.34/18 and i’m trying to use TMVA. when i go to my tmva/test directory and try to launch ROOT, i get:

[~/local/root/tmva/test]$ root -l
Error in TMacOSXSystem::DynamicPathName: libTMVA.1[.so | .dll | .dylib | .sl | .dl | .a] does not exist in $TMVASYS/lib:/Users/pandolf/local/root/lib:/Users/pandolf/local/root/lib:/Users/pandolf/local/root/lib:/Users/pandolf/local/BAT-0.2.1/lib::$TMVASYS/lib:/Users/pandolf/local/root/lib:/Users/pandolf/local/root/cint/cint/stl

now i’m not really sure i understand what it’s looking for, but i did verify that the following file exists:

[~/local/root/tmva]$ ll ~/local/root/lib/libTMVA.so
-rwxr-xr-x 1 pandolf staff 6408156 May 12 14:00 …/lib/libTMVA.so

any helpers?

thanks in advance
f

It looks like you have not enabled tmva at configure time.
With the option:

--enable-tmva

hey thanks for the quick reply

not sure i understand exactly what you mean but if i do:

[~/local/root/tmva/test]$ root -l --enable-tmva

i get the same error. plus if i check if tmva is enabled with this:

[~/local/root/tmva]$ root-config --has-tmva
yes

i get yes.

f

Ok … --enable-tmva is not a root option, it is an option at configure time when you do the configure command before building root.
It looks like you have not done that . Anyway tmva seems enabled with the root you have.
I will ask my colleague, who knows better about it, to help you.

Hi,

I think there is problem in the test/TMVAlogon.C file where it tries to load libTMVA.1.so instead of libTMVA.so.
We will fix this issue, in the meantime you can edit the file and comment the line, which is not actually needed anymore

Lorenzo

hey lorenzo

thanks for the help. it does seem to solve the problem, as in the error message goes away now. but then when i try to compile the classification macro i get an error:

[~/local/root/tmva/test]$ root -l

TMVA – Toolkit for Multivariate Data Analysis
Version 4.2.0, Sep 19, 2013
Copyright © 2005-2010 CERN, MPI-K Heidelberg, Us of Bonn and Victoria
Home page: tmva.sf.net
Citation info: tmva.sf.net/citeTMVA.html
License: tmva.sf.net/LICENSE

TMVAlogon: use “TMVA” style [TMVA style based on “Plain” with modifications defined in tmvaglob.C]

root [0] .L TMVAClassification.C++
Info in TMacOSXSystem::ACLiC: creating shared library /Users/pandolf/local/root/tmva/test/./TMVAClassification_C.so
In file included from /Users/pandolf/local/root/tmva/test/TMVAClassification_C_ACLiC_dict.cxx:17:
In file included from /Users/pandolf/local/root/tmva/test/TMVAClassification_C_ACLiC_dict.h:34:
/Users/pandolf/local/root/tmva/test/./TMVAClassification.C:496:27: error: use of undeclared identifier 'TMVAGui’
if (!gROOT->IsBatch()) TMVAGui( outfileName );
^
1 error generated.
clang: error: no such file or directory: '/Users/pandolf/local/root/tmva/test/TMVAClassification_C_ACLiC_dict.o’
Error in : Compilation failed!

any ideas on what i might be doing wrong now?

f

Hi,

Maybe you realized it by now but its the line that calls the TMVAGui function in TMVAGUI.C, comment it and when the results be ready load the TMVAGUI.C, (.L TMVAGUI.C) file and call the function ( TMVAGUI() ). if you just run it .x TMVAclasification.C without compiling its also going to work. But the function is not defined inside the code so its not going to compile.