docs: update build instructions to include meson

This commit is contained in:
Brenden Forward 2023-09-25 22:02:09 -04:00
parent b478f470f3
commit 0ee39cf99e
No known key found for this signature in database

View File

@ -93,7 +93,8 @@ exist a valid `libuv` wrapper in C++. That's all.
To be able to use `uvw`, users must provide the following system-wide tools:
* A full-featured compiler that supports at least C++17.
* `libuv` (which version depends on the tag of `uvw` in use).
* `libuv` (which version depends on the tag of `uvw` in use)
* If you use `meson`, libuv will be downloaded for you
The requirements below are mandatory to compile the tests and to extract the
documentation:
@ -106,6 +107,17 @@ by `CMake` in some cases (see below for further details).<br/>
Because of that, users don't have to install it to run the tests or when `uvw`
libraries are compiled through `CMake`.
## Meson
You can use `uvw` with [meson](https://mesonbuild.com/) by simply adding it to your `subprojects` directory in your project. Currently, `uvw` is not available with `meson wrap`, but this will change with the release of `uvw` 3.2.1.
To compile `uvw` from source without using it as a subproject, in the `uvw` source directory, run:
* `$ meson setup build`
* If you want a static library, add `--default-library=static`
* `$ cd build`
* `$ meson compile`
## Library
`uvw` is a dual-mode library. It can be used in its header-only form or as a