"INIPARSER" crashes compile process on winxp/mingw! why?

Discuss the future of Warzone 2100 with us.
smallfly
Trained
Trained
Posts: 85
Joined: 21 Aug 2009, 10:26

"INIPARSER" crashes compile process on winxp/mingw! why?

Post by smallfly »

Hello together,

i want to compile wz on winxp using mingw and so i followed the compile guide on the website. starting the compiler all runs fine for about 10 seconds. then there is a error about "iniparser". :(

did anyone try to compile the trunk in the last days and got problems with "iniparser"? i need help with that.

thanks for your answers

EDIT: there seem to be more errors. they are all like "... src/multiint.c:2959: undefined reference to iniparser_ ...": Here a part of the compiler output (the end of it)

Code: Select all

g++ -std=gnu99 -g -Wall -Werror-implicit-function-declaration -O0  -o warzone2100.exe message_parser.tab.o message_lexer.lex.
rser.tab.o scriptvals_lexer.lex.o action.o advvis.o ai.o aiexperience.o astar.o atmos.o aud.o baseobject.o bridge.o bucket3d.
se.o cluster.o cmddroid.o combat.o component.o configuration.o console.o data.o design.o difficulty.o display3d.o display.o d
e3demo.o edit3d.o effects.o environ.o feature.o formation.o fpath.o frontend.o function.o game.o gateway.o geometry.o group.o
.o init.o intdisplay.o intelmap.o intimage.o intorder.o keybind.o keyedit.o keymap.o level_lexer.lex.o levels.o lighting.o lo
 main.o map.o mapdisplay.o mapgrid.o mechanics.o message.o miscimd.o mission.o move.o multibot.o multigifts.o multiint.o mult
mit.o multimenu.o multiopt.o multiplay.o multistat.o multistruct.o multisync.o objects.o objmem.o oprint.o order.o parsetest.
ctile.o radar.o raycast.o research.o scores.o scriptai.o scriptcb.o scriptextern.o scriptfuncs.o scriptobj.o scripttabs.o scr
tion.o seqdisp.o stats.o structure.o target.o terrain.o text.o texture.o transporter.o version.o visibility.o warcam.o warzon
ers.o ../lib/libgamelib.a ../lib/libivis_common.a ../lib/libivis_opengl.a ../lib/libnetplay.a ../lib/libscript.a ../lib/libse
/libsound.a ../lib/libwidget.a ../lib/libframework.a ../lib/libexceptionhandler.a ../lib/libsqlite3.a -LC:/devpkg/lib -mwindo
SDLmain -lSDL -lpng12 -lphysfs -lz -lvorbisfile -lvorbis -logg -lpopt -lintl -lGLC -lglu32 -lopengl32 -lopenal32 -ldbghelp -l
m -lws2_32 -lbfd -liberty -liconv -lz -lfreetype -lfontconfig -lexpat -ltheora
frontend.o: In function `runSinglePlayerMenu':
C:/development/trunk/src/frontend.c:416: undefined reference to `challengesUp'
C:/development/trunk/src/frontend.c:418: undefined reference to `runChallenges'
C:/development/trunk/src/frontend.c:469: undefined reference to `addChallenges'
C:/development/trunk/src/frontend.c:484: undefined reference to `challengesUp'
C:/development/trunk/src/frontend.c:492: undefined reference to `challengesUp'
C:/development/trunk/src/frontend.c:494: undefined reference to `displayChallenges'
init.o: In function `stageThreeShutDown':
C:/development/trunk/src/init.c:1113: undefined reference to `challengesUp'
C:/development/trunk/src/init.c:1114: undefined reference to `challengeActive'
main.o: In function `startGameLoop':
C:/development/trunk/src/main.c:589: undefined reference to `challengeActive'
mission.o: In function `addMissionTimerInterface':
C:/development/trunk/src/mission.c:533: undefined reference to `challengeActive'
mission.o: In function `intUpdateMissionTimer':
C:/development/trunk/src/mission.c:2197: undefined reference to `challengeActive'
C:/development/trunk/src/mission.c:2213: undefined reference to `challengeActive'
multiint.o:C:/development/trunk/src/multiint.c:1123: more undefined references to `challengeActive' follow
multiint.o: In function `startMultiOptions':
C:/development/trunk/src/multiint.c:2959: undefined reference to `iniparser_load'
C:/development/trunk/src/multiint.c:2971: undefined reference to `iniparser_getstring'
C:/development/trunk/src/multiint.c:2972: undefined reference to `iniparser_getint'
C:/development/trunk/src/multiint.c:2973: undefined reference to `iniparser_getboolean'
C:/development/trunk/src/multiint.c:2975: undefined reference to `iniparser_getint'
C:/development/trunk/src/multiint.c:2976: undefined reference to `iniparser_getint'
C:/development/trunk/src/multiint.c:2982: undefined reference to `iniparser_getint'
C:/development/trunk/src/multiint.c:2986: undefined reference to `iniparser_getint'
C:/development/trunk/src/multiint.c:2990: undefined reference to `iniparser_freedict'
multilimit.o: In function `startLimitScreen':
C:/development/trunk/src/multilimit.c:237: undefined reference to `challengeActive'
scriptfuncs.o: In function `scrGameOverMessage':
C:/development/trunk/src/scriptfuncs.c:3265: undefined reference to `challengeActive'
C:/development/trunk/src/scriptfuncs.c:3270: undefined reference to `iniparser_load'
C:/development/trunk/src/scriptfuncs.c:3284: undefined reference to `iniparser_getboolean'
C:/development/trunk/src/scriptfuncs.c:3286: undefined reference to `iniparser_getint'
C:/development/trunk/src/scriptfuncs.c:3290: undefined reference to `dictionary_new'
C:/development/trunk/src/scriptfuncs.c:3300: undefined reference to `dictionary_set'
C:/development/trunk/src/scriptfuncs.c:3303: undefined reference to `iniparser_setstring'
C:/development/trunk/src/scriptfuncs.c:3305: undefined reference to `iniparser_setstring'
C:/development/trunk/src/scriptfuncs.c:3307: undefined reference to `iniparser_setstring'
C:/development/trunk/src/scriptfuncs.c:3309: undefined reference to `iniparser_dump_ini'
C:/development/trunk/src/scriptfuncs.c:3310: undefined reference to `iniparser_freedict'
collect2: ld returned 1 exit status
mingw32-make[1]: *** [warzone2100.exe] Error 1
rm message_parser.tab.c level_lexer.lex.c scriptvals_lexer.lex.c message_lexer.lex.c scriptvals_parser.tab.c
mingw32-make[1]: Leaving directory `C:/development/trunk/src'
mingw32-make: *** [src] Error 2
EDIT: any admin: please move this thread to the troubleshooting forum. sorry.
stiv
Warzone 2100 Team Member
Warzone 2100 Team Member
Posts: 876
Joined: 18 Jul 2008, 04:41
Location: 45N 86W

Re: "INIPARSER" crashes compile process on winxp/mingw! why?

Post by stiv »

Likely your source is not completely up to date. Try doing the following:

svn update
make clean
make

If your source is up to date, the 'svn update' command will simply show something like
At revision 8023.
Per
Warzone 2100 Team Member
Warzone 2100 Team Member
Posts: 3780
Joined: 03 Aug 2006, 19:39

Re: "INIPARSER" crashes compile process on winxp/mingw! why?

Post by Per »

If you are running mingw or cygwin, you may need to rerun ./autogen.sh and ./configure
User avatar
Buginator
Professional
Professional
Posts: 3285
Joined: 04 Nov 2007, 02:20

Re: "INIPARSER" crashes compile process on winxp/mingw! why?

Post by Buginator »

Per wrote:If you are running mingw or cygwin, you may need to rerun ./autogen.sh and ./configure
Looks like someone forgot to update the makefiles for the added files... all the windows makefiles need to be fixed by hand.

The cross-compiler ones are still OK.
and it ends here.
smallfly
Trained
Trained
Posts: 85
Joined: 21 Aug 2009, 10:26

Re: "INIPARSER" crashes compile process on winxp/mingw! why?

Post by smallfly »

stiv wrote:Likely your source is not completely up to date. Try doing the following:
svn update
make clean
make
If your source is up to date, the 'svn update' command will simply show something like
At revision 8023.
I did it => "Completed At revision: 8040"
Per wrote:If you are running mingw or cygwin, you may need to rerun ./autogen.sh and ./configure
How do i run the autogen.sh? This is a shell-script, right? If a just type "autogen" to command console it wants to start the editor to open the file (more correct: windows asks me for a program to open autogen.sh) And how to run configure file? I remember, some time ago, when i successfully compiled openttd, I uses msys to do that. So I need msys to run those scripts??

By the way: Which folder do I have to compile (from which directory I have to start the compile process from)? I starts compiling from /warzone/src as well as from /warzone (/warzone is the directory where /src, /makerules, /win32 etc. is located in)

Although i run the svn update process (with tortoise svn) and it says "Completed At revision: 8040" at the end, my file system has some red exclamation marks. I thought everywhere has to be a green check (?)
filesystem.jpg
// UPDATE: I deleted all directories with red exclamation marks and startet svn update again. I compiled it and got the same errors. :(

Thanks for your help! I really appreciate that! ;)
You do not have the required permissions to view the files attached to this post.
User avatar
BlueMaxima
Trained
Trained
Posts: 431
Joined: 05 Jun 2008, 09:20
Location: Sydney, Australia

Re: "INIPARSER" crashes compile process on winxp/mingw! why?

Post by BlueMaxima »

http://developer.wz2100.net/ticket/835

I-NoD's made a patch to fix this. It works. I've tested it.
Bring back...ducks!
smallfly
Trained
Trained
Posts: 85
Joined: 21 Aug 2009, 10:26

Re: "INIPARSER" crashes compile process on winxp/mingw! why?

Post by smallfly »

Great! I applied the patch and i can now compile the game. Thanks for that! But there is still one "little" problem. When I start the game i cannot see any menu items (see picture).

// EDIT: If I start the game, downloaded from wz2100.net and installed (I mean the not-self-compiled-version) then everything works fine. So it doesnt seem to be a driver problem. It has to do something with the compile process.
nomenuitems.jpg
Its only the visual effect. The button functionality seems to be ok. When I click on the position where the "new game" button (or whats it called again?) should be there appears another menu with no visible buttons (except the back-arrow top left).
withbackbutton.jpg
Clicking the position of the (unvisible) first button again, brings me to the loading screen... After a few seconds, instead of the game a return to windows happens.

if important: game starts in windowed mode after clicking the warzone2100.exe in \warzone\src
You do not have the required permissions to view the files attached to this post.
stiv
Warzone 2100 Team Member
Warzone 2100 Team Member
Posts: 876
Joined: 18 Jul 2008, 04:41
Location: 45N 86W

Re: "INIPARSER" crashes compile process on winxp/mingw! why?

Post by stiv »

if important: game starts in windowed mode after clicking the warzone2100.exe in \warzone\src
Does WZ display properly if run in fullscreen mode?
smallfly
Trained
Trained
Posts: 85
Joined: 21 Aug 2009, 10:26

Re: "INIPARSER" crashes compile process on winxp/mingw! why?

Post by smallfly »

stiv wrote:Does WZ display properly if run in fullscreen mode?
How to do that? I created a link on the desktop with the target

C:\development\warzone\src\warzone2100.exe --fullscreen

but it doesnt start in fullscreen. It still starts in windowed mode.
i-NoD
Code contributor
Code contributor
Posts: 318
Joined: 30 Nov 2008, 00:42
Location: In the middle of nowhere

Re: "INIPARSER" crashes compile process on winxp/mingw! why?

Post by i-NoD »

smallfly wrote:When I start the game i cannot see any menu items (see picture).
try to edit fonts.conf file and deleting <dir>WINDOWSFONTDIR</dir> line.
See viewtopic.php?f=4&t=3505&p=33939#p33939 for details.
smallfly
Trained
Trained
Posts: 85
Joined: 21 Aug 2009, 10:26

Re: "INIPARSER" crashes compile process on winxp/mingw! why?

Post by smallfly »

i-NoD wrote:try to edit fonts.conf file and deleting <dir>WINDOWSFONTDIR</dir> line.
See viewtopic.php?f=4&t=3505&p=33939#p33939 for details.
I dont even have a "font.conf" file in my warzone working copy. the app data file also not exists. by the way: the reported error concerns damaged fonts ingame. menu seems ok. in my case: there is no menu. do you have another idea?

thanks for now
i-NoD
Code contributor
Code contributor
Posts: 318
Joined: 30 Nov 2008, 00:42
Location: In the middle of nowhere

Re: "INIPARSER" crashes compile process on winxp/mingw! why?

Post by i-NoD »

smallfly wrote:in my case: there is no menu
am i correct to think that you referring to missing text from menus from screenshots earlier?
If that is so then check that you have 'fonts' folder with 'fonts.conf' file right where your warzone2100.exe is located.
Maybe I've forgot to copy it from mingw devpakage 'etc' folder? Its where your DejaVu fonts are located and if there is no such folder - there will no text in menus...
smallfly
Trained
Trained
Posts: 85
Joined: 21 Aug 2009, 10:26

Re: "INIPARSER" crashes compile process on winxp/mingw! why?

Post by smallfly »

Im currently not at my pc, but I know that in the warzone/src/ directory, where the warzone2100.exe is located after compiling, there is no subdirectory.
i-NoD wrote:If that is so then check that you have 'fonts' folder with 'fonts.conf' file right where your warzone2100.exe is located.
Maybe I've forgot to copy it from mingw devpakage 'etc' folder? Its where your DejaVu fonts are located and if there is no such folder - there will no text in menus...
So perhaps you really forgot to insert the copy command for it. I will test it tonight.
i-NoD
Code contributor
Code contributor
Posts: 318
Joined: 30 Nov 2008, 00:42
Location: In the middle of nowhere

Re: "INIPARSER" crashes compile process on winxp/mingw! why?

Post by i-NoD »

smallfly wrote:that in the warzone/src/ directory, where the warzone2100.exe is located after compiling
Whoa! O_o

By looking at MinGW compile guide suggestion
When this command finishes without error you should have a warzone2100.exe in the "src" directory which you can execute.
i guess that you can launch it from there, but... I've just tried to launch it from src folder and encountered the same no-fonts issue as you've described. I'm not sure how a MinGW build process should flow (since I'm using MSVC for WZ compilation) but i'm sure that if warzone2100.exe file copied in and executed from warzone/data folder where all the game data is located and 'fonts' folder with 'fonts.conf' file and fonts are inside too then all work fine.
smallfly
Trained
Trained
Posts: 85
Joined: 21 Aug 2009, 10:26

Re: "INIPARSER" crashes compile process on winxp/mingw! why?

Post by smallfly »

Jeehaw! Finally it works! Thanks to all helpers! ;) Perhaps we should update the compile guide now?

It finally worked after copying the /fonts folder from /devpkg/etc
copythat.jpg
to /warzone/src
thatworks.jpg
It doesnt work, when i just copy the warzone2100.exe from /src to /data like the following screenshot shows:
copiedtodata.jpg
You do not have the required permissions to view the files attached to this post.