Use mimalloc for musl builds
This commit is contained in:
parent
948388b019
commit
b780345e8b
|
@ -49,6 +49,9 @@ features = [ # TODO: test which of these are actually needed
|
|||
"time",
|
||||
]
|
||||
|
||||
[target.'cfg(target_env = "musl")'.dependencies]
|
||||
mimalloc = "0.1.26"
|
||||
|
||||
[build-dependencies]
|
||||
embed-resource = "1.6.1"
|
||||
|
||||
|
|
|
@ -18,6 +18,10 @@ use watchexec::{
|
|||
mod args;
|
||||
mod config;
|
||||
|
||||
#[cfg(target_env = "musl")]
|
||||
#[global_allocator]
|
||||
static GLOBAL: mimalloc::MiMalloc = mimalloc::MiMalloc;
|
||||
|
||||
#[tokio::main]
|
||||
async fn main() -> Result<()> {
|
||||
#[cfg(feature = "dev-console")]
|
||||
|
|
Loading…
Reference in New Issue