From 5cd9f88d6cafbbc2b748ffc85226d53800a05aac Mon Sep 17 00:00:00 2001 From: Daniel Mensinger Date: Sun, 20 Jun 2021 11:29:06 +0200 Subject: fix: Ensure that build targets have all methods from ExternalProgram As a side-effect from #8885 `find_program()` returns now `Executable` objects when `meson.override_find_program` is called with an executable target. To resolve this conflict the missing methods from `ExternalProgram` are added to `BuildTarget`. --- docs/markdown/snippets/build-target-found.md | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) create mode 100644 docs/markdown/snippets/build-target-found.md (limited to 'docs/markdown/snippets') diff --git a/docs/markdown/snippets/build-target-found.md b/docs/markdown/snippets/build-target-found.md new file mode 100644 index 000000000..60c50830a --- /dev/null +++ b/docs/markdown/snippets/build-target-found.md @@ -0,0 +1,16 @@ +## New `build target` methods + +The [`build target` object](Reference-manual.md#build-target-object) now supports +the following two functions, to ensure feature compatebility with +[`external program` objects](Reference-manual.html#external-program-object): + +- `found()`: Always returns `true`. This function is meant + to make executables objects feature compatible with + `external program` objects. This simplifies + use-cases where an executable is used instead of an external program. + +- `path()`: **(deprecated)** does the exact same as `full_path()`. + **NOTE:** This function is solely kept for compatebility + with `external program` objects. It will be + removed once the, also deprecated, corresponding `path()` function in the + `external program` object is removed. -- cgit v1.2.3