[webkit-changes] [WebKit/WebKit] 7aa121: [WPE][CMake] Allow disabling the build of WTR with...

Carlos Alberto Lopez Perez noreply at github.com
Tue Dec 13 20:30:18 PST 2022


  Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: 7aa121b35701dc54d093db118de218057a034f6e
      https://github.com/WebKit/WebKit/commit/7aa121b35701dc54d093db118de218057a034f6e
  Author: Carlos Alberto Lopez Perez <clopez at igalia.com>
  Date:   2022-12-13 (Tue, 13 Dec 2022)

  Changed paths:
    M Source/cmake/OptionsGTK.cmake
    M Source/cmake/OptionsWPE.cmake
    M Source/cmake/WebKitFeatures.cmake
    M Tools/PlatformGTK.cmake
    M Tools/PlatformWPE.cmake

  Log Message:
  -----------
  [WPE][CMake] Allow disabling the build of WTR without disabling the Cog build and also control the platform plugins of Cog
https://bugs.webkit.org/show_bug.cgi?id=249036

Reviewed by Michael Catanzaro.

When building WPE for the rpi3 using the script build-webkit with a
yocto-based-cross-toolchain I found this issues:

 - for mesa-vc4 target: gtk4 is not available so the
   build fails when cog tries to enable the gtk4 plugin
 - for userland target: wpebackend-fdo is not available (only wpebackend-rdk)
   and wpebackend-fdo is needed to build WebKitTestRunner, the API tests runner
   and the MiniBrowser.

To fix this issues this patch allows to have more control over how Cog is built
and also to disable the build of WTR, MiniBrowser and APITestRunner meanwhile
keeping the build of Cog enabled.

After this patch this is how you would build for this targets:

rpi3-mesa-vc4:
  -DENABLE_COG=ON -DWPE_COG_PLATFORMS=drm,headless,wayland
  So gtk4 is disabled

rpi3-userland:
  -DENABLE_MINIBROWSER=OFF -DENABLE_API_TESTS=OFF -DENABLE_LAYOUT_TESTS=OFF -DENABLE_COG=ON -DWPE_COG_PLATFORMS=none
  So only Cog gets built and also it builds without platform plugins (which require wpebackend-fdo)
  The keyword 'none' is used as a special key in CMake to later pass to the Cog meson build
  the parameter "-Dplatforms=" which is needed to set the list of platforms to empty instead
  of using the default defined on Cog at meson_options.txt

This patch also fixes the build on a cross-build environment by passing the path
of the cross-toolchain pkg_config to the Cog build.

And finally it also changes the GTK port to start using also the new introduced
CMake option ENABLE_LAYOUT_TESTS for consistency.

* Source/cmake/OptionsGTK.cmake
* Source/cmake/OptionsWPE.cmake:
* Source/cmake/WebKitFeatures.cmake:
* Tools/PlatformGTK.cmake:
* Tools/PlatformWPE.cmake:

Canonical link: https://commits.webkit.org/257827@main




More information about the webkit-changes mailing list