Compiling SWR smaug with Cygwin

Posted by Xzzy on Thu 07 Mar 2002 04:17 AM — 3 posts, 12,155 views.

USA #0
Hello all.

I am trying to compile SWR smaug with Cygwin.
I got the source from this web site.

ftp://ftp.gammon.com.au/smaug/StarWarsSce.zip

I put the source files into

C:\cygwin\bin\Nickolas\dist\src

When I type MAKE to compile the code, i get this error...

$ make
make swreality
make[1]: Entering directory `/usr/bin/Nickolas/dist/src'
gcc -c -g3 -Wall act_comm.c
In file included from act_comm.c:28:
mud.h:2638: field `total_time' has incomplete type
mud.h:2639: field `min_time' has incomplete type
mud.h:2640: field `max_time' has incomplete type
make[1]: *** [act_comm.o] Error 1
make[1]: Leaving directory `/usr/bin/Nickolas/dist/src'
make: *** [all] Error 2

I've checked some other post's, but they havn't really helped. Thanks in advance.

-Nickolas.
Australia Forum Administrator #1
There are some more posts about compiling SWR smaug, search on the word 'timeval' to see some relevant ones.

You must have done more than just used the archive you mentioned, because it doesn't have a makefile in it. I assume that you took a standard smaug archive and unzipped the other one on top of it.

Anyway, what I did to get further was:

  1. Change all references to :

    #include <time.h>

    to

    #include <sys/time.h>


  2. In comm.c, uncomment the following lines near the start:


    #include <errno.h>

    #include <unistd.h>
    #include <sys/socket.h>
    #include <netinet/in.h>
    #include <netinet/in_systm.h>
    #include <netinet/ip.h>
    #include <arpa/inet.h>
    #include <arpa/telnet.h>
    #include <netdb.h>



Then I got a whole lot of compile error about DEITY_DATA, which was a structure that was in the old mud.h but not in the new one for reasons that weren't clear.

The thing is that the source that you got from my site was designed to be compiled with MS Visual C++. The original SWR source (for Unix) should work OK under Cygwin.
Amended on Fri 08 Mar 2002 09:08 AM by Nick Gammon
USA #2
*curses self out for having a PC that hates him!*

i give up. months and months wasted on this shit...
i give up