From: Nathan Chancellor <nathan@kernel.org>
To: Richard Acayan <mailingradian@gmail.com>
Cc: Masahiro Yamada <masahiroy@kernel.org>,
Nicolas Schier <nicolas@fjasle.eu>,
Kent Overstreet <kent.overstreet@linux.dev>,
linux-kbuild@vger.kernel.org, Jon Hunter <jonathanh@nvidia.com>
Subject: Re: [PATCH -next v2] kbuild: explicitly run mksysmap as sed script from link-vmlinux.sh
Date: Wed, 5 Jun 2024 11:15:34 -0700 [thread overview]
Message-ID: <20240605181534.GA3973798@thelio-3990X> (raw)
In-Reply-To: <20240605175807.106447-3-mailingradian@gmail.com>
On Wed, Jun 05, 2024 at 01:58:09PM -0400, Richard Acayan wrote:
> In commit b18b047002b7 ("kbuild: change scripts/mksysmap into sed
> script"), the mksysmap script was transformed into a sed script,
> made directly executable with "#!/bin/sed -f". Apparently, the path to
> sed is different on NixOS.
>
> The shebang can't use the env command, otherwise the "sed -f" command
> would be treated as a single argument. This can be solved with the -S
> flag, but that is a GNU extension. Explicitly use sed instead of relying
> on the executable shebang to fix NixOS builds without breaking build
> environments using Busybox.
>
> Fixes: b18b047002b7 ("kbuild: change scripts/mksysmap into sed script")
> Signed-off-by: Richard Acayan <mailingradian@gmail.com>
Reviewed-by: Nathan Chancellor <nathan@kernel.org>
> ---
> scripts/link-vmlinux.sh | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/scripts/link-vmlinux.sh b/scripts/link-vmlinux.sh
> index 46ce5d04dbeb..518c70b8db50 100755
> --- a/scripts/link-vmlinux.sh
> +++ b/scripts/link-vmlinux.sh
> @@ -193,7 +193,7 @@ kallsyms_step()
> mksysmap()
> {
> info NM ${2}
> - ${NM} -n "${1}" | "${srctree}/scripts/mksysmap" > "${2}"
> + ${NM} -n "${1}" | sed -f "${srctree}/scripts/mksysmap" > "${2}"
> }
>
> sorttable()
> --
> 2.45.2
>
next prev parent reply other threads:[~2024-06-05 18:15 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-06-05 17:58 [PATCH -next v2] kbuild: explicitly run mksysmap as sed script from link-vmlinux.sh Richard Acayan
2024-06-05 18:15 ` Nathan Chancellor [this message]
2024-06-06 13:16 ` Masahiro Yamada
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20240605181534.GA3973798@thelio-3990X \
--to=nathan@kernel.org \
--cc=jonathanh@nvidia.com \
--cc=kent.overstreet@linux.dev \
--cc=linux-kbuild@vger.kernel.org \
--cc=mailingradian@gmail.com \
--cc=masahiroy@kernel.org \
--cc=nicolas@fjasle.eu \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox