From 9daf04bc72766f2c2427cc2f93b9a436c5b700de Mon Sep 17 00:00:00 2001 From: Yonatan Komornik Date: Mon, 13 Feb 2023 16:08:11 -0800 Subject: [PATCH] Add CI workflow to test compilation with each of the external compressors and with no external compressors. This is a sanity to make sure we don't introduce code dependencies on libraries that don't always exist (see https://github.com/facebook/zstd/pull/3497 for an example bugfix for such issue). --- .github/workflows/dev-short-tests.yml | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/.github/workflows/dev-short-tests.yml b/.github/workflows/dev-short-tests.yml index 092c933c762..48926428589 100644 --- a/.github/workflows/dev-short-tests.yml +++ b/.github/workflows/dev-short-tests.yml @@ -184,6 +184,25 @@ jobs: make gcc8install CC=gcc-8 CFLAGS="-Werror" make -j all + make-external-compressors: + strategy: + matrix: + include: + - name: "no external compressors" + flags: "HAVE_ZLIB=0 HAVE_LZ4=0 HAVE_LZMA=0" + - name: "only zlib" + flags: "HAVE_ZLIB=1 HAVE_LZ4=0 HAVE_LZMA=0" + - name: "only lz4" + flags: "HAVE_ZLIB=0 HAVE_LZ4=1 HAVE_LZMA=0" + - name: "only lzma" + flags: "HAVE_ZLIB=0 HAVE_LZ4=0 HAVE_LZMA=1" + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@ac593985615ec2ede58e132d2e21d2b1cbd6127c # tag=v3 + - name: Build with ${{matrix.name}} + run: ${{matrix.flags}} make zstd + + implicit-fall-through: runs-on: ubuntu-latest steps: