diff options
Diffstat (limited to 'docs')
-rw-r--r-- | docs/markdown/D.md | 10 | ||||
-rw-r--r-- | docs/markdown/Dependencies.md | 11 | ||||
-rw-r--r-- | docs/markdown/Reference-manual.md | 14 | ||||
-rw-r--r-- | docs/markdown/Reference-tables.md | 5 | ||||
-rw-r--r-- | docs/markdown/Release-notes-for-0.49.0.md | 5 |
5 files changed, 36 insertions, 9 deletions
diff --git a/docs/markdown/D.md b/docs/markdown/D.md index 15de2f7..2b0eaac 100644 --- a/docs/markdown/D.md +++ b/docs/markdown/D.md @@ -14,15 +14,21 @@ project('myapp', 'd') executable('myapp', 'app.d') ``` -## Compiling different versions +## [Conditional compilation](https://dlang.org/spec/version.html) -If you are using the [version()](https://dlang.org/spec/version.html) feature for conditional compilation, +If you are using the [version()](https://dlang.org/spec/version.html#version-specification) feature for conditional compilation, you can use it using the `d_module_versions` target property: ```meson project('myapp', 'd') executable('myapp', 'app.d', d_module_versions: ['Demo', 'FeatureA']) ``` +For debugging, [debug()](https://dlang.org/spec/version.html#debug) conditions are compiled automatically in debug builds, and extra identifiers can be added with the `d_debug` argument: +```meson +project('myapp', 'd') +executable('myapp', 'app.d', d_debug: [3, 'DebugFeatureA']) +``` + ## Using embedded unittests If you are using embedded [unittest functions](https://dlang.org/spec/unittest.html), your source code needs diff --git a/docs/markdown/Dependencies.md b/docs/markdown/Dependencies.md index 08ff1e2..c853677 100644 --- a/docs/markdown/Dependencies.md +++ b/docs/markdown/Dependencies.md @@ -165,15 +165,16 @@ wmf_dep = dependency('libwmf', method : 'config-tool') ## Dependencies using config tools [CUPS](#cups), [LLVM](#llvm), [pcap](#pcap), [WxWidgets](#wxwidgets), -[libwmf](#libwmf), and GnuStep either do not provide pkg-config +[libwmf](#libwmf), [GCrypt](#libgcrypt), and GnuStep either do not provide pkg-config modules or additionally can be detected via a config tool -(cups-config, llvm-config, etc). Meson has native support for these +(cups-config, llvm-config, libgcrypt-config, etc). Meson has native support for these tools, and they can be found like other dependencies: ```meson pcap_dep = dependency('pcap', version : '>=1.0') cups_dep = dependency('cups', version : '>=1.4') llvm_dep = dependency('llvm', version : '>=4.0') +libgcrypt_dep = dependency('libgcrypt', version: '>= 1.8') ``` ## AppleFrameworks @@ -309,6 +310,12 @@ The `language` keyword may used. `method` may be `auto`, `config-tool` or `pkg-config`. +## libgcrypt + +*(added 0.49.0)* + +`method` may be `auto`, `config-tool` or `pkg-config`. + ## Python3 Python3 is handled specially by meson: diff --git a/docs/markdown/Reference-manual.md b/docs/markdown/Reference-manual.md index 7902f19..0fb9f17 100644 --- a/docs/markdown/Reference-manual.md +++ b/docs/markdown/Reference-manual.md @@ -242,7 +242,7 @@ Create a custom top level build target. The only positional argument is the name of this target and the keyword arguments are the following. -- `build_by_default` *(added 0.38.0)* causes, when set to true, to +- `build_by_default` *(added 0.38)* causes, when set to true, to have this target be built by default, that is, when invoking plain `ninja`; the default value is false - `build_always` (deprecated) if `true` this target is always considered out of @@ -256,7 +256,7 @@ following. this argument is set to true, Meson captures `stdout` and writes it to the target file. Note that your command argument list may not contain `@OUTPUT@` when capture mode is active. -- `console` keyword argument conflicts with `capture`, and is meant +- `console` *(added 0.48)* keyword argument conflicts with `capture`, and is meant for commands that are resource-intensive and take a long time to finish. With the Ninja backend, setting this will add this target to [Ninja's `console` pool](https://ninja-build.org/manual.html#_the_literal_console_literal_pool), @@ -537,7 +537,8 @@ be passed to [shared and static libraries](#library). - `d_import_dirs` list of directories to look in for string imports used in the D programming language - `d_unittest`, when set to true, the D modules are compiled in debug mode -- `d_module_versions` list of module versions set when compiling D sources +- `d_module_versions` list of module version identifiers set when compiling D sources +- `d_debug` list of module debug identifiers set when compiling D sources The list of `sources`, `objects`, and `dependencies` is always flattened, which means you can freely nest and add lists while @@ -1432,14 +1433,14 @@ The `meson` object allows you to introspect various properties of the system. This object is always mapped in the `meson` variable. It has the following methods. -- `add_dist_script` causes the script given as argument to run during +- `add_dist_script(script_name, arg1, arg, ...)` causes the script given as argument to run during `dist` operation after the distribution source has been generated but before it is archived. Note that this runs the script file that is in the _staging_ directory, not the one in the source directory. If the script file can not be found in the staging directory, it is a hard error. This command can only invoked from the main project, calling it from a subproject is a hard - error. Available since 0.48.0. + error. Available since 0.48.0. Before 0.49.0, the function only accepted a single argument. - `add_install_script(script_name, arg1, arg2, ...)` causes the script given as an argument to be run during the install step, this script @@ -1626,6 +1627,9 @@ the following methods: the positional argument, you can specify external dependencies to use with `dependencies` keyword argument. +- `cmd_array()` returns an array containing the command arguments for + the current compiler. + - `compiles(code)` returns true if the code fragment given in the positional argument compiles, you can specify external dependencies to use with `dependencies` keyword argument, `code` can be either a diff --git a/docs/markdown/Reference-tables.md b/docs/markdown/Reference-tables.md index ccdcb34..39ec1cd 100644 --- a/docs/markdown/Reference-tables.md +++ b/docs/markdown/Reference-tables.md @@ -65,6 +65,11 @@ set in the cross file. Any cpu family not listed in the above list is not guaranteed to remain stable in future releases. +Those porting from autotools should note that meson does not add +endianness to the name of the cpu_family. For example, autotools +will call little endian PPC64 "ppc64le", meson will not, you must +also check the `.endian()` value of the machine for this information. + ## Operating system names These are provided by the `.system()` method call. diff --git a/docs/markdown/Release-notes-for-0.49.0.md b/docs/markdown/Release-notes-for-0.49.0.md index b294ad5..bdf5769 100644 --- a/docs/markdown/Release-notes-for-0.49.0.md +++ b/docs/markdown/Release-notes-for-0.49.0.md @@ -15,3 +15,8 @@ whose contents should look like this: A short description explaining the new feature and how it should be used. +## Libgcrypt dependency now supports libgcrypt-config + +Earlier, `dependency('libgcrypt')` could only detect the library with pkg-config +files. Now, if pkg-config files are not found, Meson will look for +`libgcrypt-config` and if it's found, will use that to find the library. |