5 releases
0.2.3 | Nov 13, 2024 |
---|---|
0.2.2 | Jul 3, 2024 |
0.2.1 | Aug 14, 2023 |
0.2.0 | Jul 6, 2023 |
0.1.0 | May 2, 2023 |
#210 in Build Utils
138 downloads per month
20KB
350 lines
xmake
A build dependency for running the xmake build tool to compile a native library.
# Cargo.toml
[build-dependencies]
xmake = "0.2.3"
The XMake executable is assumed to be xmake
unless the XMAKE
environmental variable is set.
If you need to cross-compile your project, xmake provides a built-in package manager that can set up the emscripten or Android NDK toolchains. The first two lines of the code snippet below enter a single package environment, overwriting the previous environment. However, the last line enters both the emscripten and NDK environments simultaneously.
xrepo env -b ndk shell
xrepo env -b emscripten shell
xrepo env -b "emscripten, ndk" shell
After executing one of these commands, xmake will automatically detect either the emscripten or NDK toolchain.
If you prefer to use your own toolchain, you can set either the ANDROID_NDK_HOME or EMSCRIPTEN_HOME environment variables to specify the path to the corresponding toolchain.
An example is available in the test-crate
folder of the repo.
Dependencies
~230–325KB