3 Xcode project including script for building directly a ready to use dmg file
5 -------------------------------------------------------------------------------
6 - Makefile.osx added (use Makefile -f Makefile.osx)
8 - osx directory added contains :
9 + SDLMain.h and SDLMain.m
11 + mkdmg (little script for creating dmg file)
14 share/gui.c: In function `gui_init':
15 share/gui.c:235: warning: passing arg 2 of `glGetIntegerv' from incompatible pointer type
16 share/gui.c (line 231) int m; -> GLint m;
18 - Fix in ball/main.c (line 100) and putt/main.c (line 106)
19 mouse motion events problem
20 suppression of APPLE case : "#ifdef __APPLE__"
23 - not real colors in screenshots because BMP file is little endian format
24 change image_snap in share/image.c (take screenshot in 32bits and special stuff for big endian)
26 #include <SDL_endian.h>
28 void image_snap(char *filename)
31 SDL_Surface *buf = SDL_CreateRGBSurface(SDL_SWSURFACE, w, h, 32,
32 RMASK,GMASK,255,BMASK );
34 SDL_Surface *img = SDL_CreateRGBSurface(SDL_SWSURFACE, w, h, 32,
35 #if SDL_BYTEORDER == SDL_LIL_ENDIAN
42 glReadPixels(0, 0, w, h, GL_RGBA, GL_UNSIGNED_BYTE, buf->pixels);
44 for (i = 0; i < h; i++)
45 memcpy((GLubyte *) img->pixels + 4 * w * i,
46 (GLubyte *) buf->pixels + 4 * w * (h - i), 4 * w);
50 - Multilang support with gettext
51 gettext is a linux tool that uses the LANG environement variable
52 and LANG as no value is osX
56 will launch neverball in french
58 But when you launch neverball in finder (by double clic) it will use english because LANG var has no value
59 To fix LANG in osX add it in .MacOSX/environment.plist by adding
61 <?xml version="1.0" encoding="UTF-8"?>
62 <!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
65 <key>LANG</key><string>Fr</string>
69 and relaunch user session
70 launching neverball in finder will use French
72 but when launch terminal it will complain about an error (probably because of Fink) when setting locale.
73 To avoid this error, add in ~/.bashrc
77 test -r /sw/bin/init.sh && . /sw/bin/init.sh # fink line
81 I notice that Battle for Wesnoth has the same problem. The first launch (in finder) is in english and you can select french language in game preferences that are written in ~/Library/Preferences/Wesnoth/preferences. The next launch will read : locale="fr_FR" in preferences file and launch the game in french.