summaryrefslogtreecommitdiff
path: root/.github
diff options
context:
space:
mode:
authorCristian Adam <cristian.adam@qt.io>2022-07-13 21:21:07 +0200
committerCristian Adam <cristian.adam@qt.io>2022-07-14 08:54:37 +0000
commit5088781693c9fbf0749a869b59e97227f14f5818 (patch)
treea7121bfd7daaf32392264966d36befe9622b4f45 /.github
parent9c09ade2ede85392f942388e95a199ea81ff7edb (diff)
downloadqt-creator-5088781693c9fbf0749a869b59e97227f14f5818.tar.gz
GitHub Actions: Use software OpenGL driver for tests on Linux
As done for the Windows configuration. macOS comes automagically with a software renderer. Change-Id: Ifa64fc80f9ce69b87fb589675e794ac3b537cc48 Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Diffstat (limited to '.github')
-rw-r--r--.github/workflows/build_cmake.yml11
1 files changed, 8 insertions, 3 deletions
diff --git a/.github/workflows/build_cmake.yml b/.github/workflows/build_cmake.yml
index 55a52dc914..b532968d30 100644
--- a/.github/workflows/build_cmake.yml
+++ b/.github/workflows/build_cmake.yml
@@ -121,7 +121,10 @@ jobs:
COMMAND sudo apt update
)
execute_process(
- COMMAND sudo apt install libgl1-mesa-dev libvulkan-dev libxcb-xinput-dev libxcb-xinerama0-dev libxkbcommon-dev libxkbcommon-x11-dev
+ COMMAND
+ sudo apt install libgl1-mesa-dev libvulkan-dev libxcb-xinput-dev libxcb-xinerama0-dev libxkbcommon-dev libxkbcommon-x11-dev
+ libxcb-image0 libxcb-keysyms1 libxcb-render-util0 libxcb-xkb1 libxcb-randr0 libxcb-icccm4
+ xvfb
RESULT_VARIABLE result
)
if (NOT result EQUAL 0)
@@ -605,14 +608,16 @@ jobs:
set(ENV{CTEST_OUTPUT_ON_FAILURE} "ON")
if ("${{ runner.os }}" STREQUAL "Linux")
- set(ENV{QT_QPA_PLATFORM} "offscreen")
+ set(ENV{DISPLAY} ":1")
+ set(ENV{LIBGL_ALWAYS_SOFTWARE} "1")
+ set(ctest_launcher xvfb-run --auto-servernum --server-num=1)
elseif ("${{ runner.os }}" STREQUAL "Windows")
set(ENV{QT_OPENGL} "software")
set(ENV{QT_ASSUME_STDERR_HAS_CONSOLE} "1")
endif()
execute_process(
- COMMAND ctest -j ${N} --timeout 60 --label-exclude exclude_from_precheck --exclude-regex tst_perfdata
+ COMMAND ${ctest_launcher} ctest -j ${N} --timeout 60 --label-exclude exclude_from_precheck --exclude-regex tst_perfdata
WORKING_DIRECTORY build/build
RESULT_VARIABLE result
OUTPUT_VARIABLE output