From 05a1e92e350d871d4370ce851f34aa3008915f8a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Oliver=20St=C3=B6neberg?= Date: Wed, 13 Jul 2022 21:09:07 +0200 Subject: [PATCH] speed up MinGW and Cygwin CI builds by avoiding repeated linking (#4274) * speed up MinGW and Cygwin CI builds by avoiding repeated linking * updated some CI jobs to `windows-2022` --- .github/workflows/CI-cygwin.yml | 13 +++---------- .github/workflows/CI-mingw.yml | 13 +++---------- 2 files changed, 6 insertions(+), 20 deletions(-) diff --git a/.github/workflows/CI-cygwin.yml b/.github/workflows/CI-cygwin.yml index 7aaa8cd83..c9f56bab0 100644 --- a/.github/workflows/CI-cygwin.yml +++ b/.github/workflows/CI-cygwin.yml @@ -14,7 +14,7 @@ jobs: build_cygwin: strategy: matrix: - os: [windows-2019] + os: [windows-2022] arch: [x64, x86] include: - platform: 'x86_64' @@ -33,15 +33,8 @@ jobs: platform: ${{ matrix.arch }} packages: ${{ matrix.packages }} - - name: Build cppcheck - run: | - C:\cygwin\bin\bash.exe -l -c cd %GITHUB_WORKSPACE% && make -j2 - - - name: Build test - run: | - C:\cygwin\bin\bash.exe -l -c cd %GITHUB_WORKSPACE% && make -j2 testrunner - - - name: Run test + # Cygwin will always link the binaries even if they already exist. The linking is also extremely slow. So just run the "check" target which includes all the binaries. + - name: Build all and run test run: | C:\cygwin\bin\bash.exe -l -c cd %GITHUB_WORKSPACE% && make -j2 check diff --git a/.github/workflows/CI-mingw.yml b/.github/workflows/CI-mingw.yml index 1a6b23cfe..87ace921e 100644 --- a/.github/workflows/CI-mingw.yml +++ b/.github/workflows/CI-mingw.yml @@ -14,7 +14,7 @@ jobs: build_mingw: strategy: matrix: - os: [windows-2019] + os: [windows-2019] # fails to download with "windows-2022" arch: [x64] # TODO: fix x86 build? fail-fast: false @@ -28,14 +28,7 @@ jobs: with: platform: ${{ matrix.arch }} - - name: Build cppcheck - run: | - mingw32-make -j2 - - - name: Build test - run: | - mingw32-make -j2 testrunner - - - name: Run test + # MinGW will always link the binaries even if they already exist. The linking is also extremely slow. So just run the "check" target which includes all the binaries. + - name: Build all and run test run: | mingw32-make -j2 check