From patchwork Tue Jan 14 11:00:19 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "srinuvasan.a" X-Patchwork-Id: 4005 Return-Path: Received: from shymkent.ilbers.de ([unix socket]) by shymkent (Cyrus 2.5.10-Debian-2.5.10-3+deb9u2) with LMTPA; Tue, 14 Jan 2025 12:00:55 +0100 X-Sieve: CMU Sieve 2.4 Received: from mail-wm1-f61.google.com (mail-wm1-f61.google.com [209.85.128.61]) by shymkent.ilbers.de (8.15.2/8.15.2/Debian-8+deb9u1) with ESMTPS id 50EB0mej021559 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT) for ; Tue, 14 Jan 2025 12:00:49 +0100 Received: by mail-wm1-f61.google.com with SMTP id 5b1f17b1804b1-4362b9c1641sf25307295e9.3 for ; Tue, 14 Jan 2025 03:00:49 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1736852443; cv=pass; d=google.com; s=arc-20240605; b=JwUAzXEp6qYj8AD9ok0QaPRJb5SOSkuL/UY7J3SeuVGf0W9jxsjrf9vdXeC9R+jTfm gpajNnMEsgGvDkMx3quUMXZZn060LDo49LGfAHfwMz3Ev6ApSOVHvQyLiIFkunXVKh8X +LPMoJwJx5Z1ZxWazv7ilMcVKM8vRH4eST9MTslyvXlAD9NMrYZ/ZZS4YfP6W1ybDfzu J9h8ZJNdrXWzj1vxo/p7JbMVDwon5LW6uAkPJ6hlW7IjJ+/X4wj6CdYKFcFwpj9Xwu/9 qg3t2eMwDvLyfMmnyx27sb3HHIYgXvZfWmVnjuUkbutXRAVEYpaphhoW4Ida8vPBbPRg 3D2w== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; h=list-unsubscribe:list-subscribe:list-archive:list-help:list-post :list-id:mailing-list:precedence:reply-to:feedback-id:mime-version :message-id:date:subject:cc:to:from:dkim-signature; bh=lM6mPhCLKDQE0d7s9GCMeigsSlXAlnoBjY+6Oa6FkIE=; fh=h1xQkIHZMIQLb0rYhyMtkw37ZWMLbTejniGAwueUUJ8=; b=hcnC/9X5cZiZSygp4wtVlnHShatRV+m9AFBOx9+hkuCyD5l/8QfE117kBnRTBCFpTj 5H3fxIr/58b61t0elGGZ5Ux/ZaRM6gE0kuegDCGeP2c/G7Hevo0tPpJbMyCtuZ/c+ov+ k9Z90DoJEsbSWWC6W8w0DWWLQDndU432OAihcj3blXkB4UuoFsN9lJv+blHpWfFTsldv g6YKvy7ggDGjKsrykb08QYQhbNa+ZwtQSXc6adxzGKjNtgmHzB8qzt6dojqVtFoQWqxx AxFQVFviNBkhSiYYsGHq5DI6mQ2uAnkrXySbr7kQ6gWmehRUaVeSgjjx/2hkjp9S0P2E hNQQ==; darn=isar-build.org ARC-Authentication-Results: i=2; gmr-mx.google.com; dkim=pass header.i=@siemens.com header.s=fm1 header.b=pEQ2Fo3w; spf=pass (google.com: domain of fm-1324425-2025011411003908d3d116a3dcb5d988-g4wuo0@rts-flowmailer.siemens.com designates 185.136.64.227 as permitted sender) smtp.mailfrom=fm-1324425-2025011411003908d3d116a3dcb5d988-g4WUo0@rts-flowmailer.siemens.com; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=siemens.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlegroups.com; s=20230601; t=1736852443; x=1737457243; darn=isar-build.org; h=list-unsubscribe:list-subscribe:list-archive:list-help:list-post :list-id:mailing-list:precedence:reply-to :x-original-authentication-results:x-original-sender:feedback-id :mime-version:message-id:date:subject:cc:to:from:from:to:cc:subject :date:message-id:reply-to; bh=lM6mPhCLKDQE0d7s9GCMeigsSlXAlnoBjY+6Oa6FkIE=; b=cbyRu9w5fYgED3HwplXM8/OJd/3xd7YwaCguu6cD77nRSsPB5Pd0Hex7NwdfG7rb8s MYpf1yIQuLA80amPCvwWF0ctaiS3E/V0PijrWeNwEl3yzBjnnxgYDsgKjtE8tdhghiQm mP6LkUz1Yq6vmTGzDtwUuxl7X+vWgds0SQuIucdCQ+ykjpNfezR2bgmcXntzoaWzUnPu /k0MbladPizD17oWlbU2LwTSn5iGlETtJ6agphmGbrWyUIXTUh6JTMSo6pmXw+vir6IW wcbJEg/fhA2r04FUK04eDbj/DhC6YdCcw5YLLyeAstBaDMiFjwUrGSDfIeij0iqF1N2K neXw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1736852443; x=1737457243; h=list-unsubscribe:list-subscribe:list-archive:list-help:list-post :x-spam-checked-in-group:list-id:mailing-list:precedence:reply-to :x-original-authentication-results:x-original-sender:feedback-id :mime-version:message-id:date:subject:cc:to:from:x-beenthere :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=lM6mPhCLKDQE0d7s9GCMeigsSlXAlnoBjY+6Oa6FkIE=; b=n8Er1lAXkWJP6OUkmB4hzRpPv6Z9MuUmHHkAVYVsZ0Tyo277d3vTowl0LEO5tlVshG A9JIwGPWW1kz7KSakIZGV6qQU8Jb/uebJrArI6LZBM/hcjEG+ftQ2SwhdHrL7TyrfsMm gB7NEOadRZ/Qj2IAQidpy9oEuvdv12Hilg8a/Is2ll1ZbzOmPCb1C7YR65Wcrl0Gdqrp 87aEX/LRzGhXZnDRu/Q6efMCOh2vsDCcgOcZFvSDEkMG+HKWv7CDp7nFGs8VzO1erOLu GK8Q7GPUjRqmztt+h2EMuC0BLj3iJSRShkn4vvbgII0615WKSxJB70EFY0EU07Fe5Fcv kAig== X-Forwarded-Encrypted: i=2; AJvYcCUAat+eX1lGVteQkzMee4O0M4HodnMpGgfLsbUryLdbAe+LzTDzaJJCGJM9QR3av6pIKxFIaxM=@isar-build.org X-Gm-Message-State: AOJu0Yz+MGQ8tlIBRIzdLhTfqI1TuTxvgvAZW/pgASdhiQDfl3jPtPnW B4EGAl/nGqfBpTrgZiaYRsxVBwoN9FaTbLnqWrO8tYFI3/whZuGf X-Google-Smtp-Source: AGHT+IHy6aauffyfvqV+MuC8CGtl+wK1iYBuOYIMQUlawdtLBHR4tSTPr+jQ7IvGXSfhBXPRgw9nmg== X-Received: by 2002:a05:600c:3b94:b0:434:e2ea:fc94 with SMTP id 5b1f17b1804b1-436e2696cb8mr242431555e9.11.1736852442774; Tue, 14 Jan 2025 03:00:42 -0800 (PST) X-BeenThere: isar-users@googlegroups.com Received: by 2002:a05:600c:5353:b0:434:f37c:2a56 with SMTP id 5b1f17b1804b1-436e88428c0ls27834435e9.1.-pod-prod-03-eu; Tue, 14 Jan 2025 03:00:40 -0800 (PST) X-Received: by 2002:a05:600c:3b8a:b0:434:f270:a4f0 with SMTP id 5b1f17b1804b1-436e26dda80mr184729225e9.21.1736852440406; Tue, 14 Jan 2025 03:00:40 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1736852440; cv=none; d=google.com; s=arc-20240605; b=X9CHud8taZINHKzsAiWu9Ud5AXGEAGdb0l2AfmPGx23anBF79E/E/GoLcFatbqs2K2 vC+ZRbCTes/JYof0kzR9RZs8l7qOoUZixFK+hAvbFwI+DtXE7bM/4I4NyzwmMJq829UB lIOJeNGNTl8psshIsyavy6uPQNXkcZtJgiI7trbI20bwkdP7sHafANwj45LBcPYX1Qvx rMaW1eGyo1SEQmqTEfnkzjcIA2h0dv3zTKJlUhSYGIHUfE6QlNK9n2L5tmP0X3yCDAwM xLUuezBU7EBqRuPhc8sVi0sntmQ3+b/H8uQArKF2/TxZvKNO8yRY6rB7knSckpSSr5ad o5mg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; h=feedback-id:content-transfer-encoding:mime-version:message-id:date :subject:cc:to:from:dkim-signature; bh=GgpRziIdclnimoh2ZsSt/S6u3O2aerYVVjsYH33y+xU=; fh=8FjR+eCpauVZhKjl62lGY5IVgnJRyvTOjoFZetZ3BF8=; b=ENC8xwovSojtasToLGcjxh0SSWxY/xizxWYqCnm7EiCPeW/0QoewRkyNyLwgHF5dgD igdn5kQ9BklHuEmPq6v7Tug427Qgic3a7U9kmcIIyog6AlmLCVWO75x15DqHgxrzcwq9 5qnUr7iz9eCVKYli49y7sV83TXFHIZjRDCMJlq662cGn7CAfhAQ6D56zvAZ0v1hkoU8U yAjg6sLXhSXn0OtLf9ijCG8nAhCfj3Ruxrjye+50f3hmP+UlWHa7RRKKrhBefxI89pHj bQgWxiGUdfknEGRgaFeF74wnbKIawgvJnm/QXfaLNeMHhaVWNcuQNkgfd+9cKAm3AA2d XRJw==; dara=google.com ARC-Authentication-Results: i=1; gmr-mx.google.com; dkim=pass header.i=@siemens.com header.s=fm1 header.b=pEQ2Fo3w; spf=pass (google.com: domain of fm-1324425-2025011411003908d3d116a3dcb5d988-g4wuo0@rts-flowmailer.siemens.com designates 185.136.64.227 as permitted sender) smtp.mailfrom=fm-1324425-2025011411003908d3d116a3dcb5d988-g4WUo0@rts-flowmailer.siemens.com; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=siemens.com Received: from mta-64-227.siemens.flowmailer.net (mta-64-227.siemens.flowmailer.net. [185.136.64.227]) by gmr-mx.google.com with ESMTPS id 5b1f17b1804b1-437c0efcc26si753235e9.0.2025.01.14.03.00.40 for (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Tue, 14 Jan 2025 03:00:40 -0800 (PST) Received-SPF: pass (google.com: domain of fm-1324425-2025011411003908d3d116a3dcb5d988-g4wuo0@rts-flowmailer.siemens.com designates 185.136.64.227 as permitted sender) client-ip=185.136.64.227; Received: by mta-64-227.siemens.flowmailer.net with ESMTPSA id 2025011411003908d3d116a3dcb5d988 for ; Tue, 14 Jan 2025 12:00:39 +0100 X-Patchwork-Original-From: "srinuvasan.a via isar-users" From: "srinuvasan.a" To: isar-users@googlegroups.com Cc: cedric.hombourger@siemens.com, ubely@ilbers.de, srinuvasan Subject: [PATCH] meta/recipes-devtools/sbuild-chroot: Use modern python formatting Date: Tue, 14 Jan 2025 16:30:19 +0530 Message-Id: <20250114110019.189529-1-srinuvasan.a@siemens.com> MIME-Version: 1.0 X-Flowmailer-Platform: Siemens Feedback-ID: 519:519-1324425:519-21489:flowmailer X-Original-Sender: srinuvasan.a@siemens.com X-Original-Authentication-Results: gmr-mx.google.com; dkim=pass header.i=@siemens.com header.s=fm1 header.b=pEQ2Fo3w; spf=pass (google.com: domain of fm-1324425-2025011411003908d3d116a3dcb5d988-g4wuo0@rts-flowmailer.siemens.com designates 185.136.64.227 as permitted sender) smtp.mailfrom=fm-1324425-2025011411003908d3d116a3dcb5d988-g4WUo0@rts-flowmailer.siemens.com; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=siemens.com X-Original-From: srinuvasan.a@siemens.com Reply-To: srinuvasan.a@siemens.com Precedence: list Mailing-list: list isar-users@googlegroups.com; contact isar-users+owners@googlegroups.com List-ID: X-Spam-Checked-In-Group: isar-users@googlegroups.com X-Google-Group-Id: 914930254986 List-Post: , List-Help: , List-Archive: , List-Unsubscribe: , X-Spam-Status: No, score=-4.9 required=5.0 tests=DKIMWL_WL_MED,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,MAILING_LIST_MULTI, RCVD_IN_DNSWL_BLOCKED,RCVD_IN_MSPIKE_H2,RCVD_IN_RP_CERTIFIED, RCVD_IN_RP_RNBL,RCVD_IN_RP_SAFE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.2 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on shymkent.ilbers.de X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= From: srinuvasan f-strings are faster and better than str.format(), and Moreover f-strings provide a concise and convenient way to embed Python expressions inside string literals for formatting, hence use f-strings rather than str.format(). Signed-off-by: srinuvasan --- .../recipes-devtools/sbuild-chroot/sbuild-chroot.inc | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/meta/recipes-devtools/sbuild-chroot/sbuild-chroot.inc b/meta/recipes-devtools/sbuild-chroot/sbuild-chroot.inc index d794c6fd..6478d3a6 100644 --- a/meta/recipes-devtools/sbuild-chroot/sbuild-chroot.inc +++ b/meta/recipes-devtools/sbuild-chroot/sbuild-chroot.inc @@ -23,21 +23,21 @@ python() { if d.getVar('DISTRO_GCC'): d.appendVar('SBUILD_CHROOT_PREINSTALL_COMMON', - ' libgcc-{}-dev:{}'.format(distro_gcc, distro_arch)) + f" libgcc-{distro_gcc}-dev:{distro_arch}") d.appendVar('SBUILD_CHROOT_PREINSTALL_COMMON', - ' libstdc++-{}-dev:{}'.format(distro_gcc, distro_arch)) + f" libstdc++-{distro_gcc}-dev:{distro_arch}") if bb.utils.to_boolean(d.getVar('ISAR_ENABLE_COMPAT_ARCH')): compat_arch = d.getVar('COMPAT_DISTRO_ARCH') d.appendVar('SBUILD_CHROOT_COMPAT_PREINSTALL', - ' libc6-dev:{}'.format(compat_arch)) + f" libc6-dev:{compat_arch}") d.appendVar('SBUILD_CHROOT_COMPAT_PREINSTALL', - ' crossbuild-essential-{}'.format(compat_arch)) + f" crossbuild-essential-{compat_arch}") if d.getVar('DISTRO_GCC'): d.appendVar('SBUILD_CHROOT_COMPAT_PREINSTALL', - ' libgcc-{}-dev:{}'.format(distro_gcc, compat_arch)) + f" libgcc-{distro_gcc}-dev:{compat_arch}") d.appendVar('SBUILD_CHROOT_COMPAT_PREINSTALL', - ' libstdc++-{}-dev:{}'.format(distro_gcc, compat_arch)) + f" libstdc++-{distro_gcc}-dev:{compat_arch}") } SBUILD_CHROOT_PREINSTALL_COMMON = " \