From: Jonas Gorski <jogo@openwrt.org>
To: linux-kbuild@vger.kernel.org
Cc: "Yann E. MORIN" <yann.morin.1998@free.fr>
Subject: invisible choices in kconfig
Date: Thu, 3 Sep 2015 12:40:36 +0200 [thread overview]
Message-ID: <55E823A4.3020802@openwrt.org> (raw)
Hi,
I'm trying to add* an "conditionally invisible choice" to kconfig, but
it seems like visibility is treated like a dependency in contrast to
"normal" prompt-less or invisible menu options.
Is this intentional?
A simplified version of what I'm trying to have is
config FOO
bool "Foo"
choice
prompt "Baz" if FOO
default BAZ_A
config BAZ_A
bool "Baz A"
config BAZ_B
bool "Baz B"
endchoice
But unless FOO is set, neither BAZ_A nor BAZ_B will appear in .config or
will be set.
The obvious workaround is to define a duplicate set of hidden BAZ config
values that will get selected by the BAZ choice values. But then they
also need to copy the defaults from the choice and this gets dirty really
fast and easily out of sync, in addition of introducing twice as many
config symbols.
Regards
Jonas
* actually I already added one in the expectation that it works that way.
The default non prompt value isn't checked anywhere, only the non-default
options are, so it "worked" as expected, so I didn't noticed it was
broken.
reply other threads:[~2015-09-03 10:40 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=55E823A4.3020802@openwrt.org \
--to=jogo@openwrt.org \
--cc=linux-kbuild@vger.kernel.org \
--cc=yann.morin.1998@free.fr \
/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;
as well as URLs for NNTP newsgroup(s).