Installing pygame on Mac OSX 10.6 Snow Leopard
What you need
Inside you will find folders called SDL*.framework copy them to /Library/Frameworks/
There is hope
Before you go throw all the hassle try open Terminal and run sudo easy_install pygame.
If you get errors (likely) this means it isn’t fixed jet so lets do it.
Let’s get it done
- Download http://www.libsdl.org/tmp/SDL-1.2.tar.gz
- Double-click Xcode.tar.gz, it un-tars as Xcode
- Navigate to Xcode/SDL, double-click SDL.xcodeproj
- Project menu->Edit Project Settings
- Choose “Build” tab, then make sure Deployment_for_official.. is selected in the “configuration” dropdown
- Scroll all the way to the bottom, change SDKROOT_i386 and SDKROOT_ppc to /Developer/SDKs/MacOSX10.6.sdk and close the project settings
- Make sure that “Use Base SDK”, Deployment_for_official_releases…, “Framework”, “Standard DMG” and “x86_64″ are selected in the Overview menu.
- Click Build (you will get warning, but it should compile with no errors)
- Copy the “SDL.framework” folder from “Xcode/build/” to “/Library/Frameworks”
Thanks to Scott Lyons.
We need SDL_image compiled for 64 Bit too. So:
- Download http://www.libsdl.org/projects/SDL_image/release/SDL_image-1.2.10.zip
- Double-click Xcode.tar.gz, it un-tars as Xcode
- Navigate to Xcode, double-click SDL_Image*.xcodeproj
- Project menu->Edit Project Settings
- Choose “Build” tab, then make sure Deployment_.. is selected in the “configuration” dropdown
- Scroll all the way to the bottom, change SDKROOT_i386 and SDKROOT_ppc to /Developer/SDKs/MacOSX10.6.sdk and close the project settings
- Make sure that “Mac OS X 10.6″, Deployment_…, “Framework”, “Create DMG” and “x86_64″ are selected in the Overview menu.
- Click Build (it should compile with no errors)
- Copy the “SDL.framework” folder from “Xcode/build/” to “/Library/Frameworks”
Now open Terminal and enter this:
export CC='/usr/bin/gcc-4.0' CFLAGS='-isysroot /Developer/SDKs/MacOSX10.6.sdk -arch x86_64'
export LDFLAGS='-arch x86_64'
export ARCHFLAGS='-arch x86_64'
sudo easy_install pygame



