aboutsummaryrefslogtreecommitdiff
path: root/docs/markdown/snippets
diff options
context:
space:
mode:
Diffstat (limited to 'docs/markdown/snippets')
-rw-r--r--docs/markdown/snippets/add_compile_backend_arg.md26
-rw-r--r--docs/markdown/snippets/add_meson_compile_target.md19
-rw-r--r--docs/markdown/snippets/clang_coverage.md4
-rw-r--r--docs/markdown/snippets/force_fallback_for.md10
-rw-r--r--docs/markdown/snippets/gir_fatal_warnings.md5
-rw-r--r--docs/markdown/snippets/machine_file_constants.md20
-rw-r--r--docs/markdown/snippets/response-files.md7
-rw-r--r--docs/markdown/snippets/wrap_patch.md13
8 files changed, 104 insertions, 0 deletions
diff --git a/docs/markdown/snippets/add_compile_backend_arg.md b/docs/markdown/snippets/add_compile_backend_arg.md
new file mode 100644
index 0000000..76e2abb
--- /dev/null
+++ b/docs/markdown/snippets/add_compile_backend_arg.md
@@ -0,0 +1,26 @@
+## Added ability to specify backend arguments in `meson compile`
+
+It's now possible to specify backend specific arguments in `meson compile`.
+
+Usage: `meson compile [--vs-args=args] [--ninja-args=args]`
+
+```
+ --ninja-args NINJA_ARGS Arguments to pass to `ninja` (applied only on `ninja` backend).
+ --vs-args VS_ARGS Arguments to pass to `msbuild` (applied only on `vs` backend).
+```
+
+These arguments use the following syntax:
+
+If you only pass a single string, then it is considered to have all values separated by commas. Thus invoking the following command:
+
+```
+$ meson compile --ninja-args=-n,-d,explain
+```
+
+would add `-n`, `-d` and `explain` arguments to ninja invocation.
+
+If you need to have commas or spaces in your string values, then you need to pass the value with proper shell quoting like this:
+
+```
+$ meson compile "--ninja-args=['a,b', 'c d']"
+```
diff --git a/docs/markdown/snippets/add_meson_compile_target.md b/docs/markdown/snippets/add_meson_compile_target.md
new file mode 100644
index 0000000..d75862f
--- /dev/null
+++ b/docs/markdown/snippets/add_meson_compile_target.md
@@ -0,0 +1,19 @@
+## Added ability to specify targets in `meson compile`
+
+It's now possible to specify targets in `meson compile`, which will result in building only the requested targets.
+
+Usage: `meson compile [TARGET [TARGET...]]`
+`TARGET` has the following syntax: `[PATH/]NAME[:TYPE]`.
+`NAME`: name of the target from `meson.build` (e.g. `foo` from `executable('foo', ...)`).
+`PATH`: path to the target relative to the root `meson.build` file. Note: relative path for a target specified in the root `meson.build` is `./`.
+`TYPE`: type of the target (e.g. `shared_library`, `executable` and etc)
+
+`PATH` and/or `TYPE` can be ommited if the resulting `TARGET` can be used to uniquely identify the target in `meson.build`.
+
+For example targets from the following code:
+```meson
+shared_library('foo', ...)
+static_library('foo', ...)
+executable('bar', ...)
+```
+can be invoked with `meson compile foo:shared_library foo:static_library bar`.
diff --git a/docs/markdown/snippets/clang_coverage.md b/docs/markdown/snippets/clang_coverage.md
new file mode 100644
index 0000000..733a3d9
--- /dev/null
+++ b/docs/markdown/snippets/clang_coverage.md
@@ -0,0 +1,4 @@
+## Clang coverage support
+
+llvm-cov is now used to generate coverage information when clang is used as
+the compiler. \ No newline at end of file
diff --git a/docs/markdown/snippets/force_fallback_for.md b/docs/markdown/snippets/force_fallback_for.md
new file mode 100644
index 0000000..b6af209
--- /dev/null
+++ b/docs/markdown/snippets/force_fallback_for.md
@@ -0,0 +1,10 @@
+## Force fallback for
+
+A newly-added `--force-fallback-for` command line option can now be used to
+force fallback for specific subprojects.
+
+Example:
+
+```
+meson build --force-fallback-for=foo,bar
+```
diff --git a/docs/markdown/snippets/gir_fatal_warnings.md b/docs/markdown/snippets/gir_fatal_warnings.md
new file mode 100644
index 0000000..951e98e
--- /dev/null
+++ b/docs/markdown/snippets/gir_fatal_warnings.md
@@ -0,0 +1,5 @@
+## Fatal warnings in `gnome.generate_gir()`
+
+`gnome.generate_gir()` now has `fatal_warnings` keyword argument to abort when
+a warning is produced. This is useful for example in CI environment where it's
+important to catch potential issues.
diff --git a/docs/markdown/snippets/machine_file_constants.md b/docs/markdown/snippets/machine_file_constants.md
new file mode 100644
index 0000000..84b0848
--- /dev/null
+++ b/docs/markdown/snippets/machine_file_constants.md
@@ -0,0 +1,20 @@
+## Machine file constants
+
+Native and cross files now support string and list concatenation using the `+`
+operator, and joining paths using the `/` operator.
+Entries defined in the `[constants]` section can be used in any other section.
+An entry defined in any other section can be used only within that same section and only
+after it has been defined.
+
+```ini
+[constants]
+toolchain = '/toolchain'
+common_flags = ['--sysroot=' + toolchain + '/sysroot']
+
+[properties]
+c_args = common_flags + ['-DSOMETHING']
+cpp_args = c_args + ['-DSOMETHING_ELSE']
+
+[binaries]
+c = toolchain + '/gcc'
+```
diff --git a/docs/markdown/snippets/response-files.md b/docs/markdown/snippets/response-files.md
new file mode 100644
index 0000000..624b664
--- /dev/null
+++ b/docs/markdown/snippets/response-files.md
@@ -0,0 +1,7 @@
+## Response files enabled on Linux, reined in on Windows
+
+Meson used to always use response files on Windows,
+but never on Linux.
+
+It now strikes a happier balance, using them on both platforms,
+but only when needed to avoid command line length limits.
diff --git a/docs/markdown/snippets/wrap_patch.md b/docs/markdown/snippets/wrap_patch.md
index 7d6d9c2..ae66bbd 100644
--- a/docs/markdown/snippets/wrap_patch.md
+++ b/docs/markdown/snippets/wrap_patch.md
@@ -4,3 +4,16 @@ It is now possible to use the `patch_filename` and `source_filename` value in a
`.wrap` file without `*_url` to specify a local source / patch file. All local
files must be located in the `subprojects/packagefiles` directory. The `*_hash`
entries are optional with this setup.
+
+## Local wrap patch directory
+
+Wrap files can now specify `patch_directory` instead of `patch_filename` in the
+case overlay files are local. Every files in that directory, and subdirectories,
+will be copied to the subproject directory. This can be used for example to add
+`meson.build` files to a project not using Meson build system upstream.
+The patch directory must be placed in `subprojects/packagefiles` directory.
+
+## Patch on all wrap types
+
+`patch_*` keys are not limited to `wrap-file` any more, they can be specified for
+all wrap types.