Tremulous Forum
Mods => Modding Center => Topic started by: cron on December 05, 2010, 03:39:47 pm
-
First, download and install 7-Zip (http://www.7-zip.org/). You'll need it to decompress several files we'll be using.
Then follow these steps to compile the Tremulous client on Windows using MinGW:
1. Download and install the newest mingw-get-setup.exe:
https://sourceforge.net/projects/mingw/files/Installer/ (https://sourceforge.net/projects/mingw/files/Installer/)
- Select 'Download latest repository catalogues' and install to: C:\MinGW
- Select components to install: 'mingw32-base', 'mingw32-gcc-g++', and 'msys-base'
- When complete, add the line C:\MinGW\bin; in to MS Windows' PATH environment variable (http://lmgtfy.com/?q=windows+path+environment+variable)
** Note: Msys uses a file & folder/directory hierarchy that is separate from the OS's. Edit the file C:\MinGW\msys\1.0\bin\fstab to add any folder locations that you may want mounted. See the 'Getting Started (http://www.mingw.org/wiki/Getting_Started)' guide for more info. **
2. Download the source for libcURL from curl.haxx.se and build it :
https://curl.haxx.se/latest.cgi?curl=zip (https://curl.haxx.se/dlwiz/?type=source&os=-)
Notes to flesh this out later: https://web.archive.org/web/20160108151213/http://curl.haxx.se:80/mail/lib-2007-02/0076.html
3. Download and install the OpenAL libraries that you would like to use:
Using the free LGPL licensed OpenAL Soft libraries (http://kcat.strangesoft.net/openal.html#about) (Needed for systems without OpenAL32.dll):
openal-soft-1.18.2-bin.zip (http://kcat.strangesoft.net/openal-binaries/openal-soft-1.18.2-bin.zip)
- Extract the files with 7-Zip, copy the \include\AL directory to C:\MinGW\include\
-OR-
Using the proprietary (non free) OpenAL 11 Core SDK:
OpenAL11CoreSDK.zip (http://www.openal.org/downloads/OpenAL11CoreSDK.zip)
- Copy the contents of C:\Program Files\OpenAL 1.1 SDK\include\ to C:\MinGW\include\
- Copy the contents of C:\Program Files\OpenAL 1.1 SDK\libs\ to C:\MinGW\lib\
4. Download the Git for Windows installer:
https://git-scm.com/download/win (https://git-scm.com/download/win) (64-bit or 32-bit, depending on your system)
- Run the installer. Keep the default list of components to install. On the "Adjusting your PATH environment" step, choose the 2nd option: "Use Git from the Windows Command Prompt". Keep the default options for the rest of the setup steps.
5. Start the MinGW Shell (MSys) by running C:\MinGW\msys\1.0\msys.bat (run as Administrator)
6. Clone the newest Tremulous source code
$ git clone https://github.com/darklegion/tremulous.git
( This will create a new directory /home/<username>/tremulous/ which can be located on disk at C:\MinGW\msys\1.0\home\<username>\tremulous\ )
7. Change directory to where the Tremulous source downloaded to:
$ cd tremulous
8. Create a new file named Makefile.local which contains the following lines:
CC=gcc - To specify that the GCC C compiler should be used.
USE_CURL=1 - Uses cURL to add http downloading capability to the client.
To build your own QVMs, add:
BUILD_GAME_QVM=1
-OR-
BUILD_GAME_QVM=0
INCLUDE=
LIBRARY=
9. Run make (NOT 'mingw32-make'):
$ make
If all went well, your new tremulous.x86.exe (and tremded), .DLLs and QVMs will be in build/release-mingw32-x86/, base/, and base/vm, respectively. If something went wrong, try to correct the issue and run make clean before running make again.
** If you built custom QVMs, make a new directory named VM in your %APPDATA%/Tremulous/base/ folder and copy the .qvm files into it **
10. Copy the .exe(s) to where you have Tremulous installed
(eg. C:\Program Files\Tremulous\ ), and copy the .DLLs in /base/ to C:\Program Files\Tremulous\base\ )
Note: Keep a backup of your old/original binaries, in case something goes wrong!
Tip: Don't forget to add a firewall exception for it like I always do! :)
Additional info: Ingar's "Building a custom MinGW/MSYS development environment" (http://ingar.satgnu.net/devenv/mingw32/)
Notes:
If the compile fails, delete old build files with make clean:
$ make clean
Credits:
BIG THANKS to Ingar for assistance, and to Risujin for his original post (http://tremulous.net/forum/index.php?topic=3408.0). Also thanks to gimhael for the CC=gcc fix.
Notes:
2011-09-24 : Added info about overwriting libeay32.dll
2012-04-17 : Updated link for cURL and removed outdated 1.1 source info
2012-04-18 : More cleanup and date format changes. Renamed title.
2013-07-01 : Simplified instructions
2017-10-03 : Updated URLs, use Git instead of SVN
-
Sticky?
-
Sticky?
I second that!
-
Sticky?
I need people to test this out to make sure it all works first. :police:
-
Will openal-soft use hardware if available?
-
I think there's a little misunderstanding: I suggested to use openal-soft instead of
the official implementation because I had problems with that when I used
it to compile other projects, I use openal-soft in my own devenv now.
For OpenAL support you need an OpenAL32.dll (either the official (http://"http://www.openal.org./openal/Downloads/oalinst.zip") one, or the OpenAL-soft (http://"http://kcat.strangesoft.net/openal-soft-1.12.854-bin.zip") replacement).
I can't remember if those packages install the necessary development files (includes) as well.
-
Updated the info on OpenAL and gave the topic a new name. Thanks Ingar!
-
I can only compile the GPP using GCC 3.4.5. Does this guide work for GCC 4.5.x on Windows?
I'll add instructions on setting up a separate MinGW install with older GCC if needed.
-
I keep trying to compile and get a heap of errors that are obviously the creative commons license, but I can't find the file.
-
Unfortunately on mingw filenames are case insensitive and usually the $PATH contains the current directory, so when make looks for the default C-compiler cc it finds the Creative Commons license file ./CC and tries to execute it !
Easy fix: run make CC=gcc
and it should pick up the proper C-compiler.
-
Thanks for the CC fix. I now get errors about wsiapi.h, even though I placed it in MinGw's include folder.
Javier@Javier-PC ~/tremulous
$ make CC=gcc
make[1]: Entering directory `/home/Javier/tremulous'
Building Tremulous in build/release-HPD-x86:
PLATFORM: HPD
ARCH: x86
VERSION: 1.1.0_SVN2184
COMPILE_PLATFORM: mingw32
COMPILE_ARCH: x86
CC: gcc
CFLAGS:
-DNO_VM_COMPILED
-DNO_GZIP
-Isrc/zlib
-DUSE_LOCAL_HEADERS
-DPRODUCT_VERSION="1.1.0_SVN2184"
-MMD
-DNDEBUG
-O3
CLIENT_CFLAGS:
-DUSE_MUMBLE
-DUSE_VOIP
-DFLOATING_POINT
-DUSE_ALLOCA
-Isrc/libspeex/include
SERVER_CFLAGS:
-DUSE_VOIP
LDFLAGS:
LIBS:
CLIENT_LIBS:
Output:
build/release-HPD-x86/tremded.x86
build/release-HPD-x86/tremulous.x86
build/release-HPD-x86/base/cgamex86.so
build/release-HPD-x86/base/gamex86.so
build/release-HPD-x86/base/uix86.so
make[2]: Entering directory `/home/Javier/tremulous'
DED_CC src/server/sv_client.c
DED_CC src/server/sv_ccmds.c
DED_CC src/server/sv_game.c
DED_CC src/server/sv_init.c
DED_CC src/server/sv_main.c
DED_CC src/server/sv_net_chan.c
DED_CC src/server/sv_snapshot.c
DED_CC src/server/sv_world.c
DED_CC src/qcommon/cm_load.c
DED_CC src/qcommon/cm_patch.c
DED_CC src/qcommon/cm_polylib.c
DED_CC src/qcommon/cm_test.c
DED_CC src/qcommon/cm_trace.c
DED_CC src/qcommon/cmd.c
DED_CC src/qcommon/common.c
DED_CC src/qcommon/cvar.c
DED_CC src/qcommon/files.c
DED_CC src/qcommon/md4.c
DED_CC src/qcommon/msg.c
DED_CC src/qcommon/net_chan.c
DED_CC src/qcommon/net_ip.c
In file included from src/qcommon/net_ip.c:35:0:
c:\mingw\bin\../lib/gcc/mingw32/4.5.2/../../../../include/wspiapi.h:67:11: error
: expected ')' before 'const'
c:\mingw\bin\../lib/gcc/mingw32/4.5.2/../../../../include/wspiapi.h:73:16: error
: expected ')' before '(' token
c:\mingw\bin\../lib/gcc/mingw32/4.5.2/../../../../include/wspiapi.h:82:11: error
: expected ')' before 'struct'
c:\mingw\bin\../lib/gcc/mingw32/4.5.2/../../../../include/wspiapi.h:96:1: error:
expected '=', ',', ';', 'asm' or '__attribute__' before 'char'
c:\mingw\bin\../lib/gcc/mingw32/4.5.2/../../../../include/wspiapi.h:136:11: erro
r: expected ')' before 'const'
c:\mingw\bin\../lib/gcc/mingw32/4.5.2/../../../../include/wspiapi.h:180:11: erro
r: expected ')' before 'int'
c:\mingw\bin\../lib/gcc/mingw32/4.5.2/../../../../include/wspiapi.h:237:11: erro
r: expected ')' before 'const'
c:\mingw\bin\../lib/gcc/mingw32/4.5.2/../../../../include/wspiapi.h:315:11: erro
r: expected ')' before 'const'
c:\mingw\bin\../lib/gcc/mingw32/4.5.2/../../../../include/wspiapi.h:399:11: erro
r: expected ')' before 'WORD'
c:\mingw\bin\../lib/gcc/mingw32/4.5.2/../../../../include/wspiapi.h:449:11: erro
r: expected ')' before 'struct'
c:\mingw\bin\../lib/gcc/mingw32/4.5.2/../../../../include/wspiapi.h:482:10: erro
r: expected ')' before 'const'
c:\mingw\bin\../lib/gcc/mingw32/4.5.2/../../../../include/wspiapi.h:700:16: erro
r: expected ')' before '(' token
c:\mingw\bin\../lib/gcc/mingw32/4.5.2/../../../../include/wspiapi.h:873:11: erro
r: expected ')' before 'WORD'
c:\mingw\bin\../lib/gcc/mingw32/4.5.2/../../../../include/wspiapi.h:999:14: erro
r: expected ')' before 'const'
c:\mingw\bin\../lib/gcc/mingw32/4.5.2/../../../../include/wspiapi.h:1021:16: err
or: expected ')' before '(' token
c:\mingw\bin\../lib/gcc/mingw32/4.5.2/../../../../include/wspiapi.h:1046:11: err
or: expected ')' before 'struct'
make[2]: *** [build/release-HPD-x86/ded/net_ip.o] Error 1
make[2]: Leaving directory `/home/Javier/tremulous'
make[1]: *** [targets] Error 2
make[1]: Leaving directory `/home/Javier/tremulous'
make: *** [release] Error 2
Javier@Javier-PC ~/tremulous
$
*EDIT More pertinently, how do I compile the code without wspiapi.h?
-
I think the #include of wspiapi.h or ws2spi.h can be completely removed without problems.
-
when i do step 2 i cant find the file y is this?
-
The design on the libcurl site is a bit yucky, making it hard to find the right thing, but here's a direct link to what you want: http://www.gknw.net/mirror/curl/win32/curl-7.21.4-devel-mingw32.zip (http://www.gknw.net/mirror/curl/win32/curl-7.21.4-devel-mingw32.zip)
-
This guide should definitely be stickied, the old guide is outdated.
You should add a section on what to do with the build output, especially the qvm.
-
Haha sorry Cron but I've been having the same probs as everyone else :P
At first I couldnt find the right libcURL, due to the site being a bit yucky as you said haha. I think you should put the direct link in the topic post :P
But yeah then I had the same problem as Dr. A Goon that involved using make CC=gcc
, which got me a liiittle further
And now I'm having the same problem as Dr. A Goon again, where its not finding wspiapi.h from the #include in tremulous/src/qcommon/net_ip.c, so I deleted the #include call, and now I'm just getting more errors about other files it cant find:
make[1]: Leaving directory `/home/Nolan/tremulous'
make[1]: Entering directory `/home/Nolan/tremulous/src/master'
rm -f debug-HPD-x86/*
rm -f release-HPD-x86/*
make[1]: Leaving directory `/home/Nolan/tremulous/src/master'
Nolan@Nolan-PC ~/tremulous
$ make
make[1]: Entering directory `/home/Nolan/tremulous'
Building Tremulous in build/release-HPD-x86:
PLATFORM: HPD
ARCH: x86
VERSION: 1.1.0_SVN2213
COMPILE_PLATFORM: mingw32
COMPILE_ARCH: x86
CC: cc
CFLAGS:
-DNO_VM_COMPILED
-DNO_GZIP
-Isrc/zlib
-DUSE_INTERNAL_JPEG
-Isrc/jpeg-8c
-DUSE_LOCAL_HEADERS
-DPRODUCT_VERSION="1.1.0_SVN2213"
-MMD
-DNDEBUG
-O3
CLIENT_CFLAGS:
-DUSE_MUMBLE
-DUSE_VOIP
-DFLOATING_POINT
-DUSE_ALLOCA
-Isrc/libspeex/include
SERVER_CFLAGS:
-DUSE_VOIP
LDFLAGS:
LIBS:
CLIENT_LIBS:
Output:
build/release-HPD-x86/tremded.x86
build/release-HPD-x86/tremulous.x86
build/release-HPD-x86/base/cgamex86.so
build/release-HPD-x86/base/gamex86.so
build/release-HPD-x86/base/uix86.so
make[2]: Entering directory `/home/Nolan/tremulous'
DED_CC src/server/sv_client.c
./cc: line 1: Creative_Commons: command not found
./cc: line 2: Creative: command not found
./cc: line 3: Attribution-ShareAlike: command not found
./cc: line 4: CREATIVE: command not found
./cc: line 5: SERVICES.: command not found
./cc: line 6: RELATIONSHIP.: command not found
./cc: line 7: CREATIVE: command not found
./cc: line 8: DISCLAIMS: command not found
./cc: line 9: License: command not found
./cc: line 10: syntax error near unexpected token `('
./cc: line 10: `THE WORK (AS DEFINED BELOW) IS PROVIDED UNDER THE TERMS OF THIS
CREATIVE'
make[2]: *** [build/release-HPD-x86/ded/sv_client.o] Error 2
make[2]: Leaving directory `/home/Nolan/tremulous'
make[1]: *** [targets] Error 2
make[1]: Leaving directory `/home/Nolan/tremulous'
make: *** [release] Error 2
Nolan@Nolan-PC ~/tremulous
$ make CC=gcc
make[1]: Entering directory `/home/Nolan/tremulous'
Building Tremulous in build/release-HPD-x86:
PLATFORM: HPD
ARCH: x86
VERSION: 1.1.0_SVN2213
COMPILE_PLATFORM: mingw32
COMPILE_ARCH: x86
CC: gcc
CFLAGS:
-DNO_VM_COMPILED
-DNO_GZIP
-Isrc/zlib
-DUSE_INTERNAL_JPEG
-Isrc/jpeg-8c
-DUSE_LOCAL_HEADERS
-DPRODUCT_VERSION="1.1.0_SVN2213"
-MMD
-DNDEBUG
-O3
CLIENT_CFLAGS:
-DUSE_MUMBLE
-DUSE_VOIP
-DFLOATING_POINT
-DUSE_ALLOCA
-Isrc/libspeex/include
SERVER_CFLAGS:
-DUSE_VOIP
LDFLAGS:
LIBS:
CLIENT_LIBS:
Output:
build/release-HPD-x86/tremded.x86
build/release-HPD-x86/tremulous.x86
build/release-HPD-x86/base/cgamex86.so
build/release-HPD-x86/base/gamex86.so
build/release-HPD-x86/base/uix86.so
make[2]: Entering directory `/home/Nolan/tremulous'
DED_CC src/server/sv_client.c
DED_CC src/server/sv_ccmds.c
DED_CC src/server/sv_game.c
DED_CC src/server/sv_init.c
DED_CC src/server/sv_main.c
DED_CC src/server/sv_net_chan.c
DED_CC src/server/sv_snapshot.c
DED_CC src/server/sv_world.c
DED_CC src/qcommon/cm_load.c
DED_CC src/qcommon/cm_patch.c
DED_CC src/qcommon/cm_polylib.c
DED_CC src/qcommon/cm_test.c
DED_CC src/qcommon/cm_trace.c
DED_CC src/qcommon/cmd.c
DED_CC src/qcommon/common.c
DED_CC src/qcommon/cvar.c
DED_CC src/qcommon/files.c
DED_CC src/qcommon/md4.c
DED_CC src/qcommon/msg.c
DED_CC src/qcommon/net_chan.c
DED_CC src/qcommon/net_ip.c
src/qcommon/net_ip.c:35:24: fatal error: wspiapi.h: No such file or directory
compilation terminated.
make[2]: *** [build/release-HPD-x86/ded/net_ip.o] Error 1
make[2]: Leaving directory `/home/Nolan/tremulous'
make[1]: *** [targets] Error 2
make[1]: Leaving directory `/home/Nolan/tremulous'
make: *** [release] Error 2
Nolan@Nolan-PC ~/tremulous
$ make CC=gcc
make[1]: Entering directory `/home/Nolan/tremulous'
Building Tremulous in build/release-HPD-x86:
PLATFORM: HPD
ARCH: x86
VERSION: 1.1.0_SVN2213M
COMPILE_PLATFORM: mingw32
COMPILE_ARCH: x86
CC: gcc
CFLAGS:
-DNO_VM_COMPILED
-DNO_GZIP
-Isrc/zlib
-DUSE_INTERNAL_JPEG
-Isrc/jpeg-8c
-DUSE_LOCAL_HEADERS
-DPRODUCT_VERSION="1.1.0_SVN2213M"
-MMD
-DNDEBUG
-O3
CLIENT_CFLAGS:
-DUSE_MUMBLE
-DUSE_VOIP
-DFLOATING_POINT
-DUSE_ALLOCA
-Isrc/libspeex/include
SERVER_CFLAGS:
-DUSE_VOIP
LDFLAGS:
LIBS:
CLIENT_LIBS:
Output:
build/release-HPD-x86/tremded.x86
build/release-HPD-x86/tremulous.x86
build/release-HPD-x86/base/cgamex86.so
build/release-HPD-x86/base/gamex86.so
build/release-HPD-x86/base/uix86.so
make[2]: Entering directory `/home/Nolan/tremulous'
DED_CC src/qcommon/net_ip.c
src/qcommon/net_ip.c:50:2: error: #else without #if
src/qcommon/net_ip.c:57:24: fatal error: arpa/inet.h: No such file or directory
compilation terminated.
make[2]: *** [build/release-HPD-x86/ded/net_ip.o] Error 1
make[2]: Leaving directory `/home/Nolan/tremulous'
make[1]: *** [targets] Error 2
make[1]: Leaving directory `/home/Nolan/tremulous'
make: *** [release] Error 2
Nolan@Nolan-PC ~/tremulous
$ make CC=gcc
make[1]: Entering directory `/home/Nolan/tremulous'
Building Tremulous in build/release-HPD-x86:
PLATFORM: HPD
ARCH: x86
VERSION: 1.1.0_SVN2213M
COMPILE_PLATFORM: mingw32
COMPILE_ARCH: x86
CC: gcc
CFLAGS:
-DNO_VM_COMPILED
-DNO_GZIP
-Isrc/zlib
-DUSE_INTERNAL_JPEG
-Isrc/jpeg-8c
-DUSE_LOCAL_HEADERS
-DPRODUCT_VERSION="1.1.0_SVN2213M"
-MMD
-DNDEBUG
-O3
CLIENT_CFLAGS:
-DUSE_MUMBLE
-DUSE_VOIP
-DFLOATING_POINT
-DUSE_ALLOCA
-Isrc/libspeex/include
SERVER_CFLAGS:
-DUSE_VOIP
LDFLAGS:
LIBS:
CLIENT_LIBS:
Output:
build/release-HPD-x86/tremded.x86
build/release-HPD-x86/tremulous.x86
build/release-HPD-x86/base/cgamex86.so
build/release-HPD-x86/base/gamex86.so
build/release-HPD-x86/base/uix86.so
make[2]: Entering directory `/home/Nolan/tremulous'
DED_CC src/qcommon/net_ip.c
DED_CC src/qcommon/huffman.c
DED_CC src/qcommon/parse.c
DED_CC src/qcommon/q_math.c
DED_CC src/qcommon/q_shared.c
DED_CC src/qcommon/unzip.c
DED_CC src/qcommon/ioapi.c
DED_CC src/qcommon/vm.c
DED_CC src/qcommon/vm_interpreted.c
DED_CC src/null/null_client.c
DED_CC src/null/null_input.c
DED_CC src/null/null_snddma.c
DED_CC src/sys/con_log.c
DED_CC src/sys/sys_main.c
AS src/asm/ftola.s
AS src/asm/snapvectora.s
AS src/asm/matha.s
DED_CC src/zlib/adler32.c
DED_CC src/zlib/crc32.c
DED_CC src/zlib/inffast.c
DED_CC src/zlib/inflate.c
DED_CC src/zlib/inftrees.c
DED_CC src/zlib/zutil.c
DED_CC src/sys/sys_unix.c
src/sys/sys_unix.c:35:22: fatal error: sys/mman.h: No such file or directory
compilation terminated.
make[2]: *** [build/release-HPD-x86/ded/sys_unix.o] Error 1
make[2]: Leaving directory `/home/Nolan/tremulous'
make[1]: *** [targets] Error 2
make[1]: Leaving directory `/home/Nolan/tremulous'
make: *** [release] Error 2
$
-
Yeah, what happened to me was that I screwed my PLATFORM variable to HPD which happened to you too. Set it to the windows standard, which you can find by inspecting the makefile.
-
It worked for me first time thanks
-
More info:
You should add a section on what to do with the build output, especially the qvm.
I have compiled the source.. But now what, is there another guide that can tell me what to do next? It obviously isn't runnable. How can I package it for distribution to some friends?
the tremulous.x86.exe file can be found in the build/*/ directory and the VMs can be found in vm/*/base/vm/.
You put the tremulous.x86.exe file in your Tremulous folder and execute it to play and/or put the VMs in %appdata%/Tremulous/base/vm to put your compiled gameplay changes into effect.
-
I get lots of error messages due to the fact that i have ._ files (needed for Git repo)
I'm also having problems with auto-installing tools... they block my qvm build
-
To download the newest Tremulous 1.1 source from SVN (creates a directory ~/tremulous/ ):
$ svn co -r HEAD svn://svn.icculus.org/tremulous/trunk/ ~/tremulous
there isn't really such a thing as the newest 1.1 source. r755 was the revision used in the 1.1.0 release. the network compatibility with 1.1.0 was lost at, IIRC, some 900ish revision, and after 100s of revisions later, GPP changes (including balance changes) were added. the gpp branch differs from the main branch (the trunk) basically only by default network settings (eg., the master server port). for users who do not fully understand the differences between the main branch and the gpp branch: avoid the main branch, download the gpp branch instead; ie., do not chose to run the above command.
-
Its not that... i while building the qvm it says something like installing blah blah and said something like invalid or cannot etc...
Also, i tried compiling gpp and korx qvm as is, they succeed but when i try the qvm on a local server, the korx one's buildables are screwed up (multiple rcs can be built, you can walk through them, they do not power anything e.i. do nothing at all, just visually present) and the gpp [server] has lots of [i think buildable placement] problems as it shows the coordinates of some random numbers, and the client crashes before it loads the map. This time i redone step #2, [before i had the forum opened up in a weird format and couldn't load some links [http://tremulous.net/forum/index.php?topic=14726.0;wap2]] but it seems the link no longer exists [http://www.gknw.net/mirror/curl/win32/curl-7.21.4-devel-mingw32.zip]
I googled the file but i get the same links or links that have no relation [e.i. viruses, porno sites etc...]
-
9-24-11
4-17-12
what are these silly numbers?
-
9-24-11
4-17-12
what are these silly numbers?
Dates in MM/DD/YY format?
-
9-24-11
4-17-12
what are these silly numbers?
Dates in MM/DD/YY format?
that can't be; MM/DD/YY would imply something like 04/17/12, which has a leading 0 and uses '/'s as separators. the number could be dates in Y-M-D or M-D-Y format, or could be just some fancy serial numbers. but in any case, there's an international date and time representation standard (http://www.cl.cam.ac.uk/~mgk25/iso-time.html).
-
There's also local (non-ISO 8601 complaint) standards for the display of dates which in some countries see wide spread use. It's my belief that Cron used this local standard instead of ISO 8601. Be aware that the use of ISO 8601 compliant date representation does not actually resolve your issue. Your issue is that he has not specified which format he has used. Alternatively this confusion could be avoided by using a non-ambiguous date format such as 12 April 2012.
-
a non-ambiguous date format such as 12 April 2012.
or YYYY-MM-DD...
-
It's ambiguous as YYYY-MM-DD could be mistaken for YYYY-DD-MM unless the date format has been specified.
-
It's ambiguous as YYYY-MM-DD could be mistaken for YYYY-DD-MM unless the date format has been specified.
or could be "mistaken" for YD-MY-YMDY, or any other fancy format, just as 12 April 2012 could be "mistaken" for YD <month> DY<fancy_checksum_of_the_year>. but who uses any of these fancy formats?
-
You should be aware however that there are 3 main formats used to represent dates; D-M-Y, M-D-Y, Y-M-D. 9-24-11 is obviously of the format M-D-Y and therefore in this case the format M-D-Y is non-ambiguous (just like ISO 8601). We must operate on one of two assumptions. That a person will be aware of the 3 major date formats in which case the use of M-D-YY is perfectly acceptable in this specific case or that a person will not be aware of any date formats in which case your proposed solution (the implementation of ISO 8601) is inadequate.
-
there are 3 main formats used to represent dates; D-M-Y, M-D-Y, Y-M-D.
where are you getting this shit from? if you use the MDY ordering, then separate numbers with '/' characters, ie. 1/2/3. use of the MDY ordering in combination with '-' characters is a mockery of the international standard.
We must operate on one of two assumptions. That a person will be aware of the 3 major date formats in which case the use of M-D-YY is perfectly acceptable in this specific case or that a person will not be aware of any date formats in which case your proposed solution (the implementation of ISO 8601) is inadequate.
at least my solution is better in both cases.
-
Haha sorry Cron but I've been having the same probs as everyone else :P
...
DED_CC src/sys/sys_unix.c
src/sys/sys_unix.c:35:22: fatal error: sys/mman.h: No such file or directory
compilation terminated.
make[2]: *** [build/release-HPD-x86/ded/sys_unix.o] Error 1
make[2]: Leaving directory `/home/Nolan/tremulous'
make[1]: *** [targets] Error 2
make[1]: Leaving directory `/home/Nolan/tremulous'
make: *** [release] Error 2
$
You shouldn't be in that area at all if you're compiling for win32. Your PLATFORM variable needs to be mingw32, and then your Makefile won't try to do those unix-only things (like compiling sys_unix).
I added this to my Makefile.local (in addition to what's mentioned above in the instructions) and it got things compiling fine for me on Windows in Mingw:
PLATFORM=mingw32
-
I followed exactly all the instructions but the client won't compile successfully under my Win7 64bit.
src/libs/win32/libcurl.a(strequal.o):strequal.c:(.text+0x14): undefined reference to `strcasecmp'
src/libs/win32/libcurl.a(strequal.o):strequal.c:(.text+0x48): undefined reference to `strncasecmp'
collect2.exe: error: ld returned 1 exit status
make[2]: *** [build/release-mingw32-x86/tremulous.x86.exe] Error 1
The errors seem related to libcurl. I also tried with a fresh install of everything excluding the libcurl package, but the same errors come up.
in my Makefile.local I have:
PLATFORM=mingw32
CC=gcc
BUILD_GAME_QVM=0
INCLUDE=
LIBRARY=
Any suggestions?
-
src/libs/win32/libcurl.a(strequal.o):strequal.c:(.text+0x14): undefined reference to `strcasecmp'
src/libs/win32/libcurl.a(strequal.o):strequal.c:(.text+0x48): undefined reference to `strncasecmp'
collect2.exe: error: ld returned 1 exit status
make[2]: *** [build/release-mingw32-x86/tremulous.x86.exe] Error 1
Any suggestions?
weird.
- there's a possible cause (http://curl.haxx.se/mail/lib-2013-05/0129.html).
- you can add USE_CURL=0 to try to avoid those "curly" errors; however, you then won't get the HTTP-based (fast) download capability for some (most) servers.
- you can also try editing any client source file (ie., src/client/cl_curl.c) and adding the missing functions, strcasecmp() and strncasecmp() (copy-pasted from the net).
The errors seem related to libcurl. I also tried with a fresh install of everything excluding the libcurl package, but the same errors come up.
how do you "install"? by the workings of the build system on Windows, only the internal cURL stuff is used, ie., the relevant .a file, which you can also try to replace with a newer one.
-
you can add USE_CURL=0 to try to avoid those "curly" errors
if I add USE_CURL=0 , other errors come out:
LD build/release-mingw32-x86/tremulous.x86.exe
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0xe5): undefined reference to `curl_multi_remove_handle'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0xf3): undefined reference to `curl_easy_cleanup'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x100): undefined reference to `curl_multi_cleanup'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x127): undefined reference to `curl_easy_cleanup'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x159): undefined reference to `curl_multi_remove_handle'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x167): undefined reference to `curl_easy_cleanup'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x174): undefined reference to `curl_multi_cleanup'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x19b): undefined reference to `curl_easy_cleanup'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x209): undefined reference to `curl_multi_remove_handle'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x217): undefined reference to `curl_easy_cleanup'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x225): undefined reference to `curl_multi_cleanup'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x2f0): undefined reference to `curl_easy_init'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x330): undefined reference to `curl_easy_setopt'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x35f): undefined reference to `curl_easy_setopt'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x382): undefined reference to `curl_easy_setopt'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x3ba): undefined reference to `curl_easy_setopt'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x3bf): undefined reference to `curl_version'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x3f0): undefined reference to `curl_easy_setopt'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x40e): undefined reference to `curl_easy_setopt'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x42c): undefined reference to `curl_easy_setopt'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x44a): undefined reference to `curl_easy_setopt'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x468): undefined reference to `curl_easy_setopt'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x486): more undefined references to `curl_easy_setopt' follow
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x4e4): undefined reference to `curl_multi_init'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x503): undefined reference to `curl_multi_add_handle'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x560): undefined reference to `curl_easy_setopt'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x5aa): undefined reference to `curl_easy_cleanup'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x5e3): undefined reference to `curl_easy_cleanup'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x618): undefined reference to `curl_multi_perform'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x631): undefined reference to `curl_multi_perform'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x651): undefined reference to `curl_multi_perform'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x66b): undefined reference to `curl_multi_perform'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x686): undefined reference to `curl_multi_perform'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x69d): more undefined references to `curl_multi_perform' follow
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x724): undefined reference to `curl_multi_info_read'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x757): undefined reference to `curl_easy_getinfo'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x765): undefined reference to `curl_easy_strerror'
c:/mingw/bin/../lib/gcc/mingw32/4.8.1/../../../../mingw32/bin/ld.exe: build/release-mingw32-x86/client/cl_curl.o: bad reloc address 0x20 in section `.eh_frame'
c:/mingw/bin/../lib/gcc/mingw32/4.8.1/../../../../mingw32/bin/ld.exe: final link failed: Invalid operation
how do you "install"? by the workings of the build system on Windows, only the internal cURL stuff is used, ie., the relevant .a file, which you can also try to replace with a newer one.
already tried replacing src\libs\win32\libcurl.a and sadly I get other boring errors.
Since I don't have any coding skill and no time to learn and edit the code right now, I think I will simply try switching back to gcc v4.6.3 hoping it will solve this strange issue.
btw, thanks for your help :)
-
if I add USE_CURL=0 , other errors come out:
LD build/release-mingw32-x86/tremulous.x86.exe
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0xe5): undefined reference to `curl_multi_remove_handle'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0xf3): undefined reference to `curl_easy_cleanup'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x100): undefined reference to `curl_multi_cleanup'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x127): undefined reference to `curl_easy_cleanup'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x159): undefined reference to `curl_multi_remove_handle'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x167): undefined reference to `curl_easy_cleanup'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x174): undefined reference to `curl_multi_cleanup'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x19b): undefined reference to `curl_easy_cleanup'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x209): undefined reference to `curl_multi_remove_handle'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x217): undefined reference to `curl_easy_cleanup'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x225): undefined reference to `curl_multi_cleanup'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x2f0): undefined reference to `curl_easy_init'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x330): undefined reference to `curl_easy_setopt'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x35f): undefined reference to `curl_easy_setopt'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x382): undefined reference to `curl_easy_setopt'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x3ba): undefined reference to `curl_easy_setopt'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x3bf): undefined reference to `curl_version'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x3f0): undefined reference to `curl_easy_setopt'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x40e): undefined reference to `curl_easy_setopt'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x42c): undefined reference to `curl_easy_setopt'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x44a): undefined reference to `curl_easy_setopt'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x468): undefined reference to `curl_easy_setopt'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x486): more undefined references to `curl_easy_setopt' follow
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x4e4): undefined reference to `curl_multi_init'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x503): undefined reference to `curl_multi_add_handle'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x560): undefined reference to `curl_easy_setopt'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x5aa): undefined reference to `curl_easy_cleanup'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x5e3): undefined reference to `curl_easy_cleanup'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x618): undefined reference to `curl_multi_perform'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x631): undefined reference to `curl_multi_perform'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x651): undefined reference to `curl_multi_perform'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x66b): undefined reference to `curl_multi_perform'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x686): undefined reference to `curl_multi_perform'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x69d): more undefined references to `curl_multi_perform' follow
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x724): undefined reference to `curl_multi_info_read'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x757): undefined reference to `curl_easy_getinfo'
build/release-mingw32-x86/client/cl_curl.o:cl_curl.c:(.text+0x765): undefined reference to `curl_easy_strerror'
c:/mingw/bin/../lib/gcc/mingw32/4.8.1/../../../../mingw32/bin/ld.exe: build/release-mingw32-x86/client/cl_curl.o: bad reloc address 0x20 in section `.eh_frame'
c:/mingw/bin/../lib/gcc/mingw32/4.8.1/../../../../mingw32/bin/ld.exe: final link failed: Invalid operation
remove the whole build directory first, then build.
-
remove the whole build directory first, then build.
I always remove the build directory, but that didn't help. I finally solved the problem switching to gcc v4.6.3, everything compiled right!
So, there must be some linking bug in gcc 4.8.1 with curl.
If anyone encounter the same problem:
- Get MinGW Builds: http://sourceforge.net/projects/mingwbuilds/ (http://sourceforge.net/projects/mingwbuilds/)
- Install it with these options: version:4.6.3 Architecture:x32 Threads:win32 Exception:dwarf Build:2 and choose a separate folder, like c:\Mingw-4.6.3
- Copy the whole content of c:\Mingw-4.6.3\mingw to c:\MinGW and overwrite all files
- before compiling, do a "make clean"
- Done!
-
You can try tdm mingw builds. I had no problem with them in the past.
http://tdm-gcc.tdragon.net/