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] [day] [month] [year] [list]
Message-ID: <20251125134030-7a8d0be5-7404-4885-b179-86b8aab4cd07@linutronix.de>
Date: Tue, 25 Nov 2025 13:52:55 +0100
From: Thomas Weißschuh <thomas.weissschuh@...utronix.de>
To: Ahmad Fatoum <a.fatoum@...gutronix.de>
Cc: Nathan Chancellor <nathan@...nel.org>, 
	Nicolas Schier <nicolas.schier@...ux.dev>, Simon Glass <sjg@...omium.org>, kernel@...gutronix.de, 
	linux-kernel@...r.kernel.org, linux-kbuild@...r.kernel.org, 
	Sascha Hauer <s.hauer@...gutronix.de>
Subject: Re: [PATCH] kbuild: add target to build a cpio containing modules

On Tue, Nov 25, 2025 at 01:07:20PM +0100, Ahmad Fatoum wrote:
> On 11/20/25 8:32 AM, Thomas Weißschuh wrote:
> >> diff --git a/scripts/Makefile.package b/scripts/Makefile.package
> >> index 74bcb9e7f7a4516473481468a0fcf700c3bead33..20eec9e2dec4dda3fa0ef64a15b80dccdcb55f90 100644
> >> --- a/scripts/Makefile.package
> >> +++ b/scripts/Makefile.package

(...)

> >> +quiet_cmd_cpio = CPIO    $@
> >> +      cmd_cpio = $(srctree)/usr/gen_initramfs.sh $< > $@
> > 
> > Use $(CONFIG_SHELL).
> 
> Can do. Is this to allow users to override CONFIG_SHELL from outside?

I think so. Some distributions do weird things.

> If so, why not go one step further and remove shebangs from scripts
> altogether to enforce that they are called with a $(VARIABLE) that can
> be overridden?

The shebang is also useful to enable syntax highlighting in editors, tell
linters which shell dialect (POSIX/bash) is expected and to run the script
without kbuild. I would just leave it as is.

(...)

> > Is the cpio-data= intended to make sure the line 'hostprogs := gen_init_cpio'
> > is executed? I don't think this works as usr/Makefile will overwrite 'cpio-data'
> > in any case. But it should be fine to make hostprogs definition unconditional.
> 
> Will add a commit making hostprogs := gen_init_cpio unconditional.
> The current approach worked though, because specifying the variable on
> the command line overrides cpio-data := assignments even if there are
> multiple.

Indeed. Good to know, thanks!


Thomas

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ