From patchwork Fri Jun 16 16:13:33 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: 105752 Delivered-To: patch@linaro.org Received: by 10.140.91.77 with SMTP id y71csp1383809qgd; Fri, 16 Jun 2017 09:18:56 -0700 (PDT) X-Received: by 10.55.209.6 with SMTP id s6mr13380672qki.245.1497629936220; Fri, 16 Jun 2017 09:18:56 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1497629936; cv=none; d=google.com; s=arc-20160816; b=SWFWXRD7MP/tB2muSw1/0hUqs05Mx+41WhCYhHVOBD2G6HmhzMFmts312yQousajTh KmkMTs8x1pGjxjrtVUHdFoygQ9OvkMtv90/P33eoLmTZdZ2LF8RtvRNhf15bafcJsddv RoP7nTsYLyTqh55A8FYdr8yLCtj33rpsgt4NY9gio9I1DwensX7y5HjcMXflOEPPEFyb 80CmbzDBHEzA4ekeZhiA4AaWY83z4zI0wejoA3oMIVlyv294A8cF7RAfulCSOqhpaAxA jiqIpkJ5lPxsuJ9O72ooXuDpnEeB7CSVFpcvrIzyteNONHSBQQ4L86BJYIVTMo17OkLP ZHaw== 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=UBtjIc9njwYiM9NhEpzkmS/JgF4foqtmWTHkd8UKZTA=; b=d+8thvsUsoIUu4Yp7FAoLvXVfa3claqnYmMkRzzjkl5hHGuvycmik4uacHOeeIRgIY a+0/YC/S8JdWQGlekZhzYo9/1IPTjuJ0MvTZVkMWH47vNXFTvQ7SSF/abniZXY1Hs7hc K+i0axKxdH3bhAsEtxa+bW82Ho4ZJR3AIKNiTHdiIWLAHgEVQRk6Xln6BIOTFTRM4Naz /kHnbAMPDxb+KUXhKLScuGoQNTrbB3M9xGGHYBqNCjIVkB4YqGIx0UcA3NQTf7vcwdL1 KWXPyma/gw5B1f6zXqGRFaofmuQ7Cj0imcAodioeGhWH1gWO0yudJpKncdegXzh4rYi+ k5hw== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@gmail.com header.b=FUwqxdna; 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 n45si2358943qtf.130.2017.06.16.09.18.55 for (version=TLS1 cipher=AES128-SHA bits=128/128); Fri, 16 Jun 2017 09:18:56 -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=FUwqxdna; 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]:59783 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dLtxV-0008Bx-Nw for patch@linaro.org; Fri, 16 Jun 2017 12:18:53 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:55608) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dLtt3-0004U4-VW for qemu-devel@nongnu.org; Fri, 16 Jun 2017 12:14:22 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1dLtt2-0002mc-Ss for qemu-devel@nongnu.org; Fri, 16 Jun 2017 12:14:17 -0400 Received: from mail-qt0-x22e.google.com ([2607:f8b0:400d:c0d::22e]:32893) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1dLtt2-0002mW-Nu for qemu-devel@nongnu.org; Fri, 16 Jun 2017 12:14:16 -0400 Received: by mail-qt0-x22e.google.com with SMTP id u12so69342106qth.0 for ; Fri, 16 Jun 2017 09:14:16 -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=UBtjIc9njwYiM9NhEpzkmS/JgF4foqtmWTHkd8UKZTA=; b=FUwqxdnaVop3rryGibr9jUrxCLCxggnGzDgJzIvoBR8Kk0rWcPJKPIFpIkC/DVsPK1 tqt4gKQ2itUe0fU1HxTLec6S0hzzingVBHqIAioVXZlB2bWlH+OP6DoNUXI8jSivt1IV 1ZFX9XQduPdZAptAlnpFzV+lZ1aoSabLoQ426AXBi92PWPRrn5mwVSRPRTMnZ+Wbpsat WJESgYeCoodSvxDN1EQuOQ+dsRqfD6+JYMbGziDjR9k2xkViSLlwZobPAxVb4xLz2Ms3 FwjHC7VXFD61K+10oiwBLZeT8g3sUD6BDxZ30qoQnVaEHKYTK2Rv3u5hp7tOowx1GVxY gOfg== 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=UBtjIc9njwYiM9NhEpzkmS/JgF4foqtmWTHkd8UKZTA=; b=EZAfpCDjhgwhQAH6J7wSO9qkFz/gFOPDdtv3fZCu3eSGEHHUwowGP72snDkYNhetTI wbUSaFcBZF/5r0rYGAPVKSnLKb7gckq8z1kMohWkARYjeXtJIMp7zOYoDLOjuBvmb9E0 TmnH7LlZM1fHWp8PmTDYyoLsjhvSDKHg+B7CsSIK+NFlCKj2a/VkcQYYBcZjiz3Guoco byq9fvsJgL12gbUiqU+opYRAlPIbVDpt7OqVoyVXwxLnFH9GTdCvumyu6AFh3C/VPtHw jLPjgBzQPbKcButF68Jq7l6WYBTdqhFOqri4FMmyTGVcFgGjLuW9XWcFJ101psVPuWSm CU0g== X-Gm-Message-State: AKS2vOxYmbON5F2nnlbM37/GARmNp851HntdoLFuWvXk4joUUOeHTV7R ulqKaq/6DK7abNVp4+c= X-Received: by 10.55.27.96 with SMTP id b93mr13122102qkb.235.1497629656154; Fri, 16 Jun 2017 09:14:16 -0700 (PDT) Received: from localhost.localdomain ([138.117.48.226]) by smtp.gmail.com with ESMTPSA id a62sm1691420qkd.14.2017.06.16.09.14.14 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 16 Jun 2017 09:14:15 -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: Fri, 16 Jun 2017 13:13:33 -0300 Message-Id: <20170616161334.7492-11-f4bug@amsat.org> X-Mailer: git-send-email 2.11.0 In-Reply-To: <20170616161334.7492-1-f4bug@amsat.org> References: <20170616161334.7492-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:c0d::22e Subject: [Qemu-devel] [PATCH 10/11] 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 4c0f7f444e..fc91e2fd28 100644 --- a/.travis.yml +++ b/.travis.yml @@ -220,3 +220,27 @@ matrix: - RUN_TESTS="no" 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