Browse Source

Update README for new versioning scheme + env vars

pull/141/head
Ian Chamberlain 1 year ago
parent
commit
b14cdf10f1
No known key found for this signature in database
GPG Key ID: AE5484D09405AA60
  1. 27
      ctru-sys/README.md

27
ctru-sys/README.md

@ -10,23 +10,16 @@ to use this library.
## Version ## Version
This crate's version changes according to the version of `libctru` Crate bindings are generated at build time, so the available APIs will depend on the
used to generate the bindings, with the following convention: installed version of `libctru` when the crate is built. If you want to check
what version of `libctru` is being built, you can examine these environment
* [`libctru`](https://github.com/devkitPro/libctru) version `X.Y.Z-W` variables with [`env!`](https://doc.rust-lang.org/std/macro.env.html):
* `ctru-sys` version `XY.Z.P+X.Y.Z-W`
* `LIBCTRU_VERSION`: full version string (e.g. `"2.3.1-4"`)
where `P` is usually 0 but may be incremented for fixes in e.g. * `LIBCTRU_MAJOR`: major version (e.g. `"2"` for version `2.3.1-4`)
binding generation, `libc` dependency bump, etc. * `LIBCTRU_MINOR`: minor version (e.g. `"3"` for version `2.3.1-4`)
* `LIBCTRU_PATCH`: patch version (e.g. `"1"` for version `2.3.1-4`)
It may be possible to build this crate against a different version of [`libctru`](https://github.com/devkitPro/libctru), * `LIBCTRU_RELEASE`: release version (e.g. `"4"` for version `2.3.1-4`)
but you may encounter linker errors or ABI issues. A build-time Cargo warning
(displayed when built with `-vv`) will be issued if the build script detects
a mismatch or is unable to check the installed [`libctru`](https://github.com/devkitPro/libctru) version.
## Generating bindings
Bindings of new versions of [`libctru`](https://github.com/devkitPro/libctru) can be built using the integrated [`bindgen.sh`](./bindgen.sh) script.
## License ## License

Loading…
Cancel
Save