kumquat-buildroot/package/qt5/qt5webengine/Config.in

102 lines
4.1 KiB
Plaintext
Raw Normal View History

qt5webengine: new package This patch is based on works [1] and [2]. With this patch, one can run the Qt5 WebEngine quicknanobrowser sample with the following options. BR2_TOOLCHAIN_BUILDROOT_LIBC="glibc" and BR2_TOOLCHAIN_BUILDROOT_CXX (Qt 5 needs a toolchain w/ wchar, NPTL, C++, dynamic library; for now it builds only with glibc) BR2_PACKAGE_LIBERATION (Qt needs at least one font) BR2_PACKAGE_QT5BASE_EXAMPLES (to install quicknanobrowser sample) BR2_PACKAGE_QT5BASE_GIF (do display gif) BR2_PACKAGE_QT5BASE_JPEG (do display jpeg) BR2_PACKAGE_QT5BASE_PNG (do display png) BR2_PACKAGE_QT5QUICKCONTROLS (needed by webengine) BR2_PACKAGE_QT5QUICKCONTROLS2 (needed by webengine) BR2_PACKAGE_QT5WEBENGINE (because it is what we want) Qt WebEngine requires an Open(E)GL-capable backend. As an example, the package rpi-userland must be enabled to build for a rpi. BR2_PACKAGE_RPI_USERLAND (to enable OpenGL ES backend) To browse for HTTPS websites, please consider adding the following options as well for SSL/TLS. BR2_PACKAGE_CA_CERT (for certificates) BR2_PACKAGE_NTPD (to sync date for certificates) Since version 5.9, chromium requires udev at runtime (see note 4). BR2_ROOTFS_DEVICE_CREATION_DYNAMIC_EUDEV (input backend) To run quicknanobrowser # cd /usr/lib/qt/examples/webengine/quicknanobrowser/ # ./quicknanobrowser https://www.buildroot.org/ Note: The chromium.inc has been generated using the following command. ( echo 'CHROMIUM_LICENSE_FILES = \' && cd output/build/qt5webengine-5.9.1/ && \ find "src/3rdparty/chromium/" -type f -iname "*LICENSE*" -o -iname "*COPYING*" -o -iname "*GPL*" | \ sed -e '/\.asm$/d' \ -e '/\.h$/d' \ -e '/\.c$/d' \ -e '/\.cc$/d' \ -e '/\.cpp$/d' \ -e '/\.pyc\?$/d' \ -e '/\.pl$/d' \ -e '/\.sha1$/d' \ -e '/\.patch$/d' \ -e '/licensecheck/d' \ -e 's,^,\t,' \ -e 's,$, \\,' | \ sort && \ echo '' ) >package/qt5/qt5webengine/chromium.inc Note 2: Since 5.9.1, the chromium's copy of opus fails with neon [3]. Qt WebEngine can uses buildroot ffmpeg copy which compiles fine (using qmake flag WEBENGINE_CONFIG+=use_system_ffmpeg). It implies selecting the following options. BR2_PACKAGE_FFMPEG BR2_PACKAGE_OPUS BR2_PACKAGE_LIBVPX BR2_PACKAGE_WEBP BR2_PACKAGE_WEBP_DEMUX In file included from ../../3rdparty/chromium/third_party/opus/src/silk/arm/NSQ_neon.c:31:0: /home/gportay/src/buildroot/output-rpi3-qt5.9/host/lib/gcc/arm-buildroot-linux-gnueabihf/6.4.0/include/arm_neon.h:8997:1: error: inlining failed in call to always_inline ‘vld1q_s32’: target specific option mismatch vld1q_s32 (const int32_t * __a) ^~~~~~~~~ ../../3rdparty/chromium/third_party/opus/src/silk/arm/NSQ_neon.c:40:15: note: called from here int32x4_t coef0 = vld1q_s32(coef32); ^~~~~ ../../3rdparty/chromium/third_party/opus/src/silk/arm/NSQ_neon.c: At top level: cc1: warning: unrecognized command line option ‘-Wno-#pragma-messages’ Note 3: Version 5.6.2 causes a build issue while building chromium. The build against this version is disabled until the release 5.6.3 is out. Note 4: Here is trace when udev does not run # cd /usr/lib/qt/examples/webengine/quicknanobrowser # ./quicknanobrowser QStandardPaths: XDG_RUNTIME_DIR not set, defaulting to '/tmp/runtime-root' Unable to query physical screen size, defaulting to 100 dpi. To override, set QT_QPA_EGLFS_PHYSICAL_WIDTH and QT_QPA_EGLFS_PHYSICAL_HEIGHT (in millimeters). [0101/000248.161973:WARNING:resource_bundle_qt.cpp(114)] locale_file_path.empty() for locale [0101/000248.384693:WARNING:resource_bundle_qt.cpp(114)] locale_file_path.empty() for locale [202:223:0101/000248.484954:FATAL:udev_loader.cc(38)] Check failed: false. #0 0x0000742b93de <unknown> #1 0x0000742c3c38 <unknown> #2 0x000073e1e1aa <unknown> #3 0x000073e1d96e <unknown> #4 0x000073e1defa <unknown> #5 0x000074af6364 <unknown> #6 0x000074302878 <unknown> #7 0x0000742c8fee <unknown> #8 0x0000742c9f44 <unknown> #9 0x0000742ca21e <unknown> #10 0x0000742cac4c <unknown> #11 0x0000742c87b2 <unknown> #12 0x0000742da4f6 <unknown> #13 0x000073ed9d38 <unknown> #14 0x000073eda03c <unknown> #15 0x0000742e9aec <unknown> #16 0x0000742e71dc <unknown> Aborted Note 5: On rpi and depending on what is insinde the .config, more GPU memory should be allocated to run properly qt samples. #0 0x0000742c63de <unknown> #1 0x0000742d0c38 <unknown> #2 0x0000749d7bde <unknown> #3 0x0000749e3c70 <unknown> #4 0x00007530227c <unknown> #5 0x000075302480 <unknown> #6 0x0000752fb1e4 <unknown> #7 0x00007430f878 <unknown> #8 0x0000742d5fee <unknown> #9 0x0000742d6f44 <unknown> #10 0x0000742d721e <unknown> #11 0x0000742d7ad6 <unknown> #12 0x0000742d57b2 <unknown> #13 0x0000742e74f6 <unknown> #14 0x0000742f6a74 <unknown> #15 0x0000742f41dc <unknown> Received signal 6 #0 0x0000742c63de <unknown> #1 0x0000742c66a0 <unknown> #2 0x0000725b5d10 <unknown> [end of stack trace] qml: Render process exited with code 256 (abnormal exit) # mount /dev/mmcblk0p1 /mnt # sed '/^gpu_mem_/s,=.*,=200,' -i /mnt/config.txt # umount /mnt Note 6: The first patch fixes a build issue when samples are compiled without the support of printing [4]. This patch is already merged in branch 5.9 [5] and concerns only 5.9.1. 085c2c52 Always compile QWebEnginePage::print It fixes the error below. .obj/browsermainwindow.o: In function `BrowserMainWindow::printRequested(QWebEnginePage*)': browsermainwindow.cpp:(.text+0x2cc0): undefined reference to `QWebEnginePage::print(QPrinter*, QWebEngineCallback<bool> const&)' The second patch loads both libEGL and libGLESv2 symbols implicitly instead of loading them with explicitly using hard-coded locations. It fixes a bug when providers of lib*GL does not create libraries named libEGL.so.1 and libGLESv2.s2 [6]. This patch is already merged in branch 5.9 [7]. d4c621f6 Load libEGL and libGLES2 symbols implicitly It fixes the error below. [327:347:1221/085837:ERROR:surface_factory_qt.cpp(68)] Failed to load /usr/lib/libGLESv2.so.2: /usr/lib/libGLESv2.so.2: cannot open shared object file: No such file or directory [1]: http://lists.busybox.net/pipermail/buildroot/2015-July/132010.html [2]: https://patchwork.ozlabs.org/patch/640633/ [3]: https://patchwork.ozlabs.org/patch/791332/ [4]: https://bugreports.qt.io/browse/QTBUG-61510 [5]: https://codereview.qt-project.org/#/c/198041/ [6]: https://bugreports.qt.io/browse/QTBUG-57761 [7]: https://codereview.qt-project.org/#/c/199554/ Cc: Akihiko Odaki <akihiko.odaki.4i@stu.hosei.ac.jp> Cc: Julien Corjon <corjon.j@ecagroup.com> Signed-off-by: Gaël PORTAY <gael.portay@savoirfairelinux.com> [Arnout: - move more dependencies to _ARCH_DEPENDS; - mention all toolchain dependencies in the comments] Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
2017-08-15 22:38:53 +02:00
config BR2_PACKAGE_QT5WEBENGINE_ARCH_SUPPORTS
bool
default y if BR2_aarch64 || BR2_arm || \
BR2_i386 || BR2_x86_64 || \
BR2_mips || BR2_mips64
# -m32 flag is used for 32bit builds and host tools have
# limited architecture support
depends on BR2_HOSTARCH = "x86_64" || BR2_HOSTARCH = "x86"
qt5webengine: new package This patch is based on works [1] and [2]. With this patch, one can run the Qt5 WebEngine quicknanobrowser sample with the following options. BR2_TOOLCHAIN_BUILDROOT_LIBC="glibc" and BR2_TOOLCHAIN_BUILDROOT_CXX (Qt 5 needs a toolchain w/ wchar, NPTL, C++, dynamic library; for now it builds only with glibc) BR2_PACKAGE_LIBERATION (Qt needs at least one font) BR2_PACKAGE_QT5BASE_EXAMPLES (to install quicknanobrowser sample) BR2_PACKAGE_QT5BASE_GIF (do display gif) BR2_PACKAGE_QT5BASE_JPEG (do display jpeg) BR2_PACKAGE_QT5BASE_PNG (do display png) BR2_PACKAGE_QT5QUICKCONTROLS (needed by webengine) BR2_PACKAGE_QT5QUICKCONTROLS2 (needed by webengine) BR2_PACKAGE_QT5WEBENGINE (because it is what we want) Qt WebEngine requires an Open(E)GL-capable backend. As an example, the package rpi-userland must be enabled to build for a rpi. BR2_PACKAGE_RPI_USERLAND (to enable OpenGL ES backend) To browse for HTTPS websites, please consider adding the following options as well for SSL/TLS. BR2_PACKAGE_CA_CERT (for certificates) BR2_PACKAGE_NTPD (to sync date for certificates) Since version 5.9, chromium requires udev at runtime (see note 4). BR2_ROOTFS_DEVICE_CREATION_DYNAMIC_EUDEV (input backend) To run quicknanobrowser # cd /usr/lib/qt/examples/webengine/quicknanobrowser/ # ./quicknanobrowser https://www.buildroot.org/ Note: The chromium.inc has been generated using the following command. ( echo 'CHROMIUM_LICENSE_FILES = \' && cd output/build/qt5webengine-5.9.1/ && \ find "src/3rdparty/chromium/" -type f -iname "*LICENSE*" -o -iname "*COPYING*" -o -iname "*GPL*" | \ sed -e '/\.asm$/d' \ -e '/\.h$/d' \ -e '/\.c$/d' \ -e '/\.cc$/d' \ -e '/\.cpp$/d' \ -e '/\.pyc\?$/d' \ -e '/\.pl$/d' \ -e '/\.sha1$/d' \ -e '/\.patch$/d' \ -e '/licensecheck/d' \ -e 's,^,\t,' \ -e 's,$, \\,' | \ sort && \ echo '' ) >package/qt5/qt5webengine/chromium.inc Note 2: Since 5.9.1, the chromium's copy of opus fails with neon [3]. Qt WebEngine can uses buildroot ffmpeg copy which compiles fine (using qmake flag WEBENGINE_CONFIG+=use_system_ffmpeg). It implies selecting the following options. BR2_PACKAGE_FFMPEG BR2_PACKAGE_OPUS BR2_PACKAGE_LIBVPX BR2_PACKAGE_WEBP BR2_PACKAGE_WEBP_DEMUX In file included from ../../3rdparty/chromium/third_party/opus/src/silk/arm/NSQ_neon.c:31:0: /home/gportay/src/buildroot/output-rpi3-qt5.9/host/lib/gcc/arm-buildroot-linux-gnueabihf/6.4.0/include/arm_neon.h:8997:1: error: inlining failed in call to always_inline ‘vld1q_s32’: target specific option mismatch vld1q_s32 (const int32_t * __a) ^~~~~~~~~ ../../3rdparty/chromium/third_party/opus/src/silk/arm/NSQ_neon.c:40:15: note: called from here int32x4_t coef0 = vld1q_s32(coef32); ^~~~~ ../../3rdparty/chromium/third_party/opus/src/silk/arm/NSQ_neon.c: At top level: cc1: warning: unrecognized command line option ‘-Wno-#pragma-messages’ Note 3: Version 5.6.2 causes a build issue while building chromium. The build against this version is disabled until the release 5.6.3 is out. Note 4: Here is trace when udev does not run # cd /usr/lib/qt/examples/webengine/quicknanobrowser # ./quicknanobrowser QStandardPaths: XDG_RUNTIME_DIR not set, defaulting to '/tmp/runtime-root' Unable to query physical screen size, defaulting to 100 dpi. To override, set QT_QPA_EGLFS_PHYSICAL_WIDTH and QT_QPA_EGLFS_PHYSICAL_HEIGHT (in millimeters). [0101/000248.161973:WARNING:resource_bundle_qt.cpp(114)] locale_file_path.empty() for locale [0101/000248.384693:WARNING:resource_bundle_qt.cpp(114)] locale_file_path.empty() for locale [202:223:0101/000248.484954:FATAL:udev_loader.cc(38)] Check failed: false. #0 0x0000742b93de <unknown> #1 0x0000742c3c38 <unknown> #2 0x000073e1e1aa <unknown> #3 0x000073e1d96e <unknown> #4 0x000073e1defa <unknown> #5 0x000074af6364 <unknown> #6 0x000074302878 <unknown> #7 0x0000742c8fee <unknown> #8 0x0000742c9f44 <unknown> #9 0x0000742ca21e <unknown> #10 0x0000742cac4c <unknown> #11 0x0000742c87b2 <unknown> #12 0x0000742da4f6 <unknown> #13 0x000073ed9d38 <unknown> #14 0x000073eda03c <unknown> #15 0x0000742e9aec <unknown> #16 0x0000742e71dc <unknown> Aborted Note 5: On rpi and depending on what is insinde the .config, more GPU memory should be allocated to run properly qt samples. #0 0x0000742c63de <unknown> #1 0x0000742d0c38 <unknown> #2 0x0000749d7bde <unknown> #3 0x0000749e3c70 <unknown> #4 0x00007530227c <unknown> #5 0x000075302480 <unknown> #6 0x0000752fb1e4 <unknown> #7 0x00007430f878 <unknown> #8 0x0000742d5fee <unknown> #9 0x0000742d6f44 <unknown> #10 0x0000742d721e <unknown> #11 0x0000742d7ad6 <unknown> #12 0x0000742d57b2 <unknown> #13 0x0000742e74f6 <unknown> #14 0x0000742f6a74 <unknown> #15 0x0000742f41dc <unknown> Received signal 6 #0 0x0000742c63de <unknown> #1 0x0000742c66a0 <unknown> #2 0x0000725b5d10 <unknown> [end of stack trace] qml: Render process exited with code 256 (abnormal exit) # mount /dev/mmcblk0p1 /mnt # sed '/^gpu_mem_/s,=.*,=200,' -i /mnt/config.txt # umount /mnt Note 6: The first patch fixes a build issue when samples are compiled without the support of printing [4]. This patch is already merged in branch 5.9 [5] and concerns only 5.9.1. 085c2c52 Always compile QWebEnginePage::print It fixes the error below. .obj/browsermainwindow.o: In function `BrowserMainWindow::printRequested(QWebEnginePage*)': browsermainwindow.cpp:(.text+0x2cc0): undefined reference to `QWebEnginePage::print(QPrinter*, QWebEngineCallback<bool> const&)' The second patch loads both libEGL and libGLESv2 symbols implicitly instead of loading them with explicitly using hard-coded locations. It fixes a bug when providers of lib*GL does not create libraries named libEGL.so.1 and libGLESv2.s2 [6]. This patch is already merged in branch 5.9 [7]. d4c621f6 Load libEGL and libGLES2 symbols implicitly It fixes the error below. [327:347:1221/085837:ERROR:surface_factory_qt.cpp(68)] Failed to load /usr/lib/libGLESv2.so.2: /usr/lib/libGLESv2.so.2: cannot open shared object file: No such file or directory [1]: http://lists.busybox.net/pipermail/buildroot/2015-July/132010.html [2]: https://patchwork.ozlabs.org/patch/640633/ [3]: https://patchwork.ozlabs.org/patch/791332/ [4]: https://bugreports.qt.io/browse/QTBUG-61510 [5]: https://codereview.qt-project.org/#/c/198041/ [6]: https://bugreports.qt.io/browse/QTBUG-57761 [7]: https://codereview.qt-project.org/#/c/199554/ Cc: Akihiko Odaki <akihiko.odaki.4i@stu.hosei.ac.jp> Cc: Julien Corjon <corjon.j@ecagroup.com> Signed-off-by: Gaël PORTAY <gael.portay@savoirfairelinux.com> [Arnout: - move more dependencies to _ARCH_DEPENDS; - mention all toolchain dependencies in the comments] Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
2017-08-15 22:38:53 +02:00
depends on BR2_PACKAGE_QT5_JSCORE_AVAILABLE # qt5declarative
depends on !BR2_BINFMT_FLAT # qt5base-icu
depends on BR2_USE_MMU # libglib2, qt5base-dbus
comment "qt5webengine needs udev /dev management and a glibc toolchain w/ gcc >= 4.8, host gcc >= 4.8, threads, wchar"
depends on BR2_PACKAGE_QT5WEBENGINE_ARCH_SUPPORTS
depends on !BR2_PACKAGE_HAS_UDEV || !BR2_TOOLCHAIN_USES_GLIBC || \
!BR2_HOST_GCC_AT_LEAST_4_8 || !BR2_TOOLCHAIN_GCC_AT_LEAST_4_8 || \
!BR2_TOOLCHAIN_HAS_THREADS || !BR2_USE_WCHAR
comment "qt5webengine needs an OpenGL and EGL-capable backend"
depends on BR2_PACKAGE_QT5WEBENGINE_ARCH_SUPPORTS
depends on !BR2_PACKAGE_QT5_GL_AVAILABLE || !BR2_PACKAGE_HAS_LIBEGL
comment "qt5webengine needs a toolchain not affected by GCC bug 85862"
depends on BR2_PACKAGE_QT5WEBENGINE_ARCH_SUPPORTS
depends on !BR2_PACKAGE_QT5_VERSION_5_6
depends on BR2_TOOLCHAIN_HAS_GCC_BUG_85862 # libnss
qt5webengine: new package This patch is based on works [1] and [2]. With this patch, one can run the Qt5 WebEngine quicknanobrowser sample with the following options. BR2_TOOLCHAIN_BUILDROOT_LIBC="glibc" and BR2_TOOLCHAIN_BUILDROOT_CXX (Qt 5 needs a toolchain w/ wchar, NPTL, C++, dynamic library; for now it builds only with glibc) BR2_PACKAGE_LIBERATION (Qt needs at least one font) BR2_PACKAGE_QT5BASE_EXAMPLES (to install quicknanobrowser sample) BR2_PACKAGE_QT5BASE_GIF (do display gif) BR2_PACKAGE_QT5BASE_JPEG (do display jpeg) BR2_PACKAGE_QT5BASE_PNG (do display png) BR2_PACKAGE_QT5QUICKCONTROLS (needed by webengine) BR2_PACKAGE_QT5QUICKCONTROLS2 (needed by webengine) BR2_PACKAGE_QT5WEBENGINE (because it is what we want) Qt WebEngine requires an Open(E)GL-capable backend. As an example, the package rpi-userland must be enabled to build for a rpi. BR2_PACKAGE_RPI_USERLAND (to enable OpenGL ES backend) To browse for HTTPS websites, please consider adding the following options as well for SSL/TLS. BR2_PACKAGE_CA_CERT (for certificates) BR2_PACKAGE_NTPD (to sync date for certificates) Since version 5.9, chromium requires udev at runtime (see note 4). BR2_ROOTFS_DEVICE_CREATION_DYNAMIC_EUDEV (input backend) To run quicknanobrowser # cd /usr/lib/qt/examples/webengine/quicknanobrowser/ # ./quicknanobrowser https://www.buildroot.org/ Note: The chromium.inc has been generated using the following command. ( echo 'CHROMIUM_LICENSE_FILES = \' && cd output/build/qt5webengine-5.9.1/ && \ find "src/3rdparty/chromium/" -type f -iname "*LICENSE*" -o -iname "*COPYING*" -o -iname "*GPL*" | \ sed -e '/\.asm$/d' \ -e '/\.h$/d' \ -e '/\.c$/d' \ -e '/\.cc$/d' \ -e '/\.cpp$/d' \ -e '/\.pyc\?$/d' \ -e '/\.pl$/d' \ -e '/\.sha1$/d' \ -e '/\.patch$/d' \ -e '/licensecheck/d' \ -e 's,^,\t,' \ -e 's,$, \\,' | \ sort && \ echo '' ) >package/qt5/qt5webengine/chromium.inc Note 2: Since 5.9.1, the chromium's copy of opus fails with neon [3]. Qt WebEngine can uses buildroot ffmpeg copy which compiles fine (using qmake flag WEBENGINE_CONFIG+=use_system_ffmpeg). It implies selecting the following options. BR2_PACKAGE_FFMPEG BR2_PACKAGE_OPUS BR2_PACKAGE_LIBVPX BR2_PACKAGE_WEBP BR2_PACKAGE_WEBP_DEMUX In file included from ../../3rdparty/chromium/third_party/opus/src/silk/arm/NSQ_neon.c:31:0: /home/gportay/src/buildroot/output-rpi3-qt5.9/host/lib/gcc/arm-buildroot-linux-gnueabihf/6.4.0/include/arm_neon.h:8997:1: error: inlining failed in call to always_inline ‘vld1q_s32’: target specific option mismatch vld1q_s32 (const int32_t * __a) ^~~~~~~~~ ../../3rdparty/chromium/third_party/opus/src/silk/arm/NSQ_neon.c:40:15: note: called from here int32x4_t coef0 = vld1q_s32(coef32); ^~~~~ ../../3rdparty/chromium/third_party/opus/src/silk/arm/NSQ_neon.c: At top level: cc1: warning: unrecognized command line option ‘-Wno-#pragma-messages’ Note 3: Version 5.6.2 causes a build issue while building chromium. The build against this version is disabled until the release 5.6.3 is out. Note 4: Here is trace when udev does not run # cd /usr/lib/qt/examples/webengine/quicknanobrowser # ./quicknanobrowser QStandardPaths: XDG_RUNTIME_DIR not set, defaulting to '/tmp/runtime-root' Unable to query physical screen size, defaulting to 100 dpi. To override, set QT_QPA_EGLFS_PHYSICAL_WIDTH and QT_QPA_EGLFS_PHYSICAL_HEIGHT (in millimeters). [0101/000248.161973:WARNING:resource_bundle_qt.cpp(114)] locale_file_path.empty() for locale [0101/000248.384693:WARNING:resource_bundle_qt.cpp(114)] locale_file_path.empty() for locale [202:223:0101/000248.484954:FATAL:udev_loader.cc(38)] Check failed: false. #0 0x0000742b93de <unknown> #1 0x0000742c3c38 <unknown> #2 0x000073e1e1aa <unknown> #3 0x000073e1d96e <unknown> #4 0x000073e1defa <unknown> #5 0x000074af6364 <unknown> #6 0x000074302878 <unknown> #7 0x0000742c8fee <unknown> #8 0x0000742c9f44 <unknown> #9 0x0000742ca21e <unknown> #10 0x0000742cac4c <unknown> #11 0x0000742c87b2 <unknown> #12 0x0000742da4f6 <unknown> #13 0x000073ed9d38 <unknown> #14 0x000073eda03c <unknown> #15 0x0000742e9aec <unknown> #16 0x0000742e71dc <unknown> Aborted Note 5: On rpi and depending on what is insinde the .config, more GPU memory should be allocated to run properly qt samples. #0 0x0000742c63de <unknown> #1 0x0000742d0c38 <unknown> #2 0x0000749d7bde <unknown> #3 0x0000749e3c70 <unknown> #4 0x00007530227c <unknown> #5 0x000075302480 <unknown> #6 0x0000752fb1e4 <unknown> #7 0x00007430f878 <unknown> #8 0x0000742d5fee <unknown> #9 0x0000742d6f44 <unknown> #10 0x0000742d721e <unknown> #11 0x0000742d7ad6 <unknown> #12 0x0000742d57b2 <unknown> #13 0x0000742e74f6 <unknown> #14 0x0000742f6a74 <unknown> #15 0x0000742f41dc <unknown> Received signal 6 #0 0x0000742c63de <unknown> #1 0x0000742c66a0 <unknown> #2 0x0000725b5d10 <unknown> [end of stack trace] qml: Render process exited with code 256 (abnormal exit) # mount /dev/mmcblk0p1 /mnt # sed '/^gpu_mem_/s,=.*,=200,' -i /mnt/config.txt # umount /mnt Note 6: The first patch fixes a build issue when samples are compiled without the support of printing [4]. This patch is already merged in branch 5.9 [5] and concerns only 5.9.1. 085c2c52 Always compile QWebEnginePage::print It fixes the error below. .obj/browsermainwindow.o: In function `BrowserMainWindow::printRequested(QWebEnginePage*)': browsermainwindow.cpp:(.text+0x2cc0): undefined reference to `QWebEnginePage::print(QPrinter*, QWebEngineCallback<bool> const&)' The second patch loads both libEGL and libGLESv2 symbols implicitly instead of loading them with explicitly using hard-coded locations. It fixes a bug when providers of lib*GL does not create libraries named libEGL.so.1 and libGLESv2.s2 [6]. This patch is already merged in branch 5.9 [7]. d4c621f6 Load libEGL and libGLES2 symbols implicitly It fixes the error below. [327:347:1221/085837:ERROR:surface_factory_qt.cpp(68)] Failed to load /usr/lib/libGLESv2.so.2: /usr/lib/libGLESv2.so.2: cannot open shared object file: No such file or directory [1]: http://lists.busybox.net/pipermail/buildroot/2015-July/132010.html [2]: https://patchwork.ozlabs.org/patch/640633/ [3]: https://patchwork.ozlabs.org/patch/791332/ [4]: https://bugreports.qt.io/browse/QTBUG-61510 [5]: https://codereview.qt-project.org/#/c/198041/ [6]: https://bugreports.qt.io/browse/QTBUG-57761 [7]: https://codereview.qt-project.org/#/c/199554/ Cc: Akihiko Odaki <akihiko.odaki.4i@stu.hosei.ac.jp> Cc: Julien Corjon <corjon.j@ecagroup.com> Signed-off-by: Gaël PORTAY <gael.portay@savoirfairelinux.com> [Arnout: - move more dependencies to _ARCH_DEPENDS; - mention all toolchain dependencies in the comments] Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
2017-08-15 22:38:53 +02:00
config BR2_PACKAGE_QT5WEBENGINE
bool "qt5webengine"
depends on BR2_PACKAGE_QT5WEBENGINE_ARCH_SUPPORTS
depends on BR2_TOOLCHAIN_USES_GLIBC # execinfo.h, mallinfo
depends on BR2_HOST_GCC_AT_LEAST_4_8 # qt5base-icu
depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_8 # qt5base-icu
depends on !BR2_TOOLCHAIN_HAS_GCC_BUG_85862 || BR2_PACKAGE_QT5_VERSION_5_6 # libnss
qt5webengine: new package This patch is based on works [1] and [2]. With this patch, one can run the Qt5 WebEngine quicknanobrowser sample with the following options. BR2_TOOLCHAIN_BUILDROOT_LIBC="glibc" and BR2_TOOLCHAIN_BUILDROOT_CXX (Qt 5 needs a toolchain w/ wchar, NPTL, C++, dynamic library; for now it builds only with glibc) BR2_PACKAGE_LIBERATION (Qt needs at least one font) BR2_PACKAGE_QT5BASE_EXAMPLES (to install quicknanobrowser sample) BR2_PACKAGE_QT5BASE_GIF (do display gif) BR2_PACKAGE_QT5BASE_JPEG (do display jpeg) BR2_PACKAGE_QT5BASE_PNG (do display png) BR2_PACKAGE_QT5QUICKCONTROLS (needed by webengine) BR2_PACKAGE_QT5QUICKCONTROLS2 (needed by webengine) BR2_PACKAGE_QT5WEBENGINE (because it is what we want) Qt WebEngine requires an Open(E)GL-capable backend. As an example, the package rpi-userland must be enabled to build for a rpi. BR2_PACKAGE_RPI_USERLAND (to enable OpenGL ES backend) To browse for HTTPS websites, please consider adding the following options as well for SSL/TLS. BR2_PACKAGE_CA_CERT (for certificates) BR2_PACKAGE_NTPD (to sync date for certificates) Since version 5.9, chromium requires udev at runtime (see note 4). BR2_ROOTFS_DEVICE_CREATION_DYNAMIC_EUDEV (input backend) To run quicknanobrowser # cd /usr/lib/qt/examples/webengine/quicknanobrowser/ # ./quicknanobrowser https://www.buildroot.org/ Note: The chromium.inc has been generated using the following command. ( echo 'CHROMIUM_LICENSE_FILES = \' && cd output/build/qt5webengine-5.9.1/ && \ find "src/3rdparty/chromium/" -type f -iname "*LICENSE*" -o -iname "*COPYING*" -o -iname "*GPL*" | \ sed -e '/\.asm$/d' \ -e '/\.h$/d' \ -e '/\.c$/d' \ -e '/\.cc$/d' \ -e '/\.cpp$/d' \ -e '/\.pyc\?$/d' \ -e '/\.pl$/d' \ -e '/\.sha1$/d' \ -e '/\.patch$/d' \ -e '/licensecheck/d' \ -e 's,^,\t,' \ -e 's,$, \\,' | \ sort && \ echo '' ) >package/qt5/qt5webengine/chromium.inc Note 2: Since 5.9.1, the chromium's copy of opus fails with neon [3]. Qt WebEngine can uses buildroot ffmpeg copy which compiles fine (using qmake flag WEBENGINE_CONFIG+=use_system_ffmpeg). It implies selecting the following options. BR2_PACKAGE_FFMPEG BR2_PACKAGE_OPUS BR2_PACKAGE_LIBVPX BR2_PACKAGE_WEBP BR2_PACKAGE_WEBP_DEMUX In file included from ../../3rdparty/chromium/third_party/opus/src/silk/arm/NSQ_neon.c:31:0: /home/gportay/src/buildroot/output-rpi3-qt5.9/host/lib/gcc/arm-buildroot-linux-gnueabihf/6.4.0/include/arm_neon.h:8997:1: error: inlining failed in call to always_inline ‘vld1q_s32’: target specific option mismatch vld1q_s32 (const int32_t * __a) ^~~~~~~~~ ../../3rdparty/chromium/third_party/opus/src/silk/arm/NSQ_neon.c:40:15: note: called from here int32x4_t coef0 = vld1q_s32(coef32); ^~~~~ ../../3rdparty/chromium/third_party/opus/src/silk/arm/NSQ_neon.c: At top level: cc1: warning: unrecognized command line option ‘-Wno-#pragma-messages’ Note 3: Version 5.6.2 causes a build issue while building chromium. The build against this version is disabled until the release 5.6.3 is out. Note 4: Here is trace when udev does not run # cd /usr/lib/qt/examples/webengine/quicknanobrowser # ./quicknanobrowser QStandardPaths: XDG_RUNTIME_DIR not set, defaulting to '/tmp/runtime-root' Unable to query physical screen size, defaulting to 100 dpi. To override, set QT_QPA_EGLFS_PHYSICAL_WIDTH and QT_QPA_EGLFS_PHYSICAL_HEIGHT (in millimeters). [0101/000248.161973:WARNING:resource_bundle_qt.cpp(114)] locale_file_path.empty() for locale [0101/000248.384693:WARNING:resource_bundle_qt.cpp(114)] locale_file_path.empty() for locale [202:223:0101/000248.484954:FATAL:udev_loader.cc(38)] Check failed: false. #0 0x0000742b93de <unknown> #1 0x0000742c3c38 <unknown> #2 0x000073e1e1aa <unknown> #3 0x000073e1d96e <unknown> #4 0x000073e1defa <unknown> #5 0x000074af6364 <unknown> #6 0x000074302878 <unknown> #7 0x0000742c8fee <unknown> #8 0x0000742c9f44 <unknown> #9 0x0000742ca21e <unknown> #10 0x0000742cac4c <unknown> #11 0x0000742c87b2 <unknown> #12 0x0000742da4f6 <unknown> #13 0x000073ed9d38 <unknown> #14 0x000073eda03c <unknown> #15 0x0000742e9aec <unknown> #16 0x0000742e71dc <unknown> Aborted Note 5: On rpi and depending on what is insinde the .config, more GPU memory should be allocated to run properly qt samples. #0 0x0000742c63de <unknown> #1 0x0000742d0c38 <unknown> #2 0x0000749d7bde <unknown> #3 0x0000749e3c70 <unknown> #4 0x00007530227c <unknown> #5 0x000075302480 <unknown> #6 0x0000752fb1e4 <unknown> #7 0x00007430f878 <unknown> #8 0x0000742d5fee <unknown> #9 0x0000742d6f44 <unknown> #10 0x0000742d721e <unknown> #11 0x0000742d7ad6 <unknown> #12 0x0000742d57b2 <unknown> #13 0x0000742e74f6 <unknown> #14 0x0000742f6a74 <unknown> #15 0x0000742f41dc <unknown> Received signal 6 #0 0x0000742c63de <unknown> #1 0x0000742c66a0 <unknown> #2 0x0000725b5d10 <unknown> [end of stack trace] qml: Render process exited with code 256 (abnormal exit) # mount /dev/mmcblk0p1 /mnt # sed '/^gpu_mem_/s,=.*,=200,' -i /mnt/config.txt # umount /mnt Note 6: The first patch fixes a build issue when samples are compiled without the support of printing [4]. This patch is already merged in branch 5.9 [5] and concerns only 5.9.1. 085c2c52 Always compile QWebEnginePage::print It fixes the error below. .obj/browsermainwindow.o: In function `BrowserMainWindow::printRequested(QWebEnginePage*)': browsermainwindow.cpp:(.text+0x2cc0): undefined reference to `QWebEnginePage::print(QPrinter*, QWebEngineCallback<bool> const&)' The second patch loads both libEGL and libGLESv2 symbols implicitly instead of loading them with explicitly using hard-coded locations. It fixes a bug when providers of lib*GL does not create libraries named libEGL.so.1 and libGLESv2.s2 [6]. This patch is already merged in branch 5.9 [7]. d4c621f6 Load libEGL and libGLES2 symbols implicitly It fixes the error below. [327:347:1221/085837:ERROR:surface_factory_qt.cpp(68)] Failed to load /usr/lib/libGLESv2.so.2: /usr/lib/libGLESv2.so.2: cannot open shared object file: No such file or directory [1]: http://lists.busybox.net/pipermail/buildroot/2015-July/132010.html [2]: https://patchwork.ozlabs.org/patch/640633/ [3]: https://patchwork.ozlabs.org/patch/791332/ [4]: https://bugreports.qt.io/browse/QTBUG-61510 [5]: https://codereview.qt-project.org/#/c/198041/ [6]: https://bugreports.qt.io/browse/QTBUG-57761 [7]: https://codereview.qt-project.org/#/c/199554/ Cc: Akihiko Odaki <akihiko.odaki.4i@stu.hosei.ac.jp> Cc: Julien Corjon <corjon.j@ecagroup.com> Signed-off-by: Gaël PORTAY <gael.portay@savoirfairelinux.com> [Arnout: - move more dependencies to _ARCH_DEPENDS; - mention all toolchain dependencies in the comments] Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
2017-08-15 22:38:53 +02:00
depends on BR2_TOOLCHAIN_HAS_THREADS # libglib2, libvpx, qt5base-dbus
depends on BR2_USE_WCHAR # libglib2
depends on BR2_PACKAGE_QT5_GL_AVAILABLE # qt5declarative, qt5base-eglfs
qt5webengine: new package This patch is based on works [1] and [2]. With this patch, one can run the Qt5 WebEngine quicknanobrowser sample with the following options. BR2_TOOLCHAIN_BUILDROOT_LIBC="glibc" and BR2_TOOLCHAIN_BUILDROOT_CXX (Qt 5 needs a toolchain w/ wchar, NPTL, C++, dynamic library; for now it builds only with glibc) BR2_PACKAGE_LIBERATION (Qt needs at least one font) BR2_PACKAGE_QT5BASE_EXAMPLES (to install quicknanobrowser sample) BR2_PACKAGE_QT5BASE_GIF (do display gif) BR2_PACKAGE_QT5BASE_JPEG (do display jpeg) BR2_PACKAGE_QT5BASE_PNG (do display png) BR2_PACKAGE_QT5QUICKCONTROLS (needed by webengine) BR2_PACKAGE_QT5QUICKCONTROLS2 (needed by webengine) BR2_PACKAGE_QT5WEBENGINE (because it is what we want) Qt WebEngine requires an Open(E)GL-capable backend. As an example, the package rpi-userland must be enabled to build for a rpi. BR2_PACKAGE_RPI_USERLAND (to enable OpenGL ES backend) To browse for HTTPS websites, please consider adding the following options as well for SSL/TLS. BR2_PACKAGE_CA_CERT (for certificates) BR2_PACKAGE_NTPD (to sync date for certificates) Since version 5.9, chromium requires udev at runtime (see note 4). BR2_ROOTFS_DEVICE_CREATION_DYNAMIC_EUDEV (input backend) To run quicknanobrowser # cd /usr/lib/qt/examples/webengine/quicknanobrowser/ # ./quicknanobrowser https://www.buildroot.org/ Note: The chromium.inc has been generated using the following command. ( echo 'CHROMIUM_LICENSE_FILES = \' && cd output/build/qt5webengine-5.9.1/ && \ find "src/3rdparty/chromium/" -type f -iname "*LICENSE*" -o -iname "*COPYING*" -o -iname "*GPL*" | \ sed -e '/\.asm$/d' \ -e '/\.h$/d' \ -e '/\.c$/d' \ -e '/\.cc$/d' \ -e '/\.cpp$/d' \ -e '/\.pyc\?$/d' \ -e '/\.pl$/d' \ -e '/\.sha1$/d' \ -e '/\.patch$/d' \ -e '/licensecheck/d' \ -e 's,^,\t,' \ -e 's,$, \\,' | \ sort && \ echo '' ) >package/qt5/qt5webengine/chromium.inc Note 2: Since 5.9.1, the chromium's copy of opus fails with neon [3]. Qt WebEngine can uses buildroot ffmpeg copy which compiles fine (using qmake flag WEBENGINE_CONFIG+=use_system_ffmpeg). It implies selecting the following options. BR2_PACKAGE_FFMPEG BR2_PACKAGE_OPUS BR2_PACKAGE_LIBVPX BR2_PACKAGE_WEBP BR2_PACKAGE_WEBP_DEMUX In file included from ../../3rdparty/chromium/third_party/opus/src/silk/arm/NSQ_neon.c:31:0: /home/gportay/src/buildroot/output-rpi3-qt5.9/host/lib/gcc/arm-buildroot-linux-gnueabihf/6.4.0/include/arm_neon.h:8997:1: error: inlining failed in call to always_inline ‘vld1q_s32’: target specific option mismatch vld1q_s32 (const int32_t * __a) ^~~~~~~~~ ../../3rdparty/chromium/third_party/opus/src/silk/arm/NSQ_neon.c:40:15: note: called from here int32x4_t coef0 = vld1q_s32(coef32); ^~~~~ ../../3rdparty/chromium/third_party/opus/src/silk/arm/NSQ_neon.c: At top level: cc1: warning: unrecognized command line option ‘-Wno-#pragma-messages’ Note 3: Version 5.6.2 causes a build issue while building chromium. The build against this version is disabled until the release 5.6.3 is out. Note 4: Here is trace when udev does not run # cd /usr/lib/qt/examples/webengine/quicknanobrowser # ./quicknanobrowser QStandardPaths: XDG_RUNTIME_DIR not set, defaulting to '/tmp/runtime-root' Unable to query physical screen size, defaulting to 100 dpi. To override, set QT_QPA_EGLFS_PHYSICAL_WIDTH and QT_QPA_EGLFS_PHYSICAL_HEIGHT (in millimeters). [0101/000248.161973:WARNING:resource_bundle_qt.cpp(114)] locale_file_path.empty() for locale [0101/000248.384693:WARNING:resource_bundle_qt.cpp(114)] locale_file_path.empty() for locale [202:223:0101/000248.484954:FATAL:udev_loader.cc(38)] Check failed: false. #0 0x0000742b93de <unknown> #1 0x0000742c3c38 <unknown> #2 0x000073e1e1aa <unknown> #3 0x000073e1d96e <unknown> #4 0x000073e1defa <unknown> #5 0x000074af6364 <unknown> #6 0x000074302878 <unknown> #7 0x0000742c8fee <unknown> #8 0x0000742c9f44 <unknown> #9 0x0000742ca21e <unknown> #10 0x0000742cac4c <unknown> #11 0x0000742c87b2 <unknown> #12 0x0000742da4f6 <unknown> #13 0x000073ed9d38 <unknown> #14 0x000073eda03c <unknown> #15 0x0000742e9aec <unknown> #16 0x0000742e71dc <unknown> Aborted Note 5: On rpi and depending on what is insinde the .config, more GPU memory should be allocated to run properly qt samples. #0 0x0000742c63de <unknown> #1 0x0000742d0c38 <unknown> #2 0x0000749d7bde <unknown> #3 0x0000749e3c70 <unknown> #4 0x00007530227c <unknown> #5 0x000075302480 <unknown> #6 0x0000752fb1e4 <unknown> #7 0x00007430f878 <unknown> #8 0x0000742d5fee <unknown> #9 0x0000742d6f44 <unknown> #10 0x0000742d721e <unknown> #11 0x0000742d7ad6 <unknown> #12 0x0000742d57b2 <unknown> #13 0x0000742e74f6 <unknown> #14 0x0000742f6a74 <unknown> #15 0x0000742f41dc <unknown> Received signal 6 #0 0x0000742c63de <unknown> #1 0x0000742c66a0 <unknown> #2 0x0000725b5d10 <unknown> [end of stack trace] qml: Render process exited with code 256 (abnormal exit) # mount /dev/mmcblk0p1 /mnt # sed '/^gpu_mem_/s,=.*,=200,' -i /mnt/config.txt # umount /mnt Note 6: The first patch fixes a build issue when samples are compiled without the support of printing [4]. This patch is already merged in branch 5.9 [5] and concerns only 5.9.1. 085c2c52 Always compile QWebEnginePage::print It fixes the error below. .obj/browsermainwindow.o: In function `BrowserMainWindow::printRequested(QWebEnginePage*)': browsermainwindow.cpp:(.text+0x2cc0): undefined reference to `QWebEnginePage::print(QPrinter*, QWebEngineCallback<bool> const&)' The second patch loads both libEGL and libGLESv2 symbols implicitly instead of loading them with explicitly using hard-coded locations. It fixes a bug when providers of lib*GL does not create libraries named libEGL.so.1 and libGLESv2.s2 [6]. This patch is already merged in branch 5.9 [7]. d4c621f6 Load libEGL and libGLES2 symbols implicitly It fixes the error below. [327:347:1221/085837:ERROR:surface_factory_qt.cpp(68)] Failed to load /usr/lib/libGLESv2.so.2: /usr/lib/libGLESv2.so.2: cannot open shared object file: No such file or directory [1]: http://lists.busybox.net/pipermail/buildroot/2015-July/132010.html [2]: https://patchwork.ozlabs.org/patch/640633/ [3]: https://patchwork.ozlabs.org/patch/791332/ [4]: https://bugreports.qt.io/browse/QTBUG-61510 [5]: https://codereview.qt-project.org/#/c/198041/ [6]: https://bugreports.qt.io/browse/QTBUG-57761 [7]: https://codereview.qt-project.org/#/c/199554/ Cc: Akihiko Odaki <akihiko.odaki.4i@stu.hosei.ac.jp> Cc: Julien Corjon <corjon.j@ecagroup.com> Signed-off-by: Gaël PORTAY <gael.portay@savoirfairelinux.com> [Arnout: - move more dependencies to _ARCH_DEPENDS; - mention all toolchain dependencies in the comments] Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
2017-08-15 22:38:53 +02:00
depends on BR2_PACKAGE_HAS_LIBEGL # qt5base-eglfs
depends on BR2_PACKAGE_HAS_UDEV
# v8 (a chromium 3rd-party) compiles its internal host-tools with the
# same word size as the target. For 32-bits targets, it adds the -m32
# flag (for 64-bits, it adds the -m64 flag).
# https://github.com/v8/v8/blob/5.6.326.55/gypfiles/toolchain.gypi#L1036-L1037
select BR2_HOSTARCH_NEEDS_IA32_COMPILER if !BR2_ARCH_IS_64 # v8/chromium
select BR2_PACKAGE_FFMPEG
select BR2_PACKAGE_LIBGLIB2
qt5: bump latest version to 5.10.1 The tarball filename has changed since 5.10. The module suffix *opensource-src* has changed to *everywhere-src*. I introduced the *QT5_SOURCE_TARBALL_PREFIX* variable to set the right filename according to the Qt version. qtwebengine: Select libnss. It is a requirement[1] because OpenSSL certificate validation[2] and NSS bundle[3] was dropped. Add host-libnss and host-libpng to satisfy new requirement to build an internal host-tool. Set ninja host pkg-config tool using environment variable $GN_PKG_CONFIG_HOST[4]. The build system uses pkg-config to get package data for both host and target architectures. Using the same call to pkg-config for both target and host leads to build mismatches: it tries to link a host-tool using target libraries. qt5base: sqlite plugin now uses sqlite3_column_table_name16() so select BR2_PACKAGE_SQLITE_ENABLE_COLUMN_METADATA to make sure it is available. qt5multimedia: libqgsttools was renamed to libQtMultimediaGstTools. The latter name matches the libQt5Multimedia*.so.* pattern so no additional copy command is needed for it anymore. qt5xmlpatterns: Names of the license files have changed: LICENSE.(L)GPLv3 -> LICENSE.(L)GPL3. The new files in fact already existed in 5.9.4 but the old ones were not removed yet. The new files are slightly different: there used to be a Qt header in front of it which is now removed. Also LICENSE.LGPL3 is rewrapped. qt5location, qt5quickcontrols, qt5serialport: Same license files issue, and for LICENSE.GPLv2 as well. LICENSE.GPL2 has the "How to Apply These Terms to Your New Programs" text appended to it. qt5script: Similar license file issues, but the new license files were not present yet. LICENSE.GPLv21 was removed so there is no longer a license file for the LGPL-2.1-covered Qt code. [1]: https://github.com/qt/qtwebengine/commit/9b449045fbd5fd3b58bcaff6cf0c5878cd6e64eb [2]: https://codereview.chromium.org/2862543003 [3]: https://codereview.chromium.org/1882433002 [4]: https://github.com/qt/qtwebengine/blob/v5.10.1/src/core/config/linux.pri#L111-L125 Signed-off-by: Gaël PORTAY <gael.portay@savoirfairelinux.com> [Peter: - fix sqlite plugin support in qt5base; - fix target installation of qt5multimedia ] Signed-off-by: Peter Seiderer <ps.report@gmx.net> [Arnout: - create a local host-pkg-config tool instead of extending pkgconf; - pass the same options to host-pkg-config as we do for other packages; - carry the EGL mesa3d X11 headers patch; - update license file names and hashes ] Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
2018-03-15 20:50:54 +01:00
select BR2_PACKAGE_LIBNSS if !BR2_PACKAGE_QT5_VERSION_5_6
qt5webengine: new package This patch is based on works [1] and [2]. With this patch, one can run the Qt5 WebEngine quicknanobrowser sample with the following options. BR2_TOOLCHAIN_BUILDROOT_LIBC="glibc" and BR2_TOOLCHAIN_BUILDROOT_CXX (Qt 5 needs a toolchain w/ wchar, NPTL, C++, dynamic library; for now it builds only with glibc) BR2_PACKAGE_LIBERATION (Qt needs at least one font) BR2_PACKAGE_QT5BASE_EXAMPLES (to install quicknanobrowser sample) BR2_PACKAGE_QT5BASE_GIF (do display gif) BR2_PACKAGE_QT5BASE_JPEG (do display jpeg) BR2_PACKAGE_QT5BASE_PNG (do display png) BR2_PACKAGE_QT5QUICKCONTROLS (needed by webengine) BR2_PACKAGE_QT5QUICKCONTROLS2 (needed by webengine) BR2_PACKAGE_QT5WEBENGINE (because it is what we want) Qt WebEngine requires an Open(E)GL-capable backend. As an example, the package rpi-userland must be enabled to build for a rpi. BR2_PACKAGE_RPI_USERLAND (to enable OpenGL ES backend) To browse for HTTPS websites, please consider adding the following options as well for SSL/TLS. BR2_PACKAGE_CA_CERT (for certificates) BR2_PACKAGE_NTPD (to sync date for certificates) Since version 5.9, chromium requires udev at runtime (see note 4). BR2_ROOTFS_DEVICE_CREATION_DYNAMIC_EUDEV (input backend) To run quicknanobrowser # cd /usr/lib/qt/examples/webengine/quicknanobrowser/ # ./quicknanobrowser https://www.buildroot.org/ Note: The chromium.inc has been generated using the following command. ( echo 'CHROMIUM_LICENSE_FILES = \' && cd output/build/qt5webengine-5.9.1/ && \ find "src/3rdparty/chromium/" -type f -iname "*LICENSE*" -o -iname "*COPYING*" -o -iname "*GPL*" | \ sed -e '/\.asm$/d' \ -e '/\.h$/d' \ -e '/\.c$/d' \ -e '/\.cc$/d' \ -e '/\.cpp$/d' \ -e '/\.pyc\?$/d' \ -e '/\.pl$/d' \ -e '/\.sha1$/d' \ -e '/\.patch$/d' \ -e '/licensecheck/d' \ -e 's,^,\t,' \ -e 's,$, \\,' | \ sort && \ echo '' ) >package/qt5/qt5webengine/chromium.inc Note 2: Since 5.9.1, the chromium's copy of opus fails with neon [3]. Qt WebEngine can uses buildroot ffmpeg copy which compiles fine (using qmake flag WEBENGINE_CONFIG+=use_system_ffmpeg). It implies selecting the following options. BR2_PACKAGE_FFMPEG BR2_PACKAGE_OPUS BR2_PACKAGE_LIBVPX BR2_PACKAGE_WEBP BR2_PACKAGE_WEBP_DEMUX In file included from ../../3rdparty/chromium/third_party/opus/src/silk/arm/NSQ_neon.c:31:0: /home/gportay/src/buildroot/output-rpi3-qt5.9/host/lib/gcc/arm-buildroot-linux-gnueabihf/6.4.0/include/arm_neon.h:8997:1: error: inlining failed in call to always_inline ‘vld1q_s32’: target specific option mismatch vld1q_s32 (const int32_t * __a) ^~~~~~~~~ ../../3rdparty/chromium/third_party/opus/src/silk/arm/NSQ_neon.c:40:15: note: called from here int32x4_t coef0 = vld1q_s32(coef32); ^~~~~ ../../3rdparty/chromium/third_party/opus/src/silk/arm/NSQ_neon.c: At top level: cc1: warning: unrecognized command line option ‘-Wno-#pragma-messages’ Note 3: Version 5.6.2 causes a build issue while building chromium. The build against this version is disabled until the release 5.6.3 is out. Note 4: Here is trace when udev does not run # cd /usr/lib/qt/examples/webengine/quicknanobrowser # ./quicknanobrowser QStandardPaths: XDG_RUNTIME_DIR not set, defaulting to '/tmp/runtime-root' Unable to query physical screen size, defaulting to 100 dpi. To override, set QT_QPA_EGLFS_PHYSICAL_WIDTH and QT_QPA_EGLFS_PHYSICAL_HEIGHT (in millimeters). [0101/000248.161973:WARNING:resource_bundle_qt.cpp(114)] locale_file_path.empty() for locale [0101/000248.384693:WARNING:resource_bundle_qt.cpp(114)] locale_file_path.empty() for locale [202:223:0101/000248.484954:FATAL:udev_loader.cc(38)] Check failed: false. #0 0x0000742b93de <unknown> #1 0x0000742c3c38 <unknown> #2 0x000073e1e1aa <unknown> #3 0x000073e1d96e <unknown> #4 0x000073e1defa <unknown> #5 0x000074af6364 <unknown> #6 0x000074302878 <unknown> #7 0x0000742c8fee <unknown> #8 0x0000742c9f44 <unknown> #9 0x0000742ca21e <unknown> #10 0x0000742cac4c <unknown> #11 0x0000742c87b2 <unknown> #12 0x0000742da4f6 <unknown> #13 0x000073ed9d38 <unknown> #14 0x000073eda03c <unknown> #15 0x0000742e9aec <unknown> #16 0x0000742e71dc <unknown> Aborted Note 5: On rpi and depending on what is insinde the .config, more GPU memory should be allocated to run properly qt samples. #0 0x0000742c63de <unknown> #1 0x0000742d0c38 <unknown> #2 0x0000749d7bde <unknown> #3 0x0000749e3c70 <unknown> #4 0x00007530227c <unknown> #5 0x000075302480 <unknown> #6 0x0000752fb1e4 <unknown> #7 0x00007430f878 <unknown> #8 0x0000742d5fee <unknown> #9 0x0000742d6f44 <unknown> #10 0x0000742d721e <unknown> #11 0x0000742d7ad6 <unknown> #12 0x0000742d57b2 <unknown> #13 0x0000742e74f6 <unknown> #14 0x0000742f6a74 <unknown> #15 0x0000742f41dc <unknown> Received signal 6 #0 0x0000742c63de <unknown> #1 0x0000742c66a0 <unknown> #2 0x0000725b5d10 <unknown> [end of stack trace] qml: Render process exited with code 256 (abnormal exit) # mount /dev/mmcblk0p1 /mnt # sed '/^gpu_mem_/s,=.*,=200,' -i /mnt/config.txt # umount /mnt Note 6: The first patch fixes a build issue when samples are compiled without the support of printing [4]. This patch is already merged in branch 5.9 [5] and concerns only 5.9.1. 085c2c52 Always compile QWebEnginePage::print It fixes the error below. .obj/browsermainwindow.o: In function `BrowserMainWindow::printRequested(QWebEnginePage*)': browsermainwindow.cpp:(.text+0x2cc0): undefined reference to `QWebEnginePage::print(QPrinter*, QWebEngineCallback<bool> const&)' The second patch loads both libEGL and libGLESv2 symbols implicitly instead of loading them with explicitly using hard-coded locations. It fixes a bug when providers of lib*GL does not create libraries named libEGL.so.1 and libGLESv2.s2 [6]. This patch is already merged in branch 5.9 [7]. d4c621f6 Load libEGL and libGLES2 symbols implicitly It fixes the error below. [327:347:1221/085837:ERROR:surface_factory_qt.cpp(68)] Failed to load /usr/lib/libGLESv2.so.2: /usr/lib/libGLESv2.so.2: cannot open shared object file: No such file or directory [1]: http://lists.busybox.net/pipermail/buildroot/2015-July/132010.html [2]: https://patchwork.ozlabs.org/patch/640633/ [3]: https://patchwork.ozlabs.org/patch/791332/ [4]: https://bugreports.qt.io/browse/QTBUG-61510 [5]: https://codereview.qt-project.org/#/c/198041/ [6]: https://bugreports.qt.io/browse/QTBUG-57761 [7]: https://codereview.qt-project.org/#/c/199554/ Cc: Akihiko Odaki <akihiko.odaki.4i@stu.hosei.ac.jp> Cc: Julien Corjon <corjon.j@ecagroup.com> Signed-off-by: Gaël PORTAY <gael.portay@savoirfairelinux.com> [Arnout: - move more dependencies to _ARCH_DEPENDS; - mention all toolchain dependencies in the comments] Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
2017-08-15 22:38:53 +02:00
select BR2_PACKAGE_LIBVPX
select BR2_PACKAGE_OPUS
select BR2_PACKAGE_WEBP
select BR2_PACKAGE_WEBP_DEMUX
select BR2_PACKAGE_QT5BASE_DBUS
select BR2_PACKAGE_QT5BASE_EGLFS
select BR2_PACKAGE_QT5BASE_FONTCONFIG
select BR2_PACKAGE_QT5BASE_ICU
select BR2_PACKAGE_QT5BASE_GUI
select BR2_PACKAGE_QT5BASE_WIDGETS
select BR2_PACKAGE_QT5DECLARATIVE
select BR2_PACKAGE_QT5DECLARATIVE_QUICK
select BR2_PACKAGE_QT5QUICKCONTROLS
select BR2_PACKAGE_QT5QUICKCONTROLS2
select BR2_PACKAGE_QT5WEBCHANNEL
select BR2_PACKAGE_XLIB_LIBXCOMPOSITE if BR2_PACKAGE_QT5BASE_XCB
select BR2_PACKAGE_XLIB_LIBXCURSOR if BR2_PACKAGE_QT5BASE_XCB
select BR2_PACKAGE_XLIB_LIBXI if BR2_PACKAGE_QT5BASE_XCB
select BR2_PACKAGE_XLIB_LIBXRANDR if BR2_PACKAGE_QT5BASE_XCB
select BR2_PACKAGE_XLIB_LIBXSCRNSAVER if BR2_PACKAGE_QT5BASE_XCB
select BR2_PACKAGE_XLIB_LIBXTST if BR2_PACKAGE_QT5BASE_XCB
help
The Qt WebEngine module provides a web browser engine that
makes it easy to embed content from the World Wide Web into
your Qt application.
Qt WebEngine provides C++ classes and QML types for rendering
HTML, XHTML, and SVG documents, styled using Cascading Style
Sheets (CSS) and scripted with JavaScript. HTML documents can
be made fully editable by the user through the use of the
contenteditable attribute on HTML elements.
http://doc.qt.io/qt-5/qtwebengine-index.html
if BR2_PACKAGE_QT5WEBENGINE
config BR2_PACKAGE_QT5WEBENGINE_PROPRIETARY_CODECS
bool "proprietary codecs"
help
Qt WebEngine supports the MPEG-4 Part 14 (MP4) file format,
which includes required proprietary audio and video codecs,
such as H.264 and MPEG layer-3 (MP3).
config BR2_PACKAGE_QT5WEBENGINE_ALSA
bool "alsa"
select BR2_PACKAGE_ALSA_LIB
select BR2_PACKAGE_ALSA_LIB_MIXER
select BR2_PACKAGE_ALSA_LIB_RAWMIDI
select BR2_PACKAGE_ALSA_LIB_HWDEP
select BR2_PACKAGE_ALSA_LIB_SEQ
help
Enable ALSA support.
qt5webengine: new package This patch is based on works [1] and [2]. With this patch, one can run the Qt5 WebEngine quicknanobrowser sample with the following options. BR2_TOOLCHAIN_BUILDROOT_LIBC="glibc" and BR2_TOOLCHAIN_BUILDROOT_CXX (Qt 5 needs a toolchain w/ wchar, NPTL, C++, dynamic library; for now it builds only with glibc) BR2_PACKAGE_LIBERATION (Qt needs at least one font) BR2_PACKAGE_QT5BASE_EXAMPLES (to install quicknanobrowser sample) BR2_PACKAGE_QT5BASE_GIF (do display gif) BR2_PACKAGE_QT5BASE_JPEG (do display jpeg) BR2_PACKAGE_QT5BASE_PNG (do display png) BR2_PACKAGE_QT5QUICKCONTROLS (needed by webengine) BR2_PACKAGE_QT5QUICKCONTROLS2 (needed by webengine) BR2_PACKAGE_QT5WEBENGINE (because it is what we want) Qt WebEngine requires an Open(E)GL-capable backend. As an example, the package rpi-userland must be enabled to build for a rpi. BR2_PACKAGE_RPI_USERLAND (to enable OpenGL ES backend) To browse for HTTPS websites, please consider adding the following options as well for SSL/TLS. BR2_PACKAGE_CA_CERT (for certificates) BR2_PACKAGE_NTPD (to sync date for certificates) Since version 5.9, chromium requires udev at runtime (see note 4). BR2_ROOTFS_DEVICE_CREATION_DYNAMIC_EUDEV (input backend) To run quicknanobrowser # cd /usr/lib/qt/examples/webengine/quicknanobrowser/ # ./quicknanobrowser https://www.buildroot.org/ Note: The chromium.inc has been generated using the following command. ( echo 'CHROMIUM_LICENSE_FILES = \' && cd output/build/qt5webengine-5.9.1/ && \ find "src/3rdparty/chromium/" -type f -iname "*LICENSE*" -o -iname "*COPYING*" -o -iname "*GPL*" | \ sed -e '/\.asm$/d' \ -e '/\.h$/d' \ -e '/\.c$/d' \ -e '/\.cc$/d' \ -e '/\.cpp$/d' \ -e '/\.pyc\?$/d' \ -e '/\.pl$/d' \ -e '/\.sha1$/d' \ -e '/\.patch$/d' \ -e '/licensecheck/d' \ -e 's,^,\t,' \ -e 's,$, \\,' | \ sort && \ echo '' ) >package/qt5/qt5webengine/chromium.inc Note 2: Since 5.9.1, the chromium's copy of opus fails with neon [3]. Qt WebEngine can uses buildroot ffmpeg copy which compiles fine (using qmake flag WEBENGINE_CONFIG+=use_system_ffmpeg). It implies selecting the following options. BR2_PACKAGE_FFMPEG BR2_PACKAGE_OPUS BR2_PACKAGE_LIBVPX BR2_PACKAGE_WEBP BR2_PACKAGE_WEBP_DEMUX In file included from ../../3rdparty/chromium/third_party/opus/src/silk/arm/NSQ_neon.c:31:0: /home/gportay/src/buildroot/output-rpi3-qt5.9/host/lib/gcc/arm-buildroot-linux-gnueabihf/6.4.0/include/arm_neon.h:8997:1: error: inlining failed in call to always_inline ‘vld1q_s32’: target specific option mismatch vld1q_s32 (const int32_t * __a) ^~~~~~~~~ ../../3rdparty/chromium/third_party/opus/src/silk/arm/NSQ_neon.c:40:15: note: called from here int32x4_t coef0 = vld1q_s32(coef32); ^~~~~ ../../3rdparty/chromium/third_party/opus/src/silk/arm/NSQ_neon.c: At top level: cc1: warning: unrecognized command line option ‘-Wno-#pragma-messages’ Note 3: Version 5.6.2 causes a build issue while building chromium. The build against this version is disabled until the release 5.6.3 is out. Note 4: Here is trace when udev does not run # cd /usr/lib/qt/examples/webengine/quicknanobrowser # ./quicknanobrowser QStandardPaths: XDG_RUNTIME_DIR not set, defaulting to '/tmp/runtime-root' Unable to query physical screen size, defaulting to 100 dpi. To override, set QT_QPA_EGLFS_PHYSICAL_WIDTH and QT_QPA_EGLFS_PHYSICAL_HEIGHT (in millimeters). [0101/000248.161973:WARNING:resource_bundle_qt.cpp(114)] locale_file_path.empty() for locale [0101/000248.384693:WARNING:resource_bundle_qt.cpp(114)] locale_file_path.empty() for locale [202:223:0101/000248.484954:FATAL:udev_loader.cc(38)] Check failed: false. #0 0x0000742b93de <unknown> #1 0x0000742c3c38 <unknown> #2 0x000073e1e1aa <unknown> #3 0x000073e1d96e <unknown> #4 0x000073e1defa <unknown> #5 0x000074af6364 <unknown> #6 0x000074302878 <unknown> #7 0x0000742c8fee <unknown> #8 0x0000742c9f44 <unknown> #9 0x0000742ca21e <unknown> #10 0x0000742cac4c <unknown> #11 0x0000742c87b2 <unknown> #12 0x0000742da4f6 <unknown> #13 0x000073ed9d38 <unknown> #14 0x000073eda03c <unknown> #15 0x0000742e9aec <unknown> #16 0x0000742e71dc <unknown> Aborted Note 5: On rpi and depending on what is insinde the .config, more GPU memory should be allocated to run properly qt samples. #0 0x0000742c63de <unknown> #1 0x0000742d0c38 <unknown> #2 0x0000749d7bde <unknown> #3 0x0000749e3c70 <unknown> #4 0x00007530227c <unknown> #5 0x000075302480 <unknown> #6 0x0000752fb1e4 <unknown> #7 0x00007430f878 <unknown> #8 0x0000742d5fee <unknown> #9 0x0000742d6f44 <unknown> #10 0x0000742d721e <unknown> #11 0x0000742d7ad6 <unknown> #12 0x0000742d57b2 <unknown> #13 0x0000742e74f6 <unknown> #14 0x0000742f6a74 <unknown> #15 0x0000742f41dc <unknown> Received signal 6 #0 0x0000742c63de <unknown> #1 0x0000742c66a0 <unknown> #2 0x0000725b5d10 <unknown> [end of stack trace] qml: Render process exited with code 256 (abnormal exit) # mount /dev/mmcblk0p1 /mnt # sed '/^gpu_mem_/s,=.*,=200,' -i /mnt/config.txt # umount /mnt Note 6: The first patch fixes a build issue when samples are compiled without the support of printing [4]. This patch is already merged in branch 5.9 [5] and concerns only 5.9.1. 085c2c52 Always compile QWebEnginePage::print It fixes the error below. .obj/browsermainwindow.o: In function `BrowserMainWindow::printRequested(QWebEnginePage*)': browsermainwindow.cpp:(.text+0x2cc0): undefined reference to `QWebEnginePage::print(QPrinter*, QWebEngineCallback<bool> const&)' The second patch loads both libEGL and libGLESv2 symbols implicitly instead of loading them with explicitly using hard-coded locations. It fixes a bug when providers of lib*GL does not create libraries named libEGL.so.1 and libGLESv2.s2 [6]. This patch is already merged in branch 5.9 [7]. d4c621f6 Load libEGL and libGLES2 symbols implicitly It fixes the error below. [327:347:1221/085837:ERROR:surface_factory_qt.cpp(68)] Failed to load /usr/lib/libGLESv2.so.2: /usr/lib/libGLESv2.so.2: cannot open shared object file: No such file or directory [1]: http://lists.busybox.net/pipermail/buildroot/2015-July/132010.html [2]: https://patchwork.ozlabs.org/patch/640633/ [3]: https://patchwork.ozlabs.org/patch/791332/ [4]: https://bugreports.qt.io/browse/QTBUG-61510 [5]: https://codereview.qt-project.org/#/c/198041/ [6]: https://bugreports.qt.io/browse/QTBUG-57761 [7]: https://codereview.qt-project.org/#/c/199554/ Cc: Akihiko Odaki <akihiko.odaki.4i@stu.hosei.ac.jp> Cc: Julien Corjon <corjon.j@ecagroup.com> Signed-off-by: Gaël PORTAY <gael.portay@savoirfairelinux.com> [Arnout: - move more dependencies to _ARCH_DEPENDS; - mention all toolchain dependencies in the comments] Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
2017-08-15 22:38:53 +02:00
endif