Message157504
| Author |
Matthew.Scott |
| Recipients |
Matthew.Scott, eric.araujo, tarek |
| Date |
2012年04月04日.20:49:27 |
| SpamBayes Score |
-1.0 |
| Marked as misclassified |
Yes |
| Message-id |
<1333572568.76.0.187073077098.issue14498@psf.upfronthosting.co.za> |
| In-reply-to |
| Content |
Using Python 3.2.2 and Python 3.3.0a2 (installed via 64-bit installers in official DMGs on python.org), 'distutils.util.get_platform()' returns an incorrect OS version when running on Mac OSX 10.7.
Using Python 2.6.7, and Python 2.7.1 (the versions included with Mac OSX), the output indicates 'macosx-10.7' correctly.
> for version in 2.6 2.7 3.2 3.3; do python${version} -c "from __future__ import print_function;import distutils.util,sys;print(sys.version.split()[0],distutils.util.get_platform())"; done 2.6.7 macosx-10.7-intel
2.7.1 macosx-10.7-intel
3.2.2 macosx-10.6-intel
3.3.0a2 macosx-10.6-intel
Some packages make use of this in their setup.py to determine the proper location of libraries.
For example, the 'readline' distribution's setup.py does so here: https://github.com/ludwigschwardt/python-readline/blob/6f0e801fa1632fcbb0e005eb9709aaa6051a0f28/setup.py#L33
It fails due to the incorrect assumption that it's running on 10.6 instead of 10.7. Excerpt from "python setup.py bdist_egg":
building 'readline' extension
Compiling with an SDK that doesn't seem to exist: /Developer/SDKs/MacOSX10.6.sdk
Please check your Xcode installation
gcc-4.2 -fno-strict-aliasing -fno-common -dynamic -DNDEBUG -g -O3 -isysroot /Developer/SDKs/MacOSX10.6.sdk -DHAVE_RL_CALLBACK -DHAVE_RL_CATCH_SIGNAL -DHAVE_RL_COMPLETION_APPEND_CHARACTER -DHAVE_RL_COMPLETION_DISPLAY_MATCHES_HOOK -DHAVE_RL_COMPLETION_MATCHES -DHAVE_RL_COMPLETION_SUPPRESS_APPEND -DHAVE_RL_PRE_INPUT_HOOK -I. -I/Library/Frameworks/Python.framework/Versions/3.2/include/python3.2m -c Modules/3.x/readline.c -o build/temp.macosx-10.6-intel-3.2/Modules/3.x/readline.o -Wno-strict-prototypes -isysroot /Developer/SDKs/MacOSX10.6.sdk -arch i386 -arch x86_64
In file included from Modules/3.x/readline.c:8:
/Library/Frameworks/Python.framework/Versions/3.2/include/python3.2m/Python.h:11:20: error: limits.h: No such file or directory |
|
History
|
|---|
| Date |
User |
Action |
Args |
| 2012年04月04日 20:49:28 | Matthew.Scott | set | recipients:
+ Matthew.Scott, tarek, eric.araujo |
| 2012年04月04日 20:49:28 | Matthew.Scott | set | messageid: <1333572568.76.0.187073077098.issue14498@psf.upfronthosting.co.za> |
| 2012年04月04日 20:49:28 | Matthew.Scott | link | issue14498 messages |
| 2012年04月04日 20:49:27 | Matthew.Scott | create |
|