Compiling spring (mingw and visual studio 7/8) - Page 3

Compiling spring (mingw and visual studio 7/8)

Discuss the source code and development of Spring Engine in general from a technical point of view. Patches go here too.

Moderator: Moderators

Post Reply
User avatar
SinbadEV
Posts: 6475
Joined: 02 May 2005, 03:56

Post by SinbadEV »

my guess... the DirectX SDK is missing... you'll need that to get sound working on windows still...
SeanHeron
Engines Of War Developer
Posts: 614
Joined: 09 Jun 2005, 23:39

Post by SeanHeron »

Thanks for the tip. But does that really mean downloading a 337 MB installation file ? Not that that would really be a problem, but I didn´t think it would be so big
User avatar
SinbadEV
Posts: 6475
Joined: 02 May 2005, 03:56

Post by SinbadEV »

Not only that but you have to have the "genuine windows" plugin to get it... I happened to have an extra copy of it on my drive... blame the Devs for using an industry standard... :P
SeanHeron
Engines Of War Developer
Posts: 614
Joined: 09 Jun 2005, 23:39

Post by SeanHeron »

I needed the "genuine windows" pluggin to get the VS C++ 2005 Express edition (if I remember rightly) so I´m not bothered about that. Zaphod, could you edit your front post and add that you need the directx SDK installed ?
I guess I should just write it in the wiki .....
User avatar
AF
AI Developer
Posts: 20687
Joined: 14 Sep 2004, 11:32

Post by AF »

Dont you also need the win32 platform sdk?

For me the directx sdk was 900MB and the widnwos SDK in excess of 1.5GB possibly 2 or 3
patmo98
Posts: 188
Joined: 09 Jan 2006, 17:51

Post by patmo98 »

AF wrote:Dont you also need the win32 platform sdk?

For me the directx sdk was 900MB and the widnwos SDK in excess of 1.5GB possibly 2 or 3
Strange, for me the DirectX was 589 MB, and the Windows PSDK was 894 MB. That is the size after I deleted the installers, and files in temp.
User avatar
Dragon45
Posts: 2883
Joined: 16 Aug 2004, 04:36

Post by Dragon45 »

1.5 gigs!!?


jeebus.
patmo98
Posts: 188
Joined: 09 Jan 2006, 17:51

Post by patmo98 »

Dragon45 wrote:1.5 gigs!!?


jeebus.
No one ever accused Microsoft of thinking small :wink: . When it comes to file size.
Tobi
Spring Developer
Posts: 4598
Joined: 01 Jun 2005, 11:36

Post by Tobi »

Now this thread has been promoted to "how to build spring code in mingw/dev-cpp" too, let me list some links. Except for TortoiseSVN, which can be replaced by the commandline svn client or SmartSVN and Dev-Cpp, which can be replaced by a bare MinGW system, the linked programs are a must-have if you want to compile spring with MinGW/Dev-Cpp. Zaphod, could you copy these to the main post?

Oh, and quick instructions:
  • Grab and install the above programs.
  • Make sure C:\Python2.4 and C:\Dev-Cpp\bin are in your PATH environment variable. Make sure a MINGDIR environment variable with value C:\Dev-Cpp exists. (change paths where appropriate.) Set environment variables by: Start -> Settings -> Control Panel -> System -> Advanced -> Environment variables (for Windows XP).
  • Checkout the TA Spring SVN repository.
  • Open a console (Start -> Run -> cmd.exe -> Run), cd \path\to\taspring<enter> (where you checked it out in the previous step) and type scons configure<enter>, followed by scons<enter>. Refer to scons --help for options which can be passed to scons configure.
  • Wait.
  • Copy over datafiles and stuff from official spring to the game dir (where spring.exe is created).
  • Copy missing DLLs from mingwlibs/dll.
  • Start developing.
Last edited by Tobi on 28 Mar 2006, 21:03, edited 1 time in total.
User avatar
Michilus_nimbus
Posts: 634
Joined: 19 Nov 2004, 20:38

Post by Michilus_nimbus »

Praise the lord! MinGW!
Suprano
Posts: 12
Joined: 18 Mar 2006, 18:21

Post by Suprano »

I just built TA Spring using MingW on Windows 2k, and i could load a map WITHOUT crash!!!

I rebuilt the devIL libs, but there are some strange things...

At first, compile faild, because -lIL wasn't found, i renamed libdevIL.a to libIL.a and it worked(i just remember, i also created the mingwlibs folder, because i extracted this folder in dev-cpp at first, i thing thats the reason why it worked, no the renaming...), but the game crashed when loading a map.



Later i downloaded and rebuilt the devIL libs, with much much problems..
after deleting unsued extensions (tif,png,mng) it finally compiled. i got a IL.dll and a IL.dll.a .. now i was unsre what to do.. moved the IL.dll.a to the /libs and renamed it to libIL.dll.a (which was not the name i wanted, but i forget it), then i copied over the includes folder of the devIL package, then i renamed the libIL.a in my dev-cpp folder to libIL.a_, so it was not used any more (a same copy of this file called libdevIL.a still exists in mingwlibs/), then i compiled ta spring again... the new ta spring file was copied over to the ta spring game dir, then i started it, error -> dll IL.dll not found... i copied it over, tryed again, and it worked!!!!!!!!

Here are the new created files from devIL :
http://user.supradigital.org/suprano/devIL.rar

You need to copy & rename mods/XTAPE.sd7 to mods/XTAPEv3.sd7 and you have to copy the guis & bitmaps folder from the svn dir to the spring game dir(not sure if it were these 2)

I also uploaded a binary:
http://user.supradigital.org/suprano/springmingw.exe


EDIT: I just joined a online game, but a few seconds after start, the sync errors started and after 10 secs the game closed without error message..






--Ano
Last edited by Suprano on 31 Mar 2006, 22:20, edited 1 time in total.
patmo98
Posts: 188
Joined: 09 Jan 2006, 17:51

Post by patmo98 »

Suprano wrote:I just joined a online game, but a few seconds after start, the sync errors started and after 10 secs the game closed without error message..

--Ano
I hope this didn't supprise you. You went probably went out of sync because there were chances between your copy and .70b3
Suprano
Posts: 12
Joined: 18 Mar 2006, 18:21

Post by Suprano »

no it didn't suprise me, i just wanted the hardproof ;)

I think it happens, because it is an other compiler... but maybee both, who knows..

--Ano
patmo98
Posts: 188
Joined: 09 Jan 2006, 17:51

Post by patmo98 »

Suprano wrote:no it didn't suprise me, i just wanted the hardproof ;)

I think it happens, because it is an other compiler... but maybee both, who knows..

--Ano
What rev are you using? If you want I could compile it in VS8 and we could play a game today.
Tobi
Spring Developer
Posts: 4598
Joined: 01 Jun 2005, 11:36

Post by Tobi »

Whoa, cool! So I can finally declare the mingw platform supported once I get new mingwlibs pack up :-)
patmo98
Posts: 188
Joined: 09 Jan 2006, 17:51

Post by patmo98 »

We tried to play, but something was relly strange. First we updated from the SVN, and compiled rev 1089. Then I hosted a game. The game started up just fine for me, but Suprano's game wouldn't start. I think the connection timed out. I recreated the game and the lobby wouldn't sync. I couldn't figure out what caused it, so I decided to switch to a diffierent installation.

I moved my newly compiled exe to my primary spring folder, and we tried again. Same problem. The lobby synced and we connected just fine. His connection timed out. When Suprano reconnected the lobby client wouldn't sync.

It sound like something is corupting the installation on my end (I'm using VS8). Anyone have any advice?

Just to make the point relly clear, spring.exe was nt giving sync errors. The lobby was complaining.
Suprano
Posts: 12
Joined: 18 Mar 2006, 18:21

Post by Suprano »

well the second time my connection timed out, it wasn't his fault, because my internet pc was shut down by a virus (i disabled the FW because i was going to host after that) .. but after restart, the lobby was not synced again...

We tryed several lobby restarts, but nothing happend...
The interessting thing: later, I joined an normal game, and the lobby was synced(after that i renamed my exes back to org, to be able to play a normal game), so the lobby-unsync was not caused by the different exes...

--Ano
Mugslugs
Posts: 89
Joined: 23 Aug 2005, 00:08

Post by Mugslugs »

I fed the mingw stuff to the wiki :twisted:
SeanHeron
Engines Of War Developer
Posts: 614
Joined: 09 Jun 2005, 23:39

Post by SeanHeron »

Ok thanks for all the help so far. After finally getting round to installing the directx sdk, I got the next missing include I can´t start anything with:
"afxres.h"

Compiling...
7zHeader.c
7zIn.c
7zItem.c
7zMethodID.c
LzmaDecode.c
Generating Code...
Compiling resources...
.\rts.rc(10) : fatal error RC1015: cannot open include file 'afxres.h'.

I found two instances of this header in the windows sdk, but it didnt help to add there folders to the include folders of the project.
I´d by thankful for any further hints I can get. But no worries if you cant help, as I´m not going to be doing much with the code anyway :) .
patmo98
Posts: 188
Joined: 09 Jan 2006, 17:51

Post by patmo98 »

SeanHeron wrote: .\rts.rc(10) : fatal error RC1015: cannot open include file 'afxres.h'.
Replace any instance of afxres.h in the .rc file with winres.h
I found that "fix" on google. I don't know what that file is suppost to do but at least it compiles.

Found that at http://www.winprog.org/tutorial/errors.html
Post Reply

Return to “Engine”