Codeblocks
Moderator: Moderators
Codeblocks
Im requesting a working method of building unitsync under windows that doesnt require VS2005 C++ express and a platform sdk download, OR me tearing my hair out in frustration seething with anger at codeblocks because I dont know how to get rid of the errors and which libraries and files to include.
I need a f*ckign 64bit unitsync.dll to continue AFLobby work and nobody who can compile it is doing so, and the whole thing is just borked. There arent even instructions on what is needed for unitsync.
I need a f*ckign 64bit unitsync.dll to continue AFLobby work and nobody who can compile it is doing so, and the whole thing is just borked. There arent even instructions on what is needed for unitsync.
Use:
unitsync.dll is then compiled into game/unitsync.dll
More verbose instructions are in the sticky thread on how to compile spring (follow the instructions using MinGW).
Code: Select all
scons configure
scons unitsync
More verbose instructions are in the sticky thread on how to compile spring (follow the instructions using MinGW).
Code: Select all
D:\spring_0.75b2>scons configure
scons: Reading SConscript files ...
Now configuring. If something fails, consult `config.log' for details.
Detected platform : windows
Checking gcc version... gcc not found
D:\spring_0.75b2>
there's also no config.log
Make sure gcc is in a directory which is in your PATH environment variable.
Does
on the commandline work?
Does
Code: Select all
gcc --version
Code: Select all
D:\spring_0.75b2>scons configure
scons: Reading SConscript files ...
Now configuring. If something fails, consult `config.log' for details.
Detected platform : windows
Checking gcc version... 3.4.2
profiling NOT enabled, debugging NOT enabled, level 2 optimizing enabled
Configuring spring
Checking for zip... not found
D:\spring_0.75b2>
That's an already fixed bug, maybe grabbing the latest config.py from SVN works fine as a drop in replacement, otherwise just comment out the call to check_zip_version in the configure function in that file or update to latest sourcecode.
tobis fix worked but threw up another issue:
Also D:\MinGW\include\java is not the java include path. There is no jni.h in there, rather a lot of java packages implemented in C/C++ for gcj. On my machine the correct location is C:\Program Files\Java\jdk1.6.0_02\include
Code: Select all
Microsoft Windows [Version 6.0.6000]
Copyright (c) 2006 Microsoft Corporation. All rights reserved.
C:\Users\AF-StandardUsr>d:
D:\>cd spring_0.75b2
D:\spring_0.75b2>scons configure
scons: Reading SConscript files ...
Now configuring. If something fails, consult `config.log' for details.
Detected platform : windows
Checking gcc version... 3.4.2
profiling NOT enabled, debugging NOT enabled, level 2 optimizing enabled
Configuring spring
Checking for Freetype2...
Guessing Freetype2 include path... mingwlibs\include\freetype2
Checking for SDL...
Guessing SDL include path... mingwlibs\include\SDL
Checking for Python 2.5...
Guessing Python include path... mingwlibs\include\python2.5
Checking for Python 2.4...
Guessing Python include path... mingwlibs\include\python2.4
Checking for Java... Guessing Java include path... mingwlibs\include\java
Checking headers and libraries
Checking for C++ header file GL/gl.h... yes
Checking for main() in C library GL... no
Checking for main() in C library opengl32... yes
Checking for C++ header file GL/glew.h... yes
Checking for main() in C library GLEW... no
Checking for main() in C library glew32... yes
Checking for C++ header file GL/glu.h... yes
Checking for main() in C library GLU... no
Checking for main() in C library glu32... yes
Checking for C++ header file IL/il.h... yes
Checking for main() in C library IL... no
Checking for main() in C library devil... yes
Checking for C++ header file IL/ilu.h... yes
Checking for main() in C library ILU... yes
Checking for C++ header file SDL/SDL.h... yes
Checking for main() in C library SDL... yes
Checking for main() in C library SDLmain... yes
Checking for C++ header file boost/cstdint.hpp... yes
Checking for C++ header file boost/regex.hpp... yes
Checking for main() in C library boost_regex-gcc-mt... no
Checking for main() in C library boost_regex-mt... yes
Checking for C++ header file boost/thread.hpp... yes
Checking for main() in C library boost_thread-gcc-mt... no
Checking for main() in C library boost_thread-mt... yes
Checking for main() in C library dsound... yes
Checking for C++ header file ft2build.h... yes
Checking for main() in C library freetype... yes
Checking for main() in C library gdi32... yes
Checking for main() in C library imagehlp... yes
Checking for C++ header file jni.h... yes
Checking for main() in C library mingw32... yes
Checking for main() in C library ole32... yes
Checking for C++ header file Python.h... yes
Checking for main() in C library python2.5... no
Checking for main() in C library python25... yes
Checking for main() in C library winmm... yes
Checking for main() in C library wsock32... yes
Checking for C++ header file zlib.h... yes
Checking for main() in C library z... yes
Everything seems OK. Run `scons' now to build.
scons: done reading SConscript files.
scons: Building targets ...
scons: Nothing to be done for `configure'.
scons: done building targets.
D:\spring_0.75b2>scons
scons: Reading SConscript files ...
g++ -c -O3 -pipe -g -frounding-math -fsignaling-nans -fno-strict-aliasing -mieee
-fp -Wall -mfpmath=387 -DSTREFLOP_X87=1 SMath.cpp -o SMath.o
SMath.cpp:9: warning: division by zero in `1.0e+0f / 0.'
SMath.cpp:10: warning: division by zero in `-1.0e+0f / 0.'
SMath.cpp:15: warning: division by zero in `1.0e+0 / 0.'
SMath.cpp:16: warning: division by zero in `-1.0e+0 / 0.'
SMath.cpp:24: warning: division by zero in `1.0e+0 / 0.'
SMath.cpp:25: warning: division by zero in `-1.0e+0 / 0.'
g++ -c -O3 -pipe -g -frounding-math -fsignaling-nans -fno-strict-aliasing -mieee
-fp -Wall -mfpmath=387 -DSTREFLOP_X87=1 Random.cpp -o Random.o
Random.cpp:982: warning: alignment of 'streflop::DefaultRandomState' is greater
than maximum object file alignment. Using 16
make -C libm
make: *** [streflop.a] Error 2
Failed building streflop!
D:\spring_0.75b2>
That's why it uses mingwlibs\include\java and not D:\MinGW\include\javaAlso D:\MinGW\include\java is not the java include path. There is no jni.h in there, rather a lot of java packages implemented in C/C++ for gcj. On my machine the correct location is C:\Program Files\Java\jdk1.6.0_02\include

Don't know why it fails building streflop at that point though, never seen that before. Some things to check for:
Is make in your PATH?
Is it the mingw32 make that is first in your path, not some other make program? (try make --version on commandline)
Code: Select all
Microsoft Windows [Version 6.0.6000]
Copyright (c) 2006 Microsoft Corporation. All rights reserved.
C:\Users\AF-StandardUsr>make --version
GNU Make version 3.79.1, by Richard Stallman and Roland McGrath.
Built for i686-pc-msys
Copyright (C) 1988, 89, 90, 91, 92, 93, 94, 95, 96, 97, 98, 99, 2000
Free Software Foundation, Inc.
This is free software; see the source for copying conditions.
There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A
PARTICULAR PURPOSE.
Report bugs to <bug-make@gnu.org>.
C:\Users\AF-StandardUsr>
Try newer gcc and newer binutils: http://sourceforge.net/project/showfile ... up_id=2435
3.4.2 is pretty old.
3.4.2 is pretty old.