Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-120248

[Qt WebEngine] More configure-time checks and documentation for required libraries

    XMLWordPrintable

Details

    • Linux/X11

    Description

      Case 1: libxkbfile
      I just ran into the following while trying to build Qt WebEngine on Ubuntu 22.04. It was resolved with sudo apt install libxkbfile-dev

      CMake Error at /home/USER/qt-everywhere-src-6.5.3/qtwebengine/cmake/Gn.cmake:75 (message):
        
      
        -- GN FAILED
      
        ERROR at //build/config/linux/pkg_config.gni:104:17: Script returned
        non-zero exit code.
      
            pkgresult = exec_script(pkg_config_script, args, "value")
                        ^----------
      
        Current dir: /home/USER/build-qtwebengine/src/core/RelWithDebInfo/x86_64/
      
        Command: /usr/bin/python3
        /home/USER/qt-everywhere-src-6.5.3/qtwebengine/src/3rdparty/chromium/build/config/linux/pkg-config.py
        -p /usr/bin/pkg-config xkbcommon xkbfile
      
        Returned 1.
      
        stderr:
      
        
      
        Package xkbfile was not found in the pkg-config search path.
      
        Perhaps you should add the directory containing `xkbfile.pc'
      
        to the PKG_CONFIG_PATH environment variable
      
        No package 'xkbfile' found
      
        Could not run pkg-config.
      
        
      
        See
        /home/USER/qt-everywhere-src-6.5.3/qtwebengine/src/core/ozone/BUILD.gn:8:3:
        whence it was called.
      
          pkg_config("xkb") {
          ^------------------
      
        See /home/USER/build-qtwebengine/src/core/RelWithDebInfo/x86_64/BUILD.gn:611:15: which
        caused the file to be included.
      
            deps += [ "$_ozone_extra_directory:qt" ]
                      ^---------------------------
      

       

      Case 2: cups-config
      Similarly, a customer tried to use a CUPS-less system to build Qt, using the -no-cups -no-webengine-printing-and-pdf options. Their configuration passed, but they still got the following failure:

      CMake Error at cmake/Gn.cmake:75 (message):
        
      
        -- GN FAILED
      
        ERROR at //printing/BUILD.gn:406:14: Script returned non-zero exit code.
      
              libs = exec_script("cups_config_helper.py",
                     ^----------
      
        Current dir:
        /home/USER/qt-everywhere-src-6.5.3/qtwebengine/src/pdf/Release/x86_64/
      
      
        Command: /usr/bin/python3
        /home/USER/qt-everywhere-src-6.5.3/qtwebengine/src/3rdparty/chromium/printing/cups_config_helper.py
        --libs-for-gn
      
        Returned 1.
      
        stderr:
      
        
      
        Traceback (most recent call last):
      
          File "/home/USER/qt-everywhere-src-6.5.3/qtwebengine/src/3rdparty/chromium/printing/cups_config_helper.py", line 108, in <module>
            sys.exit(main())
          File "/home/USER/qt-everywhere-src-6.5.3/qtwebengine/src/3rdparty/chromium/printing/cups_config_helper.py", line 92, in main
            flags = run_cups_config(cups_config, mode)
          File "/home/USER/qt-everywhere-src-6.5.3/qtwebengine/src/3rdparty/chromium/printing/cups_config_helper.py", line 35, in run_cups_config
            cups = subprocess.Popen([cups_config, '--cflags', '--ldflags', '--libs'],
          File "/usr/lib/python3.10/subprocess.py", line 971, in __init__
            self._execute_child(args, executable, preexec_fn, close_fds,
          File "/usr/lib/python3.10/subprocess.py", line 1863, in _execute_child
            raise child_exception_type(errno_num, err_msg, err_filename)
      
        FileNotFoundError: [Errno 2] No such file or directory: 'cups-config'
      
        
      
        See //BUILD.gn:274:15: which caused the file to be included.
      
            deps += [ "//printing:printing_unittests" ]
                      ^------------------------------
      

       

      Suggestions

      Attachments

        For Gerrit Dashboard: QTBUG-120248
        # Subject Branch Project Status CR V

        Activity

          People

            michal Michal Klocek
            skoh-qt Sze Howe Koh
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:

              Gerrit Reviews

                There are 2 open Gerrit changes