#140 [Do not merge] Add kernel bpf selftests
Closed 18 days ago by jcheca. Opened 4 months ago by jcheca.
rpms/ jcheca/clang rawhide  into  rawhide

Replace yum-builddep with dnf builddep
Jesus Checa Hidalgo • 4 months ago  
Add kernel bpf selftests to clang
Jesus Checa Hidalgo • 4 months ago  
@@ -0,0 +1,26 @@ 

+ summary: Run kernel BPF selftests

+ description: |

+   Run kernel BPF selftests

+ # TODO find a more suitable duration...

+ duration: 30m

+ test: ./test.sh

+ 

+ require:

+     - bc

+     - make

+     - dnf-plugins-core

+     - rpm-build

+     - git

+     - python3-devel

+     - python3-docutils

+     - gcc

+     - flex

+     - openssl-devel

+     - bison

+     - elfutils-libelf-devel

+     - binutils-devel

+     - libcap-devel

+     - clang

+     - llvm

+     - iproute-tc

+     - net-tools

@@ -0,0 +1,20 @@ 

+ #!/bin/sh -eux

+ 

+ # Use /home as /tmp usually has not enough space

+ rpmdir=$(mktemp -d /home/rpmbuildXXXXX)

+ dnf download --disablerepo=* --enablerepo=*-source --source kernel

+ srpm=`ls kernel-*.src.rpm`

+ dnf builddep -y $srpm

+ rpmbuild --nodeps -D "_topdir $rpmdir" -rp $srpm

+ vr=`echo $srpm | sed 's/.src.rpm//g' | cut -d - -f 2-`

+ srcdir=`find $rpmdir/BUILD -iname "*$vr.$(rpm -E '%{_arch}')"`

+ 

+ # Build modules_prepare or modules.lds won't be generated in 5+ kernels

+ make -C $srcdir/ oldconfig prepare scripts modules_prepare

+ # Build each test target

+ make -C $srcdir/tools/testing/selftests/bpf test_verifier test_progs

+ cd $srcdir/tools/testing/selftests/bpf

+ 

+ # Run actual tests

+ ./test_verifier

+ ./test_progs

This pull request aims to verify that the test bpf selftests will behave correctly with Fedora CI infrastructure.

Build failed. More information on how to proceed and troubleshoot errors available at https://fedoraproject.org/wiki/Zuul-based-ci

Build failed. More information on how to proceed and troubleshoot errors available at https://fedoraproject.org/wiki/Zuul-based-ci

1 new commit added

  • Replace yum-builddep with dnf builddep
4 months ago

Build failed. More information on how to proceed and troubleshoot errors available at https://fedoraproject.org/wiki/Zuul-based-ci

This pr needs to be reworked. Closing for now.

Pull-Request has been closed by jcheca

18 days ago