Giovanni Bajo píše v So 07. 01. 2012 v 16:02 +0100: > Hello, > > we currently suggest users to run python with "arch -i386" to use the > 32-bit version: > > Alas, this does not work with the standard Python framework that comes > with OSX:
Well, this is the only case when 'arch -i386' does not work. If you run a specific python version the VERSIONER_PYTHON_PREFER_32_BIT=yes is ignored: mac-mini:~ martin$ VERSIONER_PYTHON_PREFER_32_BIT=yes python2.7 Python 2.7.1 (r271:86832, Jun 16 2011, 16:59:05) [GCC 4.2.1 (Based on Apple Inc. build 5658) (LLVM build 2335.15.00)] on darwin Type "help", "copyright", "credits" or "license" for more information. >>> import sys >>> hex(sys.maxint) '0x7fffffffffffffff' >>> > I suggest we switch back to suggest using this environment variable to > run the 32-bit version of Python under Mac; at the same time, we can > remove the cruft code from compat that tries to run the Python binary > using "arch", as it does not work as intended anyway. The environment > variable will be automatically inherited from the main process to > subprocesses and thus all subprocesses will be 32-bti as well. I disagree with that. It won't work in other cases. The environment variable VERSIONER_PYTHON_PREFER_32_BIT is used only by /usr/bin/python. see: http://developer.apple.com/library/mac/#documentation/Darwin/Reference/ManPages/man1/python.1.html quote: ------ Rather than using the python command, one can use a specific version directly. For example, running python2.5 from the command line will run the 2.5 version of Python, independent of what the default version of Python is. One can use a specific version of Python on the #! line of a script, but that may have portability and future compatibility issues. Note that the preference files and environment variable that apply to the python command, do not apply when running a specific version of Python. In particular, running python2.6 will always default to 64-bit execution (unless one uses the arch(1) command to specifically select a 32-bit architecture). ------ The cruft code has to stay there. We could try one thing. We could suggest users to try both - arch -i386 and VERSIONER_PYTHON_PREFER_32_BIT. One will work in every case. -- You received this message because you are subscribed to the Google Groups "PyInstaller" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/pyinstaller?hl=en.
