From: thilo zirnstein <thi.zirnstein@gmail.com>
To: buildroot@buildroot.org
Cc: thilo zirnstein <thi.zirnstein@gmail.com>
Subject: [Buildroot] [PATCH v1 0/1] pahole for kconfig
Date: Mon, 20 Jul 2026 23:22:22 +0200 [thread overview]
Message-ID: <20260720212223.551236-1-thi.zirnstein@gmail.com> (raw)
Hi all,
I recently noticed that I could not enable the CONFIG_DEBUG_INFO_BTF option,
even if I enable the BR2_LINUX_KERNEL_NEEDS_HOST_PAHOLE option.
The pahole was built prior to linux but not recognized when running make linux-menuconfig.
I dug a bit and the problem seems to be:
The environment for building the configuration editor is quite limited.
Refer $(2)_CONFIGURATOR_MAKE_ENV
It explicitly clears the PATH variable.
The same environment is used to run the configuration editor.
In this environment the pahole version cannot be determined (It does not exist)
The PAHOLE_VERSION is set to 0.
The pahole is a dependence of some configurations (CONFIG_DEBUG_INFO_BTF), which cannot be enabled :/
Now the fun part :)
If you read back the .config file after running menuconfig the pahole version is resolved.
This is due to the fact that the pkg-kconfig.mk does some magic after calling $$($(2)_DIR)/.kconfig_editor_%.
It runs a bunch of fixups, defined as $$($(2)_FIXUP_DOT_CONFIG), these fixups will run kconfig-package-regen-dot-config,
which creates a oldconfig with a different environment.
Now the path to host/bin/pahole is set and the pahole version is resolved.
Nevertheless, it is an issue that the pahole version is not correct when running menuconfig.
A user never can enable the CONFIG_DEBUG_INFO_BTF option, even if he enabled the BR2_LINUX_KERNEL_NEEDS_HOST_PAHOLE option.
My fix:
I resolved the issue by adding the pahole path explicitly to the linux make flags.
Thank you for maintaining buildroot and best regards,
thilo zirnstein (1):
linux: add host-pahole to linux make flags
linux/linux.mk | 1 +
1 file changed, 1 insertion(+)
--
2.43.0
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
next reply other threads:[~2026-07-20 21:22 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-07-20 21:22 thilo zirnstein [this message]
2026-07-20 21:22 ` [Buildroot] [PATCH v1 1/1] linux: add host-pahole to linux make flags thilo zirnstein
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=20260720212223.551236-1-thi.zirnstein@gmail.com \
--to=thi.zirnstein@gmail.com \
--cc=buildroot@buildroot.org \
/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