Hello,
I am trying to run Minuit2 on my other computer. I installed root 6.22.00. I have a program called niminimzation.cpp and I try to compile it by running
g++ -I/home/christian/root/include -L/home/christian/root/lib niminimzationExample.cpp -o niminimzationExample -lMinuit2
but when I do I get the following error
/usr/bin/ld: warning: libHist.so.6.22, needed by /home/christian/root/lib/libMinuit2.so, not found (try using -rpath or -rpath-link)
/usr/bin/ld: warning: libMathCore.so.6.22, needed by /home/christian/root/lib/libMinuit2.so, not found (try using -rpath or -rpath-link)
/usr/bin/ld: warning: libCore.so.6.22, needed by /home/christian/root/lib/libMinuit2.so, not found (try using -rpath or -rpath-link)
/home/christian/root/lib/libMinuit2.so: undefined reference to `TNamed::Compare(TObject const*) const'
/home/christian/root/lib/libMinuit2.so: undefined reference to `ROOT::AddClassAlternate(char const*, char const*)'
/home/christian/root/lib/libMinuit2.so: undefined reference to `TIsAProxy::TIsAProxy(std::type_info const&)'
/home/christian/root/lib/libMinuit2.so: undefined reference to `TObject::DrawClone(char const*) const'
/home/christian/root/lib/libMinuit2.so: undefined reference to `TObject::Browse(TBrowser*)'
etc. I know that all of those libraries are in /home/christian/root/lib, so I thought I would add the ones that the error says are missing, by running,
g++ -I/home/christian/root/include niminimzationExample.cpp -o niminimzationExample -L/home/christian/root/lib -lMinuit2 -lCore -lHist
but then I get the following error:
/usr/bin/ld: warning: libMathCore.so.6.22, needed by /home/christian/root/lib/libMinuit2.so, not found (try using -rpath or -rpath-link)
/usr/bin/ld: warning: libMatrix.so.6.22, needed by /home/christian/root/lib/libHist.so, not found (try using -rpath or -rpath-link)
/usr/bin/ld: warning: libRIO.so.6.22, needed by /home/christian/root/lib/libHist.so, not found (try using -rpath or -rpath-link)
/home/christian/root/lib/libHist.so: undefined reference to `TMath::CauchyDist(double, double, double)'
/home/christian/root/lib/libHist.so: undefined reference to `ROOT::Math::GaussIntegrator::IntegralUp(double)'
/home/christian/root/lib/libHist.so: undefined reference to `TMatrixTColumn_const<double>::TMatrixTColumn_const(TMatrixT<double> const&, int)'
/home/christian/root/lib/libHist.so: undefined reference to `ROOT::Math::RichardsonDerivator::Derivative3(ROOT::Math::IBaseFunctionOneDim const&, double, double)'
/home/christian/root/lib/libHist.so: undefined reference to `TMath::BesselK0(double)'
So I am missing other libraries. Is there a way to include all of the necessary libraries at once, without having to go through all of this? On my other computer I have a stand-alone version of Minuit2 nd I can run it simply with
g++ -I/home/christian/root/include -L/home/christian/root/lib niminimzationExample.cpp -o niminimzationExample -lMinuit2
Thanks.
Christian
_ROOT Version: 6.22.00
_Platform: Linux Mint
_Compiler: gcc