Make jemalloc optional
This commit is contained in:
parent
d517fc4e92
commit
24b6217897
4
Makefile
4
Makefile
|
@ -53,7 +53,7 @@ static-%:
|
||||||
x86_64-binary: x86_64-binary-release
|
x86_64-binary: x86_64-binary-release
|
||||||
|
|
||||||
x86_64-binary-release:
|
x86_64-binary-release:
|
||||||
cross build --target x86_64-unknown-linux-musl --release --all-targets --features vendored-openssl
|
cross build --target x86_64-unknown-linux-musl --release --all-targets --features vendored-openssl,jemalloc
|
||||||
|
|
||||||
x86_64-binary-debug:
|
x86_64-binary-debug:
|
||||||
cross build --target x86_64-unknown-linux-musl --all-targets --features vendored-openssl
|
cross build --target x86_64-unknown-linux-musl --all-targets --features vendored-openssl
|
||||||
|
@ -73,7 +73,7 @@ armv7-binary-debug:
|
||||||
aarch64-binary: aarch64-binary-release
|
aarch64-binary: aarch64-binary-release
|
||||||
|
|
||||||
aarch64-binary-release:
|
aarch64-binary-release:
|
||||||
cross build --target=aarch64-unknown-linux-musl --release --all-targets --features vendored-openssl
|
cross build --target=aarch64-unknown-linux-musl --release --all-targets --features vendored-openssl,jemalloc
|
||||||
|
|
||||||
aarch64-binary-debug:
|
aarch64-binary-debug:
|
||||||
cross build --target=aarch64-unknown-linux-musl --all-targets --features vendored-openssl
|
cross build --target=aarch64-unknown-linux-musl --all-targets --features vendored-openssl
|
||||||
|
|
|
@ -9,6 +9,9 @@ homepage = "https://syndicate-lang.org/"
|
||||||
repository = "https://git.syndicate-lang.org/syndicate-lang/syndicate-rs"
|
repository = "https://git.syndicate-lang.org/syndicate-lang/syndicate-rs"
|
||||||
license = "Apache-2.0"
|
license = "Apache-2.0"
|
||||||
|
|
||||||
|
[features]
|
||||||
|
jemalloc = ["dep:tikv-jemallocator"]
|
||||||
|
|
||||||
[build-dependencies]
|
[build-dependencies]
|
||||||
preserves-schema = "3.2"
|
preserves-schema = "3.2"
|
||||||
syndicate = { path = "../syndicate", version = "0.28.0"}
|
syndicate = { path = "../syndicate", version = "0.28.0"}
|
||||||
|
@ -26,7 +29,7 @@ noise-rust-crypto = "0.5"
|
||||||
notify = "4.0"
|
notify = "4.0"
|
||||||
structopt = "0.3"
|
structopt = "0.3"
|
||||||
|
|
||||||
tikv-jemallocator = "0.5.0"
|
tikv-jemallocator = { version = "0.5.0", optional = true }
|
||||||
|
|
||||||
tungstenite = "0.13"
|
tungstenite = "0.13"
|
||||||
tokio-tungstenite = "0.14"
|
tokio-tungstenite = "0.14"
|
||||||
|
|
|
@ -26,6 +26,7 @@ mod protocol;
|
||||||
mod script;
|
mod script;
|
||||||
mod services;
|
mod services;
|
||||||
|
|
||||||
|
#[cfg(feature = "jemalloc")]
|
||||||
#[global_allocator]
|
#[global_allocator]
|
||||||
static GLOBAL: tikv_jemallocator::Jemalloc = tikv_jemallocator::Jemalloc;
|
static GLOBAL: tikv_jemallocator::Jemalloc = tikv_jemallocator::Jemalloc;
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue