Kconfig:当特定的 CONFIG_* 开关导致问题时,如何阻止它?
Kconfig
中的 depends on
是否有相反的意思?当设置特定的 CONFIG_*
开关时,至少会打印一条警告,在 make 之后写入完整配置 (
?.config
) 后,该开关不兼容*_defconfig
我当前的问题:
我正在为 ARMv7-M Systick 计时器
开发新驱动程序。存在旧版本,但该版本缺少某些功能,并且未移植到新的 U-Boot 设备模型
(DM)。当新供应商同时使用这两种驱动程序时,就会导致链接器错误。
因此,当选择旧驱动程序时,我希望使用 Kconfig
阻止使用我的驱动程序。
或者有其他建议如何解决这个问题?
(这是使用 Kbuild/Kconfig
作为构建系统的项目的通用问题。)
Is there an opposite for depends on
in Kconfig
? Which at least prints a warning when a specific CONFIG_*
switch is set, which isn't compatible after the full configuration is written (.config
) after a make *_defconfig
?
My current problem:
I'm working on a new driver for the ARMv7-M Systick timer
. There exists an old version, but this version lacks in some functionality and isn't ported to the new U-Boot device model
(DM). When a new vendor use both driver, then this leads in an linker error.
So I want prevent with Kconfig
to use my driver, when the old driver is selected.
Or any other suggestion how to solve this?
(This is a generic question for projects which use Kbuild/Kconfig
as build system.)
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
文档指出您可以使用
取决于< /code>,所以你可以这样做:
The documentation states you can use
depends on <expr>
, so you can do: