Mauro Carvalho Chehab wrote:Which I just wrote is dangerous. It is easy to get wrong, and it is not maintainable. Here is what I would do: config TUNER_1 tristate "Tuner 1" depends on ACTUAL_DEP1_OF_T1 && ACTUAL_DEP2_OF_T1 config TUNER_2 tristate "Tuner 2" depends on ACTUAL_DEP1_OF_T2 && ACTUAL_DEP2_OF_T2 select ACTUAL_DEP3_OF_T2 In this example, ACTUAL_DEP3_OF_T2 does not have further dependencies itself. And if you believe that Kconfig should assist with runtime dependencies too, not just build-time dependencies, and you believe that the "help" and "comment" directives are insufficient for that, then add meta-options like this: config META_TUNER_A tristate "Meta-tuner A" select TUNER_1 depends on ACTUAL_DEP1_OF_T1 && ACTUAL_DEP2_OF_T1 # for TUNER_1 select TUNER_2 depends on ACTUAL_DEP1_OF_T2 && ACTUAL_DEP2_OF_T2 # for TUNER_2 select ACTUAL_DEP3_OF_T2 # for TUNER_2 help Adds support for cards which contain tuner 1 and/or tuner 2. So, like I said before, I recommend: - If an option has an actual build requirement, state it explicitly by "depends on" (or alternatively "select") directly at this option. Alternatively, enclose this option or a block of options which have identical dependencies in an "if"/ "endif" block, conditional on this common dependency. - Whenever you use "select", *copy* all dependencies of option A to option B if B selects A. Alternatively, replace "select" by "select ... if C" and *copy* all dependencies of option A to option C. This is because the Kconfig files (1.) must correctly state all build dependencies and (2.) must be maintainable. If you "select" a lot, you will have of course a lot of dependencies to copy. That's the nature of "select". You can't get around that. Not as long as there is no "select" which recursively checks and maybe selects dependencies of dependencies. -- Stefan Richter -=====-==--- -=-= -=--- http://arcgraph.de/sr/ --
| Stephen Smalley | Re: [AppArmor 39/45] AppArmor: Profile loading and manipulation, pathname matching |
| Tarkan Erimer | Re: Dual-Licensing Linux Kernel with GPL V2 and GPL V3 |
| Jan Engelhardt | intel iommu (Re: -mm merge plans for 2.6.23) |
| Greg Kroah-Hartman | [PATCH 005/196] Chinese: add translation of SubmittingDrivers |
git: | |
| David Fenyes | sigsetmask()? (LINUX) |
| Stephen Tweedie | Unmounting root (no kidding!) [was: Some Linux problems---solved] |
| Les Andrzejewski | X386/WD90C31/SUMSUNG SYNC MASTER 4 |
| Doug Evans | Re: Stabilizing Linux |
| Gerrit Renker | [PATCH 27/37] dccp: Integration of dynamic feature activation - part 2 (server side) |
| Linus Torvalds | Re: [GIT]: Networking |
| Jarek Poplawski | [PATCH] pkt_sched: Destroy gen estimators under rtnl_lock(). |
| Herbert Xu | Re: [PATCH] myr10ge: again fix lro_gen_skb() alignment |
