how to compile in windows

Programmers discuss here anything related to FreeOrion programming. Primarily for the developers to discuss.

Moderator: Committer

Message
Author
OceanMachine
Pupating Mass
Posts: 95
Joined: Thu Jun 26, 2003 12:09 pm
Location: Chicago

#16 Post by OceanMachine »

For the moment you need to start the server separately. Run freeoriond.exe, to start the server, then start freeorion.exe and select localhost as your server. We will be tying them together a bit better in the future, probably when the new menu system is done, such that if you select single player or to host a multiplayer game it will automagically start the server..
Programming Lead

trace
Space Squid
Posts: 66
Joined: Fri Jun 27, 2003 6:23 pm
Location: Milkyway

#17 Post by trace »

freeoriond.exe makes the following messages:

1058784282 DEBUG : freeoriond logger initialized.
1058784282 ERROR : ServerApp::ServerApp : Server now in mode 0 (SERVER_IDLE).
1058784282 ERROR : SDL initialization failed: No available video device
1058784282 FATAL : Initiating Exit (code 1 - error termination)
1058784282 DEBUG : SDLQuit() complete.

what shall I do now ?

Yoghurt
Programmer
Posts: 376
Joined: Sat Jun 28, 2003 8:17 pm
Location: Heidelberg, Germany

#18 Post by Yoghurt »

trace wrote:what shall I do now ?
Did you update your CVS checkout? This was a bug that should be fixed now, ie. in ServerApp.cpp the getenv/putenv Stuff should be included in

Code: Select all

#ifdef FREEORION_LINUX
, if it's not, just comment out the line that says something like putenv("SDL_VIDEODRIVER=dummy")

trace
Space Squid
Posts: 66
Joined: Fri Jun 27, 2003 6:23 pm
Location: Milkyway

new Problem

#19 Post by trace »

I could compile the server and the server works now, but I have Problems with the linking of both clients. :?

I have found new lines in the readme file:
You'll also need the GG GUI library (aka GiGi). Use WinCVS or regular CVS to check out the source code files into the FreeOrion directory you just checked out:

cvs -d:pserver:[email protected]:/cvsroot/gigi login
cvs -z3 -d:pserver:[email protected]:/cvsroot/gigi co GG
Ahhm both cvs lines do not work on my computer and when I use the first line it wants a password.

I wonder why there are no files inside of C:\freeorion\SDL_net and C:\freeorion\SDL_net2 when I download with CVS, but anywhere I got those file - dont know.

errors at compiling humanclient:
C:\freeorion\objs\IntroScreen.o(.text+0x38b3)
[Warning] In function `ZN11IntroScreen7OnAboutEv':
[Linker error] undefined reference to `About::About()'
[Linker error] undefined reference to `About::~About()'
[Linker error] undefined reference to `About::~About()'
C:\freeorion\client\human\Makefile.win
[Build Error] [../../freeorion.exe] Error 1

with AiClient there were Problems I could fix, dont know how but compiling worked


I had to fill in the include filesC:\freeorion\SDL_net2 and C:\freeorion\SDL_net again in the Project Configuration

If I use an older compiled humanclient it shows an error when starting a game: Universe already built oder server error but not the same error as if I wouldnt execute the server.
Last edited by trace on Tue Jul 22, 2003 6:34 pm, edited 1 time in total.

tsev
Space Kraken
Posts: 167
Joined: Thu Jun 26, 2003 2:17 pm
Location: Pittsburgh, PA

Re: new Problem

#20 Post by tsev »

trace wrote:I could compile the server and the server works now, but I have Problems with the linking of both clients. :?

I have found new lines in the readme file:
You'll also need the GG GUI library (aka GiGi). Use WinCVS or regular CVS to check out the source code files into the FreeOrion directory you just checked out:

cvs -d:pserver:[email protected]:/cvsroot/gigi login
cvs -z3 -d:pserver:[email protected]:/cvsroot/gigi co GG
Ahhm both cvs lines do not work on my computer and when I use the first line it wants a password.

I wonder why there are no files inside of C:\freeorion\SDL_net and C:\freeorion\SDL_net2 when I download with CVS, but anywhere I got those file - dont know.

errors at compiling humanclient:
C:\freeorion\objs\IntroScreen.o(.text+0x38b3)
[Warning] In function `ZN11IntroScreen7OnAboutEv':
[Linker error] undefined reference to `About::About()'
[Linker error] undefined reference to `About::~About()'
[Linker error] undefined reference to `About::~About()'
C:\freeorion\client\human\Makefile.win
[Build Error] [../../freeorion.exe] Error 1

with AiClient there were Problems I could fix, dont know how but compiling worked


I had to fill in the include filesC:\freeorion\SDL_net2 and C:\freeorion\SDL_net again in the Project Configuration
When you say both lines don't work, do you mean that "cvs" is a "bad command or filename" or does it just not work?

Make sure you type the first, hit enter, then type the second line. If you are prompted for a password, just press enter, or if using WinCVS, press OK.

Once you've got the gigi files, make sure they are in a folder titled GG located inside your FreeOrion root directory. If the GG folder isn't there, create it.

Everything should build ok from there.
FreeOrion Programmer

tsev
Space Kraken
Posts: 167
Joined: Thu Jun 26, 2003 2:17 pm
Location: Pittsburgh, PA

#22 Post by tsev »

In WindowsKit.zip in the CVS repository there are directions for downloading and compiling in Windows using Dev-C++, a free C++ compiler and devlopment environment. Anybody is free to to download and compile the code at their leisure.

As for distributing binaries, that will only happen when certain benchmarks are reached, such as the completion of a feature version. We can't be concerned with releasing unstable builds every month.
FreeOrion Programmer

elfstone
Space Squid
Posts: 78
Joined: Fri Jun 27, 2003 9:00 am
Location: Germany

#23 Post by elfstone »

I tried to compile the human client again, and got this error:

C:/Dev-Cpp/include/freetype2/freetype/freetype.h:188: 'FT_Pos' is used as a type, but is not defined as a type.


Any further ideas?

tsev
Space Kraken
Posts: 167
Joined: Thu Jun 26, 2003 2:17 pm
Location: Pittsburgh, PA

#24 Post by tsev »

elfstone wrote:I tried to compile the human client again, and got this error:

C:/Dev-Cpp/include/freetype2/freetype/freetype.h:188: 'FT_Pos' is used as a type, but is not defined as a type.


Any further ideas?
Is that the only error you got?
FreeOrion Programmer

elfstone
Space Squid
Posts: 78
Joined: Fri Jun 27, 2003 9:00 am
Location: Germany

#25 Post by elfstone »

no, there are 269 errors, the first 30 or so with the same error, only different lines, then there are many like:

C:/Dev-Cpp/include/freetype2/freetype/freetype.h:673: syntax error before `*' token
C:/Dev-Cpp/include/freetype2/freetype/freetype.h:675: 'FT_Int' is used as a type, but is not defined as a type.


I guess the later errors follow from the first ones.

Tyreth
FreeOrion Lead Emeritus
Posts: 885
Joined: Thu Jun 26, 2003 6:23 am
Location: Australia

#26 Post by Tyreth »

the first and/or the last errors are usually the most important.

elfstone
Space Squid
Posts: 78
Joined: Fri Jun 27, 2003 9:00 am
Location: Germany

#27 Post by elfstone »

in this case, the first error is the important one. Later in the list of errors, there are a lot of "blabla" was used before declaration, since there were errors in the declaration of those functions.

So, what can i do about this:

C:/Dev-Cpp/include/freetype2/freetype/freetype.h:188: 'FT_Pos' is used as a type, but is not defined as a type.

error

mr_ed
Space Squid
Posts: 82
Joined: Thu Jun 26, 2003 1:13 pm
Location: Ottawa

#28 Post by mr_ed »

I found FT_Pos defined in freetype2/freetype/ftimage.h

Do you have that file?

trace
Space Squid
Posts: 66
Joined: Fri Jun 27, 2003 6:23 pm
Location: Milkyway

#29 Post by trace »

I tried again compiling freeorion humanclient.
Now I could download GG and put it into the freeorion directory.
I tried the newest files.
ERROR:
C:\freeorion\objs\IntroScreen.o(.text+0x38b3)
[Warning] In function `ZN11IntroScreen7OnAboutEv':
[Linker error] undefined reference to `About::About()'
[Linker error] undefined reference to `About::~About()'
[Linker error] undefined reference to `About::~About()'
C:\freeorion\client\human\Makefile.win
[Build Error] [../../freeorion.exe] Error 1

maybe it has something to do with the files in
SDL_net and SDL_net2
I could not download, but anyhow I got those files maybe via an older download - maybe they are too old

tzlaine
Programming Lead Emeritus
Posts: 1092
Joined: Thu Jun 26, 2003 1:33 pm

#30 Post by tzlaine »

Locking. Please ask for help in the Help thread.

Locked