compiling smaugwin....

Posted by Fender on Sat 01 Nov 2003 02:43 PM — 9 posts, 26,887 views.

#0
How do i go about doing this? it is precompiled when you get it. i have MS Visual Suite 6.0, but im not sure how i would go about compiling this project.....can somebody help me with detailed instructions?

thanks in advance
#1
Just adding in, i found the msvc++ workspace/project file, but when i tried to compile it it gave me like 57 errors mostly in fight.c and polymorph.c, and about 600 warnings in tables.c.......whats going on?
USA #2
Were all the errors the same? Post some of the errors that are most common, here.

[EDIT] Actually, is your other post those errors?
Amended on Sat 01 Nov 2003 04:04 PM by Zeno
#3
yeah my newest one in compiling the server, they are all header files that im not even using, i dont understand it, theres over 5000 errors.
Australia Forum Administrator #4
At least post a selection of the errors, preferably starting with the first ones. Just saying "it gave me like 57 errors" doesn't give us much to go on. With errors the error message is the important thing, not the fact that you got the message.
#5
Actually I only have one error left.

LIBCD.lib(wincrt0.obj) : error LNK2001: unresolved external symbol _WinMain@16

I've been trying to figure this one out for like 24 hours straight.

any one gota simple solution i couldnt realize?
USA #6
This means that you don't have a function called WinMain anywhere...

...which means that either you chose the wrong project settings, or you don't have the function declared, or don't have the preprocessor definitions you need to make it realize it's compiling under Windows.
#7
"This means that you don't have a function called WinMain anywhere...

...which means that either you chose the wrong project settings, or you don't have the function declared, or don't have the preprocessor definitions you need to make it realize it's compiling under Windows."

I do have the function WinMain somewhere.
And I HAVE the right project settings, and the function is declared.

which preprocessor definitions do i need?

the ones i have are:

WIN32,_DEBUG,_WINDOWS,_MBCS

o yeah, i did find more than one, so i left onlt one of them, in comm.c

and when i compiled i got the error:

LINK : error LNK2001: unresolved external symbol _WinMain

now what?
Amended on Mon 03 Nov 2003 09:24 PM by Fender
Australia Forum Administrator #8
I think the one in comm.c is the correct one. I don't see why SMAUG wants WinMain, it is a Unix (console) app. You need main, and it should be in comm.c.

As an example on this site is a file:

ftp://ftp.gammon.com.au/smaug/smaug1.4a_win_mxp_src.zip

I just unzipped that into a directory, opened the project file with MS VC++ and compiled. I got one warning and no errors.

My project settings are:

WIN32,_DEBUG,_CONSOLE,_MBCS

Note _CONSOLE instead of _WINDOWS.