| 1 |
name: install_data |
| 2 |
returns: void |
| 3 |
description: | |
| 4 |
Installs files from the source tree that are listed as positional arguments. |
| 5 |
|
| 6 |
See [Installing](Installing.md) for more examples. |
| 7 |
|
| 8 |
varargs: |
| 9 |
name: file |
| 10 |
type: file | str |
| 11 |
description: Files to install. |
| 12 |
|
| 13 |
warnings: |
| 14 |
- the `install_mode` kwarg ignored integer values between 0.59.0 -- 1.1.0. |
| 15 |
- an omitted `install_dir` kwarg did not work correctly inside of a subproject until 1.3.0. |
| 16 |
- an omitted `install_dir` kwarg did not work correctly when combined with the `preserve_path` kwarg until 1.3.0. |
| 17 |
|
| 18 |
kwargs: |
| 19 |
install_dir: |
| 20 |
type: str |
| 21 |
description: | |
| 22 |
The absolute or relative path to the installation directory. |
| 23 |
If this is a relative path, it is assumed to be relative to the prefix. |
| 24 |
|
| 25 |
If omitted, the directory defaults to `{datadir}/{projectname}` *(since 0.45.0)*. |
| 26 |
|
| 27 |
install_mode: |
| 28 |
type: list[str | int | bool] |
| 29 |
since: 0.38.0 |
| 30 |
description: | |
| 31 |
specify the file mode in symbolic format and |
| 32 |
optionally the owner/uid and group/gid for the installed files. For |
| 33 |
example: |
| 34 |
|
| 35 |
`install_mode: 'rw-r--r--'` for just the file mode |
| 36 |
|
| 37 |
`install_mode: ['rw-r--r--', 'nobody', 'nogroup']` for the file mode and the user/group |
| 38 |
|
| 39 |
`install_mode: ['rw-r-----', 0, 0]` for the file mode and uid/gid |
| 40 |
|
| 41 |
To leave any of these three as the default, specify `false`. |
| 42 |
|
| 43 |
install_tag: |
| 44 |
type: str |
| 45 |
since: 0.60.0 |
| 46 |
description: | |
| 47 |
A string used by the `meson install --tags` command |
| 48 |
to install only a subset of the files. By default these files have no install |
| 49 |
tag which means they are not being installed when `--tags` argument is specified. |
| 50 |
|
| 51 |
preserve_path: |
| 52 |
type: bool |
| 53 |
since: 0.64.0 |
| 54 |
default: false |
| 55 |
description: | |
| 56 |
Disable stripping child-directories from data files when installing. |
| 57 |
|
| 58 |
This is equivalent to GNU Automake's `nobase` option. |
| 59 |
|
| 60 |
rename: |
| 61 |
type: list[str] |
| 62 |
since: 0.46.0 |
| 63 |
description: | |
| 64 |
If specified renames each source file into corresponding file from `rename` list. |
| 65 |
Nested paths are allowed and they are |
| 66 |
joined with `install_dir`. Length of `rename` list must be equal to |
| 67 |
the number of sources. |
| 68 |
|
| 69 |
sources: |
| 70 |
type: list[file | str] |
| 71 |
description: Additional files to install. |
| 72 |
|
| 73 |
follow_symlinks: |
| 74 |
type: bool |
| 75 |
since: 1.3.0 |
| 76 |
default: true |
| 77 |
description: | |
| 78 |
If true, dereferences links and copies their target instead. The default |
| 79 |
value will become false in the future. |