Skip to content

Commit

Permalink
dnsdist: Hopefully fix building with/without XDP in CI
Browse files Browse the repository at this point in the history
  • Loading branch information
rgacogne committed Jan 23, 2024
1 parent 8f9977a commit 1e48acc
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 8 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/build-and-test-all.yml
Original file line number Diff line number Diff line change
Expand Up @@ -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' }}
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/codeql-analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -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/
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/misc-dailies.yml
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down
11 changes: 6 additions & 5 deletions tasks.py
Original file line number Diff line number Diff line change
Expand Up @@ -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 \
Expand All @@ -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}')
Expand All @@ -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):
Expand Down

0 comments on commit 1e48acc

Please sign in to comment.