From f47cbcd43967fca0d2ae8b5a0a409a6e3ed96528 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Kacper=20Michaj=C5=82ow?= Date: Thu, 6 Jun 2024 23:23:35 +0200 Subject: [PATCH] ci/mingw: don't run test on 32-bit binary Ubuntu 24.04 linux-azure kernel, used on GHA, is compiled with CONFIG_COMPAT_32BIT_TIME=n. This prevents running any 32-bit binaries through wine, so disable tests when doing i686 build. 32-bit builds are still tested on Windows. See: https://github.com/actions/runner-images/issues/9977 --- .github/workflows/build.yml | 19 ++++++++++++++++--- ci/build-mingw64.sh | 2 +- 2 files changed, 17 insertions(+), 4 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 59d38c85c5..7cd1a947bc 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -32,10 +32,14 @@ jobs: CCACHE_BASEDIR: ${{ github.workspace }} CCACHE_DIR: ${{ github.workspace }}/.ccache CCACHE_MAXSIZE: 500M + WINE: ${{ matrix.wine }} strategy: fail-fast: false matrix: - target: [i686-w64-mingw32, x86_64-w64-mingw32] + include: + - target: i686-w64-mingw32 + - target: x86_64-w64-mingw32 + wine: wine steps: - uses: actions/checkout@v4 @@ -50,11 +54,18 @@ jobs: key: ${{ matrix.target }}-${{ steps.get_time.outputs.timestamp }} restore-keys: ${{ matrix.target }}- - - name: Install dependencies + # For LuaJIT build + - name: Enable multilib + if: ${{ matrix.target == 'i686-w64-mingw32' }} run: | sudo dpkg --add-architecture i386 sudo apt-get update - sudo apt-get install -y ccache g++-mingw-w64 gcc-multilib nasm ninja-build pkg-config python3-pip wine wine32 wine64 + sudo apt-get install -y gcc-multilib + + - name: Install dependencies + run: | + sudo apt-get update + sudo apt-get install -y ccache g++-mingw-w64 nasm ninja-build pkg-config wine wine64 sudo python3 -m pip install meson - name: Install Meson Wraps @@ -81,12 +92,14 @@ jobs: cat ./mingw_build/meson-logs/meson-log.txt - name: Functional test + if: ${{ matrix.wine }} run: | cd artifact && wine ./mpv.com -v --no-config env: WINEDEBUG: '+loaddll' - name: Run meson tests + if: ${{ matrix.wine }} id: tests run: | meson test -C mingw_build diff --git a/ci/build-mingw64.sh b/ci/build-mingw64.sh index 2fb6926548..252f7a8fb5 100755 --- a/ci/build-mingw64.sh +++ b/ci/build-mingw64.sh @@ -46,7 +46,7 @@ pkgconfig = 'pkg-config' pkg-config = 'pkg-config' windres = '${TARGET}-windres' dlltool = '${TARGET}-dlltool' -exe_wrapper = 'wine' +exe_wrapper = '${WINE}' [host_machine] system = 'windows' cpu_family = '${fam}'