]> git.ipfire.org Git - thirdparty/pdns.git/commitdiff
dnsdist: Hopefully fix building with/without XDP in CI
authorRemi Gacogne <remi.gacogne@powerdns.com>
Mon, 22 Jan 2024 16:04:44 +0000 (17:04 +0100)
committerRemi Gacogne <remi.gacogne@powerdns.com>
Tue, 23 Jan 2024 11:54:32 +0000 (12:54 +0100)
.github/workflows/build-and-test-all.yml
.github/workflows/codeql-analysis.yml
.github/workflows/misc-dailies.yml
tasks.py

index 7528f78352efef155eaafb11a797981d0cdccf59..2b97fd36f302e91f7b023a7336abca425d97bcc0 100644 (file)
@@ -626,7 +626,7 @@ jobs:
           name: dnsdist-full-${{ matrix.sanitizers }}-${{ env.normalized-branch-name }}
           path: /opt/dnsdist
       - run: inv install-clang-runtime
-      - run: inv install-dnsdist-test-deps 'with-xdp'
+      - run: inv install-dnsdist-test-deps
       - run: inv test-dnsdist
       - run: inv generate-coverage-info /opt/dnsdist/bin/dnsdist $GITHUB_WORKSPACE
         if: ${{ env.COVERAGE == 'yes' && matrix.sanitizers != 'tsan' }}
index ea0493e72900ab6f0e86b9821cce9fa41e1457ad..3a76bef498412dab5812c2ea5be4bc100cf7c5dd 100644 (file)
@@ -147,7 +147,7 @@ jobs:
     - name: Install dependencies for dnsdist
       if: matrix.product == 'dnsdist'
       run: |
-        inv install-dnsdist-build-deps --skipXDP=True
+        inv install-dnsdist-build-deps --skipXDP
     - name: Autoreconf dnsdist
       if: matrix.product == 'dnsdist'
       working-directory: ./pdns/dnsdistdist/
index 90b84a94c5044b78dea59259a922407539cfa8a5..ea31204d8ee21fe05c02a188d31a3996704b0221 100644 (file)
@@ -81,7 +81,7 @@ jobs:
           submodules: recursive
       - run: build-scripts/gh-actions-setup-inv-no-dist-upgrade
       - run: inv install-clang
-      - run: inv install-dnsdist-build-deps
+      - run: inv install-dnsdist-build-deps --skipXDP
       - run: inv install-coverity-tools dnsdist
       - run: inv coverity-clang-configure
       - run: inv ci-autoconf
index d8f54a91b05fbe0af99d8da4742bc6ccbfaf4585..bb7c08af9f1a6ac5f819135bc1778244e9dd8961 100644 (file)
--- a/tasks.py
+++ b/tasks.py
@@ -297,8 +297,8 @@ def install_rec_test_deps(c): # FIXME: rename this, we do way more than apt-get
     time.sleep(5)
     c.sudo('chmod 755 /var/agentx')
 
-@task
-def install_dnsdist_test_deps(c, xdp=True): # FIXME: rename this, we do way more than apt-get
+@task(optional=['skipXDP'])
+def install_dnsdist_test_deps(c, skipXDP=False): # FIXME: rename this, we do way more than apt-get
     deps = 'libluajit-5.1-2 \
             libboost-all-dev \
             libcap2 \
@@ -317,8 +317,9 @@ def install_dnsdist_test_deps(c, xdp=True): # FIXME: rename this, we do way more
             patch \
             protobuf-compiler \
             python3-venv snmpd prometheus'
-    if xdp:
-        deps = deps + 'libbpf1 \
+    if not skipXDP:
+        deps = deps + '\
+               libbpf1 \
                libxdp1'
 
     c.sudo(f'apt-get install -y {deps}')
@@ -333,7 +334,7 @@ def install_rec_build_deps(c):
 
 @task(optional=['skipXDP'])
 def install_dnsdist_build_deps(c, skipXDP=False):
-    c.sudo('apt-get install -y --no-install-recommends ' +  ' '.join(all_build_deps + git_build_deps + dnsdist_build_deps + dnsdist_xdp_build_deps if not skipXDP else []))
+    c.sudo('apt-get install -y --no-install-recommends ' +  ' '.join(all_build_deps + git_build_deps + dnsdist_build_deps + (dnsdist_xdp_build_deps if not skipXDP else [])))
 
 @task
 def ci_autoconf(c):