[PyQt] Can't use static PyQ5 build during development on Mac OS X

Marius Shekow marius.shekow at fit.fraunhofer.de
Wed Nov 11 10:14:34 GMT 2015


Hi,

I'm not so sure whether the issue is just PyCharm. I can't seem to import PyQt5 packages in the python3 interpreter (run from the Terminal) either. When I make and install the dynamically-linked version of SIP and PyQt5, everything works (including skeleton-generation in PyCharm).

I'm wondering: which files/dirs *should* be present in my site-packages/PyQt5 directory for allowing PyQt5-based programs to work? As I said before, I just have an __init__.py (without any actual Python code), a bunch of .a files and a uic directory, nothing else.

At some point I'll also test a "completely static" set up (except for Qt itself), i.e. also compiling Python as static build first.

Best regards,
Marius Shekow
 
 
Am Mittwoch, 11. November 2015 02:54 CET, Zachary Scheuren <angryjaga at gmail.com> schrieb: 
 
> I don't think static has anything to do with it. This is an issue with
> inconsistent PyCharm skeleton generation.
> See https://youtrack.jetbrains.com/issue/PY-14103 and
> https://youtrack.jetbrains.com/issue/PY-14235
> I use PyQt4 and PyQt5 on Mac/Linux/Windows with PyCharm and with some
> configurations I get this same annoying issue, but not always.
> As stated in the link above you should be able to copy the generated

> skeletons from another setup to get code completion working for now.

> 
> 
> On Wed, Nov 11, 2015 at 1:07 AM, Marius Shekow <
> marius.shekow at fit.fraunhofer.de> wrote:
> 
> > Hi,
> >
> > my goal is to distribute a redistributable application on Mac OS X, not
> > making any assumptions about what Python, Qt, PyQt, ... the user has
> > installed. I.e. my goal is to produce a self-contained build.
> >
> > For this I want to use the existing/unmodified (dynamically linked) Python
> > 3.4 and Qt 5.5.1 distributions (because building them myself is hard), and
> > statically compile the other dependencies, such as SIP, PyQt, sqlite3, etc.
> >
> > I'm using Mac OS X El Capitan. I've downloaded Python 3.4.3 from the
> > official website and installed it. I've downloaded SIP from the RiverSide
> > homepage and compiled it statically (with python3 configure.py --static +
> > make + sudo make install). I.e. I'm using the python3 binary (for
> > configuration) that is installed from the official Python 3.4.3 installer.
> >
> > I've downloaded and installed Qt 5.5.1 from the official Qt homepage (the
> > 32/64-bit Intel distribution). This installs it to ~/Qt5.5.1
> >
> > I've then downloaded the PyQt5 sources and also built them statically
> > (python3 configure.py --static --qmake ~/Qt5.5.1/5.5/clang_64/bin/qmake)
> > I've also done "sudo make install".
> >
> > The issue is that I can't really develop Python code this way. My IDE
> > (PyCharm) claims that there is nothing in the PyQt5 package in
> > site-packages. The directory is there, in
> > /LIbrary/Frameworks/Python.framework/Versions/3.4/lib/python3.4/site-packages/PyQt5.
> > It contains an __init__.py, a bunch of .a library files and the uic
> > directory with lots of other stuff". But references such as PyQt5.WtWidgets
> > can't be resolved.
> >
> > I'd really like to be able to code in Python on MacOS X with that static
> > version. Is that possible?
> >
> > Best regards,
> > Marius Shekow
> > --
> > Marius Shekow
> > Mixed and Augmented Reality Solutions, Fraunhofer FIT
> > http://www.fit.fraunhofer.de/mars
> > Tel.: +49 (0)2241 - 14-2184
> > _______________________________________________
> > PyQt mailing list    PyQt at riverbankcomputing.com
> > https://www.riverbankcomputing.com/mailman/listinfo/pyqt
 
 




More information about the PyQt mailing list