diff options
author | Ilya Maximets <i.maximets@samsung.com> | 2019-06-11 18:31:21 +0300 |
---|---|---|
committer | Ian Stokes <ian.stokes@intel.com> | 2019-06-12 10:27:59 +0100 |
commit | bb16fbccf928365b5aae0dfff217c1851398888c (patch) | |
tree | 47021afb8b967adc8be865ce956c34b085eb27f1 | |
parent | b76aa872e63cfdce312ab2d19d017e35c4ab10e9 (diff) | |
download | openvswitch-bb16fbccf928365b5aae0dfff217c1851398888c.tar.gz |
travis: Don't install kernel for DPDK checks.
We don't need to build DPDK kernel modules to test build with OVS.
And we don't need to build OVS datapath modules for checking
userspace with DPDK.
Removed 'max-inline-insns-single' changes that only was needed for
DPDK kernel modules. Config modifications changed to update
generated build/.config instead of changing sources.
Signed-off-by: Ilya Maximets <i.maximets@samsung.com>
Reviewed-by: David Marchand <david.marchand@redhat.com>
Tested-by: David Marchand <david.marchand@redhat.com>
Signed-off-by: Ian Stokes <ian.stokes@intel.com>
-rw-r--r-- | .travis.yml | 8 | ||||
-rwxr-xr-x | .travis/linux-build.sh | 25 |
2 files changed, 17 insertions, 16 deletions
diff --git a/.travis.yml b/.travis.yml index 6621fb535..7addcb231 100644 --- a/.travis.yml +++ b/.travis.yml @@ -31,10 +31,10 @@ env: - TESTSUITE=1 KERNEL=3.16 - TESTSUITE=1 OPTS="--enable-shared" - BUILD_ENV="-m32" OPTS="--disable-ssl" - - KERNEL=3.16 DPDK=1 OPTS="--enable-shared" - - KERNEL=3.16 TESTSUITE=1 DPDK=1 - - KERNEL=3.16 DPDK_SHARED=1 - - KERNEL=3.16 DPDK_SHARED=1 OPTS="--enable-shared" + - DPDK=1 OPTS="--enable-shared" + - TESTSUITE=1 DPDK=1 + - DPDK_SHARED=1 + - DPDK_SHARED=1 OPTS="--enable-shared" - KERNEL=4.20 - KERNEL=4.19 - KERNEL=4.18 diff --git a/.travis/linux-build.sh b/.travis/linux-build.sh index 123cde575..b88bfb53e 100755 --- a/.travis/linux-build.sh +++ b/.travis/linux-build.sh @@ -3,7 +3,6 @@ set -o errexit set -x -KERNELSRC="" CFLAGS="" SPARSE_FLAGS="" EXTRA_OPTS="--enable-Werror" @@ -57,10 +56,7 @@ function install_kernel() make net/bridge/ fi - KERNELSRC=$(pwd) - if [ ! "$DPDK" ] && [ ! "$DPDK_SHARED" ]; then - EXTRA_OPTS="${EXTRA_OPTS} --with-linux=$(pwd)" - fi + EXTRA_OPTS="${EXTRA_OPTS} --with-linux=$(pwd)" echo "Installed kernel source in $(pwd)" cd .. } @@ -78,16 +74,21 @@ function install_dpdk() if [ $DIR_NAME != "dpdk-$1" ]; then mv $DIR_NAME dpdk-$1; fi cd dpdk-$1 fi - find ./ -type f | xargs sed -i 's/max-inline-insns-single=100/max-inline-insns-single=400/' - find ./ -type f | xargs sed -i 's/-Werror/-Werror -Wno-error=inline/' echo 'CONFIG_RTE_BUILD_FPIC=y' >>config/common_linuxapp sed -ri '/EXECENV_CFLAGS = -pthread -fPIC/{s/$/\nelse ifeq ($(CONFIG_RTE_BUILD_FPIC),y)/;s/$/\nEXECENV_CFLAGS = -pthread -fPIC/}' mk/exec-env/linuxapp/rte.vars.mk + + make config CC=gcc T=$TARGET + if [ "$DPDK_SHARED" ]; then - sed -i '/CONFIG_RTE_BUILD_SHARED_LIB=n/s/=n/=y/' config/common_base + sed -i '/CONFIG_RTE_BUILD_SHARED_LIB=n/s/=n/=y/' build/.config export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$(pwd)/$TARGET/lib fi - make config CC=gcc T=$TARGET - make -j4 CC=gcc RTE_KERNELDIR=$KERNELSRC + + # Disable building DPDK kernel modules. Not needed for OVS build or tests. + sed -i '/CONFIG_RTE_EAL_IGB_UIO=y/s/=y/=n/' build/.config + sed -i '/CONFIG_RTE_KNI_KMOD=y/s/=y/=n/' build/.config + + make -j4 CC=gcc echo "Installed DPDK source in $(pwd)" cd .. } @@ -97,7 +98,7 @@ function configure_ovs() ./boot.sh && ./configure $* || { cat config.log; exit 1; } } -if [ "$KERNEL" ] || [ "$DPDK" ] || [ "$DPDK_SHARED" ]; then +if [ "$KERNEL" ]; then install_kernel $KERNEL fi @@ -141,7 +142,7 @@ else make selinux-policy # Only build datapath if we are testing kernel w/o running testsuite - if [ "$KERNEL" ] && [ ! "$DPDK" ] && [ ! "$DPDK_SHARED" ]; then + if [ "$KERNEL" ]; then cd datapath fi make -j4 |