aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--data/macros.meson1
-rw-r--r--docs/markdown/Commands.md2
-rw-r--r--docs/markdown/Release-notes-for-0.54.0.md5
-rw-r--r--mesonbuild/mcompile.py11
4 files changed, 18 insertions, 1 deletions
diff --git a/data/macros.meson b/data/macros.meson
index 8a66c96..cc4953c 100644
--- a/data/macros.meson
+++ b/data/macros.meson
@@ -28,6 +28,7 @@
%{shrink:%{__meson} compile \
-C %{_vpath_builddir} \
-j %{_smp_build_ncpus} \
+ --verbose \
%{nil}}
%meson_install \
diff --git a/docs/markdown/Commands.md b/docs/markdown/Commands.md
index 615b302..dbcfee4 100644
--- a/docs/markdown/Commands.md
+++ b/docs/markdown/Commands.md
@@ -137,6 +137,7 @@ meson configure builddir -Doption=new_value
```
$ meson compile [-h] [-j JOBS] [-l LOAD_AVERAGE] [--clean] [-C BUILDDIR]
+ [--verbose]
```
Builds a default or a specified target of a configured meson project.
@@ -153,6 +154,7 @@ optional arguments:
--clean Clean the build directory.
-C BUILDDIR The directory containing build files to
be built.
+ --verbose Show more verbose output.
```
#### Examples:
diff --git a/docs/markdown/Release-notes-for-0.54.0.md b/docs/markdown/Release-notes-for-0.54.0.md
index 3202b57..2f215de 100644
--- a/docs/markdown/Release-notes-for-0.54.0.md
+++ b/docs/markdown/Release-notes-for-0.54.0.md
@@ -359,3 +359,8 @@ target that has eight source files, Meson will generate two unity
files each of which includes four source files. The old behaviour can
be replicated by setting `unity_size` to a large value, such as 10000.
+## Verbose mode for `meson compile`
+
+The new option `--verbose` has been added to `meson compile` that will enable
+more verbose compilation logs. Note that for VS backend it means that logs will
+be less verbose by default (without `--verbose` option).
diff --git a/mesonbuild/mcompile.py b/mesonbuild/mcompile.py
index e457623..0bcb56e 100644
--- a/mesonbuild/mcompile.py
+++ b/mesonbuild/mcompile.py
@@ -54,6 +54,8 @@ def get_parsed_args_ninja(options: 'argparse.Namespace', builddir: Path):
cmd.extend(['-j', str(options.jobs)])
if options.load_average > 0:
cmd.extend(['-l', str(options.load_average)])
+ if options.verbose:
+ cmd.append('-v')
if options.clean:
cmd.append('clean')
@@ -74,8 +76,10 @@ def get_parsed_args_vs(options: 'argparse.Namespace', builddir: Path):
if options.load_average:
mlog.warning('Msbuild does not have a load-average switch, ignoring.')
+ if not options.verbose:
+ cmd.append('/v:minimal')
if options.clean:
- cmd.extend(['/t:Clean'])
+ cmd.append('/t:Clean')
return cmd
@@ -108,6 +112,11 @@ def add_arguments(parser: 'argparse.ArgumentParser') -> None:
default='.',
help='The directory containing build files to be built.'
)
+ parser.add_argument(
+ '--verbose',
+ action='store_true',
+ help='Show more verbose output.'
+ )
def run(options: 'argparse.Namespace') -> int: