Compiling on MS VS 6.0

Posted by MagicDuck on Wed 18 Dec 2002 02:14 AM — 5 posts, 18,495 views.

USA #0
[Just starting out in c/++]
Can the smaug source be compiled using MS Visual Studio 6.0 Enterprise? I loaded it up using the dsp file, but when i tried to compile, it could not find a few of the headers (looked for time.h in include/sys, it was in include/, while some of the other headers did not exist). I "obtained" the headers that it requested, and now it spits out quite a few other errors... i can post them if requested.

At the moment i plan on playing around with cygwin, but i would greatly prefer using visual studio...
Australia Forum Administrator #1
The SMAUG source available from this site's download area should compile under VC 6, which is what I compiled it under (or was it 5?). Anyway, it should work with minor mods. Please post a sample of the errors if you are using that source, and it doesn't work. The "native" SMAUG is more likely to give more errors as it wasn't written with Windows in mind. The modified source has a few #ifdef WIN32 lines in it.
USA #2
Quote:
--------------------Configuration: smaug140 - Win32 Debug--------------------
Compiling...
router.c
c:\documents and settings\yan\my documents\smaug 140 workspace\smaug140\router.c(414) : error C2065: 'SIGPIPE' : undeclared identifier
services.c
c:\documents and settings\yan\my documents\smaug 140 workspace\smaug140\services.c(200) : error C2065: 'sa' : undeclared identifier
c:\documents and settings\yan\my documents\smaug 140 workspace\smaug140\services.c(200) : error C2146: syntax error : missing ';' before identifier 'ssStatus'
webclient.c
c:\documents and settings\yan\my documents\smaug 140 workspace\smaug140\webclient.c(434) : error C2065: 'SIGPIPE' : undeclared identifier
c:\documents and settings\yan\my documents\smaug 140 workspace\smaug140webclient.c(435) : error C2065: 'SIGALRM' : undeclared identifier
c:\documents and settings\yan\my documents\smaug 140 workspace\smaug140\webclient.c(460) : error C2065: 'AF_UNIX' : undeclared identifier
c:\documents and settings\yan\my documents\smaug 140 workspace\smaug140\webclient.c(460) : error C2065: 'SOCK_STREAM' : undeclared identifier
c:\documents and settings\yan\my documents\smaug 140 workspace\smaug140\webserver.c(442) : error C2065: 'SIGPIPE' : undeclared identifier
Error executing cl.exe.

smaug.exe - 8 error(s), 31 warning(s)



Those are the errors, the warnings were mainly macro redefinitions in the headers...

I am using the SMAUG source downloadable from this site, unchanged. I downloaded a few header files (unistd.h and a few related others) after getting errors when they could not be found.
Australia Forum Administrator #3
Which zip file did you use exactly? The file smaug1.4a.sce.zip has the files webclient.c and router.c, but they are not in the project. Try removing those two files from the project.
USA #4
Removing the files fixed it, thanks for the help