[SDL] Re: SDL on Mac OS X

Steven Saunders s_j_nevets at yahoo.com.au
Thu Jan 27 16:54:13 PST 2005


> I downloaded and installed the SDL and SDL development
> packages for Mac OS X that integrate with Xcode. Cool so
> far, but then I went to install some of the libraries such
> as SDL_image, SDL_mixer, SDL_ttf, etc. There were no
> pre-bult packages, so I thought I would just build them.
> However, there does not appear to be an sdl-config
> script, so the packages fail.

I'm not sure about SDL_image, and SDL_ttf, but there is a file in the
SDL_mixer source tar.gz called "PBProjects.tar.gz". If you unpack
this you should be able to use the contents to build the SDL_mixer
framework from the source using XCode. 

I have created a custom sdl-config script that I keep in ~/bin to use
when I build things that need it. It's output looks like this:

$ sdl-config --cflags
-F/Users/yourname/Library/Frameworks
-I/Users/yourname/Library/Frameworks/SDL.framework/Headers
-D_REENTRANT

$ sdl-config --libs  
/Users/yourname/bin/SDLMain.o -L/Users/yourname/Library/Frameworks
-framework Cocoa -framework SDL -lobjc

Email me if you want and I'll send it to you. (As you can see, I keep
a pre-built SDLMain.o lying around for such occasions.)

Speaking of SDLMain, you may want to grab a much better version of
SDLMain.m from the CVS repository:

http://www.libsdl.org/cgi/cvsweb.cgi/SDL12/src/main/macosx/

(I'm using revision 1.11.2.1). The version included in the SDL 1.2.8
package has problems with receiving keyboard events when you run SDL
apps that are not in an application bundle (i.e. command-line
launched ones.) The new version also creates a nice application menu
for you when you're not using a NIB.

__
Steve


Find local movie times and trailers on Yahoo! Movies.
http://au.movies.yahoo.com




More information about the SDL mailing list