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

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
Tobi
Spring Developer
Posts: 4598
Joined: 01 Jun 2005, 11:36

Post by Tobi »

Again, new mingwlibs. Only important change is MinGW compiled ogg/vorbis, so I think there is no real reason to upgrade if stuff keeps working for you.

Image
submarine
AI Developer
Posts: 834
Joined: 31 Jan 2005, 20:04

Post by submarine »

is there a possibility to upload new vs.net 2005 libs as well

i cant build spring atm due to missing ogg headers/libs
Tobi
Spring Developer
Posts: 4598
Joined: 01 Jun 2005, 11:36

Post by Tobi »

lurker is working on that
User avatar
rattle
Damned Developer
Posts: 8278
Joined: 01 Jun 2006, 13:15

Post by rattle »

Or you could build them yourself, the sources comes with VS8 project files IIRC.
submarine
AI Developer
Posts: 834
Joined: 31 Jan 2005, 20:04

Post by submarine »

i built ogg/vorbis libs myself, but now there is a probl├â┬Âem with open gl

1>..\..\Lua\LuaFBOs.cpp(60) : error C2065: 'GLEW_EXT_framebuffer_blit' : undeclared identifier

are any headers missing? wrong version of gl headers?
User avatar
rattle
Damned Developer
Posts: 8278
Joined: 01 Jun 2006, 13:15

Post by rattle »

Yeah you need to update glew as well.
User avatar
AF
AI Developer
Posts: 20687
Joined: 14 Sep 2004, 11:32

Post by AF »

any chance you can put up the oggvorbis libs?
User avatar
FLOZi
MC: Legacy & Spring 1944 Developer
Posts: 6241
Joined: 29 Apr 2005, 01:14

Post by FLOZi »

Code: Select all

build\rts\ExternalAI\GlobalAI.o:GlobalAI.cpp:(.text+0x2be3): undefined reference
 to `std::ostream& std::ostream::_M_insert<unsigned long>(unsigned long)'
C:\MinGW\lib/libstdc++.a(eh_throw.o):eh_throw.cc:(.text+0x7b): undefined referen
ce to `__w32_sharedptr_unexpected'
C:\MinGW\lib/libstdc++.a(eh_throw.o):eh_throw.cc:(.text+0x8c): undefined referen
ce to `__w32_sharedptr_terminate'
C:\MinGW\lib/libstdc++.a(eh_terminate.o):eh_terminate.cc:(.text+0x67): undefined
 reference to `__w32_sharedptr_terminate'
C:\MinGW\lib/libstdc++.a(eh_terminate.o):eh_terminate.cc:(.text+0x97): undefined
 reference to `__w32_sharedptr_unexpected'
C:\MinGW\lib/libstdc++.a(eh_terminate.o):eh_terminate.cc:(.text+0xb3): undefined
 reference to `__w32_sharedptr_terminate'
C:\MinGW\lib/libstdc++.a(eh_terminate.o):eh_terminate.cc:(.text+0xd3): undefined
 reference to `__w32_sharedptr_unexpected'
collect2: ld returned 1 exit status
scons: *** [game\spring.exe] Error 1
Current SVN rev (5054) and mingwlibs 10, gcc 4.2.1
DarkFarmer
Posts: 4
Joined: 24 Dec 2007, 05:51

Re: Compiling spring (mingw and visual studio 7/8)

Post by DarkFarmer »

hey guys

im new to the forum, howdy. im making a new RTS and i think Spring might be a good engine to use for the task.

however, im having some problems. I was able to compile the source no problem, actually it compiled on the first try for me which was nice.

However, what i dont get is that the exe im building is a different size (2 megs smaller) than the binary i downloaded, and it has some different .dll dependencies, and it crashes when i try to load one of the test scenarios. in the debugger it says its crashing while parsing one of the scripts.

so my question is, and ill look around smore, but how is it that my executable is so different and less functional than the one in the binary download and where can i get the source for that, and if i have the correct source, what might be causing my executable to be so much smaller and not worky.

thanks :)

-df
User avatar
ILMTitan
Spring Developer
Posts: 410
Joined: 13 Nov 2004, 08:35

Re: Compiling spring (mingw and visual studio 7/8)

Post by ILMTitan »

1) make sure you are using mingwlibsv10, not 9.

2) the size difference could be due to different optimization or debug options (specified when you do a scons configure).
User avatar
KDR_11k
Game Developer
Posts: 8293
Joined: 25 Jun 2006, 08:44

Re: Compiling spring (mingw and visual studio 7/8)

Post by KDR_11k »

My custom build is 2MB larger than the buildbot one...
pentup
Posts: 2
Joined: 24 Dec 2007, 09:35

Re: Compiling spring (mingw and visual studio 7/8)

Post by pentup »

Hello, I'm new around here. I used to be a huge TA fan, and recently found out about spring, so decided to take a look at it. I tried compiling it using VC8 and the Windows SDK (which I believe replaces the PlatformSDK) and got the following error:

Code: Select all

CrashHandler.cpp
..\..\System\Platform\Win\CrashHandler.cpp(91) : warning C4312: 'type cast' : conversion from 'DWORD' to 'HINSTANCE' of greater size
..\..\System\Platform\Win\CrashHandler.cpp(134) : error C2664: 'SymEnumerateModules' : cannot convert parameter 2 from 'BOOL (__stdcall *)(LPSTR,DWORD,PVOID)' to 'PSYM_ENUMMODULES_CALLBACK'
        None of the functions with this name in scope match the target type
After it failed, I downloaded the latest version of the PlatformSDK and everything compiled fine. I just wanted to let somebody know for future compatibility or whatever, that the current code doesn't compile (out of the box, at least) with the new Windows SDK.
pentup
Posts: 2
Joined: 24 Dec 2007, 09:35

Re: Compiling spring (mingw and visual studio 7/8)

Post by pentup »

Also, I'm noticing a lot of .dll dependency differences between the version I compiled and the binary available on the website. I do not see these files in the binary distribution folder (was hoping to copy them over), so I began downloading them from various websites, only to be confronted with incorrect versions and additional dependencies (ogg.dll, vorbisfile.dll, MSVCP70.dll, ...).

Could somebody give a little explanation as to why these aren't required by the binary, or why they weren't included with the vclibs archive?
User avatar
rattle
Damned Developer
Posts: 8278
Joined: 01 Jun 2006, 13:15

Re: Compiling spring (mingw and visual studio 7/8)

Post by rattle »

Never mind...
(I really need to learn to read)

Lurker is responsible for the VC libs, blame him. :)
User avatar
lurker
Posts: 3842
Joined: 08 Jan 2007, 06:13

Re: Compiling spring (mingw and visual studio 7/8)

Post by lurker »

pentup wrote:Also, I'm noticing a lot of .dll dependency differences between the version I compiled and the binary available on the website. I do not see these files in the binary distribution folder (was hoping to copy them over), so I began downloading them from various websites, only to be confronted with incorrect versions and additional dependencies (ogg.dll, vorbisfile.dll, MSVCP70.dll, ...).

Could somebody give a little explanation as to why these aren't required by the binary, or why they weren't included with the vclibs archive?
The MSVCP70.dll seems to be a new issue that is being looked at. The lack of ogg vorbis dlls is because I'm a lazy bum who hasn't repacked yet, so you need to get those out of the mingwlibs package. (side note: They're not included in the svn installer... Do buildbot builds not have ogg support? I'll give someone 20 bucks to tell me the exact settings buildbot uses to compile. My exes, like KDR's, are also about 2MB larger.)
Last edited by lurker on 24 Dec 2007, 20:39, edited 1 time in total.
User avatar
lurker
Posts: 3842
Joined: 08 Jan 2007, 06:13

Re: Compiling spring (mingw and visual studio 7/8)

Post by lurker »

pentup wrote:Hello, I'm new around here. I used to be a huge TA fan, and recently found out about spring, so decided to take a look at it. I tried compiling it using VC8 and the Windows SDK (which I believe replaces the PlatformSDK) and got the following error:

Code: Select all

CrashHandler.cpp
..\..\System\Platform\Win\CrashHandler.cpp(91) : warning C4312: 'type cast' : conversion from 'DWORD' to 'HINSTANCE' of greater size
..\..\System\Platform\Win\CrashHandler.cpp(134) : error C2664: 'SymEnumerateModules' : cannot convert parameter 2 from 'BOOL (__stdcall *)(LPSTR,DWORD,PVOID)' to 'PSYM_ENUMMODULES_CALLBACK'
        None of the functions with this name in scope match the target type
After it failed, I downloaded the latest version of the PlatformSDK and everything compiled fine. I just wanted to let somebody know for future compatibility or whatever, that the current code doesn't compile (out of the box, at least) with the new Windows SDK.
Thank you very much for this information. I installed VC9, and that is one of two errors that keep it from compiling.
DarkFarmer
Posts: 4
Joined: 24 Dec 2007, 05:51

Re: Compiling spring (mingw and visual studio 7/8)

Post by DarkFarmer »

okay, thanks for the help, we are getting further along with each iteration.

now, if i run the game in debug which i know im not supposed to do, it crashes when parsing lua scripts during the "loading" segment after I select Commanders 1000 res from the selection startup menu.

if i run it in release, i get an error from the executable that says "Could not open file: gamedata/defs.lua"

any suggestions? i promise ill make a good game with Spring :D

-df
User avatar
lurker
Posts: 3842
Joined: 08 Jan 2007, 06:13

Re: Compiling spring (mingw and visual studio 7/8)

Post by lurker »

DarkFarmer wrote:okay, thanks for the help, we are getting further along with each iteration.

now, if i run the game in debug which i know im not supposed to do, it crashes when parsing lua scripts during the "loading" segment after I select Commanders 1000 res from the selection startup menu.

if i run it in release, i get an error from the executable that says "Could not open file: gamedata/defs.lua"

any suggestions? i promise ill make a good game with Spring :D

-df
Maybe you're missing the base content packages? They change every once in a while, so you can get updated ones from the svn installer or from running installer/builddata/build.bat Or this doesn't happen when you run it from the lobby? That's odd. And it you are supposed to be able to just run spring itself fine. Or are you already making a game, in which case those startscripts assume you have at least two sides and break otherwise.
DarkFarmer
Posts: 4
Joined: 24 Dec 2007, 05:51

Re: Compiling spring (mingw and visual studio 7/8)

Post by DarkFarmer »

i redownloaded the SVN, rebuilt everything from scratch and thats how far i get. i run it, the menu comes up to choose somehting from the menu, i pick any of them and it starts to load but instead of showing the splash screen for XTA, it shows this error:

"Could not open file: gamedata/defs.lua"

and its crashing while parsing a lua script somewhere. of course, there is no gamedata/lua, i believe its imbeded in a packaged file. I am using all the correct packaged files because i'm copying the game exe over my standard installer game exe and running it, so it has everything the packaged spring.exe has, its just that there's something wrong with my build. any ideas?
imbaczek
Posts: 3629
Joined: 22 Aug 2006, 16:19

Re: Compiling spring (mingw and visual studio 7/8)

Post by imbaczek »

run installer/make_gamedata_arch.bat if you didn't.
Post Reply

Return to “Engine”