From 5a96bdc36169a7c08335fae5190b67dd0a1fac72 Mon Sep 17 00:00:00 2001 From: manuel Date: Thu, 5 May 2011 20:35:17 +0200 Subject: compile instrucations --- pacman-c++/COMPILE | 38 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 38 insertions(+) create mode 100644 pacman-c++/COMPILE (limited to 'pacman-c++/COMPILE') diff --git a/pacman-c++/COMPILE b/pacman-c++/COMPILE new file mode 100644 index 0000000..8e588d3 --- /dev/null +++ b/pacman-c++/COMPILE @@ -0,0 +1,38 @@ +=== compile - unix / linux === + +compile enet: +$ wget http://enet.bespin.org/download/enet-1.3.1.tar.gz +$ tar xfz enet-1.3.1.tar.gz +$ mv enet-1.3.1 enet +$ cd enet +$ ./configure --disable-shared +$ make -j2 + +compile pacman using qmake (or rebuild.sh) +$ ./rebuild.sh + + +=== compile - windows === + +compile enet: +- download and extract http://enet.bespin.org/download/enet-1.3.1.tar.gz to pacman directory +- rename enet-1.3.1 to enet +- open cmd and cd to that directory +- use (mingw-)gcc (the same qt sdk is using) and compile enet + you can either use mingw + configure or compile enet on your own using commandline method below + +compile enet - commandline method: +- you will need to expand %PATH% before mingw tools are usable (set PATH=/path/to/mingw;%PATH%) +- execute do this for every *.c-file replacing $file with the filename: +$ gcc -DWIN32 -I. -Iinclude -g -O2 -c -o $file.o $file.c +e.g: gcc -DWIN32 -I. -Iinclude -g -O2 -c -o host.o host.c +- execute the following command to create a dll: +$ gcc -shared -o .libs/libenet.dll *.o -lws2_32 -lwinmm + +- OPTIONAL: _instead_ of creating dll you can also create an archive and link against that + please note that you also _need to enable_ to link against ws2_32 and winmm in + the file common.pri (the part is currently commented) +$ ar cru .libs/libenet.a *.o +$ ranlib .libs/libenet.a + +compile pacman using qmake or qt creator -- cgit v1.2.3