From patchwork Tue Feb 13 09:28:36 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Uwe_Kleine-K=C3=B6nig?= X-Patchwork-Id: 13554765 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 bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (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 89A09C4829A for ; Tue, 13 Feb 2024 09:29:01 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:Message-ID:Date:Subject:Cc :To:From:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References: List-Owner; bh=ll4N4IXaAmE9Y9lAhKaz8BM8JoDnrpcCoHCSjACRHf0=; b=Ua2it/2BwICze9 OTAou0W9TDXditqUp3k5x69yBq1G88dYBQxRRkrt6UZ8wzGlV4jWVjyptSJL0R4BecSnPrzcgqNI4 bKj4yHqYm9k9C3BVBlYXC5AmTO/1cfOuE3NaYrj82mDz5JiCAt+/Bp6XZzzzZpV/ZxGAvrob21ME+ WPpUBExhKPzXtEgBFwdua/VB5z+pzZ1cWiuFfTL9PobKWWqkhUz2k/3Hsupu+aN6QJ2zO9F+DyoVm NnmrTtf3UnGk7TSrqzeo28j+HERy4sbFNzg4LBD5kDLXTLBWi24OUYBZkthF/xUbap+eEn5a3C1N3 CxU2WIRmCyWfEk6rbblw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1rZp5r-00000008bGi-47pq; Tue, 13 Feb 2024 09:28:47 +0000 Received: from metis.whiteo.stw.pengutronix.de ([2a0a:edc0:2:b01:1d::104]) by bombadil.infradead.org with esmtps (Exim 4.97.1 #2 (Red Hat Linux)) id 1rZp5p-00000008bGJ-0jCV for linux-arm-kernel@lists.infradead.org; Tue, 13 Feb 2024 09:28:47 +0000 Received: from drehscheibe.grey.stw.pengutronix.de ([2a0a:edc0:0:c01:1d::a2]) by metis.whiteo.stw.pengutronix.de with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1rZp5m-0005Lo-2M; Tue, 13 Feb 2024 10:28:42 +0100 Received: from [2a0a:edc0:0:900:1d::77] (helo=ptz.office.stw.pengutronix.de) by drehscheibe.grey.stw.pengutronix.de with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1rZp5k-000SD2-Md; Tue, 13 Feb 2024 10:28:40 +0100 Received: from ukl by ptz.office.stw.pengutronix.de with local (Exim 4.96) (envelope-from ) id 1rZp5k-003qGQ-20; Tue, 13 Feb 2024 10:28:40 +0100 From: =?utf-8?q?Uwe_Kleine-K=C3=B6nig?= To: Russell King Cc: linux-arm-kernel@lists.infradead.org, kernel@pengutronix.de Subject: [PATCH] ARM: Don't mention the full path of the source directory in mach-types.h Date: Tue, 13 Feb 2024 10:28:36 +0100 Message-ID: <20240213092835.754462-2-u.kleine-koenig@pengutronix.de> X-Mailer: git-send-email 2.43.0 MIME-Version: 1.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=1566; i=u.kleine-koenig@pengutronix.de; h=from:subject; bh=Qh0oxqEgrfQGcAaKzx+3NV5WoWZwSsXQctbrRFxM8j4=; b=owEBbQGS/pANAwAKAY+A+1h9Ev5OAcsmYgBlyzZDCAakIzP3lf99mdNL9AQuFgf9wgopakLOp Nyuf6CKmwuJATMEAAEKAB0WIQQ/gaxpOnoeWYmt/tOPgPtYfRL+TgUCZcs2QwAKCRCPgPtYfRL+ TjX0B/9/fDzAoeXsXuoURcZ78DXu0E1bjrfsanwzF9p4S3VyD/OpFMHRyqtMNMLboHCNQFjNrGm UjQ8YPrcoCQIjPZkElScCLbezSF5aTI1kFr8dHvKtNTdVrhSvN3Zj6K2jOsmLlDXFM2zops11Bk DNvAjO88qkmcEsG+/HEljifpLygjGhcyum0RA6y98fV5ItaxHeqcD9WInvmDO8GRhrCUFo8aEDc qDFE28P42kb4vyZ6a640ciTS+SoNwmu4LGh2qKqK/KyAHpZuJm8ovNdDjww/0Euu6Ka57UxNgeu Ui8IKiH6rcsgLp8tpSYGKr4MToZ7QQEoZtQ7UxZTWEnkV0iT X-Developer-Key: i=u.kleine-koenig@pengutronix.de; a=openpgp; fpr=0D2511F322BFAB1C1580266BE2DCDD9132669BD6 X-SA-Exim-Connect-IP: 2a0a:edc0:0:c01:1d::a2 X-SA-Exim-Mail-From: ukl@pengutronix.de X-SA-Exim-Scanned: No (on metis.whiteo.stw.pengutronix.de); SAEximRunCond expanded to false X-PTX-Original-Recipient: linux-arm-kernel@lists.infradead.org X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20240213_012845_238168_7BD45C34 X-CRM114-Status: GOOD ( 13.48 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org To make package building reproducible independent of the location of the source tree, the absolute path of this source tree must not be mentioned in the built artifact. So strip $abs_srctree from FILENAME in the output. This fixes a warning issued by Yocto: WARNING: linux-lxatac-6.7-r0 do_package_qa: QA Issue: File /usr/src/debug/linux-lxatac/6.7-r0/arch/arm/include/generated/asm/mach-types.h in package linux-lxatac-src contains reference to TMPDIR Signed-off-by: Uwe Kleine-König --- arch/arm/tools/gen-mach-types | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/arch/arm/tools/gen-mach-types b/arch/arm/tools/gen-mach-types index cbe1c33bb871..9592ceb8a102 100644 --- a/arch/arm/tools/gen-mach-types +++ b/arch/arm/tools/gen-mach-types @@ -21,10 +21,21 @@ NF == 3 { num[nr] = ""; nr++ } +# prepend a \ to all special chars in a regexp +function quote(s) { + return gensub("[][\\^$.|()*+?{}]", "\\\\&", "g", s) +} + +# Strip the absolute path of the source tree from the parameter +# to make the result independent of where the source is located. +function relsrcfile(fn) { + sub("^" quote(ENVIRON["abs_srctree"]) "/", "", fn) + return fn +} END { printf("/*\n"); - printf(" * This was automagically generated from %s!\n", FILENAME); + printf(" * This was automagically generated from %s!\n", relsrcfile(FILENAME)); printf(" * Do NOT edit\n"); printf(" */\n\n"); printf("#ifndef __ASM_ARM_MACH_TYPE_H\n");