From patchwork Tue Jun 27 13: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: 106419 Delivered-To: patch@linaro.org Received: by 10.140.101.48 with SMTP id t45csp1174934qge; Tue, 27 Jun 2017 06:02:02 -0700 (PDT) X-Received: by 10.200.2.139 with SMTP id p11mr3489018qtg.34.1498568522544; Tue, 27 Jun 2017 06:02:02 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1498568522; cv=none; d=google.com; s=arc-20160816; b=nXAbi5HOXp+payA6ozOOIv4GFFlZfe8zZEKX0UwTEohTg2MzxxNpdXuF0v8zQCNow9 fSlfHDWHMpTYpYKUwxLNNDkAR7UHyWe6QXulc9D/i9ocupvZ89sp1PDNoG7P0uqqDMe0 OauSFgnZTYBCchqPViV1fmrB14gpFUxyWS7kMQrffmHayt16HrgmNwiZv2J5VF8RqUt5 BtrboJB3pnR92hwHeew51roKv2onKasbeFCHRcTDTVEnhzjU3/ffBIbW88ICPevkCTIu it1YGEkTfGN0Q/KIpDivEVPN9gfqMi07WgELF3o3sdq5oWIbs/2XRCirjHUH8qe6jllm yKjQ== 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=Q8p125r9TLmS2R8npKWBvYp8MmXMzJnXkKbmawnL4TY=; b=MLNsi8iMj4UPnoDCeprgKb8Ml7zeBSAP4rHq/II8rFb+OZPf8UeMMkjQH3zR5KbPym Amqn9Kn4qhEXmIMZyUsT7e1IDJl3z5jvoBBJgz+trJz1gI9LH8bWnc9YTXvRdeFvvZwG uJYfN6ApOt7tS6Sws+YIVVX4oi7YySJQjk2dN9X1f3hVLGu+AexloISU827UMYPLMoOd r8yu555CYhXRKmCllUC4ezFRXKGmkbs6cRZ7efBo0qxCIZlWrQG3bBATNnOS6ZbQWI8F TcGmzgmMZ54fi3XjIOPTZST9jVhrozlo/volXC4pW8GN+EoG+l4NoYi3Kto+qdGpFNpY PLSQ== 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 h94si2719468qtd.295.2017.06.27.06.02.02; Tue, 27 Jun 2017 06:02:02 -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 2E7E460C04; Tue, 27 Jun 2017 13:02:02 +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=-2.6 required=5.0 tests=BAYES_00,FREEMAIL_FROM, RCVD_IN_DNSWL_LOW 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 8A2F2608B8; Tue, 27 Jun 2017 13:00:49 +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 A4D1260C04; Tue, 27 Jun 2017 13:00:39 +0000 (UTC) Received: from forward1m.cmail.yandex.net (forward1m.cmail.yandex.net [5.255.216.2]) by lists.linaro.org (Postfix) with ESMTPS id 8512960896 for ; Tue, 27 Jun 2017 13:00:31 +0000 (UTC) Received: from smtp1o.mail.yandex.net (smtp1o.mail.yandex.net [IPv6:2a02:6b8:0:1a2d::25]) by forward1m.cmail.yandex.net (Yandex) with ESMTP id 1A707218ED for ; Tue, 27 Jun 2017 16:00:30 +0300 (MSK) Received: from smtp1o.mail.yandex.net (localhost.localdomain [127.0.0.1]) by smtp1o.mail.yandex.net (Yandex) with ESMTP id C24401300B96 for ; Tue, 27 Jun 2017 16:00:28 +0300 (MSK) Received: by smtp1o.mail.yandex.net (nwsmtp/Yandex) with ESMTPSA id SSbp3IQOoi-0RCWZRTu; Tue, 27 Jun 2017 16:00:28 +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: Tue, 27 Jun 2017 16:00:06 +0300 Message-Id: <1498568406-20591-3-git-send-email-odpbot@yandex.ru> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1498568406-20591-1-git-send-email-odpbot@yandex.ru> References: <1498568406-20591-1-git-send-email-odpbot@yandex.ru> Github-pr-num: 60 Subject: [lng-odp] [PATCH v1 2/2] travis: add cross-compilation checks 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 Include setup to cross-compile ODP for ARM hard float, ARM64 and PowerPC targets. Signed-off-by: Dmitry Eremin-Solenikov --- /** Email created from pull request 60 (lumag:cross) ** https://github.com/Linaro/odp/pull/60 ** Patch: https://github.com/Linaro/odp/pull/60.patch ** Base sha: a4add29291572219143dc667db4e8a7832a5692b ** Merge commit sha: 8dd9c8beb459d65838212e3d7bbba49762c50b4b **/ .travis.yml | 100 +++++++++++++++++++++++++++++++++++++++++++++++++++--------- 1 file changed, 86 insertions(+), 14 deletions(-) diff --git a/.travis.yml b/.travis.yml index 2cc8caf7..27be7d48 100644 --- a/.travis.yml +++ b/.travis.yml @@ -38,12 +38,15 @@ addons: apt: sources: - ubuntu-toolchain-r-test - - llvm-toolchain-precise-3.8 packages: - gcc - clang-3.8 - automake autoconf autoconf-archive libtool libssl-dev graphviz mscgen doxygen - libpcap-dev + - dpkg-cross equivs + - gcc-aarch64-linux-gnu pkg-config-aarch64-linux-gnu libc6-dev-arm64-cross + - gcc-arm-linux-gnueabihf pkg-config-arm-linux-gnueabihf libc6-dev-armhf-cross + - gcc-powerpc-linux-gnu pkg-config-powerpc-linux-gnu libc6-dev-powerpc-cross # coverity_scan: # project: # name: "$TRAVIS_REPO_SLUG" @@ -62,30 +65,35 @@ env: - CONF="--enable-schedule-sp" - CONF="--enable-schedule-iquery" -install: - - echo 1000 | sudo tee /proc/sys/vm/nr_hugepages - - sudo mkdir -p /mnt/huge - - sudo mount -t hugetlbfs nodev /mnt/huge - - - sudo apt-get -qq update - - sudo apt-get install linux-headers-`uname -r` - - sudo pip install coverage - - gem install asciidoctor - - PATH=${PATH//:\.\/node_modules\/\.bin/} - +before_install: # 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 - pushd CUnit* - - ./bootstrap - - ./configure --enable-debug --enable-automated --enable-basic --enable-console --enable-examples --enable-test + - libtoolize --force --copy + - aclocal + - autoheader + - automake --add-missing --include-deps --copy + - autoconf + - ./configure --enable-debug --enable-automated --enable-basic --enable-console --enable-examples --enable-test $CROSS || cat config.log - make - sudo make install - popd - export LD_LIBRARY_PATH="/usr/local/lib:$LD_LIBRARY_PATH" +install: + - echo 1000 | sudo tee /proc/sys/vm/nr_hugepages + - sudo mkdir -p /mnt/huge + - sudo mount -t hugetlbfs nodev /mnt/huge + + - sudo apt-get -qq update + - sudo apt-get install linux-headers-`uname -r` + - sudo pip install coverage + - gem install asciidoctor + - PATH=${PATH//:\.\/node_modules\/\.bin/} + # DPDK pktio - TARGET=${TARGET:-"x86_64-native-linuxapp-gcc"} - git -c advice.detachedHead=false clone -q --depth=1 --single-branch --branch=v17.02 http://dpdk.org/git/dpdk dpdk @@ -125,6 +133,69 @@ script: jobs: include: - stage: test + compiler: aarch64-linux-gnu-gcc + env: TEST="aarch64-linux-gnu" CROSS="--host=aarch64-linux-gnu --prefix=/usr/aarch64-linux-gnu" + install: true + script: + - mkdir cross + - pushd cross + # one can not include colon in the command or bad things will happen, so mimic it + - env echo -e 'Provides\x3a multiarch-support, debconf, debconf-2.0' > dummy + - equivs-build -a arm64 dummy + - wget + http://ports.ubuntu.com/pool/main/o/openssl/libssl-dev_1.0.1f-1ubuntu2.22_arm64.deb + http://ports.ubuntu.com/pool/main/o/openssl/libssl1.0.0_1.0.1f-1ubuntu2.22_arm64.deb + http://ports.ubuntu.com/pool/main/z/zlib/zlib1g-dev_1.2.8.dfsg-1ubuntu1_arm64.deb + http://ports.ubuntu.com/pool/main/z/zlib/zlib1g_1.2.8.dfsg-1ubuntu1_arm64.deb + - sudo dpkg-cross -i -M -A -a arm64 *.deb + - popd + - ./bootstrap + - ./configure --prefix=$HOME/odp-install $CROSS + --disable-test-cpp --enable-test-vald --enable-test-helper --enable-test-perf --enable-test-perf-proc --enable-test-example + - make -j $(nproc) + - stage: test + compiler: arm-linux-gnueabihf-gcc + env: TEST="arm-linux-gnueabihf" CROSS="--host=arm-linux-gnueabihf --prefix=/usr/arm-linux-gnueabihf" + install: true + script: + - mkdir cross + - pushd cross + # one can not include colon in the command or bad things will happen, so mimic it + - env echo -e 'Provides\x3a multiarch-support, debconf, debconf-2.0' > dummy + - equivs-build -a armhf dummy + - wget + http://ports.ubuntu.com/pool/main/o/openssl/libssl-dev_1.0.1f-1ubuntu2.22_armhf.deb + http://ports.ubuntu.com/pool/main/o/openssl/libssl1.0.0_1.0.1f-1ubuntu2.22_armhf.deb + http://ports.ubuntu.com/pool/main/z/zlib/zlib1g-dev_1.2.8.dfsg-1ubuntu1_armhf.deb + http://ports.ubuntu.com/pool/main/z/zlib/zlib1g_1.2.8.dfsg-1ubuntu1_armhf.deb + - sudo dpkg-cross -i -M -A -a armhf *.deb + - popd + - ./bootstrap + - ./configure --prefix=$HOME/odp-install $CROSS + --disable-test-cpp --enable-test-vald --enable-test-helper --enable-test-perf --enable-test-perf-proc --enable-test-example + - make -j $(nproc) + - stage: test + compiler: powerpc-linux-gnu-gcc + env: TEST="powerpc-linux-gnu" CROSS="--host=powerpc-linux-gnu --prefix=/usr/powerpc-linux-gnu" + install: true + script: + - mkdir cross + - pushd cross + # one can not include colon in the command or bad things will happen, so mimic it + - env echo -e 'Provides\x3a multiarch-support, debconf, debconf-2.0' > dummy + - equivs-build -a powerpc dummy + - wget + http://ports.ubuntu.com/pool/main/o/openssl/libssl-dev_1.0.1f-1ubuntu2.22_powerpc.deb + http://ports.ubuntu.com/pool/main/o/openssl/libssl1.0.0_1.0.1f-1ubuntu2.22_powerpc.deb + http://ports.ubuntu.com/pool/main/z/zlib/zlib1g-dev_1.2.8.dfsg-1ubuntu1_powerpc.deb + http://ports.ubuntu.com/pool/main/z/zlib/zlib1g_1.2.8.dfsg-1ubuntu1_powerpc.deb + - sudo dpkg-cross -i -M -A -a powerpc *.deb + - popd + - ./bootstrap + - ./configure --prefix=$HOME/odp-install $CROSS + --disable-test-cpp --enable-test-vald --enable-test-helper --enable-test-perf --enable-test-perf-proc --enable-test-example + - make -j $(nproc) + - stage: test env: TEST=coverage compiler: gcc script: @@ -158,4 +229,5 @@ jobs: - ./scripts/ci-checkpatches.sh ${ODP_PATCHES}; after_failure: + - cat config.log - find . -name 'test-suite.log' -execdir grep -il "FAILED" {} \; -exec echo {} \; -exec cat {} \;