[PyQt] PyQt4 installed into different dir than sip and not importable on MacOSX
Andreas Pakulat
apaku at gmx.de
Sat Mar 21 08:29:28 GMT 2015
Hi Phil,
On Fri, Mar 20, 2015 at 10:39 PM, Phil Thompson <phil at riverbankcomputing.com
> wrote:
> On 20/03/2015 8:44 pm, Andreas Pakulat wrote:
>
>> Hi,
>>
>> just installed the latest PyQt4 release (4.11.3) on MacOSX and could not
>> impot PyQt4 afterwards in python. Turns out it decided to place itself
>> into
>> /System/Library/Frameworks/Python.framework/Versions/2.7/
>> lib/python2.7/site-packages,
>> however that directory is not in sys.path after starting Python.
>>
>> sip on the other hand (installed just before, version is 4.16.6) put
>> itself
>> into /Library/Python/2.7/site-packages and that is part of sys.path.
>>
>> I guess this isn't intended? Where does PyQt gather the default
>> installation directory from?
>>
>> Andreas
>>
>> PS: Passing -d /Library/Python/2.7/site-packages worked fine of course.
>>
>
> The /System/... location is for python that ships with OS X. The
> /Library/... location is for the python from python.org.
>
> Are you sure you used the same python throughout?
>
Yes very sure since I did not have a python from python.org when I tried
first time. Explicitly starting python through
/System/Library/FrameWorks/Python.framework/Versions/2.7/bin/python and
fetching sys.path still shows no site-packages under the /System/
hierarchy, but the one from /Library.
I've meanwhile installed pip using the System python and that was placed in
/Library as well.
However I do notice now that my /usr/bin/python is slightly larger than the
python2.7 binary. No idea wether thats normal or not (a hunch tells me this
is because that one reads out some OSX config to determine which Python I
want as default), but at least the dates of the two are matching (Sep 10th
2014)
All this is on a fresh OSX 10.10.
Andreas
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.riverbankcomputing.com/pipermail/pyqt/attachments/20150321/bc9390cc/attachment.html>
More information about the PyQt
mailing list