From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from shymkent.ilbers.de ([unix socket]) by shymkent (Cyrus 2.5.10-Debian-2.5.10-3+deb9u2) with LMTPA; Sun, 07 Sep 2025 22:54:12 +0200 X-Sieve: CMU Sieve 2.4 Received: from mail-qv1-f64.google.com (mail-qv1-f64.google.com [209.85.219.64]) by shymkent.ilbers.de (8.15.2/8.15.2/Debian-8+deb9u1) with ESMTPS id 587KsASQ032200 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT) for ; Sun, 7 Sep 2025 22:54:10 +0200 Received: by mail-qv1-f64.google.com with SMTP id 6a1803df08f44-70d7c7e972esf83181976d6.3 for ; Sun, 07 Sep 2025 13:54:10 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlegroups.com; s=20230601; t=1757278444; x=1757883244; darn=ilbers.de; h=list-unsubscribe:list-subscribe:list-archive:list-help:list-post :list-id:mailing-list:precedence:reply-to:x-original-sender :mime-version:subject:references:in-reply-to:message-id:to:from:date :from:to:cc:subject:date:message-id:reply-to; bh=CzmQv7n/L+QS7vIcEwiNHRQIJGWQDMqNjv9UCTLGtkQ=; b=IemSISSrPvd9CBZn5Rvvs8BcQOywhrw339CtST86s558P+mM6w25ZrDzgvAg/l1TdL o0Iegl1uhHdLiFBTyHRBNScaZfXHbA251T6RJIWj7j0K4cMYtHp8jrV3foBcjF977DcN kyWD66D1NGdy1grGkgU5IPGvtkAiQ2Yr+ujFgQKQtfEnMn8Ah7c3u51eEsDW4WSaHokl 7tPD54ia9V37V8tDS5PTpOma7IBw2xMslTcpb8Y886Pr644Xp+OMVIvLph1UytMLhe4G 0Haenvv+kyS/MKzvusfPRvXh0ZjkAOclLiMM/hdTwU8+0BHJXKPhzoDk4IOIDaT+U/mS aVkg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1757278444; x=1757883244; 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-sender:mime-version:subject:references:in-reply-to :message-id:to:from:date:x-beenthere:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=CzmQv7n/L+QS7vIcEwiNHRQIJGWQDMqNjv9UCTLGtkQ=; b=ZSKy8u6oXElpGTWdK4Yuwal0GDVxIWsYU+tUBAphCLVlj6338IVvmimwax/iK1yhhT 6ra+Z55ZN5+rNBc/9rZYq6Dc1tpR2F+6SBsPFA4nnTgyQ3S4jczqpjVhjEFC45lx42Mv lXc9QS6TYHGrx+BMaqrEc8GaKjuX29Y9oky3fGOoVxvQ87iJDS8a47ifXNWw9v1Cf8Go YR6Tn1pdr8INIp6CrDcfJD9aFvAZWnyzAPvM62sfJT9v/0ZUNpCRDoKs0R8MLE2VK0Nd JiwSBfcV8d+6cpCCNxMF/Twg/aNggz1dK2vxM+zmnR2L/tXLJ/gm2UqLa8+N2SRis1QD xkYQ== X-Forwarded-Encrypted: i=1; AJvYcCUbgr3dpsJN5NS3bYu/nHT2g16hae+P8SXJmEcmxDuZSzBNl621Jn8sE/D7Uj68UnXczMg5@ilbers.de X-Gm-Message-State: AOJu0YxzqOXpT3qXrQD5U/e8NM18FWKzj9dl0pePhjbVYrTa7sBNzQLC F8uTRMYYaAFHB89XB1TYGDTeRI60Ech4Rke15Nx4i0CCx5dZbyzpNCnB X-Google-Smtp-Source: AGHT+IEFPl1ZYNL8gEoza4tLXgK+gpxhtdeOY+wkRsBbP1BF42Ld/FysLfludQiPDPfIXaCJJ3jpqg== X-Received: by 2002:a05:6214:411:b0:70d:daae:c5ff with SMTP id 6a1803df08f44-7393ca9cae4mr71484906d6.39.1757278444319; Sun, 07 Sep 2025 13:54:04 -0700 (PDT) X-BeenThere: isar-users@googlegroups.com; h=ARHlJd6gpS+EAEHjNYXvCLniLnAzBoLnSbFdnkmmewnTbm9JOg== Received: by 2002:a05:6214:2269:b0:707:5acb:366c with SMTP id 6a1803df08f44-72d44629a4els30461056d6.2.-pod-prod-00-us; Sun, 07 Sep 2025 13:54:03 -0700 (PDT) X-Received: by 2002:a05:620a:4708:b0:817:c961:73aa with SMTP id af79cd13be357-817c961755emr157217685a.14.1757278443121; Sun, 07 Sep 2025 13:54:03 -0700 (PDT) Date: Sun, 7 Sep 2025 13:54:01 -0700 (PDT) From: "'Badrikesh Prusty' via isar-users" To: isar-users Message-Id: <242594a2-a961-4735-abf3-3b0c95f1f09fn@googlegroups.com> In-Reply-To: <20250907204258.201718-1-badrikesh.prusty@siemens.com> References: <20250907204258.201718-1-badrikesh.prusty@siemens.com> Subject: Re: [PATCH] meta: default "Rules-Requires-Root: no", make it configurable MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="----=_Part_298498_1713800846.1757278441979" X-Original-Sender: badrikesh.prusty@siemens.com X-Original-From: Badrikesh Prusty Reply-To: Badrikesh Prusty 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,HTML_MESSAGE,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-TUID: rk8jMAPGkrwy ------=_Part_298498_1713800846.1757278441979 Content-Type: multipart/alternative; boundary="----=_Part_298499_335249510.1757278441979" ------=_Part_298499_335249510.1757278441979 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Hello, This is follow up of the=20 patch: https://groups.google.com/g/isar-users/c/MYQDhaHPtX0/m/2ZWf0he8CgAJ =20 Some recipes use a predefined control.tmpl file instead of generating it=20 with the debianize class. Thanks, Badrikesh On Monday, September 8, 2025 at 2:13:15=E2=80=AFAM UTC+5:30 Badrikesh Prust= y wrote: > From: badrikesh prusty > > Setting "Rules-Requires-Root: no" in the debian/control file avoids > unnecessarily calling fakeroot in the build environment. Packages which > require root can override the new "DEBIAN_RULES_REQUIRES_ROOT" variable > with the desired value. > > Debian recommends not using fakeroot to build a package if it is not > required i.e., if a package's build doesn't require any privileged > operations such as changing ownership to root, installing/modifying > files as root. > > This also fixes hangs observed during fakeroot calls in > dpkg-buildpackage. References: > https://github.com/ilbers/isar/issues/113 > https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=3D1114644 > https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=3D1072521 > > Signed-off-by: Badrikesh Prusty > --- > meta/recipes-bsp/optee-ftpm/files/debian/control.tmpl | 1 + > meta/recipes-bsp/optee-ftpm/optee-ftpm.inc | 3 +++ > meta/recipes-bsp/optee-os/files/debian/control.tmpl | 1 + > meta/recipes-bsp/optee-os/optee-os.inc | 4 +++- > meta/recipes-bsp/trusted-firmware-a/files/debian/control.tmpl | 1 + > .../trusted-firmware-a/trusted-firmware-a-custom.inc | 4 +++- > meta/recipes-bsp/u-boot/files/debian/control.tmpl | 1 + > meta/recipes-bsp/u-boot/u-boot-custom.inc | 4 +++- > meta/recipes-kernel/linux-module/files/debian/control.tmpl | 1 + > meta/recipes-kernel/linux-module/module.inc | 2 ++ > meta/recipes-kernel/linux/files/debian/control.tmpl | 1 + > meta/recipes-kernel/linux/linux-custom.inc | 2 ++ > 12 files changed, 22 insertions(+), 3 deletions(-) > > diff --git a/meta/recipes-bsp/optee-ftpm/files/debian/control.tmpl=20 > b/meta/recipes-bsp/optee-ftpm/files/debian/control.tmpl > index e6af7554..d4374909 100644 > --- a/meta/recipes-bsp/optee-ftpm/files/debian/control.tmpl > +++ b/meta/recipes-bsp/optee-ftpm/files/debian/control.tmpl > @@ -4,6 +4,7 @@ Priority: optional > Standards-Version: 3.9.6 > Maintainer: Unknown maintainer > Build-Depends: debhelper-compat (=3D ${DEBIAN_COMPAT}),=20 > ${DEBIAN_BUILD_DEPENDS} > +Rules-Requires-Root: ${DEBIAN_RULES_REQUIRES_ROOT} > > Package: ${PN} > Architecture: any > diff --git a/meta/recipes-bsp/optee-ftpm/optee-ftpm.inc=20 > b/meta/recipes-bsp/optee-ftpm/optee-ftpm.inc > index 738b694a..257c5c4c 100644 > --- a/meta/recipes-bsp/optee-ftpm/optee-ftpm.inc > +++ b/meta/recipes-bsp/optee-ftpm/optee-ftpm.inc > @@ -23,6 +23,8 @@ DEBIAN_BUILD_DEPENDS ?=3D " \ > optee-os-tadevkit-${OPTEE_NAME} \ > " > > +DEBIAN_RULES_REQUIRES_ROOT ?=3D "no" > + > TA_CPU ?=3D "unknown" > TA_DEV_KIT_DIR ?=3D "unknown" > OPTEE_FTPM_BUILD_ARGS_EXTRA ?=3D " " > @@ -30,6 +32,7 @@ OPTEE_FTPM_BUILD_ARGS_EXTRA ?=3D " " > TEMPLATE_FILES =3D "debian/rules.tmpl debian/control.tmpl" > TEMPLATE_VARS +=3D "DEBIAN_BUILD_DEPENDS \ > DEBIAN_COMPAT \ > + DEBIAN_RULES_REQUIRES_ROOT \ > OPTEE_FTPM_BUILD_ARGS_EXTRA \ > TA_CPU \ > TA_DEV_KIT_DIR" > diff --git a/meta/recipes-bsp/optee-os/files/debian/control.tmpl=20 > b/meta/recipes-bsp/optee-os/files/debian/control.tmpl > index 7bcd6edb..443578bd 100644 > --- a/meta/recipes-bsp/optee-os/files/debian/control.tmpl > +++ b/meta/recipes-bsp/optee-os/files/debian/control.tmpl > @@ -4,6 +4,7 @@ Priority: optional > Standards-Version: 3.9.6 > Build-Depends: debhelper-compat (=3D ${DEBIAN_COMPAT}),=20 > ${DEBIAN_BUILD_DEPENDS} > Maintainer: ISAR project > +Rules-Requires-Root: ${DEBIAN_RULES_REQUIRES_ROOT} > > Package: ${DEBIAN_PACKAGE_NAME} > Architecture: ${DISTRO_ARCH} > diff --git a/meta/recipes-bsp/optee-os/optee-os.inc=20 > b/meta/recipes-bsp/optee-os/optee-os.inc > index eac75ae8..edd21f58 100644 > --- a/meta/recipes-bsp/optee-os/optee-os.inc > +++ b/meta/recipes-bsp/optee-os/optee-os.inc > @@ -22,8 +22,10 @@ DEBIAN_PACKAGE_NAME ?=3D "optee-os-${OPTEE_NAME}" > > DEBIAN_BUILD_DEPENDS ?=3D "python3-pycryptodome:native, python3-pyelftool= s" > > +DEBIAN_RULES_REQUIRES_ROOT ?=3D "no" > + > TEMPLATE_FILES =3D "debian/control.tmpl debian/rules.tmpl" > -TEMPLATE_VARS +=3D "DEBIAN_COMPAT DEBIAN_PACKAGE_NAME OPTEE_NAME=20 > DEBIAN_BUILD_DEPENDS OPTEE_PLATFORM OPTEE_EXTRA_BUILDARGS" > +TEMPLATE_VARS +=3D "DEBIAN_COMPAT DEBIAN_PACKAGE_NAME=20 > DEBIAN_RULES_REQUIRES_ROOT OPTEE_NAME DEBIAN_BUILD_DEPENDS OPTEE_PLATFORM= =20 > OPTEE_EXTRA_BUILDARGS" > > # split strip platform flavor, if any, from the specified platform string > OPTEE_PLATFORM_BASE =3D "${@d.getVar('OPTEE_PLATFORM').split('-')[0]}" > diff --git a/meta/recipes-bsp/trusted-firmware-a/files/debian/control.tmp= l=20 > b/meta/recipes-bsp/trusted-firmware-a/files/debian/control.tmpl > index cf4607e3..311b44c0 100644 > --- a/meta/recipes-bsp/trusted-firmware-a/files/debian/control.tmpl > +++ b/meta/recipes-bsp/trusted-firmware-a/files/debian/control.tmpl > @@ -4,6 +4,7 @@ Priority: optional > Standards-Version: 3.9.6 > Build-Depends: debhelper-compat (=3D ${DEBIAN_COMPAT}),=20 > ${DEBIAN_BUILD_DEPENDS} > Maintainer: ISAR project > +Rules-Requires-Root: ${DEBIAN_RULES_REQUIRES_ROOT} > > Package: trusted-firmware-a-${TF_A_NAME} > Architecture: ${DISTRO_ARCH} > diff --git=20 > a/meta/recipes-bsp/trusted-firmware-a/trusted-firmware-a-custom.inc=20 > b/meta/recipes-bsp/trusted-firmware-a/trusted-firmware-a-custom.inc > index 9f143b13..4ea7cc6c 100644 > --- a/meta/recipes-bsp/trusted-firmware-a/trusted-firmware-a-custom.inc > +++ b/meta/recipes-bsp/trusted-firmware-a/trusted-firmware-a-custom.inc > @@ -20,10 +20,12 @@ TF_A_BINARIES ?=3D "release/bl31.bin" > > DEBIAN_BUILD_DEPENDS ?=3D "" > > +DEBIAN_RULES_REQUIRES_ROOT ?=3D "no" > + > PROVIDES +=3D "trusted-firmware-a-${TF_A_NAME}" > > TEMPLATE_FILES =3D "debian/control.tmpl debian/rules.tmpl" > -TEMPLATE_VARS +=3D "DEBIAN_COMPAT \ > +TEMPLATE_VARS +=3D "DEBIAN_COMPAT DEBIAN_RULES_REQUIRES_ROOT \ > TF_A_NAME DEBIAN_BUILD_DEPENDS TF_A_PLATFORM TF_A_EXTRA_BUILDARGS" > > do_prepare_build() { > diff --git a/meta/recipes-bsp/u-boot/files/debian/control.tmpl=20 > b/meta/recipes-bsp/u-boot/files/debian/control.tmpl > index 006982c2..6cbdf02c 100644 > --- a/meta/recipes-bsp/u-boot/files/debian/control.tmpl > +++ b/meta/recipes-bsp/u-boot/files/debian/control.tmpl > @@ -4,6 +4,7 @@ Priority: optional > Standards-Version: 3.9.6 > Build-Depends: debhelper-compat (=3D ${DEBIAN_COMPAT}),=20 > ${DEBIAN_BUILD_DEPENDS} > Maintainer: ISAR project > +Rules-Requires-Root: ${DEBIAN_RULES_REQUIRES_ROOT} > > Package: u-boot-${MACHINE} > Architecture: ${DISTRO_ARCH} > diff --git a/meta/recipes-bsp/u-boot/u-boot-custom.inc=20 > b/meta/recipes-bsp/u-boot/u-boot-custom.inc > index 2d6dd8e0..e3081ce9 100644 > --- a/meta/recipes-bsp/u-boot/u-boot-custom.inc > +++ b/meta/recipes-bsp/u-boot/u-boot-custom.inc > @@ -20,12 +20,14 @@ SRC_URI +=3D "file://debian/" > > DEBIAN_BUILD_DEPENDS ?=3D "bc, bison, flex, device-tree-compiler, git" > > +DEBIAN_RULES_REQUIRES_ROOT ?=3D "no" > + > U_BOOT_BIN_INSTALL ?=3D "${U_BOOT_BIN}" > > U_BOOT_EXTRA_BUILDARGS ??=3D "BL31=3D${BL31} TEE=3D${TEE}" > > TEMPLATE_FILES =3D "debian/control.tmpl debian/rules.tmpl" > -TEMPLATE_VARS +=3D "MACHINE DEBIAN_BUILD_DEPENDS U_BOOT_CONFIG U_BOOT_BI= N \ > +TEMPLATE_VARS +=3D "MACHINE DEBIAN_BUILD_DEPENDS DEBIAN_RULES_REQUIRES_R= OOT=20 > U_BOOT_CONFIG U_BOOT_BIN \ > U_BOOT_EXTRA_BUILDARGS DEBIAN_COMPAT" > > U_BOOT_TOOLS_PACKAGE ?=3D "0" > diff --git a/meta/recipes-kernel/linux-module/files/debian/control.tmpl= =20 > b/meta/recipes-kernel/linux-module/files/debian/control.tmpl > index 45fcbc0e..914733d8 100644 > --- a/meta/recipes-kernel/linux-module/files/debian/control.tmpl > +++ b/meta/recipes-kernel/linux-module/files/debian/control.tmpl > @@ -4,6 +4,7 @@ Priority: optional > Standards-Version: 3.9.6 > Build-Depends: debhelper-compat (=3D ${DEBIAN_COMPAT}),=20 > ${DEBIAN_BUILD_DEPENDS} > Maintainer: ${MAINTAINER} > +Rules-Requires-Root: ${DEBIAN_RULES_REQUIRES_ROOT} > > Package: ${PN} > Architecture: any > diff --git a/meta/recipes-kernel/linux-module/module.inc=20 > b/meta/recipes-kernel/linux-module/module.inc > index d2a41766..b51e8965 100644 > --- a/meta/recipes-kernel/linux-module/module.inc > +++ b/meta/recipes-kernel/linux-module/module.inc > @@ -34,6 +34,7 @@ KERNEL_MODULE_SIGNATURES ??=3D "" > DEB_BUILD_PROFILES +=3D "${@'pkg.signwith' if=20 > bb.utils.to_boolean(d.getVar('KERNEL_MODULE_SIGNATURES')) else ''}" > DEPENDS +=3D "${@'module-signer secure-boot-secrets' if=20 > bb.utils.to_boolean(d.getVar('KERNEL_MODULE_SIGNATURES')) else ''}" > DEBIAN_BUILD_DEPENDS .=3D "${@', module-signer, secure-boot-secrets' if= =20 > bb.utils.to_boolean(d.getVar('KERNEL_MODULE_SIGNATURES')) else ''}" > +DEBIAN_RULES_REQUIRES_ROOT ?=3D "no" > > SRC_URI +=3D "file://debian/" > > @@ -63,6 +64,7 @@ TEMPLATE_VARS +=3D " \ > KAFLAGS \ > MODULE_DIR \ > DEBIAN_BUILD_DEPENDS \ > + DEBIAN_RULES_REQUIRES_ROOT \ > SIGNATURE_KEYFILE \ > SIGNATURE_CERTFILE \ > SIGNATURE_HASHFN \ > diff --git a/meta/recipes-kernel/linux/files/debian/control.tmpl=20 > b/meta/recipes-kernel/linux/files/debian/control.tmpl > index a79b86c4..479f8ff0 100644 > --- a/meta/recipes-kernel/linux/files/debian/control.tmpl > +++ b/meta/recipes-kernel/linux/files/debian/control.tmpl > @@ -4,6 +4,7 @@ Priority: optional > Maintainer: ${MAINTAINER} > Build-Depends: debhelper-compat (=3D ${DEBIAN_COMPAT}), bc, kmod, cpio,= =20 > ${KBUILD_DEPENDS} > Homepage: http://www.kernel.org/ > +Rules-Requires-Root: ${DEBIAN_RULES_REQUIRES_ROOT} > > Package: linux-image-${KERNEL_NAME_PROVIDED} > Build-Profiles: > diff --git a/meta/recipes-kernel/linux/linux-custom.inc=20 > b/meta/recipes-kernel/linux/linux-custom.inc > index 01e9bff7..e073206f 100644 > --- a/meta/recipes-kernel/linux/linux-custom.inc > +++ b/meta/recipes-kernel/linux/linux-custom.inc > @@ -17,6 +17,8 @@ DISTRIBUTOR ?=3D "ISAR" > # pinned due to known or possible issues with compat 12 > DEBIAN_COMPAT:buster =3D "10" > > +DEBIAN_RULES_REQUIRES_ROOT ?=3D "no" > + > KBUILD_DEPENDS ?=3D "build-essential:native, \ > libelf-dev:native, \ > libncurses-dev:native, \ > --=20 > 2.47.3 > > --=20 You received this message because you are subscribed to the Google Groups "= isar-users" group. To unsubscribe from this group and stop receiving emails from it, send an e= mail to isar-users+unsubscribe@googlegroups.com. To view this discussion visit https://groups.google.com/d/msgid/isar-users/= 242594a2-a961-4735-abf3-3b0c95f1f09fn%40googlegroups.com. ------=_Part_298499_335249510.1757278441979 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Hello,

This is follow up of the patch:=C2=A0https://gr= oups.google.com/g/isar-users/c/MYQDhaHPtX0/m/2ZWf0he8CgAJ
=C2=A0<= /div>
Some recipes use a predefined control.tmpl file instead of genera= ting it with the debianize=C2=A0class.

Thanks,
Badrikesh

On Monday, September 8, 2025 at 2:13:15=E2= =80=AFAM UTC+5:30 Badrikesh Prusty wrote:
From: badrikesh prusty <badrikes...@siemens.com>

Setting "Rules-Requires-Root: no" in the debian/control file = avoids
unnecessarily calling fakeroot in the build environment. Packages which
require root can override the new "DEBIAN_RULES_REQUIRES_ROOT"= ; variable
with the desired value.

Debian recommends not using fakeroot to build a package if it is not
required i.e., if a package's build doesn't require any privile= ged
operations such as changing ownership to root, installing/modifying
files as root.

This also fixes hangs observed during fakeroot calls in
dpkg-buildpackage. References:
https://gith= ub.com/ilbers/isar/issues/113
https://bugs.debian.org/cgi-bin/bugreport.cgi?bug= =3D1114644
https://bugs.debian.org/cgi-bin/bugreport.cgi?bug= =3D1072521

Signed-off-by: Badrikesh Prusty <badrikes...@siemens.com>
---
meta/recipes-bsp/optee-ftpm/files/debian/control.tmpl | 1 +
meta/recipes-bsp/optee-ftpm/optee-ftpm.inc | 3 +++
meta/recipes-bsp/optee-os/files/debian/control.tmpl | 1 +
meta/recipes-bsp/optee-os/optee-os.inc | 4 +++-
meta/recipes-bsp/trusted-firmware-a/files/debian/control.tmpl | 1 +
.../trusted-firmware-a/trusted-firmware-a-custom.inc | 4 +++-
meta/recipes-bsp/u-boot/files/debian/control.tmpl | 1 +
meta/recipes-bsp/u-boot/u-boot-custom.inc | 4 +++-
meta/recipes-kernel/linux-module/files/debian/control.tmpl | 1 +
meta/recipes-kernel/linux-module/module.inc | 2 ++
meta/recipes-kernel/linux/files/debian/control.tmpl | 1 +
meta/recipes-kernel/linux/linux-custom.inc | 2 ++
12 files changed, 22 insertions(+), 3 deletions(-)

diff --git a/meta/recipes-bsp/optee-ftpm/files/debian/control.tmpl b/me= ta/recipes-bsp/optee-ftpm/files/debian/control.tmpl
index e6af7554..d4374909 100644
--- a/meta/recipes-bsp/optee-ftpm/files/debian/control.tmpl
+++ b/meta/recipes-bsp/optee-ftpm/files/debian/control.tmpl
@@ -4,6 +4,7 @@ Priority: optional
Standards-Version: 3.9.6
Maintainer: Unknown maintainer <unk...@example.com>
Build-Depends: debhelper-compat (=3D ${DEBIAN_COMPAT}), ${DEBIAN_BUILD= _DEPENDS}
+Rules-Requires-Root: ${DEBIAN_RULES_REQUIRES_ROOT}
=20
Package: ${PN}
Architecture: any
diff --git a/meta/recipes-bsp/optee-ftpm/optee-ftpm.inc b/meta/recipes-= bsp/optee-ftpm/optee-ftpm.inc
index 738b694a..257c5c4c 100644
--- a/meta/recipes-bsp/optee-ftpm/optee-ftpm.inc
+++ b/meta/recipes-bsp/optee-ftpm/optee-ftpm.inc
@@ -23,6 +23,8 @@ DEBIAN_BUILD_DEPENDS ?=3D " \
optee-os-tadevkit-${OPTEE_NAME} = \
"
=20
+DEBIAN_RULES_REQUIRES_ROOT ?=3D "no"
+
TA_CPU ?=3D "unknown"
TA_DEV_KIT_DIR ?=3D "unknown"
OPTEE_FTPM_BUILD_ARGS_EXTRA ?=3D " "
@@ -30,6 +32,7 @@ OPTEE_FTPM_BUILD_ARGS_EXTRA ?=3D " "
TEMPLATE_FILES =3D "debian/rules.tmpl debian/control.tmpl"
TEMPLATE_VARS +=3D "DEBIAN_BUILD_DEPENDS \
DEBIAN_COMPAT \
+ DEBIAN_RULES_REQUIRES_ROOT \
OPTEE_FTPM_BUILD_ARGS_EXTRA \
TA_CPU \
TA_DEV_KIT_DIR"
diff --git a/meta/recipes-bsp/optee-os/files/debian/control.tmpl b/meta= /recipes-bsp/optee-os/files/debian/control.tmpl
index 7bcd6edb..443578bd 100644
--- a/meta/recipes-bsp/optee-os/files/debian/control.tmpl
+++ b/meta/recipes-bsp/optee-os/files/debian/control.tmpl
@@ -4,6 +4,7 @@ Priority: optional
Standards-Version: 3.9.6
Build-Depends: debhelper-compat (=3D ${DEBIAN_COMPAT}), ${DEBIAN_BUILD= _DEPENDS}
Maintainer: ISAR project <isar-...@googlegroups.com>
+Rules-Requires-Root: ${DEBIAN_RULES_REQUIRES_ROOT}
=20
Package: ${DEBIAN_PACKAGE_NAME}
Architecture: ${DISTRO_ARCH}
diff --git a/meta/recipes-bsp/optee-os/optee-os.inc b/meta/recipes-bsp/= optee-os/optee-os.inc
index eac75ae8..edd21f58 100644
--- a/meta/recipes-bsp/optee-os/optee-os.inc
+++ b/meta/recipes-bsp/optee-os/optee-os.inc
@@ -22,8 +22,10 @@ DEBIAN_PACKAGE_NAME ?=3D "optee-os-${OPTEE_NAME= }"
=20
DEBIAN_BUILD_DEPENDS ?=3D "python3-pycryptodome:native, python3-p= yelftools"
=20
+DEBIAN_RULES_REQUIRES_ROOT ?=3D "no"
+
TEMPLATE_FILES =3D "debian/control.tmpl debian/rules.tmpl"
-TEMPLATE_VARS +=3D "DEBIAN_COMPAT DEBIAN_PACKAGE_NAME OPTEE_NAME = DEBIAN_BUILD_DEPENDS OPTEE_PLATFORM OPTEE_EXTRA_BUILDARGS"
+TEMPLATE_VARS +=3D "DEBIAN_COMPAT DEBIAN_PACKAGE_NAME DEBIAN_RULE= S_REQUIRES_ROOT OPTEE_NAME DEBIAN_BUILD_DEPENDS OPTEE_PLATFORM OPTEE_EXTRA_= BUILDARGS"
=20
# split strip platform flavor, if any, from the specified platform str= ing
OPTEE_PLATFORM_BASE =3D "${@d.getVar('OPTEE_PLATFORM').sp= lit('-')[0]}"
diff --git a/meta/recipes-bsp/trusted-firmware-a/files/debian/control.t= mpl b/meta/recipes-bsp/trusted-firmware-a/files/debian/control.tmpl
index cf4607e3..311b44c0 100644
--- a/meta/recipes-bsp/trusted-firmware-a/files/debian/control.tmpl
+++ b/meta/recipes-bsp/trusted-firmware-a/files/debian/control.tmpl
@@ -4,6 +4,7 @@ Priority: optional
Standards-Version: 3.9.6
Build-Depends: debhelper-compat (=3D ${DEBIAN_COMPAT}), ${DEBIAN_BUILD= _DEPENDS}
Maintainer: ISAR project <isar-...@googlegroups.com>
+Rules-Requires-Root: ${DEBIAN_RULES_REQUIRES_ROOT}
=20
Package: trusted-firmware-a-${TF_A_NAME}
Architecture: ${DISTRO_ARCH}
diff --git a/meta/recipes-bsp/trusted-firmware-a/trusted-firmware-a-cus= tom.inc b/meta/recipes-bsp/trusted-firmware-a/trusted-firmware-a-custom.inc
index 9f143b13..4ea7cc6c 100644
--- a/meta/recipes-bsp/trusted-firmware-a/trusted-firmware-a-custom.inc
+++ b/meta/recipes-bsp/trusted-firmware-a/trusted-firmware-a-custom.inc
@@ -20,10 +20,12 @@ TF_A_BINARIES ?=3D "release/bl31.bin"
=20
DEBIAN_BUILD_DEPENDS ?=3D ""
=20
+DEBIAN_RULES_REQUIRES_ROOT ?=3D "no"
+
PROVIDES +=3D "trusted-firmware-a-${TF_A_NAME}"
=20
TEMPLATE_FILES =3D "debian/control.tmpl debian/rules.tmpl"
-TEMPLATE_VARS +=3D "DEBIAN_COMPAT \
+TEMPLATE_VARS +=3D "DEBIAN_COMPAT DEBIAN_RULES_REQUIRES_ROOT \
TF_A_NAME DEBIAN_BUILD_DEPENDS TF_A_PLATFORM TF_A_EXTRA_BUILDARGS&= quot;
=20
do_prepare_build() {
diff --git a/meta/recipes-bsp/u-boot/files/debian/control.tmpl b/meta/r= ecipes-bsp/u-boot/files/debian/control.tmpl
index 006982c2..6cbdf02c 100644
--- a/meta/recipes-bsp/u-boot/files/debian/control.tmpl
+++ b/meta/recipes-bsp/u-boot/files/debian/control.tmpl
@@ -4,6 +4,7 @@ Priority: optional
Standards-Version: 3.9.6
Build-Depends: debhelper-compat (=3D ${DEBIAN_COMPAT}), ${DEBIAN_BUILD= _DEPENDS}
Maintainer: ISAR project <isar-...@googlegroups.com>
+Rules-Requires-Root: ${DEBIAN_RULES_REQUIRES_ROOT}
=20
Package: u-boot-${MACHINE}
Architecture: ${DISTRO_ARCH}
diff --git a/meta/recipes-bsp/u-boot/u-boot-custom.inc b/meta/recipes-b= sp/u-boot/u-boot-custom.inc
index 2d6dd8e0..e3081ce9 100644
--- a/meta/recipes-bsp/u-boot/u-boot-custom.inc
+++ b/meta/recipes-bsp/u-boot/u-boot-custom.inc
@@ -20,12 +20,14 @@ SRC_URI +=3D "file://debian/"
=20
DEBIAN_BUILD_DEPENDS ?=3D "bc, bison, flex, device-tree-compiler,= git"
=20
+DEBIAN_RULES_REQUIRES_ROOT ?=3D "no"
+
U_BOOT_BIN_INSTALL ?=3D "${U_BOOT_BIN}"
=20
U_BOOT_EXTRA_BUILDARGS ??=3D "BL31=3D${BL31} TEE=3D${TEE}"
=20
TEMPLATE_FILES =3D "debian/control.tmpl debian/rules.tmpl"
-TEMPLATE_VARS +=3D "MACHINE DEBIAN_BUILD_DEPENDS U_BOOT_CONFIG U_= BOOT_BIN \
+TEMPLATE_VARS +=3D "MACHINE DEBIAN_BUILD_DEPENDS DEBIAN_RULES_REQ= UIRES_ROOT U_BOOT_CONFIG U_BOOT_BIN \
U_BOOT_EXTRA_BUILDARGS DEBIAN_COMPAT"
=20
U_BOOT_TOOLS_PACKAGE ?=3D "0"
diff --git a/meta/recipes-kernel/linux-module/files/debian/control.tmpl= b/meta/recipes-kernel/linux-module/files/debian/control.tmpl
index 45fcbc0e..914733d8 100644
--- a/meta/recipes-kernel/linux-module/files/debian/control.tmpl
+++ b/meta/recipes-kernel/linux-module/files/debian/control.tmpl
@@ -4,6 +4,7 @@ Priority: optional
Standards-Version: 3.9.6
Build-Depends: debhelper-compat (=3D ${DEBIAN_COMPAT}), ${DEBIAN_BUILD= _DEPENDS}
Maintainer: ${MAINTAINER}
+Rules-Requires-Root: ${DEBIAN_RULES_REQUIRES_ROOT}
=20
Package: ${PN}
Architecture: any
diff --git a/meta/recipes-kernel/linux-module/module.inc b/meta/recipes= -kernel/linux-module/module.inc
index d2a41766..b51e8965 100644
--- a/meta/recipes-kernel/linux-module/module.inc
+++ b/meta/recipes-kernel/linux-module/module.inc
@@ -34,6 +34,7 @@ KERNEL_MODULE_SIGNATURES ??=3D ""
DEB_BUILD_PROFILES +=3D "${@'pkg.signwith' if bb.utils.to= _boolean(d.getVar('KERNEL_MODULE_SIGNATURES')) else ''}&quo= t;
DEPENDS +=3D "${@'module-signer secure-boot-secrets' if b= b.utils.to_boolean(d.getVar('KERNEL_MODULE_SIGNATURES')) else '= '}"
DEBIAN_BUILD_DEPENDS .=3D "${@', module-signer, secure-boot-s= ecrets' if bb.utils.to_boolean(d.getVar('KERNEL_MODULE_SIGNATURES&#= 39;)) else ''}"
+DEBIAN_RULES_REQUIRES_ROOT ?=3D "no"
=20
SRC_URI +=3D "file://debian/"
=20
@@ -63,6 +64,7 @@ TEMPLATE_VARS +=3D " \
KAFLAGS \
MODULE_DIR \
DEBIAN_BUILD_DEPENDS \
+ DEBIAN_RULES_REQUIRES_ROOT \
SIGNATURE_KEYFILE \
SIGNATURE_CERTFILE \
SIGNATURE_HASHFN \
diff --git a/meta/recipes-kernel/linux/files/debian/control.tmpl b/meta= /recipes-kernel/linux/files/debian/control.tmpl
index a79b86c4..479f8ff0 100644
--- a/meta/recipes-kernel/linux/files/debian/control.tmpl
+++ b/meta/recipes-kernel/linux/files/debian/control.tmpl
@@ -4,6 +4,7 @@ Priority: optional
Maintainer: ${MAINTAINER}
Build-Depends: debhelper-compat (=3D ${DEBIAN_COMPAT}), bc, kmod, cpio= , ${KBUILD_DEPENDS}
Homepage: http://www.kernel.org/
+Rules-Requires-Root: ${DEBIAN_RULES_REQUIRES_ROOT}
=20
Package: linux-image-${KERNEL_NAME_PROVIDED}
Build-Profiles: <kernel>
diff --git a/meta/recipes-kernel/linux/linux-custom.inc b/meta/recipes-= kernel/linux/linux-custom.inc
index 01e9bff7..e073206f 100644
--- a/meta/recipes-kernel/linux/linux-custom.inc
+++ b/meta/recipes-kernel/linux/linux-custom.inc
@@ -17,6 +17,8 @@ DISTRIBUTOR ?=3D "ISAR"
# pinned due to known or possible issues with compat 12
DEBIAN_COMPAT:buster =3D "10"
=20
+DEBIAN_RULES_REQUIRES_ROOT ?=3D "no"
+
KBUILD_DEPENDS ?=3D "build-essential:native, \
libelf-dev:native, \
libncurses-dev:native, \
--=20
2.47.3

--
You received this message because you are subscribed to the Google Groups &= quot;isar-users" group.
To unsubscribe from this group and stop receiving emails from it, send an e= mail to isar-use= rs+unsubscribe@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/isar-use= rs/242594a2-a961-4735-abf3-3b0c95f1f09fn%40googlegroups.com.
------=_Part_298499_335249510.1757278441979-- ------=_Part_298498_1713800846.1757278441979--