lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date: Wed, 17 Apr 2024 04:37:46 +0000
From: Pratham Patel <prathampatel@...fossguy.com>
To: Masahiro Yamada <masahiroy@...nel.org>, Nathan Chancellor <nathan@...nel.org>, Nicolas Schier <nicolas@...sle.eu>, Jonathan Corbet <corbet@....net>
Cc: linux-kbuild@...r.kernel.org, linux-doc@...r.kernel.org, linux-kernel@...r.kernel.org, Pratham Patel <prathampatel@...fossguy.com>, thefirst1322@...il.com
Subject: [PATCH 1/2] kbuild: allow toggling the `with_devel` RPM macro

As it stands, there is no way to toggle the `with_devel` RPM macro
that is defined in the scripts/package/kernel.spec file, without
manually building the RPM.

Introduce the Kbuild variable KBUILD_RPM_WITH_DEVEL to toggle the
`with_devel` macro when building the binary PRM package.

The prior default of not building the `-devel` RPM package is preserved.

Signed-off-by: Pratham Patel <prathampatel@...fossguy.com>
---
 scripts/Makefile.package | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/scripts/Makefile.package b/scripts/Makefile.package
index 38653f3e8108..715e068eae60 100644
--- a/scripts/Makefile.package
+++ b/scripts/Makefile.package
@@ -47,6 +47,8 @@ $(linux-tarballs): .tmp_HEAD FORCE
 # rpm-pkg srcrpm-pkg binrpm-pkg
 # ---------------------------------------------------------------------------
 
+export KBUILD_RPM_WITH_DEVEL ?= 0
+
 quiet_cmd_mkspec = GEN     $@
       cmd_mkspec = $(srctree)/scripts/package/mkspec $@
 
@@ -71,7 +73,8 @@ rpm-pkg srcrpm-pkg binrpm-pkg: rpmbuild/SPECS/kernel.spec
 	+$(strip rpmbuild -b$(build-type) rpmbuild/SPECS/kernel.spec \
 	--define='_topdir $(abspath rpmbuild)' \
 	$(if $(filter a b, $(build-type)), \
-		--target $(UTS_MACHINE)-linux --build-in-place --noprep --define='_smp_mflags %{nil}' \
+		--target $(UTS_MACHINE)-linux --build-in-place --noprep \
+		--define='_smp_mflags %{nil}' --define='with_devel $(KBUILD_RPM_WITH_DEVEL)' \
 		$$(rpm -q rpm >/dev/null 2>&1 || echo --nodeps)) \
 	$(RPMOPTS))
 
-- 
2.42.0



Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ