[PATCH] build both 32-bit and 64-bit native extensions on Mac OS X
Kevin Bullock
kbullock+mercurial at ringworld.org
Tue Dec 20 20:34:00 UTC 2011
On Dec 20, 2011, at 11:21 AM, Brendan Cully wrote:
> On Tuesday, 20 December 2011 at 17:06, Steven Streeting wrote:
>> I encountered this issue on 10.7 with Xcode 4.2 but while wanting to build Mercurial to be compatible with 32-bit architectures as well. So that's 10.6 or before since 10.7 requires x64. I set VERSIONER_PYTHON_VERSION=2.6 for this backwards compatibility (such a build then works on 10.6 or 10.7) but noticed that the extensions only had x64 compatibility.
>>
>> So this change definitely works on 10.7, although I always use the standard Mac OS X version of Python, I'm not sure how you'd detect fink's version.
>
> In this case I think the better patch is to allow ARCHFLAGS to be set
> from the environment or build command line. You could attempt to
> discover which archs are available in the python being used, but it
> seems like more work for marginal benefit.
Turns out to be not so hard:
$ lipo /path/to/python -verify_arch i386
$ lipo /path/to/python -verify_arch x86_64
pacem in terris / мир / शान्ति / سَلاَم / 平和
Kevin R. Bullock
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mercurial-scm.org/pipermail/mercurial-devel/attachments/20111220/2fe2f141/attachment-0002.html>
More information about the Mercurial-devel
mailing list