Notifications
Clear all

Missing file in git repo


shenle
(@shenle)
Senior Chief Registered
Joined: 13 years ago
Posts: 70
Topic starter  

When compiling the latest git tree with mingw I came across the following:

in src/graphics/gl2/StarfieldMaterial.h line 12:

Code:
#include "Material.h"

But there is no Material.h in that directory. Needs either to become ../Material.h or place a copy of src/graphics/material.h in the gl2 directory as well.

(and BTW the build fails at linking stage with:

Code:
Release Win32pioneer-msvc-9.0srcPi.o:Pi.cpp:(.text+0x273): undefined reference to `GameUIInit()'
Release Win32pioneer-msvc-9.0srcuiLua.o:Lua.cpp:(.text+0x3b): undefined reference to `LuaObject<UIRegisterClass()'
Release Win32pioneer-msvc-9.0srcuiLua.o:Lua.cpp:(.text+0x40): undefined reference to `LuaObject<UIRegisterClass()'
Release Win32pioneer-msvc-9.0srcuiLua.o:Lua.cpp:(.text+0x72): undefined reference to `LuaObject<UIRegisterClass()'
c:/mingw/bin/../lib/gcc/mingw32/4.7.2/../../../../mingw32/bin/ld.exe: Release Win32pioneer-msvc-9.0srcuiLua.o: bad reloc address 0x20 in section `.eh_frame'
collect2.exe: error: ld returned 1 exit status

)


Quote
robn
 robn
(@robn)
Captain Registered
Joined: 13 years ago
Posts: 1035
 

Compiling with MinGW on Windows itself is not actually supported right now. It should almost be possible, but we haven't actually worked through it all. You might be the one to get it working!

The normal configure stuff always puts the current working directory on the include path, and src/graphics/gl2 is built from src/graphics, so it should be working ok. I think I'd prefer it if the subdir was built as a lib like other subdirs though. Still, it isn't a problem on the other autotools-based platforms we build on.

As for your linking problems, I don't understand. Those symbols all exist in files that are in the repository right now. The bad reloc error I don't know about. Are you building with the autotools scripts, or some other way? Could be a link order thing, I suppose but I'd still expect the standard collect to get it right.


ReplyQuote
shenle
(@shenle)
Senior Chief Registered
Joined: 13 years ago
Posts: 70
Topic starter  

I got everything to compile fine with the latest mingw (had to recompile all libraries of course) but this is the error I get at linking stage. What I did is use Code::Blocks to import the vc2008 project, and made slight modifications to the project to get it to compile:

-removed precompiled headers

-compiled and installed libraries in mingw (png, ogg, vorbis, sdl, zlib, glew, sigc, freetype) and adjusted the names in the linker options so the linker finds them.

Other than that everything went well until the linker spits out the error above.

In other words, no I don't use autotools, I use C::B ; ./bootstrap fails in mingw/msys:

Code:
autoreconf-2.68: Entering directory `.'
autoreconf-2.68: configure.ac: not using Gettext
autoreconf-2.68: running: aclocal --force
autoreconf-2.68: configure.ac: tracing
autoreconf-2.68: configure.ac: not using Libtool
autoreconf-2.68: running: /mingw/bin/autoconf-2.68 --force
configure.ac error: possibly undefined macro: AC_MSG_ERROR
If this token and others are legitimate, please use m4_pattern_allow.
See the Autoconf documentation.
configure.ac error: possibly undefined macro: AC_SUBST
configure.ac error: possibly undefined macro: AC_CHECK_LIB
autoreconf-2.68: /mingw/bin/autoconf-2.68 failed with exit status: 1


ReplyQuote
robn
 robn
(@robn)
Captain Registered
Joined: 13 years ago
Posts: 1035
 

Ahh, interestng. Yeah, I vaguely recall that kind of failure the last time I tried.

What you're probably seeing here is the VS project being out of date. We don't usually keep them all updated; its normally left to individuals using a given compiler to keep it building. Last check we have two, maybe three people using VS 2008 and none of them follow master closely. You might need to look for files that aren't in the project and add them in.

I'm interested to know if you get it working. We currently don't have a way for Windows people to build the game natively without MSVC. There might be some interest in a free alternative.


ReplyQuote
shenle
(@shenle)
Senior Chief Registered
Joined: 13 years ago
Posts: 70
Topic starter  

That's exactly the idea, I prefer a free (speech) alternative to free (beer).

Well, I'm making a bit of progress towards making autotools with mingw. It turns out I didn't have pkg-tool installed. I installed pkg-tool-lite, and now it fails in a different manner:

Code:
autoreconf-2.68: Entering directory `.'
autoreconf-2.68: configure.ac: not using Gettext
autoreconf-2.68: running: aclocal --force
autoreconf-2.68: configure.ac: tracing
autoreconf-2.68: configure.ac: not using Libtool
autoreconf-2.68: running: /mingw/bin/autoconf-2.68 --force
autoreconf-2.68: configure.ac: not using Autoheader
autoreconf-2.68: running: automake --add-missing --copy --force-missing
configure.ac required file `data/Makefile.in' not found
Makefile.am required directory ./data does not exist
autoreconf-2.68: automake failed with exit status: 1

Edit: ignore above, it's my fault. Stay tuned.

Yeah, I added back what was needed and now autotools work. All it was missing was pkg-config - and it works with http://sourceforge.net/projects/pkgconfiglite/

Compiling now.


ReplyQuote
shenle
(@shenle)
Senior Chief Registered
Joined: 13 years ago
Posts: 70
Topic starter  

Even with autotools, still the linker can't find libraries. Grrr.


ReplyQuote
fluffyfreak
(@fluffyfreak)
Captain Registered
Joined: 7 years ago
Posts: 1306
 

Mayeb you could try starting again based on the vs2010 or vs2012 builds. They're much more regularly updated and you already have most of the dependencies started now.


ReplyQuote
fluffyfreak
(@fluffyfreak)
Captain Registered
Joined: 7 years ago
Posts: 1306
 

Ooh also, I had planned to do something similar to yourself because the visual studio projects are setup the Express Editions which only allow for 32 bit builds. Whereas a MinGW/C::B's build could be 64bit. However I was going to start with the 32bit version since I knew that "should" be easier to get working.

Are you trying to get it built with 32 or 64 bit libs? Does this make any difference?


ReplyQuote
shenle
(@shenle)
Senior Chief Registered
Joined: 13 years ago
Posts: 70
Topic starter  

Code::Blocks can't import VS 2010 or 2012 projects. Only 2008 and older. The newer formats are incompatible.

All my builds have been 32bit. No point even thinking at 64bit before getting the basics to work.


ReplyQuote
fluffyfreak
(@fluffyfreak)
Captain Registered
Joined: 7 years ago
Posts: 1306
 

Ok then, do you have  GitHub repo + branch for this? Maybe someone, possibly me if I can find the time, can collaborate with you and get it running.


ReplyQuote