Preliminary Universal Binaries of SDL et al are available

Posts: 713
Joined: 2002.04
Post: #1
I'm just cross-posting this email received from the SDL mailing list this morning; I don't have an Intel Mac (or even any Mac running OS X more recent than 10.3) so I'm unable to run any worthwhile tests, but maybe there are SDL developers in the community with the hardware but who don't subscribe to the mailing list Wink

E. Wing on the SDL mailing list Wrote:Updated Xcode projects for Universal Binaries have been committed to
CVS and initial binary packages (.dmg) are available here:

Projects included are SDL, SDL_image, SDL_mixer, SDL_ttf, and smpeg.
(Static libraries updated for libpng, libjpeg, libfreetype, libogg,

The SDL and smpeg binaries were built against the CVS version pulled
maybe a month ago so they may be a little behind.

There are a huge list of changes made to the projects, many things not
directly related to Universal Binaries so testing is needed.

I do not have an Intel Mac to test on so I have no idea if this stuff
actually works. However, Christian Walther has been a big help in
testing 10.2.8 and 10.3.9 so I'm fairly confident we got the build
settings correct for at least PPC.

I have attempted to document the important things for producing these
Universal Binaries. Documentation is somewhat scattered through out
everything, but there is a big centralized piece of documentation in
the UniversalBinaryNotes.rtf in the SDL.dmg.

As far as Universal Binaries are concerned, the big things were:
- Build with gcc 3.3 on PPC, 4.0 on Intel.
- We couldn't get any of the MMX/SSE code to compile/link (SDL and smpeg).
- All 3rd party dependencies had to be rebuilt as Universal

There were also a bunch of non-Universal things that have been updated:
- I converted the SDL-satellites to create .dmg's instead of .pkg installers
- Updated all 3rd party static libraries with current versions. (I
think libpng was the most dramatic going from 1.0.? to 1.2.8 with API
breakage. I haven't found any problems so far in doing this.)
- Changed some compiler optimization settings
- Finally updated the exports list for SDL_mixer
- Tried to include a static smpeg in SDL_mixer (multiple build
variants in Xcode project now)
- Enabled Altivec in SDL (we forgot to add the flags to Xcode last time)
- More documentation

Since so many things have changed, there might be new problems
introduced. The big issue I've found so far is with SDL_mixer. As I
mentioned in other threads, Mikmod and SMPEG continue to cause
problems. SMPEG is currently compiled into the binary in the above
link, but produces runtime assertion errors for me.

Areas that need testing/focus/fixing:
- Test to make sure binaries actually work (especially on x86).
- Test to make sure Altivec is actually working on PowerPC.
- Test to make sure things work on older versions of OS X and things
can be built on those systems linking against our Universal
- Test to make sure the Xcode projects actually work on other systems
(make sure absolute paths were not accidentally set).
- Fix MMX/SSE optimizations so they can be compiled in for SDL and smpeg
- Fix Mikmod for SDL_mixer
- Fix smpeg/mp3 playback for SDL_mixer

Also, there is a longer term needed task of figuring out what to do
with all the "deprecated API" warnings we get now under Tiger. It is
likely that using deprecated APIs will cause us to fall off optimized
code paths in the future.

There's probably a bunch of other stuff I'm forgetting. There really
were hundreds of little things I mucked with so it's hard to remember
them all.

Again, please read over the UniversalBinaryNotes.rtf in the SDL.dmg.
This will hopefully explain a great many things that may seem strange

If you have any questions, feel free to ask.


Mark Bishop
Student and freelance OS X & iOS developer
Quote this message in a reply
Posts: 110
Joined: 2002.07
Post: #2
Someone managed to make an universal sdl app ?

Quote this message in a reply
Posts: 5,143
Joined: 2002.04
Post: #3
I've built an Intel SDL app with the frameworks linked here... I assume they have a PPC side Smile
Quote this message in a reply
Posts: 110
Joined: 2002.07
Post: #4
OneSadCookie Wrote:I've built an Intel SDL app with the frameworks linked here... I assume they have a PPC side Smile

Love im going to AIM you like crazy Love
Quote this message in a reply
Posts: 70
Joined: 2002.07
Post: #5
OneSadCookie Wrote:I've built an Intel SDL app with the frameworks linked here... I assume they have a PPC side Smile

I'm not really sure what the big deal is -- I assume it's 10.2.8 support. In dim3, it's 10.3.9 for PPC, 10.4 for Intel, so I just took the standard 1.2.9 SDL, added i386, added arch specific name/value pairs for the SDK and compile switches, and it works.

OF COURSE, I have really low needs for SDL (I just use it for resolution switching and Input), so I certainly don't care if any altivec or accelerated paths are working/not-working, so I could be mistaken.

Did the same for OpenAL, SpiderMonkey, and libPNG. No problems for any of them.

[>] Brian
Quote this message in a reply
Posts: 15
Joined: 2005.12
Post: #6
I was able to compile a univeral SDL.framework (before I found this thread). The SDLtest applications seem to work okay.

My big problem is that I need a Universal SDL_net.framework. Has anyone tried this yet? I took the old ProjectBuilder code (PBProjects.tar.gz supplied with the source), and upgraded the targets. However I get
Quote:Native Target Upgrade Log for Target 'Framework'

Target Framework cannot be upgraded because it contains the following files in its Sources build phase which are not supported by the native build system:

Upgrade process finished.
Trying to build fails with "Command /Developer/Private/jam failed with exit code 1" error.

Any takers? This is on a MacBook Pro.
Quote this message in a reply
Post: #7
What i did was compile it all and grab the lib???.? from the build folder and the hidden folder (build/.lib/). Stuck it in a folder along with the include headers. It seems to work exactly like a framework. I was able to build and run code using SDL just fine. I do however get flickering.
Quote this message in a reply
Post Reply