Skip to content Skip to sidebar Skip to footer

Building Universal Binaries On Mac - Forcing Single Compiler Child Process

Cheers, at company, we're creating a port of our games, and we need to compile PythonOgre, a wrapper of Ogre3d for Python. This is an enormous chunk of code, particularly the gener

Solution 1:

I've checked the source of Apple's GCC driver (the one that supports those -arch options and runs the children processes), and there's no option or environment variable that you can choose.

The only options I see left to you are:

  • download the Apple driver (e.g. from there; end of the page) and modify the file driverdriver.c so that processes are launched sequentially (rather than in parallel)
  • do separate i386 and powerpc builds, and join the final build objects (executables, shared libraries, etc.) using lipo

I hope this helps!

Solution 2:

Will just turning off one core do? Apparently, installing the Apple Developer Tools (XCode et al.) gives you a Processor system preference pane, allowing you to turn off one core. I was trying to test this, but the XCode install failed for some reason...

EDIT: I know this was a while ago, but I just thought of something. Why not build with -march=i386 and -march=ppc separately and then combine the binaries using lipo?

Post a Comment for "Building Universal Binaries On Mac - Forcing Single Compiler Child Process"