aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJia Tan <jiat0218@gmail.com>2023-01-07 11:16:55 +0800
committerJia Tan <jiat0218@gmail.com>2023-01-07 21:15:16 +0800
commit747c7f2b34bd498f6702c6875500a26b06201772 (patch)
tree29ed9c3fa72d7b80321d5d4930742a7e7b296528
parentCI/CD: Add new -p (PHASE) argument to ci_build.sh (diff)
downloadxz-747c7f2b34bd498f6702c6875500a26b06201772.tar.xz
CI/CD: Reduce job runners to 4 instead of using matrix strategy.
The old version used too many runners that resulted in unnecessary dependency downloads. Now, the runners are reused for the different configurations for each OS and build system.
-rw-r--r--.github/workflows/ci.yml95
1 files changed, 83 insertions, 12 deletions
diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml
index d86c696c..4a46e256 100644
--- a/.github/workflows/ci.yml
+++ b/.github/workflows/ci.yml
@@ -26,17 +26,54 @@ jobs:
Linux-Autotools:
# Just run on latest ubuntu
runs-on: ubuntu-latest
- strategy:
- matrix:
- check_types: ["crc32", "crc32,crc64", "crc32,sha256", "crc32,crc64,sha256"]
- disable: [encoders, decoders, bcj, delta, threads]
steps:
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- uses: actions/checkout@v2
- name: Install Dependencies
run: sudo apt-get install -y autoconf automake build-essential po4a autopoint
- - name: Build
- run: ./build-aux/ci_build.sh -b autotools -c ${{ matrix.check_types }} -d ${{ matrix.disable }}
+
+ # -b specifies the build system to use.
+ # -p specifies the phase (build or test) to help narrow down an error
+ # if one occurs.
+ - name: Build with full features
+ run: ./build-aux/ci_build.sh -b autotools -p build
+ - name: Test with full features
+ run: ./build-aux/ci_build.sh -b autotools -p test
+
+ - name: Build without encoders
+ run: ./build-aux/ci_build.sh -b autotools -d encoders -p build
+ - name: Test without encoders
+ run: ./build-aux/ci_build.sh -b autotools -d encoders -p test
+
+ - name: Build without decoders
+ run: ./build-aux/ci_build.sh -b autotools -d decoders -p build
+ - name: Test without decoders
+ run: ./build-aux/ci_build.sh -b autotools -d decoders -p test
+
+ - name: Build without threads
+ run: ./build-aux/ci_build.sh -b autotools -d threads -p build
+ - name: Test without threads
+ run: ./build-aux/ci_build.sh -b autotools -d threads -p test
+
+ - name: Build without BCJ filters
+ run: ./build-aux/ci_build.sh -b autotools -d bcj -p build
+ - name: Test without BCJ filters
+ run: ./build-aux/ci_build.sh -b autotools -d bcj -p test
+
+ - name: Build without Delta filters
+ run: ./build-aux/ci_build.sh -b autotools -d delta -p build
+ - name: Test without Delta filters
+ run: ./build-aux/ci_build.sh -b autotools -d delta -p test
+
+ - name: Build without sha256 check
+ run: ./build-aux/ci_build.sh -b autotools -c crc32,crc64 -p build
+ - name: Test without sha256 check
+ run: ./build-aux/ci_build.sh -b autotools -c crc32,crc64 -p test
+
+ - name: Build without crc64 check
+ run: ./build-aux/ci_build.sh -b autotools -c crc32,sha256 -p build
+ - name: Test without crc64 check
+ run: ./build-aux/ci_build.sh -b autotools -c crc32,sha256 -p test
Linux-CMake:
runs-on: ubuntu-latest
@@ -49,17 +86,51 @@ jobs:
MacOS-Autotools:
runs-on: macos-latest
- strategy:
- matrix:
- check_types: ["crc32", "crc32,crc64", "crc32,sha256", "crc32,crc64,sha256"]
- disable: [encoders, decoders, bcj, delta, threads]
steps:
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- uses: actions/checkout@v2
- name: Install Dependencies
run: brew install autoconf automake libtool po4a
- - name: Build
- run: ./build-aux/ci_build.sh -b autotools -c ${{ matrix.check_types }} -d ${{ matrix.disable }}
+
+ - name: Build with full features
+ run: ./build-aux/ci_build.sh -b autotools -p build
+ - name: Test with full features
+ run: ./build-aux/ci_build.sh -b autotools -p test
+
+ - name: Build without encoders
+ run: ./build-aux/ci_build.sh -b autotools -d encoders -p build
+ - name: Test without encoders
+ run: ./build-aux/ci_build.sh -b autotools -d encoders -p test
+
+ - name: Build without decoders
+ run: ./build-aux/ci_build.sh -b autotools -d decoders -p build
+ - name: Test without decoders
+ run: ./build-aux/ci_build.sh -b autotools -d decoders -p test
+
+ - name: Build without threads
+ run: ./build-aux/ci_build.sh -b autotools -d threads -p build
+ - name: Test without threads
+ run: ./build-aux/ci_build.sh -b autotools -d threads -p test
+
+ - name: Build without BCJ filters
+ run: ./build-aux/ci_build.sh -b autotools -d bcj -p build
+ - name: Test without BCJ filters
+ run: ./build-aux/ci_build.sh -b autotools -d bcj -p test
+
+ - name: Build without Delta filters
+ run: ./build-aux/ci_build.sh -b autotools -d delta -p build
+ - name: Test without Delta filters
+ run: ./build-aux/ci_build.sh -b autotools -d delta -p test
+
+ - name: Build without sha256 check
+ run: ./build-aux/ci_build.sh -b autotools -c crc32,crc64 -p build
+ - name: Test without sha256 check
+ run: ./build-aux/ci_build.sh -b autotools -c crc32,crc64 -p test
+
+ - name: Build without crc64 check
+ run: ./build-aux/ci_build.sh -b autotools -c crc32,sha256 -p build
+ - name: Test without crc64 check
+ run: ./build-aux/ci_build.sh -b autotools -c crc32,sha256 -p test
MacOS-CMake:
runs-on: macos-latest