[Coin-discuss] OSX 10.2.8, CoinTime.hpp and Sbb

Sven de Vries devries at ma.tum.de
Thu Oct 30 06:04:10 EST 2003


Hi,

tried to build Sbb on my mac.
first it complains :

Compiling OsiClpSolverInterface.cpp
In file included from /Users/devries/COIN/include/CoinTime.hpp:14,
                 from OsiClpSolverInterface.cpp:6:
/usr/include/sys/resource.h:81: field `ru_utime' has incomplete type
/usr/include/sys/resource.h:82: field `ru_stime' has incomplete type
/usr/include/sys/resource.h:124: 'rlim_t' is used as a type, but is not
defined
   as a type.
/usr/include/sys/resource.h:125: 'rlim_t' is used as a type, but is not
defined
   as a type.
/usr/include/sys/resource.h:130: parse error before `[' token
In file included from OsiClpSolverInterface.cpp:6:
/Users/devries/COIN/include/CoinTime.hpp: In function `double
CoinCpuTime()':
/Users/devries/COIN/include/CoinTime.hpp:31: `struct rusage' has no member
   named `ru_utime'
/Users/devries/COIN/include/CoinTime.hpp:32: `struct rusage' has no member
   named `ru_utime'


on my machine the following chang of CoinTime.hpp worked:
#include <ctime>
#if defined(_MSC_VER)
// Turn off compiler warning about long names
#  pragma warning(disable:4786)
#else
#include <sys/resource.h>
#endif

into:
#include <ctime>
#if defined(_MSC_VER)
// Turn off compiler warning about long names
#  pragma warning(disable:4786)
#else
// for macosx
#include <sys/time.h>
//
#include <sys/resource.h>
#endif

what's the way to get that incorporated?

then Sbb compiles, but for the Sbb unitTest the linker complains:

make -f Makefile.test

Creating sbb
g++ -I-  -Wall -Wpointer-arith -Wcast-qual -Wwrite-strings -Wconversion
-Wstrict-prototypes -Wmissing-prototype
s -pipe -DCOIN_USE_CLP -g -DSBB_DEBUG -I./include
-I/Users/devries/COIN/Sbb/include -I/Users/devries/COIN/inclu
de -I/Users/devries/COIN/include -I/Users/devries/COIN/include
-I/Users/devries/COIN/Clp/include -I/Users/devri
es/COIN/include -DCOIN_USE_BZLIB -DCOIN_USE_ZLIB -o Darwin-g/sbb
Darwin-g/SbbMain.o Darwin-g/SbbParam.o Darwin-
g/unitTest.o -L/Users/devries/COIN/lib -L/Users/devries/COIN/lib
-L/Users/devries/COIN/lib -L/Users/devries/COI
N/lib -L/Users/devries/COIN/lib -L/Users/devries/COIN/lib  -lSbb -lCgl
-lOsi -lCoin -lOsiClp -lClp -lbz2 -lz
 -lm
ld: warning table of contents of library:
/Users/devries/COIN/lib/libCoin.a not sorted slower link editing will
 result (use the ranlib(1) -s option)
ld: Undefined symbols:
OsiSimplexInterface::OsiSimplexInterface[not-in-charge]()
OsiSimplexInterface::~OsiSimplexInterface [not-in-charge]()
make_fixed(CoinPresolveMatrix*, CoinPresolveAction const*)
drop_zero_coefficients(CoinPresolveMatrix*, CoinPresolveAction const*)
presolve_make_memlists(int*, int*, presolvehlink*, int)
dupcol_action::presolve(CoinPresolveMatrix*, CoinPresolveAction const*)
duprow_action::presolve(CoinPresolveMatrix*, CoinPresolveAction const*)
doubleton_action::presolve(CoinPresolveMatrix*, CoinPresolveAction const*)
tripleton_action::presolve(CoinPresolveMatrix*, CoinPresolveAction const*)
do_tighten_action::presolve(CoinPresolveMatrix*, CoinPresolveAction
const*)
CoinPresolveAction::throwCoinError(char const*, char const*)
CoinPresolveMatrix::~CoinPresolveMatrix [in-charge]()
remove_dual_action::presolve(CoinPresolveMatrix*, CoinPresolveAction
const*)
CoinPostsolveMatrix::check_nbasic()
CoinPostsolveMatrix::~CoinPostsolveMatrix [in-charge]()
implied_free_action::presolve(CoinPresolveMatrix*, CoinPresolveAction
const*, int&)
CoinPrePostsolveMatrix::~CoinPrePostsolveMatrix [not-in-charge]()
drop_empty_cols_action::presolve(CoinPresolveMatrix*, CoinPresolveAction
const*)
drop_empty_rows_action::presolve(CoinPresolveMatrix*, CoinPresolveAction
const*)
slack_doubleton_action::presolve(CoinPresolveMatrix*, CoinPresolveAction
const*, bool&)
forcing_constraint_action::presolve(CoinPresolveMatrix*,
CoinPresolveAction const*)
make[2]: *** [Darwin-g/sbb] Error 1
make[1]: *** [unitTest] Error 2
make: *** [unitTest] Error 2


(sorry about the line-wrapping).

Any advice how to get it compile?

greetings!
sven




More information about the Coin-discuss mailing list