Issue #27 resolved

i386 and x86_64

Kentzo avatarKentzo created an issue

By default python install.py only compiles modules for current architecture. It should be possible to compile pyobjc for both i386 and x86_64

Comments (3)

  1. Ronald Oussoren

    That's odd, the build should already be i386 and x86_64. On my machine:

    Lib/objc/_objc.so: Mach-O universal binary with 2 architectures
    Lib/objc/_objc.so (for architecture i386):  Mach-O bundle i386
    Lib/objc/_objc.so (for architecture x86_64):    Mach-O 64-bit bundle x86_64
    

    The architectures uses are those supported by the distutils configuration, on my machine:

    $ python -c 'from distutils.sysconfig import get_config_var; print get_config_var("CFLAGS")'
    -fno-strict-aliasing -fno-common -dynamic -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.8.sdk -arch i386 -arch x86_64 -g -O2 -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes
    

    Which copy of python do you use (version, own build, python.org build, /usr/bin/python)? And on what version of OSX (especially when using /usr/bin/python)?

    One other thing to check: does "python setup.py install" in the pyobjc-core subproject install a single architecture or multiple?

  2. Kentzo
    $python -c 'from distutils.sysconfig import get_config_var; print get_config_var("CFLAGS")'
    
    -fno-strict-aliasing -fno-common -dynamic -I/usr/local/include -DNDEBUG -g  -O3 -Wall -Wstrict-prototypes
    

    I was able to produce fat binaries by modifying env variable:

    export CFLAGS='-arch i386 -arch x86_64'
    

    Do you mean no additional steps needed?

  3. Log in to comment
Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for ProjectModifiedEvent.java.
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.