From 3645bf8d0fa9b45542d732235c1499e08877e78c Mon Sep 17 00:00:00 2001 From: Sebastien Boeuf Date: Mon, 12 Aug 2019 10:34:47 -0700 Subject: [PATCH] tests: Build virtiofsd from specific branch In order to be able to use the latest version from virtiofsd binary, the integration tests will now build it directly from a branch located on sboeuf's QEMU fork. The same way the kernel is hosted on sboeuf's linux kernel fork, this allows to update the version of the virtiofs daemon based on latest patches from virtio-fs maintainers. Signed-off-by: Sebastien Boeuf --- Jenkinsfile | 2 +- scripts/run_integration_tests.sh | 11 ++++++++--- 2 files changed, 9 insertions(+), 4 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index 0468ad3a6..42fcb9353 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -5,7 +5,7 @@ stage ("Builds") { } stage ('Install system packages') { sh "sudo DEBIAN_FRONTEND=noninteractive apt-get install -yq build-essential mtools libssl-dev pkg-config" - sh "sudo apt-get install -yq flex bison libelf-dev qemu-utils qemu-system" + sh "sudo apt-get install -yq flex bison libelf-dev qemu-utils qemu-system libglib2.0-dev libpixman-1-dev libseccomp-dev" } stage ('Install Rust') { sh "nohup curl https://sh.rustup.rs -sSf | sh -s -- -y" diff --git a/scripts/run_integration_tests.sh b/scripts/run_integration_tests.sh index 57364e03b..92d2bc75b 100755 --- a/scripts/run_integration_tests.sh +++ b/scripts/run_integration_tests.sh @@ -78,12 +78,17 @@ if [ ! -f "$VMLINUX_IMAGE" ]; then popd fi -VIRTIOFSD_URL="$(curl --silent https://api.github.com/repos/intel/nemu/releases/latest | grep "browser_download_url" | grep "virtiofsd-x86_64" | grep -o 'https://.*[^ "]')" VIRTIOFSD="$WORKLOADS_DIR/virtiofsd" +VIRTIOFSD_DIR="virtiofsd_build" if [ ! -f "$VIRTIOFSD" ]; then pushd $WORKLOADS_DIR - wget --quiet $VIRTIOFSD_URL -O "virtiofsd" - chmod +x "virtiofsd" + git clone --depth 1 "https://github.com/sboeuf/qemu.git" -b "virtio-fs" $VIRTIOFSD_DIR + pushd $VIRTIOFSD_DIR + ./configure --prefix=$PWD --target-list=x86_64-softmmu + make virtiofsd -j `nproc` + cp virtiofsd $VIRTIOFSD + popd + rm -r $VIRTIOFSD_DIR sudo setcap cap_sys_admin+epi "virtiofsd" popd fi