Tremulous Forum
		Mods => Modding Center => Topic started by: Piper802 on June 13, 2009, 01:33:19 am
		
			
			- 
				My friend wants me to compile the MGDev source and I was following this guide here:
 http://projects.mercenariesguild.net/projects/mgdev/wiki/Getthesource
 
 I'm trying to use the MSysGit method. So far I've installed MSysGit and I ran the commandgit clone git://git.mercenariesguild.net/mgdev.git mgdev
 It downloaded the source to the folder MGDev, but when I run "make" in MSys it returns this error:
 $ make
 make[1]: Entering directory `/home/Owner/mgdev'
 
 Building Tremulous in build/release-mingw32-x86:
 PLATFORM: mingw32
 ARCH: x86
 VERSION: 1.1.0
 COMPILE_PLATFORM: mingw32
 COMPILE_ARCH: x86
 CC: gcc
 
 CFLAGS:
 -MMD
 -Wall
 -fno-strict-aliasing
 -Wimplicit
 -Wstrict-prototypes
 -DUSE_ICON
 -DWINVER=0x501
 -DUSE_OPENAL
 -DUSE_OPENAL_DLOPEN
 -DUSE_CURL
 -DCURL_STATICLIB
 -m32
 -Isrc/SDL12/include
 -DUSE_MUMBLE
 -DUSE_VOIP
 -DFLOATING_POINT
 -DUSE_ALLOCA
 -Isrc/libspeex/include
 -DUSE_LOCAL_HEADERS
 -DPRODUCT_VERSION="1.1.0"
 -DNDEBUG
 -O3
 -march=i586
 -fno-omit-frame-pointer
 -ffast-math
 -falign-loops=2
 -funroll-loops
 -falign-jumps=2
 -falign-functions=2
 -fstrength-reduce
 
 LDFLAGS:
 /bin/sh.exe: -c: line 1: syntax error near unexpected token `;'
 /bin/sh.exe: -c: line 1: `for i in ;  do  echo "    $i";  done'
 make[1]: [targets] Error 2 (ignored)
 
 LIBS:
 -lws2_32
 -lwinmm
 
 Output:
 build/release-mingw32-x86/tremded.x86.exe
 build/release-mingw32-x86/base/cgamex86.dll
 build/release-mingw32-x86/base/gamex86.dll
 build/release-mingw32-x86/base/uix86.dll
 build/release-mingw32-x86/base/vm/cgame.qvm
 build/release-mingw32-x86/base/vm/game.qvm
 build/release-mingw32-x86/base/vm/ui.qvm
 
 make[2]: Entering directory `/home/Owner/mgdev'
 LD build/release-mingw32-x86/tremded.x86.exe
 build/release-mingw32-x86/ded/net_ip.o(.text+0x335d):net_ip.c: undefined reference to `gai_strerror'
 make[2]: *** [build/release-mingw32-x86/tremded.x86.exe] Error 1
 make[2]: Leaving directory `/home/Owner/mgdev'
 make[1]: *** [targets] Error 2
 make[1]: Leaving directory `/home/Owner/mgdev'
 make: *** [release] Error 2
 
I think it could just be a syntax error in the source, but then again I'm no expert.
 Any suggestions on how to fix it? Thanks in advance.
- 
				gai_strerror should be #defined in ws2tcpip.h. It is a macro that expands to gai_strerrorA, when the linker still has the name gai_strerror then the compiler didn't include the header file correctly.
 Unfortunately your log doesn't show the compiler step, only the linker step. I think the real error is in the compile step (try to delete the net_ip.o file and re-make - I guess there is a warning about the missing header file....)
 
- 
				Update your mingw runtime (see mingw download site)