mirror of
https://forgejo.ellis.link/continuwuation/continuwuity/
synced 2026-04-22 03:55:49 +00:00
Compare commits
2 Commits
renovate/h
...
main
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
027f6a4b02 | ||
|
|
42028f155b |
@@ -8,7 +8,9 @@
|
||||
callPackage,
|
||||
rustPlatform,
|
||||
cargoExtraArgs ? "",
|
||||
rustflags ? "",
|
||||
rocksdb ? callPackage ./rocksdb.nix { },
|
||||
profile ? "release",
|
||||
}:
|
||||
let
|
||||
# see https://crane.dev/API.html#cranelibfiltercargosources
|
||||
@@ -35,6 +37,8 @@ let
|
||||
env = {
|
||||
ROCKSDB_INCLUDE_DIR = "${rocksdb}/include";
|
||||
ROCKSDB_LIB_DIR = "${rocksdb}/lib";
|
||||
CARGO_PROFILE = profile;
|
||||
RUSTFLAGS = rustflags;
|
||||
};
|
||||
};
|
||||
in
|
||||
|
||||
@@ -5,6 +5,7 @@
|
||||
{
|
||||
perSystem =
|
||||
{
|
||||
self',
|
||||
pkgs,
|
||||
craneLib,
|
||||
...
|
||||
@@ -12,7 +13,22 @@
|
||||
{
|
||||
packages = {
|
||||
rocksdb = pkgs.callPackage ./rocksdb.nix { };
|
||||
default = pkgs.callPackage ./continuwuity.nix { inherit self craneLib; };
|
||||
default = pkgs.callPackage ./continuwuity.nix {
|
||||
inherit self craneLib;
|
||||
# extra features via `cargoExtraArgs`
|
||||
cargoExtraArgs = "-F http3";
|
||||
# extra RUSTFLAGS via `rustflags`
|
||||
# the stuff below is required for http3
|
||||
rustflags = "--cfg reqwest_unstable";
|
||||
};
|
||||
# users may also override this with other cargo profiles to build for other feature sets
|
||||
#
|
||||
# other examples include:
|
||||
#
|
||||
# - release-high-perf
|
||||
max-perf = self'.packages.default.override {
|
||||
profile = "release-max-perf";
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user