From e9c2e1bc52b4539a2232904aa0b18f4d9c4d723a Mon Sep 17 00:00:00 2001 From: Tobias Klauser Date: Mon, 29 Mar 2021 18:15:38 +0200 Subject: Add GitHub action for build testing Signed-off-by: Tobias Klauser --- .github/workflows/build.yml | 53 +++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 53 insertions(+) create mode 100644 .github/workflows/build.yml diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml new file mode 100644 index 0000000..3cbd5ea --- /dev/null +++ b/.github/workflows/build.yml @@ -0,0 +1,53 @@ +name: Build + +on: + push: + branches: + - master + pull_request: + branches: + - master + +jobs: + build: + strategy: + matrix: + CC: [gcc, clang] + runs-on: ubuntu-latest + + steps: + - name: Install dependencies + run: | + sudo apt-get install -y --no-install-recommends libnl-3-dev libnl-genl-3-dev libnl-route-3-dev libnetfilter-conntrack-dev libgeoip-dev liburcu-dev libpcap-dev libnet1-dev libcli-dev clang + + - name: Check out code + uses: actions/checkout@v2 + + - name: Build (with all features) + run: | + CC=${{ matrix.CC }} ./configure + make CC=${{ matrix.CC }} + + - name: Build (without GeoIP) + run: | + make clean + CC=${{ matrix.CC }} ./configure --disable-geoip + make CC=${{ matrix.CC }} + + - name: Build (without zlib) + run: | + make clean + CC=${{ matrix.CC }} ./configure --disable-zlib + make CC=${{ matrix.CC }} + + - name: Build (without GeoIP and zlib) + run: | + make clean + CC=${{ matrix.CC }} ./configure --disable-geoip --disable-zlib + make CC=${{ matrix.CC }} + + - name: Build (without libnl) + run: | + make clean + CC=${{ matrix.CC }} ./configure --disable-libnl + make CC=${{ matrix.CC }} -- cgit v1.2.3-54-g00ecf