Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: bd507c3437567e45f8e17d36ad122fb19c7d962f
      
https://github.com/WebKit/WebKit/commit/bd507c3437567e45f8e17d36ad122fb19c7d962f
  Author: Kimmo Kinnunen <[email protected]>
  Date:   2026-10-05 (Mon, 05 Oct 2026)

  Changed paths:
    M Source/CMakeLists.txt
    M Source/ThirdParty/ANGLE/CMakeLists.txt
    A Source/ThirdParty/ANGLE/TestSources.cmake
    A Source/ThirdParty/ANGLE/Tests.cmake
    M Source/ThirdParty/ANGLE/WebKit/run-angle-tests
    M Source/ThirdParty/gmock/CMakeLists.txt

  Log Message:
  -----------
  ANGLE: Build the ANGLE test executables in the CMake build
https://bugs.webkit.org/show_bug.cgi?id=325490
rdar://188581694

Reviewed by Zak Ridouh.

Add ANGLEUnitTests, ANGLEEnd2EndTests, ANGLEDeqpGLES2Tests and
ANGLEDeqpGLES3Tests to the CMake build, mirroring the Xcode targets of
the same name. They are not part of the default build. Build the
ANGLETests target, or one of the executables, to get them.

The tests use internal ANGLE symbols that libANGLE-shared does not
export. Add ANGLE-static (libANGLE.a), an archive of the same objects
libANGLE-shared is linked from, so nothing is compiled twice. Unlike
the Xcode libANGLE.a it also contains the public gl*/egl* entry points,
so the test source lists omit libEGL_autogen.cpp, libGLESv2_autogen.cpp
and global_state.cpp.

dEQP needs exceptions and RTTI. The CMake gtest is built without RTTI,
so the gtest harness sources, which derive from testing::Test, keep
WebKit's default flags. The dEQP sources get -fexceptions -frtti. This
matches upstream, which builds dEQP into a separate libtester library.

Invoke:
  Tools/Scripts/build-webkit --cmake --debug --makeargs=ANGLETests

or:
  cmake --build WebKitBuild/cmake-mac/Debug --target ANGLETests

or:
  cmake --build WebKitBuild/cmake-mac/Debug
  ninja -C WebKitBuild/cmake-mac/Debug ANGLETests

* Source/CMakeLists.txt:
Add gmock next to gtest.

* Source/ThirdParty/ANGLE/CMakeLists.txt:
Add ANGLE-static and include Tests.cmake on macOS when API tests are
enabled.

* Source/ThirdParty/ANGLE/TestSources.cmake: Added.
Source lists copied from the Sources build phases of ANGLE.xcodeproj.

* Source/ThirdParty/ANGLE/Tests.cmake: Added.
The test targets, staging of the dEQP runtime data next to the
executables, and the ANGLETests target.

* Source/ThirdParty/ANGLE/WebKit/run-angle-tests:
Add --cmake to run the tests from WebKitBuild/cmake-mac, and accept
ANGLEUnitTests as a product.

* Source/ThirdParty/gmock/CMakeLists.txt:
Replace the upstream googlemock build script with a minimal one, like
Source/ThirdParty/gtest/CMakeLists.txt. Built only when linked.

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



To unsubscribe from these emails, change your notification settings at 
https://github.com/WebKit/WebKit/settings/notifications

Reply via email to