aboutsummaryrefslogtreecommitdiff
path: root/docs/markdown
diff options
context:
space:
mode:
authorAdam C. Foltzer <acfoltzer@galois.com>2017-06-09 14:51:58 -0700
committerAdam C. Foltzer <acfoltzer@galois.com>2017-06-09 15:14:02 -0700
commitbdd4c45b173055931db1c758cd7f016693d3a924 (patch)
treea868e261a3771996dbd3c1dd03c5bac049f60389 /docs/markdown
parent22cfd44221ada3219d9096e15dc8b00d32e0f9f6 (diff)
downloadmeson-bdd4c45b173055931db1c758cd7f016693d3a924.zip
meson-bdd4c45b173055931db1c758cd7f016693d3a924.tar.gz
meson-bdd4c45b173055931db1c758cd7f016693d3a924.tar.bz2
Enhance Rust support
- Adds a `crate_type` kwarg to library targets, allowing the different types of Rust [linkage][1]. - Shared libraries use the `dylib` crate type by default, but can also be `cdylib` - Static libraries use the `rlib` crate type by default, but can also be `staticlib` - If any Rust target has shared library dependencies, add the appropriate linker arguments, including rpath for the sysroot of the Rust compiler [1]: https://doc.rust-lang.org/reference/linkage.html
Diffstat (limited to 'docs/markdown')
-rw-r--r--docs/markdown/Reference-manual.md5
1 files changed, 3 insertions, 2 deletions
diff --git a/docs/markdown/Reference-manual.md b/docs/markdown/Reference-manual.md
index 492666b..61a66f0 100644
--- a/docs/markdown/Reference-manual.md
+++ b/docs/markdown/Reference-manual.md
@@ -510,11 +510,12 @@ Joins the given strings into a file system path segment. For example `join_paths
Builds a library that is either static or shared depending on the value of `default_library` user option. You should use this instead of [`shared_library`](#shared_library) or [`static_library`](#static_library) most of the time. This allows you to toggle your entire project (including subprojects) from shared to static with only one option.
-The keyword arguments for this are the same as for [`executable`](#executable) with the following addition:
+The keyword arguments for this are the same as for [`executable`](#executable) with the following additions:
- `name_prefix` the string that will be used as the suffix for the target by overriding the default (only used for libraries). By default this is `lib` on all platforms and compilers except with MSVC where it is omitted.
+- `crate_type` specifies the crate type for Rust libraries. Defaults to `dylib` for shared libraries and `rlib` for static libraries.
-`static_library` and `shared_library` also accept this keyword argument.
+`static_library` and `shared_library` also accept these keyword arguments.
### message()