diff options
author | Simon Glass <sjg@chromium.org> | 2017-08-04 03:30:30 -0600 |
---|---|---|
committer | Simon Glass <sjg@chromium.org> | 2017-09-11 21:43:58 -0600 |
commit | 8639f69a61b47971dba47ab5ed72e47436729bb1 (patch) | |
tree | 05510aa7c0d0ef1acc2aab1561c6f65b1ca133be /tools/genboardscfg.py | |
parent | ee3e520dad0b368df4541cd0af0d4011cf481e5b (diff) |
genconfig.py: Print defconfig next to warnings
At present we sometimes see warnings of the form:
/tmp/tmpMA89kB:36: warning: overriding the value of CMD_SPL.
Old value: "y", new value: "y".
This is not very useful as it does not show whch defconfig file it relates
to. Update the tool to show this.
Signed-off-by: Simon Glass <sjg@chromium.org>
Diffstat (limited to 'tools/genboardscfg.py')
-rwxr-xr-x | tools/genboardscfg.py | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/tools/genboardscfg.py b/tools/genboardscfg.py index 2e871feaf4f..2345a197984 100755 --- a/tools/genboardscfg.py +++ b/tools/genboardscfg.py @@ -124,7 +124,7 @@ class KconfigScanner: os.environ['srctree'] = os.getcwd() os.environ['UBOOTVERSION'] = 'dummy' os.environ['KCONFIG_OBJDIR'] = '' - self._conf = kconfiglib.Config() + self._conf = kconfiglib.Config(print_warnings=False) def __del__(self): """Delete a leftover temporary file before exit. @@ -166,7 +166,10 @@ class KconfigScanner: else: f.write(line[colon + 1:]) - self._conf.load_config(self._tmpfile) + warnings = self._conf.load_config(self._tmpfile) + if warnings: + for warning in warnings: + print '%s: %s' % (defconfig, warning) try_remove(self._tmpfile) self._tmpfile = None |