[PyQt] Supplying PyQt5 via PyPI

Marcus Ottosson konstruktion at gmail.com
Fri Sep 19 09:11:44 BST 2014


Hi Darren,

Thanks for the tip, I remember reading something about this a while back
but didn't make any connection to this problem. I'll give this a go.

Might also add, for anyone using Windows and Python 2.7, the repository is
downloadable and will (should) re-produce the same error at which point you
can test any solutions out yourself and potentially submit a pull-request
on GitHub to resolve the issue. The sooner we get this off the ground, the
sooner folks can start installing PyQt5 via pip. I'll be back on this next
week.

Best,
Marcus

On 18 September 2014 21:39, Darren Dale <dsdale24 at gmail.com> wrote:

> The PyQt{4,5} windows installers create a qt.conf file in two locations,
> one in the same directory as the python.exe, and the other in
> site-packages\PyQt{4,5}. This is necessary to make the Qt libraries
> relocateable, that is, ignore the hard-coded file paths in qmake.exe and
> QtCore.dll. I think you need to create these files based on the
> documentation at http://qt-project.org/doc/qt-5/qt-conf.html , something
> along the lines of
>
> [Paths]
> Prefix = .
> Binaries= .
>
> in site-packages/PyQt{4,5}, and
>
> [Paths]
> Prefix = Lib/site-packages/PyQt4
> Binaries = Lib/site-packages/PyQt4
>
> in C:\Python2.7 (for example). Note that these paths are relative (and
> they use / path separators). The installers provided by Riverbank generate
> absolute paths (C:/Python2.7/Lib/site-packages/PyQt4), which won't work for
> what you are trying to do via PyPI, since you don't know where the user
> installed python. I've tested these qt.conf files with relative paths just
> now, running the qtdemo from PyQt4, and it works. If I delete those files,
> the qtdemo gives me errors related to the sqlite drivers (plugins, I
> believe) not being found, which is similar to the problem you reported.
>
> A side note, I've just finished developing conda packages for Qt5 and
> PyQt{4,5}. At install time, the conda package manager makes an effort to
> replace the hard-coded paths generated at build time with the path required
> for the actual install, in which case the qt.conf file is not needed. The
> Qt windows installer does the same thing, replacing the (padded) build path
> with the installation path.
>
> I found this thread useful when I was working on the conda packages:
>
>
> http://stackoverflow.com/questions/4699311/how-to-install-qt-on-windows-after-building/17640221#17640221
>
> Darren
>
>
> On Thu, Sep 18, 2014 at 4:26 AM, Marcus Ottosson <konstruktion at gmail.com>
> wrote:
>
>> I’ve uploaded an initial version, compiled using VS2013x64 for Python 2.7
>> x64 under Windows 8.1.
>> https://github.com/pyqt/pyqt5
>>
>> But I’ve run into an issue that maybe someone here knows of a solution to.
>> https://github.com/pyqt/pyqt5/issues/2
>>
>> I also noticed that the namespace “pyqt” was free on GitHub. Phil, I
>> would understand if you would like this namespace for yourself. That is
>> fine by me, just let me know and we’ll handle the transfer. Until then I’ll
>> hold onto it and make sure it doesn’t end up in the wrong hands.
>>
>> Also, if you have any preference on the notice about this repository or
>> organisation not being affiliated with your company, let me know and I’ll
>> type it in.
>>
>> Best,
>> Marcus
>>>>
>> On 17 September 2014 20:04, Marcus Ottosson <konstruktion at gmail.com>
>> wrote:
>>
>>> Gotcha. Thanks, Phil.
>>>
>>> On 17 September 2014 19:41, Phil Thompson <phil at riverbankcomputing.com>
>>> wrote:
>>>
>>>> On 17/09/2014 6:08 pm, Marcus Ottosson wrote:
>>>>
>>>>> Hi Nenad and Florian,
>>>>>
>>>>> The thought did occur to me about providing more versions via PyPI,
>>>>> but I
>>>>> can only imagine, and as mentioned by Phil, the amount of work
>>>>> involved in
>>>>> actually getting something like that off the ground.
>>>>>
>>>>> Having said that, as there seems to be some interest, I see no reason
>>>>> why
>>>>> we couldn’t make it a team effort. I’ll be working on GitHub and
>>>>> getting
>>>>> PyPI builds up via Travis, as that is how I’m working currently.
>>>>>
>>>>> I’ll give a shout once I’ve gotten started and maybe we could start
>>>>> talking
>>>>> about ways to go at it from there?
>>>>>
>>>>> For reference, this <https://github.com/abstractfactory/pyblish> is
>>>>> the
>>>>> project the I’m working with.
>>>>>
>>>>> You could install one of the Windows installers and see what gets
>>>>> installed
>>>>> in site-packages\PyQt5.
>>>>>
>>>>> Thanks Phil, I’ll have a look at that. Out of interest, how did *you*
>>>>> figure this out?
>>>>>
>>>>
>>>> Most of it is obvious, the rest is trial-and-error and bug reports.
>>>>
>>>> Phil
>>>>
>>>
>>>
>>>
>>> --
>>> *Marcus Ottosson*
>>> konstruktion at gmail.com
>>>
>>
>>
>>
>> --
>> *Marcus Ottosson*
>> konstruktion at gmail.com
>>
>> _______________________________________________
>> PyQt mailing list    PyQt at riverbankcomputing.com
>> http://www.riverbankcomputing.com/mailman/listinfo/pyqt
>>
>
>


-- 
*Marcus Ottosson*
konstruktion at gmail.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.riverbankcomputing.com/pipermail/pyqt/attachments/20140919/c4436ff5/attachment-0001.html>


More information about the PyQt mailing list