[Coin-discuss] COIN on a Mac

ScottWelz at aol.com ScottWelz at aol.com
Sat Jan 4 17:25:06 EST 2003


Matt,

You are correct.   I resolved this issue while I was also working through a 
couple of other issues and forgot to go back and dig deeper on this one.   
Darwin does indeed have the proper time.h header where it is supposed to be.

It turns out that my issue was that the structure "timeval" was not declared. 
  This results in the "rusage" structure (which uses timeval) in resource.h 
not behaving properly.   The "timeval" structure is declared in sys/time.h.   
If I add a line in OsiClpSolverInterface.cpp everything works:

#include <time.h>
#if defined(_MSC_VER)
// Turn off compiler warning about long names
#   pragma warning(disable:4786)
#else
#include <sys/time.h>            //   Add this line
#include <sys/times.h>
#include <sys/resource.h>
#include <unistd.h>
#endif

Any suggestions on a better way to deal with this?

Scott
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://list.coin-or.org/pipermail/coin-discuss/attachments/20030104/382f0cf4/attachment.html>


More information about the Coin-discuss mailing list