aboutsummaryrefslogtreecommitdiff
path: root/docs
diff options
context:
space:
mode:
Diffstat (limited to 'docs')
-rw-r--r--docs/markdown/Custom-build-targets.md9
-rw-r--r--docs/markdown/Reference-manual.md4
-rw-r--r--docs/markdown/Tutorial.md15
3 files changed, 22 insertions, 6 deletions
diff --git a/docs/markdown/Custom-build-targets.md b/docs/markdown/Custom-build-targets.md
index f0b50d8..76bf939 100644
--- a/docs/markdown/Custom-build-targets.md
+++ b/docs/markdown/Custom-build-targets.md
@@ -29,14 +29,15 @@ it does for source generation.
See [Generating Sources](Generating-sources.md) for more information on this topic.
-## Details on compiler invocations
+## Details on command invocation
Meson only permits you to specify one command to run. This is by
design as writing shell pipelines into build definition files leads to
-code that is very hard to maintain. If your compilation requires
+code that is very hard to maintain. If your command requires
multiple steps you need to write a wrapper script that does all the
-necessary work. When doing this you need to be mindful of the
-following issues:
+necessary work.
+
+When doing this you need to be mindful of the following issues:
* do not assume that the command is invoked in any specific directory
* a target called `target` file `outfile` defined in subdir `subdir`
diff --git a/docs/markdown/Reference-manual.md b/docs/markdown/Reference-manual.md
index 9a5ccc5..d315b53 100644
--- a/docs/markdown/Reference-manual.md
+++ b/docs/markdown/Reference-manual.md
@@ -397,6 +397,10 @@ the following special string substitutions:
The returned object also has methods that are documented in the
[object methods section](#custom-target-object) below.
+**Note:** Assuming that `command:` is executed by a POSIX `sh` shell is not
+portable, notably to Windows. Instead, consider using a `native: true`
+[executable()](#executable), or a python script.
+
### declare_dependency()
``` meson
diff --git a/docs/markdown/Tutorial.md b/docs/markdown/Tutorial.md
index f108c0c..bf337ba 100644
--- a/docs/markdown/Tutorial.md
+++ b/docs/markdown/Tutorial.md
@@ -75,12 +75,23 @@ When Meson is run it prints the following output.
Now we are ready to build our code.
+
+```console
+$ cd builddir
+$ ninja
```
+
+If your Meson version is newer than 0.55.0, you can use the new
+backend-agnostic build command:
+
+```console
$ cd builddir
$ meson compile
```
-Once that is done we can run the resulting binary.
+For the rest of this document we are going to use the latter form.
+
+Once the executable is built we can run it.
```console
$ ./demo
@@ -135,7 +146,7 @@ need to recreate our build directory, run any sort of magical commands
or the like. Instead we just type the exact same command as if we were
rebuilding our code without any build system changes.
-```
+```console
$ meson compile
```