QtWebEngine-6.11.0

#### Beyond Linux® From Scratch (systemd Edition) - Version r13.0-475

### Chapter 25. Graphical Environment Libraries

- Prev

  Qt-6.11.0

- Next

  startup-notification-0.12

- Up
- Home

# QtWebEngine-6.11.0

## Introduction to QtWebEngine

### Important

This package has historically had frequent updates that address security vulnerabilities. To determine the latest status check the BLFS Security Advisories.

QtWebEngine integrates chromium's web capabilities into Qt. It ships with its own copy of ninja which it uses for the build if it cannot find a system copy, and various copies of libraries from ffmpeg, icu, libvpx, and zlib (including libminizip) which have been forked by the chromium developers.

This package and browsers using it may be useful if you need to use a website designed for google chrome, or chromium, browsers.

### Warning

QtWebEngine uses a forked copy of chromium, and is therefore vulnerable to many issues found there. The Qt developers seem to fork a newer version for minor Qt versions, but because chromium moves to newer versions very often, by the time the Qt developers get a forked version to pass their extended tests it is always an old version and security fixes from chromium (some of which have a CVE number) can take several months to appear in a QtWebengine release, even if the severity has been rated as Critical.

Therefore, you should be wary of using QtWebEngine in a sensitive context and should always update to the next release as soon as it appears in this book, even if is not flagged as a Security Update. Identifying which vulnerabilities have been fixed in a particular release requires pulling the appropriate 'based-NNN' branch just before the previous and current releases and is often impractical. Reports of fixed QTBUG items do not seem to be available and there is not any documentation in the tarball for changes after the qt-5 versions.

### Note

Development versions of BLFS may not build or run some packages properly if LFS or dependencies have been updated since the most recent stable versions of the books.

### Warning

By default, ninja will use all online CPUs +2 (if at least 4 exist), even if they are not available to the current task because the build terminal has been restricted with 'taskset'. In BLFS, this package takes more time to build than any other. In one example, the build of this package crashed at about the 90 percent point due to an out of memory problem on a system with 24 cores and 32 GB of memory.

To work around this, see the Command Explanations below.

### Package Information

- Download (HTTP): https://download.qt.io/official_releases/qt/6.11/6.11.0/submodules/qtwebengine-everywhere-src-6.11.0.tar.xz

- Download MD5 sum: ee64c0d6e35df14a8164a5a4ede2777e

- Download size: 552 MB

- Estimated disk space required: 17 GB (379 MB installed)

- Estimated build time: 44 SBU (using parallelism=8)

### qtwebengine Dependencies

#### Required

Cups-2.4.19, html5lib-1.1, nodejs-24.15.0, nss-3.123.1, pciutils-3.15.0, and Qt-6.11.0

#### Recommended

### Note

If these packages are not installed, the build process will compile and install its own (perhaps older) version, with the side effect of increasing build and installed disk space and build time.

either alsa-lib-1.2.15.3 or PulseAudio-17.0 (or both), FFmpeg-8.1, ICU-78.3, libwebp-1.6.0, libxslt-1.1.45, Opus-1.6.1, and pipewire-1.6.4

#### Optional

MIT Kerberos V5-1.22.2, Poppler-26.04.0, jsoncpp, libsrtp, and snappy

## Installation of qtwebengine

Install qtwebengine by running the following commands:

    mkdir build &&
    cd    build &&

    cmake -D CMAKE_MESSAGE_LOG_LEVEL=STATUS             \
          -D QT_FEATURE_webengine_system_ffmpeg=ON      \
          -D QT_FEATURE_webengine_system_icu=ON         \
          -D QT_FEATURE_webengine_proprietary_codecs=ON \
          -D QT_FEATURE_webengine_webrtc_pipewire=ON    \
          -D QT_BUILD_EXAMPLES_BY_DEFAULT=OFF           \
          -D QT_GENERATE_SBOM=OFF                       \
          -G Ninja ..                                   &&
    ninja

This package does not come with a test suite.

Now, as the `root` user:

    ninja install

## Command Explanations

`CMAKE_MESSAGE_LOG_LEVEL=STATUS`: Output interesting messages that project users might be interested in. Ideally these should be concise, no more than a single line, but still informative.

`QT_FEATURE_webengine_system_*`: Specify what external packages the system should use.

`QT_BUILD_EXAMPLES_BY_DEFAULT=OFF`: Do not build examples by default.

`NINJAJOBS=4 make`: If you patched system ninja in LFS to recognize the NINJAJOBS environment variable, this command will run system ninja with the specified number of jobs (i.e. 4). There are several reasons why you might want to use options like this this:

- Building on a subset of CPUs allows measuring the build time for a smaller number of processors, and/or running other CPU-intensive tasks at the same time. For an editor on a machine with a lot of CPUs, trying to measure the build time for a 4-CPU machine, `NINJAJOBS=4 make` will give a reasonable approximation (there is a short period where N+2 python and node jobs run).

- On a machine with only 4 CPUs online, the default of scheduling N+2 jobs for qtwebengine is slower by between 3% and 7%, probably because of the size of the C++ files and their many includes and templates. Therefore, if in doubt set NINJAJOBS to the number of CPUs.

- Reducing the number of cores being used on long running, CPU intensive packages may alleviate heat problems.

- Reducing the number of cores will prevent potential out-of-memory problems on systems that do not have enough memory (or swap) when all cores are active. A suggested approach is to limit the number of cores to about one core for each 1.5 GB of combined RAM and swap space.

## Configuring QtWebEngine

### Configuration Information

If you are upgrading from an older minor version of this application, for some webpages to load you may need to clear the browser caches, e.g. for falkon they will be found in `~/.cache/falkon/`. You will need to do this if the browser starts to render the page and then changes to a blank tab with a message that something went wrong, and a button to Retry. Even after removing the old caches, you may need to retry a few times for each affected tab.

If a browser using this package fails to run and when run from a term it reports 'Trace/breakpoint trap' that is probably a kernel configuration issue - there is no need to rebuild QtWebEngine, see the next section, recompile the kernel and reboot to the new kernel.

## Kernel Configuration

This package does not require any of the optional kernel namespace items, but if User namespace is enabled (as happens in some unit files, for hardening) PID namespace must also be enabled. In that case enable the following options in the kernel configuration and recompile the kernel if necessary:

    General setup --->
      -*- Namespaces support --->                                       [NAMESPACES]
        # Enable or disable *both* of them:
        [ /*] User namespace                                               [USER_NS]
        [ /*] PID Namespaces                                                [PID_NS]

## Contents

Installed Programs: qtwebengine_convert_dict and QtWebEngineProcess (both in $QT6DIR/libexec)
Installed Libraries: libQt6Pdf.so, libQt6PdfQuick.so, libQt6PdfWidgets.so, libQt6WebEngineCore.so, libQt6WebEngineiQuick.so, libQt6WebEngineQuickDelegatesQml.so, and libQt6WebEngineWidgets.so
Installed Directories: $QT6DIR/include/QtPdf, $QT6DIR/include/QtPdfQuick, $QT6DIR/include/QtPdfWidgets, $QT6DIR/include/QtWebEngineCore, $QT6DIR/include/QtWebEngineQuick, $QT6DIR/include/QtWebEngineWidgets, $QT6DIR/qml/QtWebEngine, and $QT6DIR/translations/qtwebengine_locales

### Short Descriptions

qtwebengine_convert_dict | converts hunspell dictionaries (`.dic`) to chromium format (`.bdic`)
QtWebEngineProcess | is a libexec program which runs a zygote process (one that listens for spawn requests from a master process and will fork itself in response)

- Prev

  Qt-6.11.0

- Next

  startup-notification-0.12

- Up
- Home