From nobody Fri May 10 03:45:43 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of lists.xenproject.org designates 192.237.175.120 as permitted sender) client-ip=192.237.175.120; envelope-from=xen-devel-bounces@lists.xenproject.org; helo=lists.xenproject.org; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of lists.xenproject.org designates 192.237.175.120 as permitted sender) smtp.mailfrom=xen-devel-bounces@lists.xenproject.org; dmarc=pass(p=reject dis=none) header.from=citrix.com ARC-Seal: i=1; a=rsa-sha256; t=1687364456; cv=none; d=zohomail.com; s=zohoarc; b=dYJnd4o9FEnARyp3B3qO43nMl1PhcbI0S82tfK+6hgUG+51TP2rVL//nB4tHu8EOYZ91eSVKnGANjo15T8Sk0UdgyTcm7CbK2NzprdDReK0QQF9YJoL+LFfHA7X7BLHZ3argnliEmfn7nJ90UlwH46EA3t0RNqiklAYHYYaktpY= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1687364456; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=DkCm9TFo8v2RoJIOmCSNeL+SjJV1Hpo+nbZ7hn2C8Dg=; b=ZKPLd2l4Q1+iG+Z31U9cv9y1kSskKPN/QJP6KQvmmf2Iu6jZadGeQPZpiQ37OEJR5PSK4jHcc1zvjdAfpDNb4XUlaVL7eaqrbldZYJ93Cu3BBQBk4qCnGhj0YKN+lcIbaSJRy8YZhtMUpWN5Hz7vmZ9Ei+4UB0jDKiuWGCgrd2s= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of lists.xenproject.org designates 192.237.175.120 as permitted sender) smtp.mailfrom=xen-devel-bounces@lists.xenproject.org; dmarc=pass header.from= (p=reject dis=none) Return-Path: Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) by mx.zohomail.com with SMTPS id 1687364456474357.0464647180145; Wed, 21 Jun 2023 09:20:56 -0700 (PDT) Received: from list by lists.xenproject.org with outflank-mailman.552932.863188 (Exim 4.92) (envelope-from ) id 1qC0Z9-0000ta-7p; Wed, 21 Jun 2023 16:20:19 +0000 Received: by outflank-mailman (output) from mailman id 552932.863188; Wed, 21 Jun 2023 16:20:19 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1qC0Z9-0000tT-5I; Wed, 21 Jun 2023 16:20:19 +0000 Received: by outflank-mailman (input) for mailman id 552932; Wed, 21 Jun 2023 16:20:18 +0000 Received: from se1-gles-flk1-in.inumbo.com ([94.247.172.50] helo=se1-gles-flk1.inumbo.com) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1qC0Z7-0000tN-SZ for xen-devel@lists.xenproject.org; Wed, 21 Jun 2023 16:20:18 +0000 Received: from esa5.hc3370-68.iphmx.com (esa5.hc3370-68.iphmx.com [216.71.155.168]) by se1-gles-flk1.inumbo.com (Halon) with ESMTPS id 7fd7d6ea-104f-11ee-8611-37d641c3527e; Wed, 21 Jun 2023 18:20:14 +0200 (CEST) X-Outflank-Mailman: Message body and most headers restored to incoming version 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: 7fd7d6ea-104f-11ee-8611-37d641c3527e DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=citrix.com; s=securemail; t=1687364414; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=Gb48MUKG+E+eor+Y9T0107+AbYui+pKfJlvFsRozBlw=; b=a/iu2aBYUubJjdWB5iU4lv8o/t7VpnUQC4J14Z0A65BazeccWf3LMjfY hY+i04+Dtg8SJvPGtyestnCHif+0thUCMfA8dT7vTbTkbQrMju66kiVYz PCN32KCHIBqrWkP+5rqp9qPIuuN3VlqZ04SZe8BiEKQ6Nc4VVeF4eN1sk U=; Authentication-Results: esa5.hc3370-68.iphmx.com; dkim=none (message not signed) header.i=none X-SBRS: 4.0 X-MesageID: 112386257 X-Ironport-Server: esa5.hc3370-68.iphmx.com X-Remote-IP: 162.221.156.123 X-Policy: $RELAYED IronPort-Data: A9a23:YRusZqAFMWTFIRVW/xbjw5YqxClBgxIJ4kV8jS/XYbTApD5x1WZVx 2YeWD+DM/eNZzfyc9lwYYW+8EgFupWGm9RiQQY4rX1jcSlH+JHPbTi7wuUcHAvJd5GeExg3h yk6QoOdRCzhZiaE/n9BCpC48T8nk/nOHuGmYAL9EngZbRd+Tys8gg5Ulec8g4p56fC0GArIs t7pyyHlEAbNNwVcbCRMs8pvlDs15K6p4G1C5wRiDRx2lAS2e0c9Xcp3yZ6ZdxMUcqEMdsamS uDKyq2O/2+x13/B3fv8z94X2mVTKlLjFVDmZkh+AsBOsTAbzsAG6Y4pNeJ0VKtio27hc+ada jl6ncfYpQ8BZsUgkQmGOvVSO3kW0aZuoNcrLZUj2CA6IoKvn3bEmp1T4E8K0YIw2bt4Hm5i/ NUkMiEcNw+ip8S276K2Vbw57igjBJGD0II3v3hhyXfSDOo8QICFSKLPjTNa9G5u3IYUR6+YP pdHL2M1N3wsYDUWUrsTIJs4gOevgGi5azBCoUiZjaE2/3LS3Ep6172F3N/9I4XQHpULxBvHz o7A12vdDhMcEo2f8BqA8W+i27TJzBngV51HQdVU8dY12QbOlwT/EiY+RVa95PW0lEO6c9ZeM FAPvDojq7Ao806mRcW7WAe3yFaGtxgQQctNEMU17QiMzuzf5APxLmoOQyNFadcmnNQrXjFs3 ViM9/vrGDhuvbu9WX+bsLCOoluaIjMJJGUPYSsFSwot4NT5pow3yBXVQb5LD6qdntDzXzbqz Fi3QDMW3utJy5RRjuPioA6B2mj3znTUcuIrziaKUX2qwgpQWJS0dtW3yHj97dlQIZnMGzFto 0M4d9iiAPEmVM/dy3bdH7xdRtlF9N7ebmSC3AcH840Jsm30piX9Jd04DCRWfh8BDyoSRdP+j KY/Uyt17YQbAnalZLQfj2mZW5VzlviI+TgIu5npgjtyjntZLlXvENlGPxL44owUuBFEfVsDE Zmaa92wKn0RFL5qyjG7L89Ej+90nHBgnT6DH8Chp/hC7VZ5TCTPIYrpzXPUNrxphE96iFi9H ylj2zuilEwEDbyWjtj/+o8PN1EaRUXX9rivw/G7gtWre1I8cEl4Uq+5/F/UU9A990ijvruSr y7Vt44x4AaXuEAr3i3aNiw8MO+zBs0XQLBSFXVEAGtEEkMLOe6HhJrzvbNtFVX73ISPFcJJc sQ= IronPort-HdrOrdr: A9a23:CyWqda9ic9VO3+SwEJVuk+AKI+orL9Y04lQ7vn2ZKCYlCPBw8v rEoB1173HJYVoqNU3I2urhBED4ewK7yXct2/hpAV7AZmjbUQmTXfpfBOLZqlWLJ8SUzIFgPM lbH5SWR+eAbmRSvILW7Ay5DNo60LC8gcWVbYC39QYUcejGUdAF0+48MHf9LmRmAA1LH4AwGp a/6tovnUvDRUgq X-Talos-CUID: 9a23:cpD+C2z7MWoQGQvJ9PGWBgU3R886fVHU5UvKMl7hFkdJbr26WVKPrfY= X-Talos-MUID: =?us-ascii?q?9a23=3AJo9F+w5c5aw3PGKfxApnzv65xoxnx6isDmZckaw?= =?us-ascii?q?mvsqZO3ErPWanlzuoF9o=3D?= X-IronPort-AV: E=Sophos;i="6.00,261,1681185600"; d="scan'208";a="112386257" From: Anthony PERARD To: CC: Anthony PERARD , Jason Andryuk , Andrew Cooper , "George Dunlap" , Jan Beulich , "Julien Grall" , Stefano Stabellini , Wei Liu Subject: [XEN PATCH 1/3] build: define ARCH and SRCARCH later Date: Wed, 21 Jun 2023 17:19:57 +0100 Message-ID: <20230621161959.1061178-2-anthony.perard@citrix.com> X-Mailer: git-send-email 2.40.1 In-Reply-To: <20230621161959.1061178-1-anthony.perard@citrix.com> References: <20230621161959.1061178-1-anthony.perard@citrix.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @citrix.com) X-ZM-MESSAGEID: 1687364458599100001 Content-Type: text/plain; charset="utf-8" Defining ARCH and SRCARCH later in xen/Makefile allows to switch to immediate evaluation variable type. ARCH and SRCARCH depends on value defined in Config.mk and aren't used TARGET_SUBARCH or TARGET_ARCH, and not before it's needed in a sub-make or a rule. This will help reduce the number of times the shell rune is been run. With GNU make 4.4, the number of execution of the command present in these $(shell ) increased greatly. This is probably because as of make 4.4, exported variable are also added to the environment of $(shell ) construct. Also, `make -d` shows a lot of these: Makefile:39: not recursively expanding SRCARCH to export to shell funct= ion Makefile:38: not recursively expanding ARCH to export to shell function Reported-by: Jason Andryuk Signed-off-by: Anthony PERARD Tested-by: Jason Andryuk Tested-by: for the whole series, FYI. --- xen/Makefile | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/xen/Makefile b/xen/Makefile index e89fc461fc4b..9631e45cfb9b 100644 --- a/xen/Makefile +++ b/xen/Makefile @@ -35,12 +35,6 @@ MAKEFLAGS +=3D -rR =20 EFI_MOUNTPOINT ?=3D $(BOOT_DIR)/efi =20 -ARCH=3D$(XEN_TARGET_ARCH) -SRCARCH=3D$(shell echo $(ARCH) | \ - sed -e 's/x86.*/x86/' -e s'/arm\(32\|64\)/arm/g' \ - -e s'/riscv.*/riscv/g') -export ARCH SRCARCH - # Allow someone to change their config file export KCONFIG_CONFIG ?=3D .config =20 @@ -241,6 +235,13 @@ include scripts/Kbuild.include include $(XEN_ROOT)/Config.mk =20 # Set ARCH/SUBARCH appropriately. + +ARCH :=3D $(XEN_TARGET_ARCH) +SRCARCH :=3D $(shell echo $(ARCH) | \ + sed -e 's/x86.*/x86/' -e s'/arm\(32\|64\)/arm/g' \ + -e s'/riscv.*/riscv/g') +export ARCH SRCARCH + export TARGET_SUBARCH :=3D $(XEN_TARGET_ARCH) export TARGET_ARCH :=3D $(shell echo $(XEN_TARGET_ARCH) | \ sed -e 's/x86.*/x86/' -e s'/arm\(32\|64\)/arm/= g' \ --=20 Anthony PERARD From nobody Fri May 10 03:45:43 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of lists.xenproject.org designates 192.237.175.120 as permitted sender) client-ip=192.237.175.120; envelope-from=xen-devel-bounces@lists.xenproject.org; helo=lists.xenproject.org; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of lists.xenproject.org designates 192.237.175.120 as permitted sender) smtp.mailfrom=xen-devel-bounces@lists.xenproject.org; dmarc=pass(p=reject dis=none) header.from=citrix.com ARC-Seal: i=1; a=rsa-sha256; t=1687364459; cv=none; d=zohomail.com; s=zohoarc; b=V4XNNeWBJfa9DHMacNwjmNH85FnJMVO93pf8wrxsy0cuzqEjZ/yIgQ10qkmpjyF0eJL3GcP9EfOUzfAryb8t8RawvvLBxEkR8i/c0HrS9NHGkXYg+XVc1LOgpkYzjhRbj5V05ktf/40zl94WzuF/QTV+5wqkZCY0Q90eNBPtmQk= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1687364459; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=5GeRI3DlfIOegCQxUGOBKrS5BTJoly9KuDv+ig8H33M=; b=ZXhFcd65aDuAmZRVoUJvC2hwYo8AUSiVbmCFiHohrRcGIqnSMtx3S09tpgiVKvhqnymvm7pHt5NtNXnBSrMVQAlkrvRmjl/Qc9LAeKqI1naz+SH9FT8zgwQ+0UFmvzVhJjjg62GRCpQDiG1hC7Io9bI7c0I9t4CuzLDH0pTVllQ= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of lists.xenproject.org designates 192.237.175.120 as permitted sender) smtp.mailfrom=xen-devel-bounces@lists.xenproject.org; dmarc=pass header.from= (p=reject dis=none) Return-Path: Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) by mx.zohomail.com with SMTPS id 1687364459573729.0111121859729; Wed, 21 Jun 2023 09:20:59 -0700 (PDT) Received: from list by lists.xenproject.org with outflank-mailman.552934.863208 (Exim 4.92) (envelope-from ) id 1qC0ZH-0001Q2-TM; Wed, 21 Jun 2023 16:20:27 +0000 Received: by outflank-mailman (output) from mailman id 552934.863208; Wed, 21 Jun 2023 16:20:27 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1qC0ZH-0001Pt-Ps; Wed, 21 Jun 2023 16:20:27 +0000 Received: by outflank-mailman (input) for mailman id 552934; Wed, 21 Jun 2023 16:20:26 +0000 Received: from se1-gles-flk1-in.inumbo.com ([94.247.172.50] helo=se1-gles-flk1.inumbo.com) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1qC0ZG-0000tN-ES for xen-devel@lists.xenproject.org; Wed, 21 Jun 2023 16:20:26 +0000 Received: from esa6.hc3370-68.iphmx.com (esa6.hc3370-68.iphmx.com [216.71.155.175]) by se1-gles-flk1.inumbo.com (Halon) with ESMTPS id 86a7faa8-104f-11ee-8611-37d641c3527e; Wed, 21 Jun 2023 18:20:24 +0200 (CEST) X-Outflank-Mailman: Message body and most headers restored to incoming version 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: 86a7faa8-104f-11ee-8611-37d641c3527e DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=citrix.com; s=securemail; t=1687364424; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=za3buGGichHq8l7ZDrIYQqz3imkrrBJj9JEN24suhkc=; b=BnJ2InxGIyHAzTl85hY7P6iqsPdEBPE60odSxjFeW85R99MT69EUXIEV yJHrGS0Fl+rXHsk01FaGztC26zyIPw+cdqh5/vn45IEBLmD1XyYeVOeiw vqJaST2jXCsp9C9kA8g5NNYn8WEAXa9TM6cMrURDzj8HfEfEkS8QJelo7 g=; Authentication-Results: esa6.hc3370-68.iphmx.com; dkim=none (message not signed) header.i=none X-SBRS: 4.0 X-MesageID: 112968613 X-Ironport-Server: esa6.hc3370-68.iphmx.com X-Remote-IP: 162.221.156.123 X-Policy: $RELAYED IronPort-Data: A9a23:d68rDq1mvf/mAbqcQvbD5e1xkn2cJEfYwER7XKvMYLTBsI5bp2RSy 2IWCjyFOfzZNmanLYslbYjl8RgP7JLUnNRjHgs5pC1hF35El5HIVI+TRqvS04F+DeWYFR46s J9OAjXkBJppJpMJjk71atANlVEliefTAOK6ULWeUsxIbVcMYD87jh5+kPIOjIdtgNyoayuAo tq3qMDEULOf82cc3lk8teTb8HuDgNyo4GlD5gJkPKgX1LPjvyJ94Kw3dPnZw0TQGuG4LsbiL 87fwbew+H/u/htFIrtJRZ6iLyXm6paLVeS/oiI+t5qK23CulQRrukoPD9IOaF8/ttm8t4sZJ OOhF3CHYVxB0qXkwIzxWvTDes10FfUuFLTveRBTvSEPpqFvnrSFL/hGVSkL0YMkFulfIzwTq dUdKWwxSxmDp7ik3LThcOdRmZF2RCXrFNt3VnBIyDjYCbAtQIzZQrWM7thdtNsyrpkQR7CEP ZNfMGcxKk2aOHWjOX9OYH46tO6umnn4dSwesF+PrLA7y2PS0BZwwP7mN9+9ltmiHJwPzxjI+ Dudl4j/KjMZNJ+0ygeMzm2D16zonT7+B5I9OKLto5aGh3XMnzdOWXX6T2CTsfS/z0KzRd9bA 0gV4TY167g/8lSxSdvwVAH+p2SL1jYeUtxcCfwn6ymCz6PV50CSAW1sZjxLZcEitcQ2bSc3z VLPlNTsbRRtrbmURHS15rqS6zSoNkA9NnQebCUJSQ8E5djLo4wpiB/LCNF5H8adkdndCTz2h TeQo0ADa6471JBRkf/hpBae3mzq/8KSJuIo2unJdkD4s19QYY/5W6mh6XiB/+pGdryXc0bU6 RDohPOiAPAy4YClzXLdH79dQ+j5vZ5pIxWH3wcxQsBJGyCFvif6INsOuGwWyFJBaJ5sRNP/X KPEVeq9Drd3NWDiU6J4apnZ5y8Cnfm5ToSNuhw5g7NzjnlNmOyvpnsGiba4hTyFraTVufhX1 W2nWcitF20GLq9s0SC7QewQuZdymHBhnzONHc2rlUT9uVZ7WJJyYe1fWGZik8hjtP/UyOkr2 4s32zS2J+V3D7SlP3i/HX87JlEWN3krba0aWOQOHtNv1jFOQTl7Y9eImONJRmCQt/gN/gs+1 i3nCxAwJZuWrSGvFDhmnVgzNO+wBcoj9ilT0O5FFQ/A5kXPqL2HtM83H6bbt5F9rISPEdYco yE5Rvi9 IronPort-HdrOrdr: A9a23:O4+ueq38PCzK4QmNl4MYoAqjBLQkLtp133Aq2lEZdPRUGvb2qy nIpoV96faUskdpZJhOo7G90cW7LE80sKQFg7X5Xo3SODUO2lHJEGgK1+KLqFfd8m/Fh4tgPM 9bAs5D4bbLY2SS4/yX3ODBKadC/OW6 X-Talos-CUID: 9a23:qAvoRGBp+nLofdL6Ews6qRI9H8F5TljUzFeKMVO+U1xndaLAHA== X-Talos-MUID: 9a23:51LYawp+qJH4NQlFhRoezxNhNIRD4JmnNF8iwNYhu9SBajxfFyjI2Q== X-IronPort-AV: E=Sophos;i="6.00,261,1681185600"; d="scan'208";a="112968613" From: Anthony PERARD To: CC: Anthony PERARD , Jason Andryuk , Andrew Cooper , "George Dunlap" , Jan Beulich , "Julien Grall" , Stefano Stabellini , Wei Liu Subject: [XEN PATCH 2/3] build: evaluate XEN_BUILD_* and XEN_DOMAIN on first use Date: Wed, 21 Jun 2023 17:19:58 +0100 Message-ID: <20230621161959.1061178-3-anthony.perard@citrix.com> X-Mailer: git-send-email 2.40.1 In-Reply-To: <20230621161959.1061178-1-anthony.perard@citrix.com> References: <20230621161959.1061178-1-anthony.perard@citrix.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @citrix.com) X-ZM-MESSAGEID: 1687364460480100005 Content-Type: text/plain; charset="utf-8" With GNU make 4.4, the number of execution of the command present in these $(shell ) increased greatly. This is probably because as of make 4.4, exported variable are also added to the environment of $(shell ) construct. Also, `make -d` shows a lot of these: Makefile:15: not recursively expanding XEN_BUILD_DATE to export to shel= l function Makefile:16: not recursively expanding XEN_BUILD_TIME to export to shel= l function Makefile:17: not recursively expanding XEN_BUILD_HOST to export to shel= l function Makefile:14: not recursively expanding XEN_DOMAIN to export to shell fu= nction So, to avoid having these command been run more than necessery, we will use a construct to evaluate on first use. Reported-by: Jason Andryuk Signed-off-by: Anthony PERARD --- xen/Makefile | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/xen/Makefile b/xen/Makefile index 9631e45cfb9b..b58c2a7f4539 100644 --- a/xen/Makefile +++ b/xen/Makefile @@ -11,10 +11,10 @@ export XEN_FULLVERSION =3D $(XEN_VERSION).$(XEN_SUBVE= RSION)$(XEN_EXTRAVERSION) -include xen-version =20 export XEN_WHOAMI ?=3D $(USER) -export XEN_DOMAIN ?=3D $(shell ([ -x /bin/dnsdomainname ] && /bin/dnsdomai= nname) || ([ -x /bin/domainname ] && /bin/domainname || echo [unknown])) -export XEN_BUILD_DATE ?=3D $(shell LC_ALL=3DC date) -export XEN_BUILD_TIME ?=3D $(shell LC_ALL=3DC date +%T) -export XEN_BUILD_HOST ?=3D $(shell hostname) +export XEN_DOMAIN ?=3D $(eval XEN_DOMAIN :=3D $(shell ([ -x /bin/dnsdomain= name ] && /bin/dnsdomainname) || ([ -x /bin/domainname ] && /bin/domainname= || echo [unknown])))$(XEN_DOMAIN) +export XEN_BUILD_DATE ?=3D $(eval XEN_BUILD_DATE :=3D $(shell LC_ALL=3DC d= ate))$(XEN_BUILD_DATE) +export XEN_BUILD_TIME ?=3D $(eval XEN_BUILD_TIME :=3D $(shell LC_ALL=3DC d= ate +%T))$(XEN_BUILD_TIME) +export XEN_BUILD_HOST ?=3D $(eval XEN_BUILD_HOST :=3D $(shell hostname))$(= XEN_BUILD_HOST) =20 # Best effort attempt to find a python interpreter, defaulting to Python 3= if # available. Fall back to just `python` if `which` is nowhere to be found. --=20 Anthony PERARD From nobody Fri May 10 03:45:43 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of lists.xenproject.org designates 192.237.175.120 as permitted sender) client-ip=192.237.175.120; envelope-from=xen-devel-bounces@lists.xenproject.org; helo=lists.xenproject.org; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of lists.xenproject.org designates 192.237.175.120 as permitted sender) smtp.mailfrom=xen-devel-bounces@lists.xenproject.org; dmarc=pass(p=reject dis=none) header.from=citrix.com ARC-Seal: i=1; a=rsa-sha256; t=1687364459; cv=none; d=zohomail.com; s=zohoarc; b=lq3/NDGNqGEa32onipSueEfANoCB2qycUCVMifmoYPfLvVNXKiZ/kFpBlQXVH+fxPkDFP8EAoMu1xBFU/5mcI1+lI9Ph/ZdM37su+bg6WZmbABkNJoy6AGrwfvXBnHcQ6a3lwLFRoHVvbRsWsKRUhh+eC882v2Un4GSo0UlYUU4= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1687364459; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=KUgiHHybVIClu2Jq0w2IGqjZMqO7Wch+VQBuOWsG8W8=; b=Ftpi09xGDwWuGJ+zCKaijBEaZRYW1qR8Wk2bU9LokVrS2a+z+0202QoJdzVcjCgrGb5rpJSr9/2c1JxSHP9MVPGvyCDyYMD8XRMIS6biTEPQHSapXkgUHSJVazXH0dB4XWICsnpAl4fgQLkXuzYPNGzcR3R5Ee0ujj40e6GJYaU= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of lists.xenproject.org designates 192.237.175.120 as permitted sender) smtp.mailfrom=xen-devel-bounces@lists.xenproject.org; dmarc=pass header.from= (p=reject dis=none) Return-Path: Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) by mx.zohomail.com with SMTPS id 1687364459566621.338970167622; Wed, 21 Jun 2023 09:20:59 -0700 (PDT) Received: from list by lists.xenproject.org with outflank-mailman.552935.863218 (Exim 4.92) (envelope-from ) id 1qC0ZJ-0001fy-5V; Wed, 21 Jun 2023 16:20:29 +0000 Received: by outflank-mailman (output) from mailman id 552935.863218; Wed, 21 Jun 2023 16:20:29 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1qC0ZJ-0001fr-2G; Wed, 21 Jun 2023 16:20:29 +0000 Received: by outflank-mailman (input) for mailman id 552935; Wed, 21 Jun 2023 16:20:27 +0000 Received: from se1-gles-flk1-in.inumbo.com ([94.247.172.50] helo=se1-gles-flk1.inumbo.com) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1qC0ZH-0000tN-J3 for xen-devel@lists.xenproject.org; Wed, 21 Jun 2023 16:20:27 +0000 Received: from esa6.hc3370-68.iphmx.com (esa6.hc3370-68.iphmx.com [216.71.155.175]) by se1-gles-flk1.inumbo.com (Halon) with ESMTPS id 86bd7a0c-104f-11ee-8611-37d641c3527e; Wed, 21 Jun 2023 18:20:25 +0200 (CEST) X-Outflank-Mailman: Message body and most headers restored to incoming version 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: 86bd7a0c-104f-11ee-8611-37d641c3527e DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=citrix.com; s=securemail; t=1687364425; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=FeiN0tZrNokVbRAYwlZ3w177gJNyDQjG2lOR1qJ+z1Q=; b=MkhyOWrv9TaxZVBygKMdBLdLrLwnKQBsHJiU6rfkA8TEBuP0ZEHENoa9 T5ktPqX8V589HZNlo+Yi8CEAHIeooYftehwn0NnQrN62iBpsAX2kOjBeU mGOmckreAkDYyVB63NvRrRqE0buVQzNOzaxVT07yIQw0AYl3XAb8KeplK 8=; Authentication-Results: esa6.hc3370-68.iphmx.com; dkim=none (message not signed) header.i=none X-SBRS: 4.0 X-MesageID: 112968615 X-Ironport-Server: esa6.hc3370-68.iphmx.com X-Remote-IP: 162.221.156.123 X-Policy: $RELAYED IronPort-Data: A9a23:aK77MKLbiVy/ipZGFE+R75UlxSXFcZb7ZxGr2PjKsXjdYENSgWAEx 2MfWjuGMvyMajOmfNwjYY63/EgF6MTVmN4xHFRlqX01Q3x08seUXt7xwmUcnc+xBpaaEB84t ZV2hv3odp1coqr0/0/1WlTZhSAgk/rOHvykU7Ss1hlZHWdMUD0mhQ9oh9k3i4tphcnRKw6Ws Jb5rta31GWNglaYCUpKrfrbwP9TlK6q4mhA4AZnPawjUGL2zBH5MrpOfcldEFOgKmVkNrbSb /rOyri/4lTY838FYj9yuu+mGqGiaue60Tmm0hK6aYD76vRxjnVaPpIAHOgdcS9qZwChxLid/ jnvWauYEm/FNoWU8AgUvoIx/ytWZcWq85efSZSzXFD6I+QrvBIAzt03ZHzaM7H09c5VXDwS3 PkZdAwoZxCj3fCqxuiBRNRz05FLwMnDZOvzu1llxDDdS/0nXYrCU+PB4towMDUY354UW6yEP oxANGQpNU6bC/FMEg5/5JYWleG0hn75YntApUicv6Yf6GnP1g1hlrPqNbI5f/TTHJ8EwBbG/ z+uE2LROy1AafLO4gi/3nPyo83NrzPqV4tMG+jtnhJtqALKnTFCYPEMbnOrrP/8hkOgVtZ3L 00P5jFovaU07FasTNT2Q1u/unHslhwVXdZKAvA5wA6Iw6vQpQ2eAwAsTDRMddgnv88eXiEx2 xmCmNaBLT5ytLyYT1qN+7HSqim9UQAONnMLbyIASQoD4vHgrZs1gxaJScxseIaqivXlFDe2x CqFxBXSnJ1K05RNjf/iuwma3XT1/MOhohMJChv/fD/4sip8ZdKZQoWoyQLJ8fAaFoikUQzU1 JQboPRy/NziHLnUynzSGrVSReHzjxqWGGaC2AAyRvHN4xzooif+Jt4IvVmSMW8zaq45lSnVj Fg/UO+7zLtaJzOUYKB+eOpd4Ox6nPG7RbwJuh05B+eig6SdlyfdpkmCnWbKgwjQfLEEyMnTw 6uzf8e2Fmo9Aq961jewTOp1+eZ1ln9klT2LGMChn07PPV+iiJm9E+1tDbdzRrphsPPsTPv9r r6zyPdmOz0ACbajM0E7AKYYLEwQLGhTOHwFg5U/SwJ3GSI/QDtJI6aIkdscl3lNw/w9ehHgo ivsBSe1CTPX2RX6FOl9QiA/NOy3Acok9hrW/0UEZD6V5pTqWq73hI93Snf9VeN/nAC/5ZaYl 8U4Rvg= IronPort-HdrOrdr: A9a23:nKWhJaqIi8UpSiAqhMSQJjMaV5oteYIsimQD101hICG8cqSj+P xG+85rsiMc6QxhIU3I9urgBEDtex7hHNtOkOss1NSZLW3bUQmTTL2KhLGKq1aLJ8S9zJ856U 4JSdkZNDSaNzZHZKjBjDVQa+xQo+W6zA== X-Talos-CUID: 9a23:HPgsfGzPI65Ukn8vPBLsBgU2R515W3jckEv1Kk+YU3R1TuevR2KPrfY= X-Talos-MUID: =?us-ascii?q?9a23=3AGmrBSQ7stVpQweutcoSAkZDuxoxR3/7zJhEmo68?= =?us-ascii?q?qupehFy5CKyaShWq4F9o=3D?= X-IronPort-AV: E=Sophos;i="6.00,261,1681185600"; d="scan'208";a="112968615" From: Anthony PERARD To: CC: Anthony PERARD , Jason Andryuk , Andrew Cooper , "George Dunlap" , Jan Beulich , "Julien Grall" , Stefano Stabellini , Wei Liu Subject: [XEN PATCH 3/3] Config.mk: evaluate XEN_COMPILE_ARCH and XEN_OS on first use Date: Wed, 21 Jun 2023 17:19:59 +0100 Message-ID: <20230621161959.1061178-4-anthony.perard@citrix.com> X-Mailer: git-send-email 2.40.1 In-Reply-To: <20230621161959.1061178-1-anthony.perard@citrix.com> References: <20230621161959.1061178-1-anthony.perard@citrix.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @citrix.com) X-ZM-MESSAGEID: 1687364460493100006 Content-Type: text/plain; charset="utf-8" With GNU make 4.4, the number of execution of the command present in these $(shell ) increased greatly. This is probably because as of make 4.4, exported variable are also added to the environment of $(shell ) construct. So, to avoid having these command been run more than necessery, we will use a construct to evaluate on first use. Reported-by: Jason Andryuk Signed-off-by: Anthony PERARD --- Config.mk | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Config.mk b/Config.mk index c529b1ba19cd..5fbdbc4500d2 100644 --- a/Config.mk +++ b/Config.mk @@ -19,13 +19,13 @@ or =3D $(if $(strip $(1)),$(1),$(if $(strip $(2))= ,$(2),$(if $(strip $(3)),$( =20 -include $(XEN_ROOT)/.config =20 -XEN_COMPILE_ARCH ?=3D $(shell uname -m | sed -e s/i.86/x86_32/ \ +XEN_COMPILE_ARCH ?=3D $(eval XEN_COMPILE_ARCH :=3D $(shell uname -m | s= ed -e s/i.86/x86_32/ \ -e s/i86pc/x86_32/ -e s/amd64/x86_64/ \ -e s/armv7.*/arm32/ -e s/armv8.*/arm64/ \ - -e s/aarch64/arm64/) + -e s/aarch64/arm64/))$(XEN_COMPILE_ARCH) =20 XEN_TARGET_ARCH ?=3D $(XEN_COMPILE_ARCH) -XEN_OS ?=3D $(shell uname -s) +XEN_OS ?=3D $(eval XEN_OS :=3D $(shell uname -s))$(XEN_OS) =20 CONFIG_$(XEN_OS) :=3D y =20 --=20 Anthony PERARD