From patchwork Tue Aug 1 12:15:20 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Roger Pau Monne X-Patchwork-Id: 9874471 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 3E0FB6038F for ; Tue, 1 Aug 2017 12:18:00 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 38E82286A4 for ; Tue, 1 Aug 2017 12:18:00 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 2DB0A286B9; Tue, 1 Aug 2017 12:18:00 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-4.2 required=2.0 tests=BAYES_00, RCVD_IN_DNSWL_MED autolearn=ham version=3.3.1 Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id C78DC286A9 for ; Tue, 1 Aug 2017 12:17:59 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dcW5L-0001um-Dr; Tue, 01 Aug 2017 12:15:39 +0000 Received: from mail6.bemta6.messagelabs.com ([193.109.254.103]) by lists.xenproject.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dcW5J-0001uV-Rr for xen-devel@lists.xenproject.org; Tue, 01 Aug 2017 12:15:37 +0000 Received: from [85.158.143.35] by server-8.bemta-6.messagelabs.com id 60/F2-09901-9E070895; Tue, 01 Aug 2017 12:15:37 +0000 X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFlrGIsWRWlGSWpSXmKPExsXitHSDve6LgoZ Ig0uvTSy+b5nM5MDocfjDFZYAxijWzLyk/IoE1owpB90LPktWtHxcwN7A+F+4i5GTQ0LAX2JD z012EJtNQEfi4tydbF2MHBwiAioSt/cagISZBUIkWo99ASsRBrLfd+wEs1mASpY+fcIGYvMKW ErsuX+MGWKknsTbiS8YQWxOASuJy/tngtUIAdUcXTgJql5Q4uTMJywQ8zUlWrf/Zoew5SWat8 5mhqhXlOif94BtAiPfLCQts5C0zELSsoCReRWjenFqUVlqka6lXlJRZnpGSW5iZo6uoYGZXm5 qcXFiempOYlKxXnJ+7iZGYJgxAMEOxrubAg4xSnIwKYnyKvbURwrxJeWnVGYkFmfEF5XmpBYf YpTh4FCS4J2X3xApJFiUmp5akZaZAwx4mLQEB4+SCO9HkDRvcUFibnFmOkTqFKMux6sJ/78xC bHk5eelSonz3gApEgApyijNgxsBi75LjLJSwryMQEcJ8RSkFuVmlqDKv2IU52BUEua9BjKFJz OvBG7TK6AjmICOkCytBTmiJBEhJdXAaBx5LNvL3OCHU4BOodHfSr4Lxq9lrl6sTmWcJbS8suK XRt6y70rrj/LaK1QKdkpK33z73MfJPJaRnVeh3GPqKoN/h3YvEaq6zfVUfuI65nXZ9RZl0Rfu XuhM8nPov7+nQSE5KLzGK2t3Fu8a3wqe/LMmGzm8M2TWJSU/tlreGxYr/piNf64SS3FGoqEWc 1FxIgDNt1cjuQIAAA== X-Env-Sender: prvs=3795ac843=roger.pau@citrix.com X-Msg-Ref: server-7.tower-21.messagelabs.com!1501589734!75981592!1 X-Originating-IP: [66.165.176.63] X-SpamReason: No, hits=0.0 required=7.0 tests=sa_preprocessor: VHJ1c3RlZCBJUDogNjYuMTY1LjE3Ni42MyA9PiAzMDYwNDg=\n, received_headers: No Received headers X-StarScan-Received: X-StarScan-Version: 9.4.25; banners=-,-,- X-VirusChecked: Checked Received: (qmail 53192 invoked from network); 1 Aug 2017 12:15:36 -0000 Received: from smtp02.citrix.com (HELO SMTP02.CITRIX.COM) (66.165.176.63) by server-7.tower-21.messagelabs.com with RC4-SHA encrypted SMTP; 1 Aug 2017 12:15:36 -0000 X-IronPort-AV: E=Sophos;i="5.41,306,1498521600"; d="scan'208";a="442180418" From: Roger Pau Monne To: Date: Tue, 1 Aug 2017 13:15:20 +0100 Message-ID: <20170801121526.25266-6-roger.pau@citrix.com> X-Mailer: git-send-email 2.11.0 (Apple Git-81) In-Reply-To: <20170801121526.25266-1-roger.pau@citrix.com> References: <20170801121526.25266-1-roger.pau@citrix.com> MIME-Version: 1.0 Cc: Ian Jackson , Roger Pau Monne Subject: [Xen-devel] [PATCH OSSTEST v2 05/11] mfi-common: move set_freebsd_runvars to mfi-common X-BeenThere: xen-devel@lists.xen.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xen.org Sender: "Xen-devel" X-Virus-Scanned: ClamAV using ClamSMTP So that it can also be used by make-hosts-flight. No functional change intended. Signed-off-by: Roger Pau Monné Acked-by: Ian Jackson --- make-freebsd-flight | 31 ------------------------------- mfi-common | 31 +++++++++++++++++++++++++++++++ 2 files changed, 31 insertions(+), 31 deletions(-) diff --git a/make-freebsd-flight b/make-freebsd-flight index 64dfe9a6..72695742 100755 --- a/make-freebsd-flight +++ b/make-freebsd-flight @@ -36,37 +36,6 @@ job_create_build_filter_callback () { : } -set_freebsd_runvars () { - # Caller should have done if required: - # local freebsd_runvars - # - # Figure out where are the installer binaries. The order is the - # following: - # - # 1. Env variable FREEBSD__BUILDJOB: use the output from a - # previous build--freebsd. - # - # 2. Env variables FREEBSD_DIST, FREEBSD_VERSION: set before calling - # into make-flight, provide the path to the installer image, the sets - # to install and the version being installed. - # - # 3. Config file FreeBSDDist, FreeBSDVersion: same as 2. except that - # they are set on the config file. - # - envvar="FREEBSD_${arch^^}_BUILDJOB" - if [ -n "${!envvar}" ]; then - freebsd_runvars="freebsdbuildjob=${!envvar}" - elif [ -n "$FREEBSD_DIST" ] && [ -n "$FREEBSD_VERSION" ]; then - freebsd_runvars="freebsd_distpath=$FREEBSD_DIST/$arch \ - freebsd_version=$FREEBSD_VERSION" - else - distpath=`getconfig "FreeBSDDist"` - version=`getconfig "FreeBSDVersion"` - freebsd_runvars="freebsd_distpath=$distpath/$arch \ - freebsd_version=$version" - fi -} - for arch in "$arches"; do set_freebsd_runvars job_create_build build-$arch-freebsd build-freebsd \ diff --git a/mfi-common b/mfi-common index 4827c827..8a9546ab 100644 --- a/mfi-common +++ b/mfi-common @@ -113,6 +113,37 @@ set_hostos_runvars () { esac } +set_freebsd_runvars () { + # Caller should have done if required: + # local freebsd_runvars + # + # Figure out where are the installer binaries. The order is the + # following: + # + # 1. Env variable FREEBSD__BUILDJOB: use the output from a + # previous build--freebsd. + # + # 2. Env variables FREEBSD_DIST, FREEBSD_VERSION: set before calling + # into make-flight, provide the path to the installer image, the sets + # to install and the version being installed. + # + # 3. Config file FreeBSDDist, FreeBSDVersion: same as 2. except that + # they are set on the config file. + # + local envvar="FREEBSD_${arch^^}_BUILDJOB" + if [ -n "${!envvar}" ]; then + freebsd_runvars="freebsdbuildjob=${!envvar}" + elif [ -n "$FREEBSD_DIST" ] && [ -n "$FREEBSD_VERSION" ]; then + freebsd_runvars="freebsd_distpath=$FREEBSD_DIST/$arch \ + freebsd_version=$FREEBSD_VERSION" + else + local distpath=`getconfig "FreeBSDDist"` + local version=`getconfig "FreeBSDVersion"` + freebsd_runvars="freebsd_distpath=$distpath/$arch \ + freebsd_version=$version" + fi +} + create_build_jobs () { local arch