classification
Title: Add "intel" universal architecture on OSX
Type: enhancement Stage: resolved
Components: Build, Macintosh Versions: Python 3.1, Python 2.7, Python 2.6
process
Status: closed Resolution: fixed
Dependencies: Superseder:
Assigned To: ronaldoussoren Nosy List: jszakmeister, loewis, plux, ronaldoussoren, tarek, zzzeek
Priority: normal Keywords:

Created on 2009-06-08 21:35 by ronaldoussoren, last changed 2009-09-15 19:20 by ronaldoussoren. This issue is now closed.

Files
File name Uploaded Description Edit
arch-intel.patch ronaldoussoren, 2009-06-08 21:35
arch-intel-v2.patch ronaldoussoren, 2009-09-06 12:05
Messages (9)
msg89118 - (view) Author: Ronald Oussoren (ronaldoussoren) * (Python committer) Date: 2009-06-08 21:35
Apple just announced that MacOSX 10.6 ("Snow Leopard") will be released 
in September, and will only support intel systems.

This means that the --with-universal-archs option is not 100% usable if 
you want to build a version of Python that specifically targets this 
release of the OS.

The attached patch adds the option '--with-universal-archs=intel', which 
will build a 32-bit/64-bit framework for intel systemsn (that is i386 
and x86_64). 

Note: the patch is for the trunk, I'll port it to 3.x after review.
msg89119 - (view) Author: Martin v. Löwis (loewis) * (Python committer) Date: 2009-06-08 21:51
What do you mean by "not 100% usable"? I would hope that a four-way
binary still works just fine, no? So what are the restrictions?
msg89129 - (view) Author: Ronald Oussoren (ronaldoussoren) * (Python committer) Date: 2009-06-09 00:17
The details of snow leopard are under NDA, but based on public 
information :

* Snow Leopard will only support Intel-based systems

* Apple's "rosetta" dynamaic translation subsystem for running PPC code 
on an intel system only supports 32-bit PPC code.

There is therefore no reason to include 64-bit PPC code in builds for 
Snow Leopard, and I wouldn't be surprised if SL would ship without 64-
bit PPC code in system frameworks.
msg89132 - (view) Author: Martin v. Löwis (loewis) * (Python committer) Date: 2009-06-09 04:32
> The details of snow leopard are under NDA, but based on public 
> information :

This is all fine, and really not surprising. My question is:
Why is that causing limited usability? I would expect that
Snow Leopard just ignores the PPC bits in the universal binaries,
and just accesses the x86 bits. The binaries might be larger
than necessary; people bothered by that could easily strip them
using ditto (IIUC).

I'm fine with an option of not building the PPC bits - I'm
just puzzled by the claim that, without the patch, it will
not be "100% usable".
msg89141 - (view) Author: John Szakmeister (jszakmeister) * Date: 2009-06-09 09:32
I think Ronald is trying to say that a 10.6 SDK is likely not to support
building 64-bit binaries at all for the PPC (since there won't be 64-bit
versions of the supporting libraries).  So you need this patch, if
you're going to build against it.  I don't think he's trying to claim
that fat binaries won't run if there is 64-bit PPC code in them.  FWIW,
it's the --with-universal-archs option that he said wasn't 100% usable,
not the binaries.
msg89164 - (view) Author: Martin v. Löwis (loewis) * (Python committer) Date: 2009-06-09 20:36
> FWIW,
> it's the --with-universal-archs option that he said wasn't 100% usable,
> not the binaries.

Ah, ok. That clarifies it.
msg92066 - (view) Author: Mattias Stahre (plux) Date: 2009-08-29 20:20
Is there any progress on this?
msg92302 - (view) Author: Ronald Oussoren (ronaldoussoren) * (Python committer) Date: 2009-09-06 12:05
I've attached a new patch "arch-intel-v2.patch" that relects my current 
thinking about this patch.

This adds two new options to the "--with-univeral-archs" option for 
configure: "intel" and "3-way". The former builds a universal binary 
with the i386 and x86_64 architectures, the latter builds one with the 
i386, x86_64 and ppc architectures.

The "intel" build is most useful when your code only needs to run on 
modernish systems, the latter allows you to run scripts on PPC systems 
as well.

Both can be build on Snow Leopard systems. The current options "all" and 
"64-bit" cannot be used when you perform your build and target the 
default SDK because the system doesn't ship with PPC64 suppport anymore.

I intend to apply this patch for 2.7 and 3.2 unless there is serious 
opposition against this. The patch will not be backported to earlier 
versions.
msg92649 - (view) Author: Ronald Oussoren (ronaldoussoren) * (Python committer) Date: 2009-09-15 19:17
Committed in 74806 (trunk), 74807 (2.6), 74808 (3.x), 74809 (3.1)
History
Date User Action Args
2009-09-15 19:20:29ronaldoussorensetstatus: open -> closed
2009-09-15 19:17:40ronaldoussorensetresolution: fixed
messages: + msg92649

keywords: - patch, needs review
type: enhancement
stage: resolved
2009-09-06 12:05:51ronaldoussorensetfiles: + arch-intel-v2.patch

messages: + msg92302
2009-08-29 20:32:05zzzeeksetnosy: + zzzeek
2009-08-29 20:20:31pluxsetnosy: + plux

messages: + msg92066
versions: + Python 2.6
2009-06-11 10:20:17tareksetnosy: + tarek
2009-06-09 20:36:25loewissetmessages: + msg89164
2009-06-09 09:32:39jszakmeistersetnosy: + jszakmeister
messages: + msg89141
2009-06-09 04:32:21loewissetmessages: + msg89132
2009-06-09 00:17:28ronaldoussorensetmessages: + msg89129
2009-06-08 21:51:33loewissetnosy: + loewis
messages: + msg89119
2009-06-08 21:35:38ronaldoussorencreate