diff options
Diffstat (limited to 'tools')
-rwxr-xr-x | tools/config.py | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/tools/config.py b/tools/config.py index 96c4576..9283fd8 100755 --- a/tools/config.py +++ b/tools/config.py @@ -53,7 +53,12 @@ def main(args): def writeItem(node, gen): while node: if isinstance(node.item, kconfiglib.Symbol): - gen.write("#define CONFIG_{0} \"{1}\"\n".format(node.item.name, node.item.str_value)) + if node.item.str_value == 'y': + gen.write("#define CONFIG_{0}\n".format(node.item.name)) + elif node.item.str_value == 'n': + gen.write("#undef CONFIG_{0}\n".format(node.item.name)) + else: + gen.write("#define CONFIG_{0} \"{1}\"\n".format(node.item.name, node.item.str_value)) if node.list: writeItem(node.list, gen) |