diff options
author | Nirbheek Chauhan <nirbheek@centricular.com> | 2016-11-08 15:53:47 +0530 |
---|---|---|
committer | Jussi Pakkanen <jpakkane@gmail.com> | 2016-11-08 17:43:24 -0500 |
commit | a2262103fb749b570c4096b43ee107ad7143c04e (patch) | |
tree | 0f92a5ddca431d391d8918c9d84ec23c32d99389 /mesonbuild/backend/ninjabackend.py | |
parent | 841380acfe682023b0df9fa76debbe3030f31daa (diff) | |
download | meson-a2262103fb749b570c4096b43ee107ad7143c04e.zip meson-a2262103fb749b570c4096b43ee107ad7143c04e.tar.gz meson-a2262103fb749b570c4096b43ee107ad7143c04e.tar.bz2 |
Implement mlog.warning and use it everywhere for warnings
Prepends the string with 'WARNING:' in ANSI yellow.
Closes https://github.com/mesonbuild/meson/issues/961
Diffstat (limited to 'mesonbuild/backend/ninjabackend.py')
-rw-r--r-- | mesonbuild/backend/ninjabackend.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/mesonbuild/backend/ninjabackend.py b/mesonbuild/backend/ninjabackend.py index 0f8dcae..63380bd 100644 --- a/mesonbuild/backend/ninjabackend.py +++ b/mesonbuild/backend/ninjabackend.py @@ -215,7 +215,7 @@ int dummy; with open(os.path.join(builddir, 'compile_commands.json'), 'wb') as f: f.write(jsondb) except Exception: - mlog.log(mlog.red('Warning:', 'Could not create compilation database.')) + mlog.warning('Could not create compilation database.') # Get all generated headers. Any source file might need them so # we need to add an order dependency to them. @@ -581,7 +581,7 @@ int dummy; elem.add_item('DESC', 'Generating HTML coverage report.') elem.write(outfile) if not added_rule: - mlog.log(mlog.red('Warning:'), 'coverage requested but neither gcovr nor lcov/genhtml found.') + mlog.warning('coverage requested but neither gcovr nor lcov/genhtml found.') def generate_install(self, outfile): install_data_file = os.path.join(self.environment.get_scratch_dir(), 'install.dat') |