[muscle] Re: MUSCLE on CYGWIN problem.

  • From: "David Svanberg" <ds@xxxxxxxxxxx>
  • To: <muscle@xxxxxxxxxxxxx>
  • Date: Wed, 29 Oct 2003 11:38:53 +0100

Hi,

I changed some lines in the SetupSystem.cpp file to make muscled compile on
CYGWIN:

Previous:
****************************************
#ifdef WIN32
# include <winsock.h>
# include <signal.h>
#else
# if defined(__BEOS__) || defined(__CYGWIN__)
#  include <signal.h>
# else
#  include <sys/signal.h>  // changed signal.h to sys/signal.h to work with
OS/X
#  include <sys/times.h>
# endif
#endif

Now:
****************************************
#ifdef WIN32
# include <winsock.h>
# include <signal.h>
#else
# if defined(__BEOS__)
#  include <signal.h>
# elif defined(__CYGWIN__)
#  include <signal.h>
#  include <sys/signal.h>
#  include <sys/times.h>
# else
#  include <sys/signal.h>  // changed signal.h to sys/signal.h to work with
OS/X
#  include <sys/times.h>
# endif
#endif

Best Regards,
David

-----Opprinnelig melding-----
Fra: muscle-bounce@xxxxxxxxxxxxx [mailto:muscle-bounce@xxxxxxxxxxxxx]På;
vegne av Jeremy Friesner
Sendt: 28. oktober 2003 17:17
Til: muscle@xxxxxxxxxxxxx
Emne: [muscle] Re: MUSCLE on CYGWIN problem.


Hi David,

I'm not sure why CygWin doesn't define "struct tms" ... maybe they forgot
to implement that, or maybe there is a header file that needs to be
#include'd
... perhaps <sys/times.h> or <times.h> =3F

Presumably also a CygWin environment still has access to Win32 APIs=3F
If so, you could define WIN32 and GetRunTime64() could then use the
Win32 implementation of that function.

Let me know if you figure out a good fix, so I can make it work better
for the next version.

Jeremy

> Hi!
>
> How to compile MUSCLE server on CYGWIN=3F
>
> I get the following error (cd muscle/server/;make):
>
>
g++ -I.. -DMUSCLE=5FSINGLE=5FTHREAD=5FONLY -DMUSCLE=5FENABLE=5FZLIB=5FENCODI
NG -fno-exce
> ptio
>
ns -DMUSCLE=5FNO=5FEXCEPTIONS -Wall -W -Wno-multichar -g -DMUSCLE=5FENABLE=5
FMEMORY=5F
> TRAC
> KING   -c -o SetupSystem.o ../system/SetupSystem.cpp
> ../system/SetupSystem.cpp: In function `uint64 muscle::GetRunTime64()':
> ../system/SetupSystem.cpp:125: error: aggregate `muscle::tms junk' has
>    incomplete type and cannot be defined
> ../system/SetupSystem.cpp:126: error: `times' undeclared (first use this
>    function)
> ../system/SetupSystem.cpp:126: error: (Each undeclared identifier is
> reported
>    only once for each function it appears in.)
> make: *** [SetupSystem.o] Error 1







Other related posts: