summaryrefslogtreecommitdiff
path: root/kconfiglib.py
diff options
context:
space:
mode:
authorUlf Magnusson <ulfalizer@gmail.com>2017-09-19 07:06:17 +0200
committerUlf Magnusson <ulfalizer@gmail.com>2017-09-19 07:29:33 +0200
commit4fce6c53e1bdac803c77f0be8bedece22d73c30c (patch)
tree7b22a9efadef8d7fba6dd957a50aa640b19c28e6 /kconfiglib.py
parent44a9a3df46782e40ae46ea2370db6ab06b49b3a0 (diff)
Include 'if' deps. in _determine_actual_symbols()
Previously, only WEIRD_1 and not WEIRD_2 would be considered not a choice symbol in the following fragment. This lead to a weird warning in U-Boot. choice config FOO config WEIRD_1 depends on FOO if FOO config WEIRD_2 endif endchoice Also add some testcases for weird choice symbols.
Diffstat (limited to 'kconfiglib.py')
-rw-r--r--kconfiglib.py8
1 files changed, 4 insertions, 4 deletions
diff --git a/kconfiglib.py b/kconfiglib.py
index 30b1493..b408900 100644
--- a/kconfiglib.py
+++ b/kconfiglib.py
@@ -1055,7 +1055,7 @@ class Config(object):
# Symbol or Choice
# See comment for 'menu_dep'
- stmt.menu_dep = depends_on_expr
+ stmt.menu_dep = _make_and(deps, depends_on_expr)
# Propagate dependencies to prompts
@@ -2369,9 +2369,9 @@ class Symbol(Item):
# dependencies inherited from enclosing menus and ifs
self.all_referenced_syms = set()
- # This records only dependencies specified with 'depends on'. Needed
- # when determining actual choice items (hrrrr...). See also
- # Choice._determine_actual_symbols().
+ # This records only dependencies from enclosing ifs and menus together
+ # with local 'depends on' dependencies. Needed when determining actual
+ # choice items (hrrrr...). See Choice._determine_actual_symbols().
self.menu_dep = None
# See Symbol.get_ref/def_locations().