From e982d5118e9056e2e08810fa6ca24cf7c24495b9 Mon Sep 17 00:00:00 2001 From: Peter Hutterer Date: Wed, 3 May 2017 11:16:30 +1000 Subject: docs: clarify that vcs_tag output can be used as source "you should put in your main program" is confusing, "that can be used as source" is slightly better. --- docs/markdown/Reference-manual.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'docs/markdown') diff --git a/docs/markdown/Reference-manual.md b/docs/markdown/Reference-manual.md index 116fd58..cbcbbdc 100644 --- a/docs/markdown/Reference-manual.md +++ b/docs/markdown/Reference-manual.md @@ -641,7 +641,7 @@ This command detects revision control commit information at build time and place - `output` file to write the results to (e.g. `version.c`) - `fallback` version number to use when no revision control information is present, such as when building from a release tarball -Meson will read the contents of `input`, replace the string `@VCS_TAG@` with the detected revision number and write the result to `output`. This method returns an opaque [`custom_target`](#custom_target) object that you should put in your main program. If you desire more specific behavior than what this command provides, you should use `custom_target`. +Meson will read the contents of `input`, replace the string `@VCS_TAG@` with the detected revision number and write the result to `output`. This method returns an opaque [`custom_target`](#custom_target) object that can be used as source. If you desire more specific behavior than what this command provides, you should use `custom_target`. ## Built-in objects -- cgit v1.1 From 4378655a39be1d693a73432f344b74600c4d8651 Mon Sep 17 00:00:00 2001 From: Peter Hutterer Date: Wed, 3 May 2017 11:25:44 +1000 Subject: docs: document additional args for vcs_tag Supported as of 223596d7bf8ab9b839e0031022c132a3ccd4fd1d --- docs/markdown/Reference-manual.md | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) (limited to 'docs/markdown') diff --git a/docs/markdown/Reference-manual.md b/docs/markdown/Reference-manual.md index cbcbbdc..66027c2 100644 --- a/docs/markdown/Reference-manual.md +++ b/docs/markdown/Reference-manual.md @@ -635,13 +635,15 @@ Defined tests can be run in a backend-agnostic way by calling `mesontest` inside ctarget vcs_tag(...) ``` -This command detects revision control commit information at build time and places it in the specified output file. This file is guaranteed to be up to date on every build. Keywords are similar to `custom_target` and all of them are mandatory. +This command detects revision control commit information at build time and places it in the specified output file. This file is guaranteed to be up to date on every build. Keywords are similar to `custom_target`. -- `input` file to modify (e.g. `version.c.in`) -- `output` file to write the results to (e.g. `version.c`) -- `fallback` version number to use when no revision control information is present, such as when building from a release tarball +- `input` file to modify (e.g. `version.c.in`) (required) +- `output` file to write the results to (e.g. `version.c`) (required) +- `fallback` version number to use when no revision control information is present, such as when building from a release tarball (required) +- `command` string list with the command to execute, see [`custom_target`](#custom_target) for details on how this command must be specified +- `replace_string` string in the input file to substitute with the commit information (defaults to `@VCS_TAG@`) -Meson will read the contents of `input`, replace the string `@VCS_TAG@` with the detected revision number and write the result to `output`. This method returns an opaque [`custom_target`](#custom_target) object that can be used as source. If you desire more specific behavior than what this command provides, you should use `custom_target`. +Meson will read the contents of `input`, substitute the `replace_string` with the detected revision number, and write the result to `output`. This method returns an opaque [`custom_target`](#custom_target) object that can be used as source. If you desire more specific behavior than what this command provides, you should use `custom_target`. ## Built-in objects -- cgit v1.1 From 7a3be163cbceb9f569ff454dc23fdfecadc166cc Mon Sep 17 00:00:00 2001 From: Peter Hutterer Date: Thu, 4 May 2017 09:06:00 +1000 Subject: Default to project_version() in vcs_tag fallback --- docs/markdown/Reference-manual.md | 2 +- docs/markdown/Release-notes-for-0.41.0.md | 5 +++++ 2 files changed, 6 insertions(+), 1 deletion(-) (limited to 'docs/markdown') diff --git a/docs/markdown/Reference-manual.md b/docs/markdown/Reference-manual.md index 66027c2..9c4df7e 100644 --- a/docs/markdown/Reference-manual.md +++ b/docs/markdown/Reference-manual.md @@ -639,7 +639,7 @@ This command detects revision control commit information at build time and place - `input` file to modify (e.g. `version.c.in`) (required) - `output` file to write the results to (e.g. `version.c`) (required) -- `fallback` version number to use when no revision control information is present, such as when building from a release tarball (required) +- `fallback` version number to use when no revision control information is present, such as when building from a release tarball (defaults to `meson.project_version()`) - `command` string list with the command to execute, see [`custom_target`](#custom_target) for details on how this command must be specified - `replace_string` string in the input file to substitute with the commit information (defaults to `@VCS_TAG@`) diff --git a/docs/markdown/Release-notes-for-0.41.0.md b/docs/markdown/Release-notes-for-0.41.0.md index 6e00ecd..9c02cdc 100644 --- a/docs/markdown/Release-notes-for-0.41.0.md +++ b/docs/markdown/Release-notes-for-0.41.0.md @@ -12,3 +12,8 @@ Add features here as code is merged to master. ## Dependency Handler for LLVM Native support for linking against LLVM using the `dependency` function. + +## vcs_tag keyword fallback is is now optional + +The `fallback` keyword in `vcs_tag` is now optional. If not given, its value +defaults to the return value of `meson.project_version()`. -- cgit v1.1