From patchwork Fri May 26 07:00:06 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Github ODP bot X-Patchwork-Id: 100553 Delivered-To: patch@linaro.org Received: by 10.182.142.97 with SMTP id rv1csp85272obb; Fri, 26 May 2017 00:01:37 -0700 (PDT) X-Received: by 10.237.34.246 with SMTP id q51mr487391qtc.39.1495782097824; Fri, 26 May 2017 00:01:37 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1495782097; cv=none; d=google.com; s=arc-20160816; b=vm6L6b3dSAQb+NJoNtCj6nBnJ8z/AvkUtgG1RLgUUTdvcRVBKV9uvkTmqIrGxNQJKJ VeXN/ss4flNtDepQso+UTIF8zMW1FOkVFSpEjq+C8h7ajmWIsjrrg6sp0GSvbAXKEc9l klBcHkt1ZoYg73TLEYC5rzhhAVeoaZPMckt0MRvM3QFBDJ7O/+0IrSe6/CHR7PalYrvO E/iAbNvn/W2WCVIwjfzQ+RHH3JhntLSuIiG7QU/ODcPccF9b3r1B8tbXKV+Ki7n6p106 3lWGXUuvbx4Y2BnIaC5fwclO6dA24focQU+FA2cQIk4ckVBec2om++BWTL5TnoWwjeUG NCyA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:subject:github-pr-num :references:in-reply-to:message-id:date:to:from:delivered-to :arc-authentication-results; bh=OsL3gYgktKQ9O2trSyPCrKX9gpuF6yElPxqqBEsv1yI=; b=wralmoXMLTUMUhtKbtv7rWD+VHFvbKYdezZlGXSMhny/IiG7FR01PnDQ6SkXOTXO7o oPoij8vTAnv59F7iCTtDYhX7gvq0EMKcc4OHVwkf1R0SO5TD3xjpQSe6PESn6Hy/4MbU lUxYUeTYbovy5i6YO9sokJyBWHF5IKPrZncqnXJHGLQerkwvTIA0pct7sQtT8aja+M43 mDwg/xEZNMB4kMxjQwTOCs6c552cGT1eo1Y3fQv9X4wwOrw4uk1sYfKSkTI5pKY/E7uv Ieoec0MwP+lkMqj/4a4cjL9SdtJnnemB2BwkvwK+tBb87iOKk+aiNJMUaK/sqCWJXh2k TTUg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of lng-odp-bounces@lists.linaro.org designates 54.225.227.206 as permitted sender) smtp.mailfrom=lng-odp-bounces@lists.linaro.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=yandex.ru Return-Path: Received: from lists.linaro.org (lists.linaro.org. [54.225.227.206]) by mx.google.com with ESMTP id d137si5392111qkc.269.2017.05.26.00.01.37; Fri, 26 May 2017 00:01:37 -0700 (PDT) Received-SPF: pass (google.com: domain of lng-odp-bounces@lists.linaro.org designates 54.225.227.206 as permitted sender) client-ip=54.225.227.206; Authentication-Results: mx.google.com; spf=pass (google.com: domain of lng-odp-bounces@lists.linaro.org designates 54.225.227.206 as permitted sender) smtp.mailfrom=lng-odp-bounces@lists.linaro.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=yandex.ru Received: by lists.linaro.org (Postfix, from userid 109) id 7248D60F57; Fri, 26 May 2017 07:01:37 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on ip-10-142-244-252 X-Spam-Level: X-Spam-Status: No, score=-5.4 required=5.0 tests=BAYES_00,FREEMAIL_FROM, RCVD_IN_DNSWL_LOW, RCVD_IN_MSPIKE_H2, URIBL_BLOCKED autolearn=disabled version=3.4.0 Received: from [127.0.0.1] (localhost [127.0.0.1]) by lists.linaro.org (Postfix) with ESMTP id 5C5FE60BF2; Fri, 26 May 2017 07:01:26 +0000 (UTC) X-Original-To: lng-odp@lists.linaro.org Delivered-To: lng-odp@lists.linaro.org Received: by lists.linaro.org (Postfix, from userid 109) id 2CCC860CCC; Fri, 26 May 2017 07:01:21 +0000 (UTC) Received: from forward2p.cmail.yandex.net (forward2p.cmail.yandex.net [77.88.31.17]) by lists.linaro.org (Postfix) with ESMTPS id 7336060CCC for ; Fri, 26 May 2017 07:00:25 +0000 (UTC) Received: from smtp3j.mail.yandex.net (smtp3j.mail.yandex.net [95.108.130.68]) by forward2p.cmail.yandex.net (Yandex) with ESMTP id 018D72150E for ; Fri, 26 May 2017 10:00:23 +0300 (MSK) Received: from smtp3j.mail.yandex.net (localhost.localdomain [127.0.0.1]) by smtp3j.mail.yandex.net (Yandex) with ESMTP id E4AAF6241107 for ; Fri, 26 May 2017 10:00:16 +0300 (MSK) Received: by smtp3j.mail.yandex.net (nwsmtp/Yandex) with ESMTPSA id BYf5vKlPVr-0FJao04v; Fri, 26 May 2017 10:00:16 +0300 (using TLSv1.2 with cipher ECDHE-RSA-AES128-SHA256 (128/128 bits)) (Client certificate not present) X-Yandex-Suid-Status: 1 0 From: Github ODP bot To: lng-odp@lists.linaro.org Date: Fri, 26 May 2017 10:00:06 +0300 Message-Id: <1495782008-5146-2-git-send-email-odpbot@yandex.ru> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1495782008-5146-1-git-send-email-odpbot@yandex.ru> References: <1495782008-5146-1-git-send-email-odpbot@yandex.ru> Github-pr-num: 42 Subject: [lng-odp] [PATCH v1 1/3] travis: split build into separate stages X-BeenThere: lng-odp@lists.linaro.org X-Mailman-Version: 2.1.16 Precedence: list List-Id: "The OpenDataPlane \(ODP\) List" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: lng-odp-bounces@lists.linaro.org Sender: "lng-odp" From: Dmitry Eremin-Solenikov Introduce separate parallel builds for checkpatch, doxygen, distcheck and plain checks. Signed-off-by: Dmitry Eremin-Solenikov --- /** Email created from pull request 42 (lumag:stages) ** https://github.com/Linaro/odp/pull/42 ** Patch: https://github.com/Linaro/odp/pull/42.patch ** Base sha: 472d34cc0fd2b5f96277b1799583ab6c45375d40 ** Merge commit sha: 4308c4223e9828b6818fbdaf8d6236666995e077 **/ .travis.yml | 136 +++++++++++++++++++++++++++++------------------------------- 1 file changed, 65 insertions(+), 71 deletions(-) diff --git a/.travis.yml b/.travis.yml index 65edfbb3..e22d6ab6 100644 --- a/.travis.yml +++ b/.travis.yml @@ -33,65 +33,50 @@ env: # you need generated new one at https://codecov.io specific for your repo. - CODECOV_TOKEN=8e1c0fd8-62ff-411e-a79f-5839f6662c11 -matrix: - include: - - compiler: gcc - addons: - apt: - sources: - - ubuntu-toolchain-r-test - packages: - - gcc - env: MY_CF="-O0 -coverage" MY_LDF="--coverage" DOCOV=1 - - compiler: clang - addons: - apt: - sources: - - ubuntu-toolchain-r-test - - llvm-toolchain-precise-3.8 - packages: - - clang-3.8 - - compiler: gcc - addons: +addons: apt: - sources: - - ubuntu-toolchain-r-test - packages: - - gcc - env: TEST="CHECKPATCH" + sources: + - ubuntu-toolchain-r-test + - llvm-toolchain-precise-3.8 + packages: + - gcc + - clang-3.8 + - automake autoconf libtool libssl-dev graphviz mscgen doxygen + - libpcap-dev +# coverity_scan: +# project: +# name: "$TRAVIS_REPO_SLUG" +# notification_email: xxxx +# build_command_prepend: "./bootstrap && ./configure --enable-test-cpp --enable-test-vald --enable-test-helper --enable-test-perf --enable-user-guides --enable-test-perf-proc --enable-test-example" +# build_command: "make" +# branch_pattern: coverity_scan + +compiler: + - gcc + - clang-3.8 -before_install: +install: - echo 1000 | sudo tee /proc/sys/vm/nr_hugepages - sudo mkdir -p /mnt/huge - sudo mount -t hugetlbfs nodev /mnt/huge - - if [ "$TEST" = "CHECKPATCH" ]; then - echo ${TRAVIS_COMMIT_RANGE}; - ODP_PATCHES=`echo ${TRAVIS_COMMIT_RANGE} | sed 's/\.//'`; - if [ -z "${ODP_PATCHES}" ]; then env; exit 1; fi; - ./scripts/ci-checkpatches.sh ${ODP_PATCHES}; - exit $?; - fi - - sudo apt-get -qq update - - sudo apt-get install automake autoconf libtool libssl-dev graphviz mscgen doxygen - - sudo apt-get install libpcap-dev linux-headers-`uname -r` + - sudo apt-get install linux-headers-`uname -r` - sudo pip install coverage - gem install asciidoctor - PATH=${PATH//:\.\/node_modules\/\.bin/} - - if [ "$CC" = "clang" ]; then export CXX="clang++-3.8" CC="clang-3.8" LD="clang-3.8"; fi # Install cunit for the validation tests because distro version is too old and fails C99 compile - sudo apt-get remove libcunit1-dev libcunit1 - export CUNIT_VERSION=2.1-3 - curl -sSOL https://github.com/Linaro/libcunit/releases/download/${CUNIT_VERSION}/CUnit-${CUNIT_VERSION}.tar.bz2 - tar -jxf *.bz2 - - cd CUnit* + - pushd CUnit* - ./bootstrap - ./configure --enable-debug --enable-automated --enable-basic --enable-console --enable-examples --enable-test - make - sudo make install - - cd .. + - popd - export LD_LIBRARY_PATH="/usr/local/lib:$LD_LIBRARY_PATH" # DPDK pktio @@ -103,55 +88,64 @@ before_install: - pushd ${TARGET} - sed -ri 's,(CONFIG_RTE_LIBRTE_PMD_PCAP=).*,\1y,' .config - popd - - make install T=${TARGET} EXTRA_CFLAGS="-fPIC" > /dev/null + - make install T=${TARGET} EXTRA_CFLAGS="-fPIC" - popd # Netmap pktio - - sudo apt-get source linux-image-$(uname -r) > /dev/null - - KSRC="$PWD/`find . -name kernel-parameters.txt | cut -d / -f 2 `" - git -c advice.detachedHead=false clone -q --depth=1 --single-branch --branch=v11.2 https://github.com/luigirizzo/netmap.git - pushd netmap/LINUX - - ./configure --kernel-sources=$KSRC - - make > /dev/null + - ./configure + - make - sudo insmod ./netmap.ko - popd script: - ./bootstrap - - ./configure -# doxygen does not trap on warnings, check for them here. - - make doxygen-doc |tee doxygen.log - - fgrep -rvq warning ./doxygen.log - - make distcheck - - - ./bootstrap - - ./configure --prefix=$HOME/odp-install --enable-test-cpp --enable-test-vald --enable-test-helper --enable-test-perf --enable-user-guides --enable-test-perf-proc --enable-test-example --with-dpdk-path=`pwd`/dpdk/${TARGET} --with-netmap-path=`pwd`/netmap CFLAGS="$MY_CF" CXXFLAGS="$MY_CF" LDFLAGS="$MY_LDF" - - make -j 4 + - ./configure --prefix=$HOME/odp-install --enable-test-cpp --enable-test-vald --enable-test-helper --enable-test-perf --enable-user-guides --enable-test-perf-proc --enable-test-example --with-dpdk-path=`pwd`/dpdk/${TARGET} --with-netmap-path=`pwd`/netmap + - make -j $(nproc) - sudo LD_LIBRARY_PATH="/usr/local/lib:$LD_LIBRARY_PATH" make check - make install - echo "Checking linking and run from install..." - pushd $HOME - echo "Dynamic link.." - - ${CC} ${OLDPWD}/example/hello/odp_hello.c -o odp_hello_inst -I${HOME}/odp-install/include -L${HOME}/odp-install/lib -lodp-linux -L${OLDPWD}/dpdk/x86_64-native-linuxapp-gcc/lib -lrt -ldpdk -lpthread -lcrypto -lpcap $MY_CF $MY_LDF -ldl + - ${CC} ${OLDPWD}/example/hello/odp_hello.c -o odp_hello_inst -I${HOME}/odp-install/include -L${HOME}/odp-install/lib -lodp-linux -L${OLDPWD}/dpdk/x86_64-native-linuxapp-gcc/lib -lrt -ldpdk -lpthread -lcrypto -lpcap -ldl - LD_LIBRARY_PATH="${HOME}/odp-install/lib:$LD_LIBRARY_PATH" ./odp_hello_inst - echo "Static link.." - - ${CC} ${OLDPWD}/example/hello/odp_hello.c -o odp_hello_inst -I${HOME}/odp-install/include -L${HOME}/odp-install/lib -lodp-linux -L${OLDPWD}/dpdk/x86_64-native-linuxapp-gcc/lib -lrt -ldpdk -lpthread -lcrypto -lpcap $MY_CF $MY_LDF -ldl -static + - ${CC} ${OLDPWD}/example/hello/odp_hello.c -o odp_hello_inst -I${HOME}/odp-install/include -L${HOME}/odp-install/lib -lodp-linux -L${OLDPWD}/dpdk/x86_64-native-linuxapp-gcc/lib -lrt -ldpdk -lpthread -lcrypto -lpcap -ldl -static - ./odp_hello_inst - - popd - - sudo rm -rf dpdk - - sudo rm -rf netmap - - sudo rm -rf $KSRC - -after_success: - - if [ -n "$DOCOV" ]; then find . -type f -iname '*.[ch]' -not -path ".git/*" -execdir gcov {} \; ; bash <(curl -s https://codecov.io/bash) -X coveragepy; fi - -addons: - coverity_scan: - project: - name: "$TRAVIS_REPO_SLUG" - notification_email: xxxx - build_command_prepend: "./bootstrap && ./configure --enable-test-cpp --enable-test-vald --enable-test-helper --enable-test-perf --enable-user-guides --enable-test-perf-proc --enable-test-example" - build_command: "make" - branch_pattern: coverity_scan +jobs: + include: + - stage: test + env: TEST=coverage + compiler: gcc + script: + - ./bootstrap + - ./configure --prefix=$HOME/odp-install --enable-test-cpp --enable-test-vald --enable-test-helper --enable-test-perf --enable-user-guides --enable-test-perf-proc --enable-test-example --with-dpdk-path=`pwd`/dpdk/${TARGET} --with-netmap-path=`pwd`/netmap CFLAGS="$-O0 -coverage" CXXFLAGS="-O0 -coverage" LDFLAGS="--coverage" + - make check -j $(nproc) + - find . -type f -iname '*.[ch]' -not -path ".git/*" -execdir gcov {} \; ; bash <(curl -s https://codecov.io/bash) -X coveragepy + - stage: test + env: TEST=distcheck + compiler: gcc + script: + - ./bootstrap + - ./configure + - make distcheck + - stage: test + env: TEST=doxygen + compiler: gcc + script: + # doxygen does not trap on warnings, check for them here. + - ./bootstrap + - ./configure + - make doxygen-doc |tee doxygen.log + - fgrep -rvq warning ./doxygen.log + - stage: test + env: TEST=checkpatch + compiler: gcc + script: + - echo ${TRAVIS_COMMIT_RANGE}; + - ODP_PATCHES=`echo ${TRAVIS_COMMIT_RANGE} | sed 's/\.//'`; + - if [ -z "${ODP_PATCHES}" ]; then env; exit 1; fi; + - ./scripts/ci-checkpatches.sh ${ODP_PATCHES};