gnu: python-pyqt: Substitute the full path of <qprinter.h>.

* gnu/packages/qt.scm (python-pyqt)[phases]: When building
  python-pyqtwebengine, qprinter.h can not be found.  This substitutes the full
  path of qprinter.h in the qprinter sip specification file.
This commit is contained in:
Mike Rosset 2020-01-14 03:04:59 -08:00 committed by Pierre Neidhardt
parent 353e9f733c
commit 9deae98281
No known key found for this signature in database
GPG key ID: 9BDCF497A4BBCC7F

View file

@ -1947,6 +1947,17 @@ (define-public python-pyqt
,@%gnu-build-system-modules)
#:phases
(modify-phases %standard-phases
;; When building python-pyqtwebengine, <qprinter.h> can not be
;; included. Here we substitute the full path to the header in the
;; store.
(add-before 'configure 'substitute-source
(lambda* (#:key inputs #:allow-other-keys)
(let* ((qtbase (assoc-ref inputs "qtbase"))
(qtprinter.h (string-append "\"" qtbase "/include/qt5/QtPrintSupport/qprinter.h\"")))
(substitute* "sip/QtPrintSupport/qprinter.sip"
(("<qprinter.h>")
qtprinter.h))
#t)))
(replace 'configure
(lambda* (#:key inputs outputs #:allow-other-keys)
(let* ((out (assoc-ref outputs "out"))