Subject: Re: bug#24404: "calibre" package fails to build.

From: Andreas Enge <[email-masked]>
Date: Thu, 2 Aug 2018 19:23:52 +0200

On Thu, Aug 02, 2018 at 07:04:22PM +0200, Andreas Enge wrote:
> Apparently something needs to be done since our qtwebkit is not in the
> qt installation directory. But this was also the case before, and I do
> not see how we handled this.

I tried the following:
   $ /gnu/store/p7qc46d0a0kksqlrk9jp9368d85w5980-profile/bin/qmake -d -o cfgtest_QtWebKit.mk cfgtest_QtWebKit.pro

The very lengthy output contains something like this:
DEBUG 1: /gnu/store/p7qc46d0a0kksqlrk9jp9368d85w5980-profile/lib/qt5/mkspecs/features/qt.prf:176: calling built-in $$eval(QT.webkit.name)
DEBUG 1: /gnu/store/p7qc46d0a0kksqlrk9jp9368d85w5980-profile/lib/qt5/mkspecs/features/qt.prf:176: MODULE_NAME :=
DEBUG 1: /gnu/store/p7qc46d0a0kksqlrk9jp9368d85w5980-profile/lib/qt5/mkspecs/features/qt.prf:177: calling built-in $$eval(QT.webkit.module)
DEBUG 1: /gnu/store/p7qc46d0a0kksqlrk9jp9368d85w5980-profile/lib/qt5/mkspecs/features/qt.prf:177: MODULE_MODULE :=
DEBUG 1: /gnu/store/p7qc46d0a0kksqlrk9jp9368d85w5980-profile/lib/qt5/mkspecs/features/qt.prf:178: calling built-in $$eval(QT.webkit.includes)
DEBUG 1: /gnu/store/p7qc46d0a0kksqlrk9jp9368d85w5980-profile/lib/qt5/mkspecs/features/qt.prf:178: MODULE_INCLUDES :=
DEBUG 1: /gnu/store/p7qc46d0a0kksqlrk9jp9368d85w5980-profile/lib/qt5/mkspecs/features/qt.prf:179: calling built-in $$eval(QT.webkit.libs)
DEBUG 1: /gnu/store/p7qc46d0a0kksqlrk9jp9368d85w5980-profile/lib/qt5/mkspecs/features/qt.prf:179: MODULE_LIBS :=
DEBUG 1: /gnu/store/p7qc46d0a0kksqlrk9jp9368d85w5980-profile/lib/qt5/mkspecs/features/qt.prf:180: calling built-in $$eval(QT.webkit.frameworks)
DEBUG 1: /gnu/store/p7qc46d0a0kksqlrk9jp9368d85w5980-profile/lib/qt5/mkspecs/features/qt.prf:180: MODULE_FRAMEWORKS :=
DEBUG 1: /gnu/store/p7qc46d0a0kksqlrk9jp9368d85w5980-profile/lib/qt5/mkspecs/features/qt.prf:181: calling built-in $$eval(QT.webkit.uses)
DEBUG 1: /gnu/store/p7qc46d0a0kksqlrk9jp9368d85w5980-profile/lib/qt5/mkspecs/features/qt.prf:181: MODULE_USES :=
DEBUG 1: /gnu/store/p7qc46d0a0kksqlrk9jp9368d85w5980-profile/lib/qt5/mkspecs/features/qt.prf:182: calling built-in $$eval(QT.webkit.module_config)
DEBUG 1: /gnu/store/p7qc46d0a0kksqlrk9jp9368d85w5980-profile/lib/qt5/mkspecs/features/qt.prf:182: MODULE_CONFIG :=
DEBUG 1: /gnu/store/p7qc46d0a0kksqlrk9jp9368d85w5980-profile/lib/qt5/mkspecs/features/qt.prf:184: evaluating test function "isEmpty"
DEBUG 1: /gnu/store/p7qc46d0a0kksqlrk9jp9368d85w5980-profile/lib/qt5/mkspecs/features/qt.prf:184: calling built-in isEmpty(MODULE_NAME)
DEBUG 1: /gnu/store/p7qc46d0a0kksqlrk9jp9368d85w5980-profile/lib/qt5/mkspecs/features/qt.prf:184: test function returned true
DEBUG 1: /gnu/store/p7qc46d0a0kksqlrk9jp9368d85w5980-profile/lib/qt5/mkspecs/features/qt.prf:184: taking 'then' branch
DEBUG 1: /gnu/store/p7qc46d0a0kksqlrk9jp9368d85w5980-profile/lib/qt5/mkspecs/features/qt.prf:184: entering block
DEBUG 1: /gnu/store/p7qc46d0a0kksqlrk9jp9368d85w5980-profile/lib/qt5/mkspecs/features/qt.prf:185: BAD_QT := webkit

When I then look at
/gnu/store/7xfg1s783krjwrp8xmh2nywl7v4x0pq4-qtwebkit-5.212.0-alpha2/mkspecs/modules/qt_lib_webkit.pri
it contains exactly this information:
QT.webkit.VERSION = 5.212.0
QT.webkit.MAJOR_VERSION = 5
QT.webkit.MINOR_VERSION = 212
QT.webkit.PATCH_VERSION = 0
QT.webkit.name = QtWebKit
QT.webkit.module = Qt5WebKit
QT.webkit.DEFINES = QT_WEBKIT_LIB
QT.webkit.includes = "/gnu/store/7xfg1s783krjwrp8xmh2nywl7v4x0pq4-qtwebkit-5.212.0-alpha2/include" "/gnu/store/7xfg1s783krjwrp8xmh2nywl7v4x0pq4-qtwebkit-5.212.0-alpha2/include/QtWebKit"
QT.webkit.private_includes =
QT.webkit.libs = "/gnu/store/7xfg1s783krjwrp8xmh2nywl7v4x0pq4-qtwebkit-5.212.0-alpha2/lib"
QT.webkit.rpath = "/gnu/store/7xfg1s783krjwrp8xmh2nywl7v4x0pq4-qtwebkit-5.212.0-alpha2/lib"
QT.webkit.depends = core gui network
QT.webkit.run_depends = sensors positioning qml quick core_private gui_private
QT.webkit.bins = /gnu/store/7xfg1s783krjwrp8xmh2nywl7v4x0pq4-qtwebkit-5.212.0-alpha2/bin
QT.webkit.libexec =
QT.webkit.plugins =
QT.webkit.imports =
QT.webkit.qml =
QT.webkit.frameworks =
QT.webkit.module_config = v2
QT_MODULES += webkit
QMAKE_LIBS_PRIVATE +=
QMAKE_RPATHDIR += /gnu/store/7xfg1s783krjwrp8xmh2nywl7v4x0pq4-qtwebkit-5.212.0-alpha2/lib

So somehow we need to tell qmake where to search for the .pri files for qtwebkit.

Andreas