From patchwork Tue Mar 1 12:11:31 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Anthony PERARD X-Patchwork-Id: 12764676 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 7D94AC433FE for ; Tue, 1 Mar 2022 12:12:04 +0000 (UTC) Received: from list by lists.xenproject.org with outflank-mailman.281297.479574 (Exim 4.92) (envelope-from ) id 1nP1M1-00007Y-Iz; Tue, 01 Mar 2022 12:11:45 +0000 X-Outflank-Mailman: Message body and most headers restored to incoming version Received: by outflank-mailman (output) from mailman id 281297.479574; Tue, 01 Mar 2022 12:11:45 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1nP1M1-00007Q-FV; Tue, 01 Mar 2022 12:11:45 +0000 Received: by outflank-mailman (input) for mailman id 281297; Tue, 01 Mar 2022 12:11:43 +0000 Received: from se1-gles-sth1-in.inumbo.com ([159.253.27.254] helo=se1-gles-sth1.inumbo.com) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1nP1Lz-0008Ic-Qg for xen-devel@lists.xenproject.org; Tue, 01 Mar 2022 12:11:43 +0000 Received: from esa3.hc3370-68.iphmx.com (esa3.hc3370-68.iphmx.com [216.71.145.155]) by se1-gles-sth1.inumbo.com (Halon) with ESMTPS id c025121f-9958-11ec-8eba-a37418f5ba1a; Tue, 01 Mar 2022 13:11:42 +0100 (CET) X-BeenThere: xen-devel@lists.xenproject.org List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xenproject.org Precedence: list Sender: "Xen-devel" X-Inumbo-ID: c025121f-9958-11ec-8eba-a37418f5ba1a DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=citrix.com; s=securemail; t=1646136702; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=ud7MXxbX94bNlyXml0X8hASsYOPzgNU7AYPT+z5zGV8=; b=I3Gdhs8ShNjYbIy6U8g83SBnMvezC8+6bTLDMixNRZy6ORPug9067Rce mxMhD1wt8R8RIcLrCMA1Icbh33dEImuDCLJzbON9DlnZX5k+GRmUaXboT M+NBiKStoCRLortPe9CFmxrdQXEmIjVlWEE+6NuWBZD/4Bxj5UmTz0uDM M=; Authentication-Results: esa3.hc3370-68.iphmx.com; dkim=none (message not signed) header.i=none X-SBRS: 5.1 X-MesageID: 65205231 X-Ironport-Server: esa3.hc3370-68.iphmx.com X-Remote-IP: 162.221.156.83 X-Policy: $RELAYED IronPort-Data: A9a23:FJ87bKBgtdeQkRVW/zXjw5YqxClBgxIJ4kV8jS/XYbTApD9302EPz 2oeWGGDaPaJZjfxf90jaoS08EpSuJ7QxtJqQQY4rX1jcSlH+JHPbTi7wuYcHM8wwunrFh8PA xA2M4GYRCwMZiaA4E/raNANlFEkvU2ybuOU5NXsZ2YgHWeIdA970Ug5w7Vh29Yy6TSEK1jlV e3a8pW31GCNg1aYAkpMg05UgEoy1BhakGpwUm0WPZinjneH/5UmJMt3yZWKB2n5WuFp8tuSH I4v+l0bElTxpH/BAvv9+lryn9ZjrrT6ZWBigVIOM0Sub4QrSoXfHc/XOdJFAXq7hQllkPhfm NgKpbq3ZD4tJ6KcoNg9dCRCGWZhaPguFL/veRBTsOSWxkzCNXDt3+9vHAc9OohwFuRfWD8Us 6ZCcXZUM07F17neLLGTE4GAguwqKtXrO4UO/Glt1zjDAd4tQIzZQrWM7thdtNs1rp4TR66DP ZFAAdZpRCjvXDhwKHkMM4Adhva2iFXkeixEuE3A8MLb5ECMlVcsgdABKuH9YceWTM9YmkKZo GPu/GnjBBwectuFxlKt+Xu2iujCtSjyQo4VGfuz8fsCqE2ewCkfBQMbUXO/oOKlkQiuVtRHM UsW9yEy668o+ySDUd3VTxC+5nmesXYht8F4SrNgrlvXk+yNvljfVjNsoiN9hMIOmp87AiwM0 XKwm8rmVQRTkJqoU3ja6eLBxd+tAhQ9IWgHbC4CaAIK5dj/vY0+5i7yosZf/L2d1YOsR2ypq 9yehG1n3uhI05ZXv0mu1Q2f21qRSo71ohnZD+k9dkas9UtHaYGsfOREAnCLvK8bfO51orRs1 UXoevRyDshTVflhdwTXGY3h+Y1FAd7faFUwZnY1QvEcG8yFoSLLQGypyGgWyL1VGsgFYyT1R 0TYpBlc4pReVFPzM/MpO93qVZhzlPGxfTgAahwyRoAVCnSWXFXalByCmGbKhzy9+KTSuftX1 WinnTaEUi9BVPUPIMueTOYBy747rh3SNkuILa0XOy+PiOLEDFbMEO9tGALXMogRsfPVyC2Io o03H5bblH1ivBjWP3C/HXg7dgtRcxDWxPne9qRqSwJ0ClE+STF5VqSImutJlk4Mt/09q9okN 0qVAidwoGcTT1WdQelWQhiPsI/SYKs= IronPort-HdrOrdr: A9a23:x5wfiaGUJ/VBdCIfpLqE0MeALOsnbusQ8zAXP0AYc3Jom6uj5q aTdZUgpGfJYVkqOE3I9ertBEDEewK4yXcX2/h3AV7BZniEhILAFugLhuGO/9SjIVybygc079 YYT0EUMrzN5DZB4voSmDPIceod/A== X-IronPort-AV: E=Sophos;i="5.90,146,1643691600"; d="scan'208";a="65205231" From: Anthony PERARD To: CC: , , , Anthony PERARD , Doug Goldstein Subject: [XEN PATCH 1/3] automation: adding debian:stable container Date: Tue, 1 Mar 2022 12:11:31 +0000 Message-ID: <20220301121133.19271-2-anthony.perard@citrix.com> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20220301121133.19271-1-anthony.perard@citrix.com> References: <20220301121133.19271-1-anthony.perard@citrix.com> MIME-Version: 1.0 This container will be used to check that generated source file in the git repository are up to date. Signed-off-by: Anthony PERARD --- automation/build/debian/stable.dockerfile | 53 +++++++++++++++++++++++ 1 file changed, 53 insertions(+) create mode 100644 automation/build/debian/stable.dockerfile diff --git a/automation/build/debian/stable.dockerfile b/automation/build/debian/stable.dockerfile new file mode 100644 index 0000000000..912c4a5345 --- /dev/null +++ b/automation/build/debian/stable.dockerfile @@ -0,0 +1,53 @@ +FROM debian:stable +LABEL maintainer.name="The Xen Project" \ + maintainer.email="xen-devel@lists.xenproject.org" + +RUN useradd -ms /bin/bash user +ENV DEBIAN_FRONTEND=noninteractive + +# build depends +RUN apt-get update && \ + apt-get --quiet --yes install \ + build-essential \ + autoconf \ + zlib1g-dev \ + libncurses5-dev \ + libssl-dev \ + python3-dev \ + xorg-dev \ + uuid-dev \ + libyajl-dev \ + libaio-dev \ + libglib2.0-dev \ + clang \ + libpixman-1-dev \ + pkg-config \ + flex \ + bison \ + # gettext for Xen < 4.13 + gettext \ + acpica-tools \ + bin86 \ + bcc \ + liblzma-dev \ + # libc6-dev-i386 for Xen < 4.15 + libc6-dev-i386 \ + libnl-3-dev \ + ocaml-nox \ + libfindlib-ocaml-dev \ + markdown \ + transfig \ + pandoc \ + checkpolicy \ + wget \ + git \ + nasm \ + gnupg \ + golang \ + && \ + apt-get autoremove -y && \ + apt-get clean && \ + rm -rf /var/lib/apt/lists* /tmp/* /var/tmp/* + +USER user +WORKDIR /build From patchwork Tue Mar 1 12:11:32 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Anthony PERARD X-Patchwork-Id: 12764673 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 375D9C433EF for ; Tue, 1 Mar 2022 12:12:04 +0000 (UTC) Received: from list by lists.xenproject.org with outflank-mailman.281298.479585 (Exim 4.92) (envelope-from ) id 1nP1M2-0000Op-R3; Tue, 01 Mar 2022 12:11:46 +0000 X-Outflank-Mailman: Message body and most headers restored to incoming version Received: by outflank-mailman (output) from mailman id 281298.479585; Tue, 01 Mar 2022 12:11:46 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1nP1M2-0000Og-NZ; Tue, 01 Mar 2022 12:11:46 +0000 Received: by outflank-mailman (input) for mailman id 281298; Tue, 01 Mar 2022 12:11:45 +0000 Received: from se1-gles-sth1-in.inumbo.com ([159.253.27.254] helo=se1-gles-sth1.inumbo.com) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1nP1M0-0008Ic-S6 for xen-devel@lists.xenproject.org; Tue, 01 Mar 2022 12:11:44 +0000 Received: from esa3.hc3370-68.iphmx.com (esa3.hc3370-68.iphmx.com [216.71.145.155]) by se1-gles-sth1.inumbo.com (Halon) with ESMTPS id c23443fd-9958-11ec-8eba-a37418f5ba1a; Tue, 01 Mar 2022 13:11:43 +0100 (CET) X-BeenThere: xen-devel@lists.xenproject.org List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xenproject.org Precedence: list Sender: "Xen-devel" X-Inumbo-ID: c23443fd-9958-11ec-8eba-a37418f5ba1a DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=citrix.com; s=securemail; t=1646136703; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=cqtCddEDOMO9N2RINgp4gRg+BSZg2vJGBvVef7c4kfs=; b=fNkZWA8hX3vSDkdwh/BlOQpW2wKTSQyt1fQxzXDyatog/f8/OLp2B5VY A+9RzzYLWRAEI4pLsCQnnOHtlFOtZqYcfmYH/JSQcM9xsOC7e0JkQH+Pk 65Q47jxU8o+q1YEaUFRxb7rG+iQ/VKvujtIByE1VZPfl1K18jQ01kQNxt Y=; Authentication-Results: esa3.hc3370-68.iphmx.com; dkim=none (message not signed) header.i=none X-SBRS: 5.1 X-MesageID: 65205233 X-Ironport-Server: esa3.hc3370-68.iphmx.com X-Remote-IP: 162.221.156.83 X-Policy: $RELAYED IronPort-Data: A9a23:wkIlAqnuMJDzGyxqp31RZiHo5gydJkRdPkR7XQ2eYbSJt1+Wr1Gzt xJOWGuDbP+JZDb0Kdwjb46z/BtU7ZSHndBjSwRkqng1EiMWpZLJC+rCIxarNUt+DCFioGGLT Sk6QoOdRCzhZiaE/n9BCpC48T8kk/vgqoPUUIYoAAgoLeNfYHpn2EoLd9IR2NYy24DiW1rV4 7senuWEULOb828sWo4rw/rrRCNH5JwebxtB4zTSzdgS1LPvvyF94KA3fMldHFOhKmVgJcaoR v6r8V2M1jixEyHBqD+Suu2TnkUiGtY+NOUV45Zcc/DKbhNq/kTe3kunXRa1hIg+ZzihxrhMJ NtxWZOYbg10Dq7VxfYhVBgASC8uOu5i9oP/Li3q2SCT5xWun3rExvxvCAc9PJEC+/YxCmZLn RAaAGlTNFbZ3bvwme/lDLk37iggBJCD0Ic3s3d8zTbfHLA+TIrKWani7t5ExjYgwMtJGJ4yY uJHNGA3MU6bOHWjPH9JBJ8kmbewmkXlTDtWjECetPQ14XbqmVkZPL/Fb4OOJ43iqd9utl2Du mvM8mD9AxcbHN+S0zyI9jSrnOCntSjyQo4VGZWz/+Rmh1DVzWsWYDUGWF3+rfSnh0qWX9NEN 1dS6icotbI19kGgUp/6RRLQiGGAlg4RXZxXCeJS1e2W4vOKuUDDXDFCF2MfLox93CMredA0/ niDwuPqHGF9jLqUESmTprDXiT2OASdAeAfuehQ4ZQcC5tDipqQ6gRTOUstvHcaJszHlJd3j6 2vU9XZj3t3/meZOjvzmpg6f31pAs7CUFlZd2+nBYo6yAuqVjqaBbpfg11XU5O0owG2xHgjY5 yhsdyRzAYkz4XCxeM6lHb1l8FKBva/t3NjgbbhHRcFJG9OFoSPLQGyoyGsiTHqFy+5dEdMTX GfduBlK+LhYN2awYKl8buqZUpp2k/C/Toq5D6mNP7Kih6Sdkifdp0mCgmbKggjQfLUEy/lja f93j+72ZZrlNUiX5GXvHLpMuVPa7is/2XnSVfjGI+ePitKjiIquYe5dajOmN7lhhIvd+Vm92 4sPZqOilkQEOMWjM3a/zGLmBQ1TRZTNLcut8JI/my/qClcOJVzN/NeKmeJxI9E+xv8N/goKl 1nkMnJlJJPErSWvAW23hrpLMtsDgb4XQaoHABER IronPort-HdrOrdr: A9a23:crhbyazxyZGY8tnSuOGhKrPwKr1zdoMgy1knxilNoRw8SKOlfq eV7ZMmPH7P+U8ssR4b+OxoVJPsfZqYz+8W3WBzB8bHYOCFgguVxehZhOOIqQEIWReOk9K1vZ 0QFZSWY+efMbEVt6rHCXGDYrUd/OU= X-IronPort-AV: E=Sophos;i="5.90,146,1643691600"; d="scan'208";a="65205233" From: Anthony PERARD To: CC: , , , Anthony PERARD , Doug Goldstein Subject: [XEN PATCH 2/3] automation: automatically build debian:stable container Date: Tue, 1 Mar 2022 12:11:32 +0000 Message-ID: <20220301121133.19271-3-anthony.perard@citrix.com> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20220301121133.19271-1-anthony.perard@citrix.com> References: <20220301121133.19271-1-anthony.perard@citrix.com> MIME-Version: 1.0 Only run this on the staging branch, whenever the dockerfile changes. Signed-off-by: Anthony PERARD --- .gitlab-ci.yml | 2 ++ automation/gitlab-ci/containers.yaml | 22 ++++++++++++++++++++++ 2 files changed, 24 insertions(+) create mode 100644 automation/gitlab-ci/containers.yaml diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index c8bd7519d5..f934d3eff8 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -1,7 +1,9 @@ stages: + - containers - build - test include: + - 'automation/gitlab-ci/containers.yaml' - 'automation/gitlab-ci/build.yaml' - 'automation/gitlab-ci/test.yaml' diff --git a/automation/gitlab-ci/containers.yaml b/automation/gitlab-ci/containers.yaml new file mode 100644 index 0000000000..2daf257f11 --- /dev/null +++ b/automation/gitlab-ci/containers.yaml @@ -0,0 +1,22 @@ +debian-stable-container: + stage: containers + image: docker:stable + variables: + BUILD_CONTAINER: debian/stable + tags: + - container-builder + only: + refs: + - staging + changes: + - automation/build/${BUILD_CONTAINER}.dockerfile + services: + - docker:dind + before_script: + - apk add make + - docker info + - docker login -u $CI_DEPLOY_USER -p $CI_DEPLOY_PASSWORD $CI_REGISTRY + script: + - make -C automation/build ${BUILD_CONTAINER} PUSH=1 + after_script: + - docker logout From patchwork Tue Mar 1 12:11:33 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Anthony PERARD X-Patchwork-Id: 12764674 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id EF769C433F5 for ; Tue, 1 Mar 2022 12:12:03 +0000 (UTC) Received: from list by lists.xenproject.org with outflank-mailman.281299.479590 (Exim 4.92) (envelope-from ) id 1nP1M3-0000Rz-6d; Tue, 01 Mar 2022 12:11:47 +0000 X-Outflank-Mailman: Message body and most headers restored to incoming version Received: by outflank-mailman (output) from mailman id 281299.479590; Tue, 01 Mar 2022 12:11:47 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1nP1M3-0000Qy-0H; Tue, 01 Mar 2022 12:11:47 +0000 Received: by outflank-mailman (input) for mailman id 281299; Tue, 01 Mar 2022 12:11:46 +0000 Received: from se1-gles-sth1-in.inumbo.com ([159.253.27.254] helo=se1-gles-sth1.inumbo.com) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1nP1M2-0008Ic-1O for xen-devel@lists.xenproject.org; Tue, 01 Mar 2022 12:11:46 +0000 Received: from esa3.hc3370-68.iphmx.com (esa3.hc3370-68.iphmx.com [216.71.145.155]) by se1-gles-sth1.inumbo.com (Halon) with ESMTPS id c2e86dc5-9958-11ec-8eba-a37418f5ba1a; Tue, 01 Mar 2022 13:11:45 +0100 (CET) X-BeenThere: xen-devel@lists.xenproject.org List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xenproject.org Precedence: list Sender: "Xen-devel" X-Inumbo-ID: c2e86dc5-9958-11ec-8eba-a37418f5ba1a DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=citrix.com; s=securemail; t=1646136705; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=fvTSRerL3DdcqoyCmQ0+MA1pOOEfGWViyWiS5fU/zLA=; b=DDPj4bNJOrtGiDYZ/b7sCSjeBTxOpm2IJGRZgcgmF4mBytOxIM7Cob3a 8mb3punCkri7i9dFvYetSJyWmQgjL0OKFYaf6tN1/fEaGlEImuaPfTkR/ 0mPnnwe3JUBkVd0cWsdD8uPzIBfFS144PujVHM43kss3ZkGMZ9CyKdlP1 8=; Authentication-Results: esa3.hc3370-68.iphmx.com; dkim=none (message not signed) header.i=none X-SBRS: 5.1 X-MesageID: 65205238 X-Ironport-Server: esa3.hc3370-68.iphmx.com X-Remote-IP: 162.221.156.83 X-Policy: $RELAYED IronPort-Data: A9a23:hiHVhq1UC5XQPIzHrfbD5c9xkn2cJEfYwER7XKvMYLTBsI5bp2YEx 2AfUGjUbvyIZWrxLd1xOd+//EkHuJCGnddiGVZspC1hF35El5HIVI+TRqvS04J+DSFhoGZPt Zh2hgzodZhsJpPkjk7xdOCn9xGQ7InQLlbGILes1htZGEk1EE/NtTo5w7Rj2tUw2IDja++wk YiaT/P3aQfNNwFcagr424rbwP+4lK2v0N+wlgVWicFj5DcypVFMZH4sDfjZw0/DaptVBoaHq 9Prl9lVyI97EyAFUbtJmp6jGqEDryW70QKm0hK6UID66vROS7BbPg/W+5PwZG8O4whlkeydx /0UrLC+eTsOJ5btwuY6fRZWGTFAJZNZreqvzXiX6aR/zmXDenrohf5vEFs3LcsT/eMf7WNmr KJCbmpXN1ba2rzwkOnTpupE36zPKOHiOp8fvXdxiynUF/88TbjIQrnQ5M8e1zA17ixLNaiDP ZJEM2E/BPjGSydpYQgQNaI8oLqhiHbycx0BpkKzvaVitgA/yyQuieOwYbI5YOeiXt5Jl0yVo mbH+WXRARwAMtGbjz2f/RqEjebVkST2cIkbDrG/+7hhh1j77nweDlgaWEW2pdG9i1WiQJRPJ koM4C0soKMuskuxQbHVQBmQsHOC+BkGVLJt//YSsV/XjPCOukDAWzZCHmUphMEaWNEeHCUG2 G+1uMrSJGZtl5OaR3iNyK+qsmbnUcQKFlMqaSgBRAoDxtDspoAvkx7CJupe/L6JYs7dQm+pn W3TxMQqr/BK1JNQif3nlbzSq2/0/vD0ohgJChI7t45Pxidwf8abaoOh8jA3Bt4Qfd/CHjFtU JXp8vVyDdzi77nQzERho81XRdlFAspp1hWG2TaD+LF7qlyQF4aLJ9w43d2HDB4B3jw4UTHoe lTPngha+YVeOnCnBYcuPd7vU5txk/S5TI20PhwxUjaoSsIqHONg1HszDXN8Iki3yBR8+U3BE c3znTmQ4YYyVv08kWveqxY12r433CEurV4/trigpylLJYG2PSbPIZ9caQPmRrlgsMus/VWEm /4CZpDi40gOD4XDjtz/rNd7waYidiNgW/gbaqV/K4a+H+aRMDp5Wq+JnOh4INQNcmY8vr6gw 0xRk3RwkDLX7UAr4y3QApy/QNsDhapCkE8= IronPort-HdrOrdr: A9a23:HKz9f6k4paRf1XdCTpxvL7Q1lEbpDfIU3DAbv31ZSRFFG/Fxl6 iV8sjzsiWE7gr5OUtQ4exoV5PhfZqxz/JICMwqTNKftWrdyQyVxeNZnOjfKlTbckWUnINgPO VbAsxD4bXLfCFHZK3BgTVQfexO/DD+ytHLudvj X-IronPort-AV: E=Sophos;i="5.90,146,1643691600"; d="scan'208";a="65205238" From: Anthony PERARD To: CC: , , , Anthony PERARD , Doug Goldstein Subject: [XEN PATCH 3/3] automation: check for generated files Date: Tue, 1 Mar 2022 12:11:33 +0000 Message-ID: <20220301121133.19271-4-anthony.perard@citrix.com> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20220301121133.19271-1-anthony.perard@citrix.com> References: <20220301121133.19271-1-anthony.perard@citrix.com> MIME-Version: 1.0 Try to find out whether genereted files that are commited needs to be regenerated. Signed-off-by: Anthony PERARD --- automation/gitlab-ci/test.yaml | 10 +++++ automation/scripts/check-generated-files | 55 ++++++++++++++++++++++++ 2 files changed, 65 insertions(+) create mode 100755 automation/scripts/check-generated-files diff --git a/automation/gitlab-ci/test.yaml b/automation/gitlab-ci/test.yaml index 56747fb335..a4b08c26ca 100644 --- a/automation/gitlab-ci/test.yaml +++ b/automation/gitlab-ci/test.yaml @@ -25,6 +25,16 @@ build-each-commit-gcc: tags: - x86_64 +build-check-generated-files-tools: + extends: .test-jobs-common + variables: + CONTAINER: debian:stable + script: + - automation/scripts/check-generated-files + needs: [] + tags: + - x86_64 + qemu-alpine-arm64-gcc: extends: .test-jobs-common variables: diff --git a/automation/scripts/check-generated-files b/automation/scripts/check-generated-files new file mode 100755 index 0000000000..054ea3e025 --- /dev/null +++ b/automation/scripts/check-generated-files @@ -0,0 +1,55 @@ +#!/bin/bash + +# Check that generated files that are commited are actually up to date + +check_git_status() { + output="$(git status --porcelain --untracked-files=no)" + if [ -n "$output" ]; then + echo + echo "Files potentially needs to be regenerated:" + echo "$output" + return 1 + fi +} + +set -e +set -x + +# Try to have recently changed files more recent than generated files if those haven't been regenerated. +if [[ "$CI_COMMIT_BEFORE_SHA" && "$CI_COMMIT_BEFORE_SHA" != 0000000000000000000000000000000000000000 ]]; then + git switch --detach $CI_COMMIT_BEFORE_SHA + git switch --detach - +fi + +# Lists of files that generate other commited files: +touch tools/libs/light/*.idl + + +# Regen autoconf files +./autogen.sh + +# build up our configure options +cfgargs=() + +# Disable non-tools subsystems +cfgargs+=("--disable-xen") +cfgargs+=("--disable-stubdom") +cfgargs+=("--disable-docs") + + +# Disable external trees +cfgargs+=("--with-system-seabios=/bin/false") +cfgargs+=("--with-system-qemu=/bin/false") +cfgargs+=("--with-system-ipxe=/usr/lib/ipxe/ipxe.pxe") +cfgargs+=("--disable-ovmf") +cfgargs+=("--disable-pvshim") +cfgargs+=("--disable-qemu-traditional") + + +./configure --quiet "${cfgargs[@]}" +make -s -j$(nproc) build-tools + +if ! check_git_status; then + git diff + exit 1 +fi