Message ID | 20201221203952.22168-3-ps.report@gmx.net |
---|---|
State | Changes Requested |
Headers | show |
Series | [v1] package/qt5webengine: add optional host-freetype/host-libjpeg dependency | expand |
Hello Peter, On Mon, 21 Dec 2020 21:39:51 +0100 Peter Seiderer <ps.report@gmx.net> wrote: > - add optional host-freetype dependency > > Fixes: > > Command: .../host/bin/python2 .../build/qt5webengine-5.15.2/src/3rdparty/chromium/build/config/linux/pkg-config.py -p .../build/qt5webengine-5.15.2/host-bin/host-pkg-config freetype2 > Returned 1. > stderr: > > Package freetype2 was not found in the pkg-config search path. > Perhaps you should add the directory containing `freetype2.pc' > to the PKG_CONFIG_PATH environment variable > Package 'freetype2', required by 'virtual:world', not found > Could not run pkg-config. > > See //build/linux/BUILD.gn:24:3: whence it was called. > pkg_config("freetype_from_pkgconfig") { > ^-------------------------------------- > See //build/config/freetype/BUILD.gn:10:24: which caused the file to be included. > public_configs = [ "//build/linux:freetype_from_pkgconfig" ] > ^-------------------------------------- > Project ERROR: GN run error! > make[4]: *** [Makefile:82: sub-gn_run-pro-make_first] Error 3 > make[3]: *** [Makefile:79: sub-core-make_first] Error 2 > make[2]: *** [Makefile:49: sub-src-make_first] Error 2 > > - add optiobal hist-libjpeg dependency > > Fixes: > > https://gitlab.com/buildroot.org/buildroot/-/jobs/917539230 > > Command: .../host/bin/python2 .../build/qt5webengine-5.15.2/src/3rdparty/chromium/build/config/linux/pkg-config.py -p .../build/qt5webengine-5.15.2/host-bin/host-pkg-config libjpeg > Returned 1. > stderr: > Package libjpeg was not found in the pkg-config search path. > Perhaps you should add the directory containing `libjpeg.pc' > to the PKG_CONFIG_PATH environment variable > Package 'libjpeg', required by 'virtual:world', not found > Could not run pkg-config. > See //third_party/BUILD.gn:17:3: whence it was called. > pkg_config("system_libjpeg") { > ^----------------------------- > See //third_party/blink/renderer/platform/BUILD.gn:159:5: which caused the file to be included. > "//third_party:jpeg", > ^------------------- > Project ERROR: GN run error! > > Signed-off-by: Peter Seiderer <ps.report@gmx.net> > --- > package/qt5/qt5webengine/qt5webengine.mk | 8 ++++++++ > 1 file changed, 8 insertions(+) > > diff --git a/package/qt5/qt5webengine/qt5webengine.mk b/package/qt5/qt5webengine/qt5webengine.mk > index 64c9c96cc2..8ab50a0fbf 100644 > --- a/package/qt5/qt5webengine/qt5webengine.mk > +++ b/package/qt5/qt5webengine/qt5webengine.mk > @@ -29,6 +29,14 @@ endif > > QT5WEBENGINE_DEPENDENCIES += host-libpng host-libnss libnss > > +ifeq ($(BR2_PACKAGE_QT5BASE_FONTCONFIG),y) > +QT5WEBENGINE_DEPENDENCIES += host-freetype > +endif > + > +ifeq ($(BR2_PACKAGE_QT5BASE_JPEG),y) > +QT5WEBENGINE_DEPENDENCIES += host-libjpeg > +endif This looks really odd. Why would these target-related features require host-freetype and host-libjpeg ? Aren't we instead seeing some pkg-config issue where it's trying to find freetype/libjpeg for the target, but it for some reason doesn't work, and tries to find them for the host ? Thomas
Hello Peter, On Wed, 30 Dec 2020 11:18:23 +0100 Thomas Petazzoni <thomas.petazzoni@bootlin.com> wrote: > > +ifeq ($(BR2_PACKAGE_QT5BASE_FONTCONFIG),y) > > +QT5WEBENGINE_DEPENDENCIES += host-freetype > > +endif > > + > > +ifeq ($(BR2_PACKAGE_QT5BASE_JPEG),y) > > +QT5WEBENGINE_DEPENDENCIES += host-libjpeg > > +endif > > This looks really odd. Why would these target-related features require > host-freetype and host-libjpeg ? Aren't we instead seeing some > pkg-config issue where it's trying to find freetype/libjpeg for the > target, but it for some reason doesn't work, and tries to find them for > the host ? Do you have some further feedback on this issue ? Thanks! Thomas
Hello Thomas, On Tue, 19 Jan 2021 22:22:34 +0100, Thomas Petazzoni <thomas.petazzoni@bootlin.com> wrote: > Hello Peter, > > On Wed, 30 Dec 2020 11:18:23 +0100 > Thomas Petazzoni <thomas.petazzoni@bootlin.com> wrote: > > > > +ifeq ($(BR2_PACKAGE_QT5BASE_FONTCONFIG),y) > > > +QT5WEBENGINE_DEPENDENCIES += host-freetype > > > +endif > > > + > > > +ifeq ($(BR2_PACKAGE_QT5BASE_JPEG),y) > > > +QT5WEBENGINE_DEPENDENCIES += host-libjpeg > > > +endif > > > > This looks really odd. Why would these target-related features require > > host-freetype and host-libjpeg ? Aren't we instead seeing some > > pkg-config issue where it's trying to find freetype/libjpeg for the > > target, but it for some reason doesn't work, and tries to find them for > > the host ? > > Do you have some further feedback on this issue ? Did try to find out where the mismatch comes from...., but without success... The best solution/hack so far is: --- a/package/qt5/qt5webengine/host-pkg-config.in +++ b/package/qt5/qt5webengine/host-pkg-config.in @@ -2,5 +2,5 @@ PKG_CONFIG_SYSROOT_DIR="/" \ PKG_CONFIG_ALLOW_SYSTEM_CFLAGS=1 \ PKG_CONFIG_ALLOW_SYSTEM_LIBS=1 \ -PKG_CONFIG_LIBDIR="@HOST_DIR@/lib/pkgconfig:@HOST_DIR@/share/pkgconfig" \ +PKG_CONFIG_LIBDIR="@HOST_DIR@/lib/pkgconfig:@HOST_DIR@/share/pkgconfig:@SYSROOT@/usr/lib/pkgconfig" \ exec @HOST_DIR@/bin/pkgconf "$@" --- a/package/qt5/qt5webengine/qt5webengine.mk +++ b/package/qt5/qt5webengine/qt5webengine.mk @@ -54,7 +54,7 @@ QT5WEBENGINE_PRE_CONFIGURE_HOOKS += QT5WEBENGINE_PYTHON2_SYMLINK QT5WEBENGINE_ENV += NINJAFLAGS="-j$(PARALLEL_JOBS)" define QT5WEBENGINE_CREATE_HOST_PKG_CONFIG - sed s%@HOST_DIR@%$(HOST_DIR)%g $(QT5WEBENGINE_PKGDIR)/host-pkg-config.in > $(@D)/host-bin/host-pkg-config + sed s%@HOST_DIR@%$(HOST_DIR)%g $(QT5WEBENGINE_PKGDIR)/host-pkg-config.in | sed s%@SYSROOT@%$(STAGING_DIR)%g > $(@D)/host-bin/host-pkg-config chmod +x $(@D)/host-bin/host-pkg-config endef QT5WEBENGINE_PRE_CONFIGURE_HOOKS += QT5WEBENGINE_CREATE_HOST_PKG_CONFIG Regards, Peter > > Thanks! > > Thomas
Hello Peter, On Thu, 21 Jan 2021 22:03:00 +0100 Peter Seiderer <ps.report@gmx.net> wrote: > Did try to find out where the mismatch comes from...., but without success... > > The best solution/hack so far is: > > --- a/package/qt5/qt5webengine/host-pkg-config.in > +++ b/package/qt5/qt5webengine/host-pkg-config.in > @@ -2,5 +2,5 @@ > PKG_CONFIG_SYSROOT_DIR="/" \ > PKG_CONFIG_ALLOW_SYSTEM_CFLAGS=1 \ > PKG_CONFIG_ALLOW_SYSTEM_LIBS=1 \ > -PKG_CONFIG_LIBDIR="@HOST_DIR@/lib/pkgconfig:@HOST_DIR@/share/pkgconfig" \ > +PKG_CONFIG_LIBDIR="@HOST_DIR@/lib/pkgconfig:@HOST_DIR@/share/pkgconfig:@SYSROOT@/usr/lib/pkgconfig" \ > exec @HOST_DIR@/bin/pkgconf "$@" > > > --- a/package/qt5/qt5webengine/qt5webengine.mk > +++ b/package/qt5/qt5webengine/qt5webengine.mk > @@ -54,7 +54,7 @@ QT5WEBENGINE_PRE_CONFIGURE_HOOKS += QT5WEBENGINE_PYTHON2_SYMLINK > QT5WEBENGINE_ENV += NINJAFLAGS="-j$(PARALLEL_JOBS)" > > define QT5WEBENGINE_CREATE_HOST_PKG_CONFIG > - sed s%@HOST_DIR@%$(HOST_DIR)%g $(QT5WEBENGINE_PKGDIR)/host-pkg-config.in > $(@D)/host-bin/host-pkg-config > + sed s%@HOST_DIR@%$(HOST_DIR)%g $(QT5WEBENGINE_PKGDIR)/host-pkg-config.in | sed s%@SYSROOT@%$(STAGING_DIR)%g > $(@D)/host-bin/host-pkg-config > chmod +x $(@D)/host-bin/host-pkg-config Ouch, but this is also very wrong, it makes host-pkg-config (which is there to query results about native libraries), return results for cross-compiled libraries :-/ Thomas
On Mon, 21 Dec 2020 21:39:51 +0100 Peter Seiderer <ps.report@gmx.net> wrote: > - add optional host-freetype dependency > > Fixes: > > Command: .../host/bin/python2 .../build/qt5webengine-5.15.2/src/3rdparty/chromium/build/config/linux/pkg-config.py -p .../build/qt5webengine-5.15.2/host-bin/host-pkg-config freetype2 > Returned 1. > stderr: > > Package freetype2 was not found in the pkg-config search path. > Perhaps you should add the directory containing `freetype2.pc' > to the PKG_CONFIG_PATH environment variable > Package 'freetype2', required by 'virtual:world', not found > Could not run pkg-config. > > See //build/linux/BUILD.gn:24:3: whence it was called. > pkg_config("freetype_from_pkgconfig") { > ^-------------------------------------- > See //build/config/freetype/BUILD.gn:10:24: which caused the file to be included. > public_configs = [ "//build/linux:freetype_from_pkgconfig" ] > ^-------------------------------------- > Project ERROR: GN run error! > make[4]: *** [Makefile:82: sub-gn_run-pro-make_first] Error 3 > make[3]: *** [Makefile:79: sub-core-make_first] Error 2 > make[2]: *** [Makefile:49: sub-src-make_first] Error 2 I am falling into this issue while building the following defconfig: BR2_arm=y BR2_arm1176jzf_s=y BR2_TOOLCHAIN_EXTERNAL=y BR2_ROOTFS_DEVICE_CREATION_DYNAMIC_EUDEV=y BR2_PACKAGE_QT5=y BR2_PACKAGE_QT5WEBENGINE=y BR2_PACKAGE_RPI_USERLAND=y Did you had the chance to investigate more deeply why having fontconfig support in Qt leads qt5webengine wanting to find freetype2 on the host? Thomas
On Sun, 9 Jan 2022 14:27:48 +0100 Thomas Petazzoni <thomas.petazzoni@bootlin.com> wrote: > I am falling into this issue while building the following defconfig: > > BR2_arm=y > BR2_arm1176jzf_s=y > BR2_TOOLCHAIN_EXTERNAL=y > BR2_ROOTFS_DEVICE_CREATION_DYNAMIC_EUDEV=y > BR2_PACKAGE_QT5=y > BR2_PACKAGE_QT5WEBENGINE=y > BR2_PACKAGE_RPI_USERLAND=y > > Did you had the chance to investigate more deeply why having fontconfig > support in Qt leads qt5webengine wanting to find freetype2 on the host? Interestingly, in commit https://github.com/meta-qt5/meta-qt5/commit/280487f20bca829527a597d6263b0344a01917ac#diff-f0ffde666f6ff0282f8400203b3ba20968494d3c7245106eca761bd79baa1c78R26 the meta-qt5 layer, when upgrading Qt to 5.15.2 added jpeg-native and freetype-native as new unconditional dependencies. But there are no explanations. Is it really because the Chromium stuff is building a host tool with freetype/jpeg, or is it just a workaround for some incorrect behavior of the Chromium build process that needs freetype/jpeg on the target, but checks for them on the host? Thomas
Hello Thomas, On Sun, 9 Jan 2022 14:27:48 +0100, Thomas Petazzoni <thomas.petazzoni@bootlin.com> wrote: > On Mon, 21 Dec 2020 21:39:51 +0100 > Peter Seiderer <ps.report@gmx.net> wrote: > > > - add optional host-freetype dependency > > > > Fixes: > > > > Command: .../host/bin/python2 .../build/qt5webengine-5.15.2/src/3rdparty/chromium/build/config/linux/pkg-config.py -p .../build/qt5webengine-5.15.2/host-bin/host-pkg-config freetype2 > > Returned 1. > > stderr: > > > > Package freetype2 was not found in the pkg-config search path. > > Perhaps you should add the directory containing `freetype2.pc' > > to the PKG_CONFIG_PATH environment variable > > Package 'freetype2', required by 'virtual:world', not found > > Could not run pkg-config. > > > > See //build/linux/BUILD.gn:24:3: whence it was called. > > pkg_config("freetype_from_pkgconfig") { > > ^-------------------------------------- > > See //build/config/freetype/BUILD.gn:10:24: which caused the file to be included. > > public_configs = [ "//build/linux:freetype_from_pkgconfig" ] > > ^-------------------------------------- > > Project ERROR: GN run error! > > make[4]: *** [Makefile:82: sub-gn_run-pro-make_first] Error 3 > > make[3]: *** [Makefile:79: sub-core-make_first] Error 2 > > make[2]: *** [Makefile:49: sub-src-make_first] Error 2 > > I am falling into this issue while building the following defconfig: > > BR2_arm=y > BR2_arm1176jzf_s=y > BR2_TOOLCHAIN_EXTERNAL=y > BR2_ROOTFS_DEVICE_CREATION_DYNAMIC_EUDEV=y > BR2_PACKAGE_QT5=y > BR2_PACKAGE_QT5WEBENGINE=y > BR2_PACKAGE_RPI_USERLAND=y > > Did you had the chance to investigate more deeply why having fontconfig > support in Qt leads qt5webengine wanting to find freetype2 on the host? The observation is that all (optional) qt target options are requested by qtwebengine for the host (and buildroot package fontconfig selects freetype)... Regards, Peter > > Thomas
Hello Thomas, On Sun, 9 Jan 2022 14:44:30 +0100, Thomas Petazzoni <thomas.petazzoni@bootlin.com> wrote: > On Sun, 9 Jan 2022 14:27:48 +0100 > Thomas Petazzoni <thomas.petazzoni@bootlin.com> wrote: > > > I am falling into this issue while building the following defconfig: > > > > BR2_arm=y > > BR2_arm1176jzf_s=y > > BR2_TOOLCHAIN_EXTERNAL=y > > BR2_ROOTFS_DEVICE_CREATION_DYNAMIC_EUDEV=y > > BR2_PACKAGE_QT5=y > > BR2_PACKAGE_QT5WEBENGINE=y > > BR2_PACKAGE_RPI_USERLAND=y > > > > Did you had the chance to investigate more deeply why having fontconfig > > support in Qt leads qt5webengine wanting to find freetype2 on the host? > > Interestingly, in commit > https://github.com/meta-qt5/meta-qt5/commit/280487f20bca829527a597d6263b0344a01917ac#diff-f0ffde666f6ff0282f8400203b3ba20968494d3c7245106eca761bd79baa1c78R26 > the meta-qt5 layer, when upgrading Qt to 5.15.2 added jpeg-native and > freetype-native as new unconditional dependencies. > > But there are no explanations. Is it really because the Chromium stuff > is building a host tool with freetype/jpeg, or is it just a workaround > for some incorrect behavior of the Chromium build process that needs > freetype/jpeg on the target, but checks for them on the host? Would say yes... Regards, Peter > > Thomas
On Mon, Dec 21, 2020 at 1:40 PM Peter Seiderer <ps.report@gmx.net> wrote: > > - add optional host-freetype dependency > > Fixes: > > Command: .../host/bin/python2 .../build/qt5webengine-5.15.2/src/3rdparty/chromium/build/config/linux/pkg-config.py -p .../build/qt5webengine-5.15.2/host-bin/host-pkg-config freetype2 > Returned 1. > stderr: > > Package freetype2 was not found in the pkg-config search path. > Perhaps you should add the directory containing `freetype2.pc' > to the PKG_CONFIG_PATH environment variable > Package 'freetype2', required by 'virtual:world', not found > Could not run pkg-config. > > See //build/linux/BUILD.gn:24:3: whence it was called. > pkg_config("freetype_from_pkgconfig") { > ^-------------------------------------- > See //build/config/freetype/BUILD.gn:10:24: which caused the file to be included. > public_configs = [ "//build/linux:freetype_from_pkgconfig" ] > ^-------------------------------------- > Project ERROR: GN run error! > make[4]: *** [Makefile:82: sub-gn_run-pro-make_first] Error 3 > make[3]: *** [Makefile:79: sub-core-make_first] Error 2 > make[2]: *** [Makefile:49: sub-src-make_first] Error 2 > > - add optiobal hist-libjpeg dependency > > Fixes: > > https://gitlab.com/buildroot.org/buildroot/-/jobs/917539230 > > Command: .../host/bin/python2 .../build/qt5webengine-5.15.2/src/3rdparty/chromium/build/config/linux/pkg-config.py -p .../build/qt5webengine-5.15.2/host-bin/host-pkg-config libjpeg > Returned 1. > stderr: > Package libjpeg was not found in the pkg-config search path. > Perhaps you should add the directory containing `libjpeg.pc' > to the PKG_CONFIG_PATH environment variable > Package 'libjpeg', required by 'virtual:world', not found > Could not run pkg-config. > See //third_party/BUILD.gn:17:3: whence it was called. > pkg_config("system_libjpeg") { > ^----------------------------- > See //third_party/blink/renderer/platform/BUILD.gn:159:5: which caused the file to be included. > "//third_party:jpeg", > ^------------------- > Project ERROR: GN run error! > > Signed-off-by: Peter Seiderer <ps.report@gmx.net> Tested-by: James Hilliard <james.hilliard1@gmail.com> > --- > package/qt5/qt5webengine/qt5webengine.mk | 8 ++++++++ > 1 file changed, 8 insertions(+) > > diff --git a/package/qt5/qt5webengine/qt5webengine.mk b/package/qt5/qt5webengine/qt5webengine.mk > index 64c9c96cc2..8ab50a0fbf 100644 > --- a/package/qt5/qt5webengine/qt5webengine.mk > +++ b/package/qt5/qt5webengine/qt5webengine.mk > @@ -29,6 +29,14 @@ endif > > QT5WEBENGINE_DEPENDENCIES += host-libpng host-libnss libnss > > +ifeq ($(BR2_PACKAGE_QT5BASE_FONTCONFIG),y) > +QT5WEBENGINE_DEPENDENCIES += host-freetype > +endif > + > +ifeq ($(BR2_PACKAGE_QT5BASE_JPEG),y) > +QT5WEBENGINE_DEPENDENCIES += host-libjpeg > +endif > + > QT5WEBENGINE_CONF_OPTS += WEBENGINE_CONFIG+=use_system_ffmpeg > > ifeq ($(BR2_PACKAGE_QT5WEBENGINE_PROPRIETARY_CODECS),y) > -- > 2.29.2 > > _______________________________________________ > buildroot mailing list > buildroot@busybox.net > http://lists.busybox.net/mailman/listinfo/buildroot
diff --git a/package/qt5/qt5webengine/qt5webengine.mk b/package/qt5/qt5webengine/qt5webengine.mk index 64c9c96cc2..8ab50a0fbf 100644 --- a/package/qt5/qt5webengine/qt5webengine.mk +++ b/package/qt5/qt5webengine/qt5webengine.mk @@ -29,6 +29,14 @@ endif QT5WEBENGINE_DEPENDENCIES += host-libpng host-libnss libnss +ifeq ($(BR2_PACKAGE_QT5BASE_FONTCONFIG),y) +QT5WEBENGINE_DEPENDENCIES += host-freetype +endif + +ifeq ($(BR2_PACKAGE_QT5BASE_JPEG),y) +QT5WEBENGINE_DEPENDENCIES += host-libjpeg +endif + QT5WEBENGINE_CONF_OPTS += WEBENGINE_CONFIG+=use_system_ffmpeg ifeq ($(BR2_PACKAGE_QT5WEBENGINE_PROPRIETARY_CODECS),y)
- add optional host-freetype dependency Fixes: Command: .../host/bin/python2 .../build/qt5webengine-5.15.2/src/3rdparty/chromium/build/config/linux/pkg-config.py -p .../build/qt5webengine-5.15.2/host-bin/host-pkg-config freetype2 Returned 1. stderr: Package freetype2 was not found in the pkg-config search path. Perhaps you should add the directory containing `freetype2.pc' to the PKG_CONFIG_PATH environment variable Package 'freetype2', required by 'virtual:world', not found Could not run pkg-config. See //build/linux/BUILD.gn:24:3: whence it was called. pkg_config("freetype_from_pkgconfig") { ^-------------------------------------- See //build/config/freetype/BUILD.gn:10:24: which caused the file to be included. public_configs = [ "//build/linux:freetype_from_pkgconfig" ] ^-------------------------------------- Project ERROR: GN run error! make[4]: *** [Makefile:82: sub-gn_run-pro-make_first] Error 3 make[3]: *** [Makefile:79: sub-core-make_first] Error 2 make[2]: *** [Makefile:49: sub-src-make_first] Error 2 - add optiobal hist-libjpeg dependency Fixes: https://gitlab.com/buildroot.org/buildroot/-/jobs/917539230 Command: .../host/bin/python2 .../build/qt5webengine-5.15.2/src/3rdparty/chromium/build/config/linux/pkg-config.py -p .../build/qt5webengine-5.15.2/host-bin/host-pkg-config libjpeg Returned 1. stderr: Package libjpeg was not found in the pkg-config search path. Perhaps you should add the directory containing `libjpeg.pc' to the PKG_CONFIG_PATH environment variable Package 'libjpeg', required by 'virtual:world', not found Could not run pkg-config. See //third_party/BUILD.gn:17:3: whence it was called. pkg_config("system_libjpeg") { ^----------------------------- See //third_party/blink/renderer/platform/BUILD.gn:159:5: which caused the file to be included. "//third_party:jpeg", ^------------------- Project ERROR: GN run error! Signed-off-by: Peter Seiderer <ps.report@gmx.net> --- package/qt5/qt5webengine/qt5webengine.mk | 8 ++++++++ 1 file changed, 8 insertions(+)