mirror of
https://gitlab.computer.surgery/matrix/grapevine.git
synced 2025-12-16 23:31:24 +01:00
remove jemalloc support
It's no longer being developed and it is very very annoying to maintain support for.
This commit is contained in:
parent
55a01e7113
commit
e6dbc293f1
8 changed files with 27 additions and 89 deletions
|
|
@ -6,7 +6,6 @@
|
|||
, pkgsBuildHost
|
||||
, rocksdb
|
||||
, rust
|
||||
, rust-jemalloc-sys
|
||||
, snappy
|
||||
, stdenv
|
||||
|
||||
|
|
@ -35,19 +34,12 @@ let
|
|||
lib.optionals default-features allDefaultFeatures ++
|
||||
lib.optionals all-features allFeatures);
|
||||
|
||||
featureEnabled = feature : builtins.elem feature features';
|
||||
|
||||
buildDepsOnlyEnv =
|
||||
let
|
||||
rocksdb' = rocksdb.override {
|
||||
enableJemalloc = featureEnabled "jemalloc";
|
||||
};
|
||||
in
|
||||
{
|
||||
NIX_OUTPATH_USED_AS_RANDOM_SEED = "randomseed";
|
||||
CARGO_PROFILE = profile;
|
||||
ROCKSDB_INCLUDE_DIR = "${rocksdb'}/include";
|
||||
ROCKSDB_LIB_DIR = "${rocksdb'}/lib";
|
||||
ROCKSDB_INCLUDE_DIR = "${rocksdb}/include";
|
||||
ROCKSDB_LIB_DIR = "${rocksdb}/lib";
|
||||
}
|
||||
//
|
||||
(import ./cross-compilation-env.nix {
|
||||
|
|
@ -86,8 +78,6 @@ let
|
|||
|
||||
dontStrip = profile != "release";
|
||||
|
||||
buildInputs = lib.optional (featureEnabled "jemalloc") rust-jemalloc-sys;
|
||||
|
||||
nativeBuildInputs = [
|
||||
# bindgen needs the build platform's libclang. Apparently due to "splicing
|
||||
# weirdness", pkgs.rustPlatform.bindgenHook on its own doesn't quite do the
|
||||
|
|
|
|||
|
|
@ -2,10 +2,6 @@
|
|||
{ inputs
|
||||
, lib
|
||||
, rocksdb
|
||||
, rust-jemalloc-sys
|
||||
|
||||
# Options (keep sorted)
|
||||
, enableJemalloc ? false
|
||||
}:
|
||||
|
||||
let
|
||||
|
|
@ -17,10 +13,7 @@ let
|
|||
(builtins.readFile ../../../flake.lock)
|
||||
).nodes.rocksdb.original.ref;
|
||||
})).override {
|
||||
jemalloc = rust-jemalloc-sys;
|
||||
|
||||
enableLiburing = false;
|
||||
inherit enableJemalloc;
|
||||
};
|
||||
|
||||
cVersion = rocksdb'.version;
|
||||
|
|
|
|||
|
|
@ -1,12 +0,0 @@
|
|||
# This derivation will set the JEMALLOC_OVERRIDE variable, causing the
|
||||
# tikv-jemalloc-sys crate to use the nixpkgs jemalloc instead of building it's
|
||||
# own. In order for this to work, we need to set flags on the build that match
|
||||
# whatever flags tikv-jemalloc-sys was going to use. These are dependent on
|
||||
# which features we enable in tikv-jemalloc-sys.
|
||||
|
||||
{ rust-jemalloc-sys }:
|
||||
|
||||
rust-jemalloc-sys.override {
|
||||
# tikv-jemalloc-sys/unprefixed_malloc_on_supported_platforms feature
|
||||
unprefixed = true;
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue