From patchwork Thu Jun 22 03:32:16 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= X-Patchwork-Id: 106141 Delivered-To: patch@linaro.org Received: by 10.140.91.2 with SMTP id y2csp2255754qgd; Wed, 21 Jun 2017 20:39:37 -0700 (PDT) X-Received: by 10.55.214.2 with SMTP id t2mr446048qki.220.1498102777150; Wed, 21 Jun 2017 20:39:37 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1498102777; cv=none; d=google.com; s=arc-20160816; b=oGRYc6fyfaVahAPWMclxcsy/uXrHu2igRz3YIWlvqtIIYqBjB3AFe3NGVucV9h/3Si 0R6E0+ScZGbG7PR7q9sWUXpo6eBeEn7d//4fdXoiL81q9gV/mzZ+i6peOxwPHNg7kfvu kZVDE3Grnm16RGCyyuYIOhIyWWHvmdZH3QaT56B8NfpnxzV4FmyFuUG7d3syGSxc13/H TCGv+3Mhvl5dLEdIY7pwkmtQR6fZ116HjZyaiel/qclh8By+yHktW5srjo/E8He7/Rrv 5xzLYZHhtK73ku/Os8lR1aHjXZzf6PVerBCkRDuCBdZI/Qbdw86W+rWeZyvi7T1WZ77D trUA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:subject :content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:to:from:dkim-signature:arc-authentication-results; bh=DWPTf11AaT1PXKOs7ftM3yjH6O/xHzuc89nzUZ8r4xk=; b=cPgzAIUgTQeZYgXnOQIbEFN2P7A66g1XADWoK9qPJRbfLc5xSU+Sw49P/XsxCYI1pu 9kPrJVyXe/NYNFJZj1J4773p9zrvNkyEzWI+NEr9FvrXZ7DSZ7ZiPRgUXRNGQHk3TTC+ CWyqyFLyj98cZ2/uHtcxHiT8gTiMqtw4CKBxr/lSzsSMe4WrFF+x+jycVTwN0zd6c89d Ka6ygElOAORtmMsioa6oqsJ1MOekbnxeaYQ1BhpXG4BsbpErl/vZh5lF71lQZUEbXYyL lMKchi7ldmcSTmU4NYSI300lMHnVHp2Zr+0GAYD9K4/4Ninwp9lO+2UbvvG+ejFgFMoF wRWw== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@gmail.com header.b=omlmMxVe; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 2001:4830:134:3::11 as permitted sender) smtp.mailfrom=qemu-devel-bounces+patch=linaro.org@nongnu.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [2001:4830:134:3::11]) by mx.google.com with ESMTPS id 138si304975qkh.173.2017.06.21.20.39.36 for (version=TLS1 cipher=AES128-SHA bits=128/128); Wed, 21 Jun 2017 20:39:37 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 2001:4830:134:3::11 as permitted sender) client-ip=2001:4830:134:3::11; Authentication-Results: mx.google.com; dkim=fail header.i=@gmail.com header.b=omlmMxVe; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 2001:4830:134:3::11 as permitted sender) smtp.mailfrom=qemu-devel-bounces+patch=linaro.org@nongnu.org Received: from localhost ([::1]:56884 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dNsxy-0002Lv-SH for patch@linaro.org; Wed, 21 Jun 2017 23:39:34 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:56154) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dNsrq-0005fe-Gw for qemu-devel@nongnu.org; Wed, 21 Jun 2017 23:33:15 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1dNsro-0004qj-4N for qemu-devel@nongnu.org; Wed, 21 Jun 2017 23:33:14 -0400 Received: from mail-qk0-x229.google.com ([2607:f8b0:400d:c09::229]:33918) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1dNsrn-0004qF-W7 for qemu-devel@nongnu.org; Wed, 21 Jun 2017 23:33:12 -0400 Received: by mail-qk0-x229.google.com with SMTP id d14so3032972qkb.1 for ; Wed, 21 Jun 2017 20:33:11 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=DWPTf11AaT1PXKOs7ftM3yjH6O/xHzuc89nzUZ8r4xk=; b=omlmMxVeLr70xrzWuUp7kKJOUR98md7x/xpm/umK1rWvmafAr9Ehp2SCCLi4HZrV8+ yvF78HW4XxD8GOXE5q9mqf0TixD4830ip+B9GIDOw5YcpxJJmOEJTkR9qeG7hCTHU092 G0quICXXbj12/SCuq2EI3A5olieaS9OaHEXz2444xqVhFnKPsvQIbKDYzUopch3acZAA mrzhnQpd4DJrKWuJUWIHOnqOrKTNKnHufpLwLqkO4oPKbK101HVPFKyNkNmcm8IzgZoG JO+tyh4Kf3XDQvPccOV/nKbKXG587cxOw7u0ufizUtvwn/VzQp+Zk44S71oPtiHyU7Rj y8YA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=DWPTf11AaT1PXKOs7ftM3yjH6O/xHzuc89nzUZ8r4xk=; b=N4Wh7talWIrC49tqlSzncZxL7nZ60Zux48ZEM4wCjk/ig6StVUNLAQk3yaP5uxbIf6 BGC57X9BWePnTnQeQn6eyKnn0Fip6EOBYqmq5RUFFXmrh6t0Fz20ztX6qoparmyl5UzJ z1h+Unjyf1NZ4b1ITjgCuLgO6zghmssDB9+rkeJhE5fIpylEwi04htKqiJQIdchau2PT 3lYcTNfl+sz7vUNw+yWBPemNdQFgCfjJby8pP1MHC6+e3cInqEe8RDf78oHesiOYAuTl bhHOv58idy4cgypU8XtDrVnZUqtp81qCikCJOS/Qcjzd9nngVDIcYcjVKeOXaco4BXT9 jOnw== X-Gm-Message-State: AKS2vOx/Q9+auRPNWnbJWytxjHA3QjiC1p6WAqjtMlv45PJe9un0I1D0 1ccM9LCqtp+bUn+99Q4= X-Received: by 10.55.18.90 with SMTP id c87mr463738qkh.174.1498102391178; Wed, 21 Jun 2017 20:33:11 -0700 (PDT) Received: from yoga.offpageads.com ([138.117.48.226]) by smtp.gmail.com with ESMTPSA id g39sm247454qtc.12.2017.06.21.20.33.09 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 21 Jun 2017 20:33:10 -0700 (PDT) From: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= To: qemu-devel@nongnu.org, =?utf-8?q?Alex_Benn=C3=A9e?= , Fam Zheng , Peter Maydell Date: Thu, 22 Jun 2017 00:32:16 -0300 Message-Id: <20170622033231.19344-7-f4bug@amsat.org> X-Mailer: git-send-email 2.11.0 In-Reply-To: <20170622033231.19344-1-f4bug@amsat.org> References: <20170622033231.19344-1-f4bug@amsat.org> MIME-Version: 1.0 X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2607:f8b0:400d:c09::229 Subject: [Qemu-devel] [PATCH v2 06/21] travis: Add config to do a Coverity Scan upload X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" From: Peter Maydell Add config to travis to do a Coverity Scan build and upload, using the new run-coverity-scan script. There is an official integration between Travis and Coverity Scan: https://github.com/travis-ci/travis-build/blob/master/lib/travis/build/addons/coverity_scan.rb which slurps values out of the .travis.yml and downloads a build script from Coverity which does the bulk of the work: https://scan.coverity.com/scripts/travisci_build_coverity_scan.sh However we choose to roll our own since this seems less confusing and also allows us to include debug features (notably the ability to do a "dry run" test which doesn't actually upload anything). Signed-off-by: Peter Maydell Signed-off-by: Philippe Mathieu-Daudé --- .travis.yml | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) -- 2.11.0 diff --git a/.travis.yml b/.travis.yml index 0220f7472e..29c9ef72a4 100644 --- a/.travis.yml +++ b/.travis.yml @@ -218,3 +218,27 @@ matrix: - TEST_CMD="" before_script: - ./configure ${CONFIG} --extra-cflags="-g3 -O0 -fsanitize=thread -fuse-ld=gold" || cat config.log + # Build and upload to Coverity Scan. + # We do not impose any rate limiting here, but instead rely on the + # limiting done by the coverity servers, which for a project of QEMU's + # size means one build a day. The run-coverity-scan script will exit + # early if the limiter does not permit a new upload, so the effect will + # be that the first build (only) in each 24 hour period will be scanned. + # If we needed to apply a limit at the Travis end, the simplest approach + # would be to run the scan only if the branch was 'coverity-scan', and + # use a cron job to push master to the 'coverity-scan' branch periodically. + # We run on the trusty Travis hosts so that there's a wider set of + # dependencies satisfied to improve coverage. + - dist: trusty + env: + - COVERITY=1 + - COVERITY_BUILD_CMD="make -j3" + - COVERITY_EMAIL=peter.maydell@linaro.org + # This 'secure' setting sets COVERITY_TOKEN= + # and was created with travis encrypt -r qemu/qemu COVERITY_TOKEN=... + - secure: "D3E6E5bacui53fYBQrx0wQr8ZTvo6VIBPKfg0QHj2uwa6OPFkUlcMr/EHWvdbZNAa4Q1bv1vhlED5OPRfPmQYzxQNT4SAxDZeuZnikgIymfqQXNOjKw4kRUDO9P42QanyFd+EAu2JDVClAeJPgBpa/ns4CNrGDK+Q3coGndCP8o=" + before_script: + - if [ "$TRAVIS_PULL_REQUEST" = "true" ]; then echo "Skipping Coverity (pullreq)"; exit 0; fi + - if [ "$TRAVIS_BRANCH" != "master" ]; then echo "Skipping Coverity (wrong branch)"; exit 0; fi + script: + - ./scripts/run-coverity-scan