diff options
author | Jan Tojnar <jtojnar@gmail.com> | 2022-01-29 19:54:15 +0100 |
---|---|---|
committer | Eli Schwartz <eschwartz93@gmail.com> | 2022-02-09 11:04:59 -0500 |
commit | df451f10130fc5d64cf1c65504a69bedd2fbdfdd (patch) | |
tree | efc457f194ce5312bb59da5791f5f10eaa2bbabf /docs/markdown/Builtin-options.md | |
parent | d2d9df3121d228797d0b3bccfd614849b637c0fe (diff) | |
download | meson-df451f10130fc5d64cf1c65504a69bedd2fbdfdd.zip meson-df451f10130fc5d64cf1c65504a69bedd2fbdfdd.tar.gz meson-df451f10130fc5d64cf1c65504a69bedd2fbdfdd.tar.bz2 |
meson: Allow directory options outside of prefix
This bring us in line with Autotools and CMake and it is useful
for platforms like Nix, which install projects
into multiple independent prefixes.
As a consequence, `get_option` might return absolute paths for some
directory options, if a directory outside of prefix is passed.
This is technically a backwards incompatible change but its effect
should be minimal, thanks to widespread use of `join_paths`/`/` operator
and pkg-config generator module. It should only cause an issue when
a path were constructed by concatenating the value of directory path option.
Also remove a comment about commonpath since we do not use that since
<https://github.com/mesonbuild/meson/commit/00f5dadd5b7d71c30bd7393d165a87f554eb92e5>.
Fixes: https://github.com/mesonbuild/meson/issues/2561
Diffstat (limited to 'docs/markdown/Builtin-options.md')
-rw-r--r-- | docs/markdown/Builtin-options.md | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/docs/markdown/Builtin-options.md b/docs/markdown/Builtin-options.md index 613b8b8..db3c3e8 100644 --- a/docs/markdown/Builtin-options.md +++ b/docs/markdown/Builtin-options.md @@ -23,13 +23,15 @@ For legacy reasons `--warnlevel` is the cli argument for the They can also be edited after setup using `meson configure -Doption=value`. -Installation options are all relative to the prefix, except: +Installation options are usually relative to the prefix but it should +not be relied on, since they can be absolute paths in the following cases: * When the prefix is `/usr`: `sysconfdir` defaults to `/etc`, `localstatedir` defaults to `/var`, and `sharedstatedir` defaults to `/var/lib` * When the prefix is `/usr/local`: `localstatedir` defaults to `/var/local`, and `sharedstatedir` defaults to `/var/local/lib` +* When an absolute path outside of prefix is provided by the user/distributor. ### Directories |