Bug 378657 - Compilation fails due to SIP not including /usr/share/sip/PyQt5
Summary: Compilation fails due to SIP not including /usr/share/sip/PyQt5
Status: RESOLVED FIXED
Alias: None
Product: krita
Classification: Applications
Component: General (show other bugs)
Version: git master (please specify the git hash!)
Platform: Compiled Sources Linux
: NOR normal
Target Milestone: ---
Assignee: Krita Bugs
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2017-04-11 10:24 UTC by beojan
Modified: 2017-05-16 14:49 UTC (History)
4 users (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description beojan 2017-04-11 10:24:19 UTC
Compilation fails when sip is run, failing to find QtCore/QtCoremod.sip, because it doesn't look in /usr/share/sip/PyQt5.
Comment 1 wolthera 2017-04-11 13:43:36 UTC
Which distro are you running?

On an Ubuntu Flavour I could get everything to work by installed the following deps: python3, python3-sip-dev, python3-pyqt-dev and pyqt5-dev
Comment 2 beojan 2017-04-11 13:44:58 UTC
Arch, with PyQt5 installed.
Comment 3 Quiralta 2017-04-11 15:28:12 UTC
In Arch is simply called python (without the 3), pyqt5-common, python-pyqt5, python-sip, sip, (check that all those are installed)

I'm on Arch/plasma too, compiling just fine here.
Comment 4 beojan 2017-04-11 15:32:26 UTC
They're all installed. Editing the build makefile to add `-I /usr/share/sip/PyQt5` to the sip command line makes the build succeed.
Comment 5 Halla Rempt 2017-04-11 18:00:40 UTC
I'm not sure about arch... Never used it. But I also never tried to build with distro packages of PyQt and Python on OpenSUSE, only with home-built packages where PyQt and sip are in a special location.

In all cases, you can set PYQT_SIP_DIR_OVERRIDE on the cmake command line to the right location, and the build should succeed, if the version of sip is correct.
Comment 6 beojan 2017-04-11 18:07:13 UTC
The strange thing is that it *is* correctly detecting the PyQt5 directory.
Comment 7 Dmitry Kazakov 2017-04-13 13:22:37 UTC
I can confirm the bug on Ubuntu 16.04. If python and sip packages are installed, Krita finds them and activates the features, but compilation fails due to absence of some include files. The trouble is successfully workarounded by setting PYQT_SIP_DIR_OVERRIDE definition. That looks like some bug in our(?) cmake files.
Comment 8 Halla Rempt 2017-05-16 14:49:34 UTC
Git commit fd89b3a67d4a02a2394423b6c0aac3384bdafa4a by Boudewijn Rempt.
Committed on 16/05/2017 at 14:49.
Pushed by rempt into branch 'master'.

Add the system sip location to the sip_include path

This lets the pykrita sip module build out of the box on Ubuntu
17.04 if all dependencies are correctly installed.

M  +12   -1    plugins/extensions/pykrita/sip/CMakeLists.txt

https://commits.kde.org/krita/fd89b3a67d4a02a2394423b6c0aac3384bdafa4a