[Pythonmac-SIG] building universal binaries
Kevin Ollivier
kevino at theolliviers.com
Wed Jan 25 22:23:15 CET 2006
Hi,
On Jan 25, 2006, at 11:02 AM, bear wrote:
>
>
> Kevin Ollivier wrote:
>> Take out the -syslibroot part (which is only needed for libtool,
>> IIUC)
>> and make sure the "-arch ppc -arch i386" bit is in LDFLAGS as well.
>> That's how I got wxWidgets building Universal binaries. :-)
>>
> I had *just* read your wx-dev post and was going to ask about the
> particulars.
>
> When I try this:
>
> CFLAGS=' -isysroot /Developer/SDKs/MacOSX10.4u.sdk -arch ppc -arch
> i386'
> LDFLAGS=' -isysroot /Developer/SDKs/MacOSX10.4u.sdk -arch ppc -arch
> i386'
>
> I get this:
> checking for C compiler default output filename... configure:
> error:
> C compiler cannot create executables
How exactly are you doing this? Are you passing these flags into
configure, or editing the configure script? I'm seeing that it does
matter where in the configure script the options are added. From my
tests so far, the test 'failures' in the configure script are
incorrect - it seems these options just trip up the tests somehow. (I
think, for example, the multi-architecture flags don't work with
flags for a "dry run" compile from what I've read) I've found that
for wx, adding the options after these tests worked correctly.
> and if remove the -sysroot part from LDFLAGS, configure runs but
> then I
> get quite a few errors during the final parts of make:
> /usr/bin/ld: warning Parser/acceler.o cputype (7, architecture
> i386)
> does not match cputype (18) for specified -arch flag: ppc (file not
> loaded)
I've found that without the -isysroot, it creates/links "single
architecture" objects even when multiple -arch flags are
specified. ;-/ So you'll need to be able to specify those flags but
after the basic tests are run. At least, that's how I was able to
succeed with wx.
Hope this helps!
Kevin
> I appreciate any schooling you can offer me :)
>
> - bear
>
> _______________________________________________
> Pythonmac-SIG maillist - Pythonmac-SIG at python.org
> http://mail.python.org/mailman/listinfo/pythonmac-sig
More information about the Pythonmac-SIG
mailing list