[Tux4kids-commits] r731 - tuxtype/branches/tuxtype-soc-mh
lummeh-guest at alioth.debian.org
lummeh-guest at alioth.debian.org
Sun Aug 31 07:42:53 UTC 2008
Author: lummeh-guest
Date: 2008-08-31 07:42:52 +0000 (Sun, 31 Aug 2008)
New Revision: 731
Added:
tuxtype/branches/tuxtype-soc-mh/README-CROSSBUILD.txt
Log:
missing config files
Added: tuxtype/branches/tuxtype-soc-mh/README-CROSSBUILD.txt
===================================================================
--- tuxtype/branches/tuxtype-soc-mh/README-CROSSBUILD.txt (rev 0)
+++ tuxtype/branches/tuxtype-soc-mh/README-CROSSBUILD.txt 2008-08-31 07:42:52 UTC (rev 731)
@@ -0,0 +1,93 @@
+Building TuxType for Windows on a Debian System:
+------------------------------------------------
+
+David Bruce <dbruce at tampabay.rr.com>
+
+TuxType can be cross-built for Windows on a Debian (or probably nearly
+any Linux or Unix) system. The process closely follows the work done
+by Yves Combe <yves at ycombe.net> for a cross-build of TuxMath. I adapted
+the TuxType svn source as follows to get this to work:
+
+
+- Copied cross-configure.sh and cross-make.sh from tuxmath unmodified.
+- Modified configure.in to check for mingw32 build.
+- Copied nsis/tuxtype.nsi.in from tuxmath's nsis/tuxmath.nsi.in with
+ very minor modifications (basically different program name).
+- Modified Makefile.am by adding code from tuxmath's Makefile.am to
+ support nsis installer as makefile target, with some modifications.
+- Minor changes to tuxtype's C source code:
+ - Added local function prototype for print_at() in practice.c.
+ - Several additional debugging output statements added.
+ - int_rand() as defined in playgame.c did not work correctly in
+ Windows, replaced using rand() % in several locations.
+ - WORD_qty counter didn't work right under Windows (could not
+ figure out why!), added simple code to count words in list
+ within WORDS_use() rather than rely on counter.
+
+Before the crossbuild can be done, you need to get the environment prepared.
+(Below taken from Tuxmath docs with very slight editing)
+
+ To set up a crossbuild environment:
+
+ 1. Install mingw32 (apt-get install mingw32) and makensis (apt-get install nsis)
+
+ NOTE: the versions of the mingw32 packages in Etch work fine, but the newer
+ ones currently in Sid (specifically mingw32-binutils 2.17.50) fail, at least
+ on my amd-64 host.
+
+ 2. Create directory structure:
+ - mkdir /usr/local/cross-tools
+ - mkdir /usr/local/cross-tools/i586-mingw32msvc
+ - mkdir /usr/local/cross-tools/i586-mingw32msvc/lib
+ - mkdir /usr/local/cross-tools/i586-mingw32msvc/include
+
+ 3. Install precompiled win32�dev files (lib and includes) for SDL, SDL-image
+ SDL-ttf, and SDL-mixer in the lib and include directories you just created.
+ You can get all of these from www.libsdl.org. I had some trouble with
+ this step as the SDL libs have varieties intended for both mingw32 and MSVC -
+ I was able to build successfully using the mingw32 ones. I also had to put
+ all the lib files directly under /usr/local/cross-tools/i586-mingw32msvc/lib
+ to get it to work. My /usr/local/cross-tools/i586-mingw32msvc/lib contains:
+
+ dbruce at debian:/usr/local/cross-tools/i586-mingw32msvc/lib$ ls
+ asprintf.lib jpeg.dll libSDL.la SDL_image.dll SDL_ttf.dll zlib1.dll
+ charset.lib libgw32c.a libSDLmain.a SDL_image.lib smpeg.dll
+ iconv.lib libpng12.dll libtiff.dll SDL_mixer.dll vorbis.dll
+ intl.lib libSDL.dll.a ogg.dll SDL_mixer.lib vorbisfile.dll
+
+ (asprintf.lib, charset.lib, iconv.lib, and intl.lib are definitely not needed.
+ Some of the others may not be needed, either, but I guarantee that everything
+ that *is* needed is on this list - DSB).
+
+ The header files can be in their own folders as long as they are under
+ /usr/local/cross-tools/i586-mingw32msvc/include
+
+ 4. Install libgw32c (the dev file):
+ http://gnuwin32.sourceforge.net/packages/libgw32c.htm in the same directory.
+ This gives you the file "libgw32c.a" that you need to have in the lib directory.
+
+ 5. You need to have a directory containing all of the dlls that will need to be
+ packaged into the installer. The Makefile expects them to be in NSI_DLL_DIR,
+ which is set to ~/tuxtype_dll. On my machine, I have:
+
+ dbruce at debian:~/tuxtype_dll$ ls
+ jpeg.dll ogg.dll SDL_mixer.dll vorbis.dll
+ libpng12.dll SDL.dll SDL_ttf.dll vorbisfile.dll
+ libtiff.dll SDL_image.dll smpeg.dll zlib1.dll
+
+
+ (Note - this has mostly the same files as the cross-tools lib directory - it is most
+ likely possible to eliminate this redundancy in some way.).
+
+ 6. If you have done a native (Linux) build in the same source tree, run "make clean"
+ and "make distclean" to get rid of the autogenerated files.
+
+ 7. From the trunk dir, run:
+ ./autoreconf --install
+ ./cross-configure.sh --with-sdl-prefix
+ ./cross-make.sh
+ ./cross-make.sh nsis
+
+ You should now have the installer (something like "tuxtype-1.5.11-win32-installer.exe")
+ in the trunk directory. Execute the installer on the target Windows machine to install
+ the program.
\ No newline at end of file
More information about the Tux4kids-commits
mailing list