diff --git a/tools/kconfig_new/confgen.py b/tools/kconfig_new/confgen.py index 5d4b5041e..72b102672 100755 --- a/tools/kconfig_new/confgen.py +++ b/tools/kconfig_new/confgen.py @@ -408,6 +408,8 @@ def write_cmake(deprecated_options, config, filename): val = sym.str_value if sym.orig_type in (kconfiglib.BOOL, kconfiglib.TRISTATE) and val == "n": val = "" # write unset values as empty variables + elif sym.orig_type == kconfiglib.STRING: + val = kconfiglib.escape(val) write("set({}{} \"{}\")\n".format( prefix, sym.name, val))