[Tux4kids-commits] r138 - in tuxmath/trunk: . docs src

Tim Holy tholy-guest at alioth.debian.org
Thu Mar 15 13:10:00 CET 2007


Author: tholy-guest
Date: 2007-03-15 12:10:00 +0000 (Thu, 15 Mar 2007)
New Revision: 138

Removed:
   tuxmath/trunk/mac_cplibs.sh
Modified:
   tuxmath/trunk/Makefile.am
   tuxmath/trunk/docs/INSTALL.txt
   tuxmath/trunk/docs/changelog
   tuxmath/trunk/src/Makefile.am
Log:
Update documentation on MacOSX build, and remove infrastructure for old UNIX-style build. (That work was never completed in a portable way.)


Modified: tuxmath/trunk/Makefile.am
===================================================================
--- tuxmath/trunk/Makefile.am	2007-03-15 12:08:55 UTC (rev 137)
+++ tuxmath/trunk/Makefile.am	2007-03-15 12:10:00 UTC (rev 138)
@@ -43,5 +43,3 @@
 	fi
 #	-rm tuxmath- at VERSION@-win32-installer.exe
 
-macapp:
-	cd src && $(MAKE) $(AM_MAKEFLAGS) bundle && $(MAKE) $(AM_MAKEFLAGS) bundle-fw && $(MAKE) $(AM_MAKEFLAGS) bundle-libs && $(MAKE) $(AM_MAKEFLAGS) bundle-dmg

Modified: tuxmath/trunk/docs/INSTALL.txt
===================================================================
--- tuxmath/trunk/docs/INSTALL.txt	2007-03-15 12:08:55 UTC (rev 137)
+++ tuxmath/trunk/docs/INSTALL.txt	2007-03-15 12:10:00 UTC (rev 138)
@@ -228,22 +228,39 @@
       --------------------
       You have to have the development tools and development libraries for SDL.  Here's the approach that worked for me:
 	  1. Download and install XCode from the Apple web site.
-	  2. Download and install Fink (http://fink.sourceforge.net/).
-	  3. fink install sdl sdl-image sdl-mixer.
-	And if you haven't gotten the source code for tuxmath yet,
-	  4. fink install svn-client-ssl (the pre-built binary for the svn-client doesn't support SSL!)
-	  5. svn co https://svn.tux4kids.net/tuxmath/
+	  2. Check out the code from the subversion repository at alioth.
+	     You may have to download and install Fink
+             (http://fink.sourceforge.net/). You may then have to do
+	           fink install svn-client-ssl
+             if the pre-built binary for the svn-client doesn't
+             support SSL.
+	  3. Download & install the SDL (www.libsdl.org) Frameworks for
+             MacOSX. You'll need SDL, SDL_image, SDL_mixer, and SDL_ttf.
+	  4. Open the Xcode project (in tuxmath's macosx/ directory)
+             and hit "build." Cross your fingers. The most likely
+             issue you'll encounter is that, as tuxmath progresses,
+             new source code files get added to (or old ones deleted from)
+             the src/ directory.  So, you might have to add or remove
+             files from the project.
+	  5. To build a disk image, open a terminal and navigate to
+             the macosx/ directory. Type "make macapp". After a short
+             while, the TuxMath.dmg disk image will appear in the
+	     build/Release directory. You can surely also do this
+	     using GUI tools.
 
-	Then you can follow the instructions above for Linux/Unix.
+     The main issues in getting the Mac build to work come from the
+     fact that it is not using the automake system. So, certain macros
+     have to be defined by Xcode (under Project->Edit Project
+     Settings, then choose the Build tab, in the collection
+     Preprocessing).
+     Currently, the macro definitions are these:
+     MACOSX=1 DATA_PREFIX=\"TuxMath.app/Contents/Resources/data\"
+     VERSION=\"1.5\" $(inherited)
 
-      Building a disk image:
-      ---------------------
-      A disk image is a file that can be copied to another Mac, allowing the application to be run.  Assuming you have set up your build environment as above, you can build a disk image by running (from the "trunk" directory)
-	./autogen.sh
-	./configure
-	make macapp
-      The disk image will reside in a subdirectory macbuild, and has the name TuxMath.dmg.
+     In particular, VERSION could be updated with each release (you
+     also should edit InfoPlist.strings if you want the Finder's
+     notion of the version # to be updated).
 
-      Possible issues:
-      ---------------
-      The Mac build system has not yet been configured to make a "universal binary," i.e. one that runs on either PPC or Intel macs.
+     Currently, internationalization is disabled on MacOSX.
+     Anyone who knows how to get the Linux internationalization
+     framework working on MacOSX is invited to contribute.
\ No newline at end of file

Modified: tuxmath/trunk/docs/changelog
===================================================================
--- tuxmath/trunk/docs/changelog	2007-03-15 12:08:55 UTC (rev 137)
+++ tuxmath/trunk/docs/changelog	2007-03-15 12:10:00 UTC (rev 138)
@@ -1,4 +1,14 @@
 changelog for "tuxmath"
+2007.Mar.15 (svn.debian.org/tux4kids - revision ??? & ???)
+  Build:
+    * First revision adds Xcode building for MacOSX
+    * Second commit removes the earlier (incomplete) approach to a
+	UNIX-style build. (This was abandoned mainly for reasons of
+	building Universal Binaries---the SDL Frameworks supposedly
+	only work with Xcode)
+	
+        Tim Holy < holy at wustl period edu >
+	
 2007.Mar.08  (svn.debian.org/tux4kids - revision 125)
   Game:
     * High scores now saved to and read from file, not yet

Deleted: tuxmath/trunk/mac_cplibs.sh
===================================================================
--- tuxmath/trunk/mac_cplibs.sh	2007-03-15 12:08:55 UTC (rev 137)
+++ tuxmath/trunk/mac_cplibs.sh	2007-03-15 12:10:00 UTC (rev 138)
@@ -1,24 +0,0 @@
-#! /bin/sh
-
-# A function that takes as input a binary name and a lib target directory
-# cpswlibs <binaryname> <directory to copy dependencies to>
-function cpswlibs {
-# Get the list of dependencies in /sw, excluding self
-fls=$(otool -L $1 | grep "/sw" | cut -f 2 | cut -d "(" -f 1 | grep -v $1)
-echo $fls
-# Copy these dependencies into the target directory
-cp $fls $2
-}
-
-# Run cpswlibs on the input binary name
-BINNAME=$1
-LIBDIRNAME=$2
-cpswlibs $BINNAME $LIBDIRNAME
-# Now run cpswlibs on each of the libraries that we copied
-echo $LIBDIRNAME
-fls=$(ls $LIBDIRNAME)
-for i in $fls; do
-    echo $i
-    cpswlibs $LIBDIRNAME/$i $LIBDIRNAME
-done
-# For tuxmath we don't need any more recursions that this
\ No newline at end of file

Modified: tuxmath/trunk/src/Makefile.am
===================================================================
--- tuxmath/trunk/src/Makefile.am	2007-03-15 12:08:55 UTC (rev 137)
+++ tuxmath/trunk/src/Makefile.am	2007-03-15 12:10:00 UTC (rev 138)
@@ -36,47 +36,4 @@
 tuxmathrc.o: tuxmathrc.rc
 	$(WINDRES) -i $< -o $@
 
-
-#------------------ Packaging rules for Mac OSX ------------------------
-#---Many thanks to the developers (esp. Sidney Markowitz?) of Enigma,---
-#---whose Makefiles were the template for this one.---------------------
-
-bundle_name := $(top_builddir)/macbuild/TuxMath.app
-# Special target to copy all needed game files to TuxMath.app/Contents/Resources.
-# For Mac OS X bundle.
-.PHONY: bundle
-bundle:
-	-rm -rf $(bundle_name)/Contents
-	mkdir -p $(bundle_name)/Contents/MacOS
-	mkdir -p $(bundle_name)/Contents/Resources/data/
-	echo "APPL????" > $(bundle_name)/Contents/PkgInfo
-	cp $(top_builddir)/Info.plist $(bundle_name)/Contents/
-	cp $(top_builddir)/data/images/tuxmath.icns $(bundle_name)/Contents/Resources/
-	tar -cf - --exclude .svn -C $(top_builddir)/data . | tar xpf - -C $(bundle_name)/Contents/Resources/data
-	mkdir -p $(bundle_name)/Contents/lib
-	mkdir -p $(bundle_name)/Contents/bin
-	cp $(top_builddir)/tuxmath.sh $(bundle_name)/Contents/MacOS/tuxmath
-
-# Special target to copy the binary to Enigma.app/Contents/MacOS.
-.PHONY: bundle-fw
-bundle-fw: tuxmath-fw-mosx
-	cp tuxmath-fw $(bundle_name)/Contents/bin/tuxmath
-	strip $(bundle_name)/Contents/bin/tuxmath
-
-# Special target to copy the libraries from /sw/lib (from Fink)
-.PHONY: bundle-libs
-bundle-libs: tuxmath-fw-mosx
-	$(top_builddir)/mac_cplibs.sh tuxmath-fw $(bundle_name)/Contents/lib/
-
-# Special target to create a binary linked with Mac OS X frameworks
-static_prefix := `$(SDL_CONFIG) --prefix`
-.PHONY: tuxmath-fw-mosx
-tuxmath-fw-mosx: $(tuxmath_OBJECTS) $(tuxmath_DEPENDENCIES)
-	$(CXX) $(LDFLAGS) -o tuxmath-fw $(tuxmath_OBJECTS) $(tuxmath_DEPENDENCIES) -L$(static_prefix)/lib -lSDLmain -lSDL -lSDL_image -lSDL_mixer -framework Cocoa -framework OpenGL
-
-# Special target to make a disk image of the bundled app
-.PHONY: bundle-dmg
-bundle-dmg:
-	hdiutil create  -ov -srcfolder $(bundle_name) -volname TuxMath -imagekey zlib-level=6 $(top_builddir)/macbuild/TuxMath.dmg
-
 noinst_HEADERS = highscore.h




More information about the Tux4kids-commits mailing list