[Cbc] Linking Cbc 2.7

Kevin Tierney kevt at itu.dk
Mon Nov 28 17:52:53 EST 2011


Dear all,

I am getting an error linking to Cbc 2.7 (from the SVN and 2.7.5), and I 
was hoping somebody has a suggestion.

I built Cbc from source, including the third party libraries.

With the following linker command, I am receiving the following error:

g++ MipModelACoin.o MipModelA.o  main.o -m64 
-L/home/kevt/Utilities/coin/coin-Cbc/lib 
-L/home/kevt/Utilities/coin/coin-Cbc/ThirdParty/Lapack/lib 
-L/home/kevt/Utilities/coin/coin-Cbc/ThirdParty/Blas/lib -lCbc 
-lCbcSolver -lCgl -lOsi -lOsiCbc -lOsiClp -lClp -lCoinUtils -lcoinlapack 
-lcoinblas -lgfortran -lm -o mip

/home/kevt/Utilities/coin/coin-Cbc/lib/libOsiCbc.so: undefined reference 
to `CbcModel::CbcModel(CbcModel const&, bool)'
/home/kevt/Utilities/coin/coin-Cbc/lib/libOsiCbc.so: undefined reference 
to `CbcStrategyDefault::~CbcStrategyDefault()'
/home/kevt/Utilities/coin/coin-Cbc/lib/libOsiCbc.so: undefined reference 
to `CbcModel::setStrategy(CbcStrategy&)'
/home/kevt/Utilities/coin/coin-Cbc/lib/libOsiCbc.so: undefined reference 
to `CbcStrategyDefault::CbcStrategyDefault(int, int, int, int)'
/home/kevt/Utilities/coin/coin-Cbc/lib/libOsiCbc.so: undefined reference 
to `CbcModel::CbcModel(OsiSolverInterface const&)'
/home/kevt/Utilities/coin/coin-Cbc/lib/libOsiCbc.so: undefined reference 
to `CbcModel::~CbcModel()'
/home/kevt/Utilities/coin/coin-Cbc/lib/libOsiCbc.so: undefined reference 
to `CbcModel::passInMessageHandler(CoinMessageHandler*)'
/home/kevt/Utilities/coin/coin-Cbc/lib/libOsiCbc.so: undefined reference 
to `CbcModel::branchAndBound(int)'
collect2: ld returned 1 exit status

Does anyone know why that error is happening? It doesn't really make any 
sense to me, since I have the libCbc library int he same directory as 
the libOsiCbc library (they were built together at the same time...)

My system is Ubuntu 11.10 64bit.

Thanks for your help.

Kevin


More information about the Cbc mailing list