continuwuity/nix/packages/default.nix
aviac 388cbeb60e
Some checks failed
Checks / Prek / Check changed files (push) Successful in 28s
Checks / Prek / Pre-commit & Formatting (push) Successful in 1m39s
Release Docker Image / Build linux-arm64 (release) (push) Failing after 2m6s
Checks / Prek / Clippy and Cargo Tests (push) Has been skipped
Documentation / Build and Deploy Documentation (push) Successful in 10m51s
Release Docker Image / Build linux-amd64 (release) (push) Successful in 57m8s
Release Docker Image / Create Multi-arch Release Manifest (push) Has been skipped
Release Docker Image / Build linux-amd64 (max-perf) (push) Has been skipped
Release Docker Image / Build linux-arm64 (max-perf) (push) Has been skipped
Release Docker Image / Create Max-Perf Manifest (push) Has been skipped
Release Docker Image / Mirror Images (push) Has been skipped
Release Docker Image / Release Binaries (push) Has been skipped
build(nix): allow overriding TARGET_CPU
2026-05-19 09:58:48 +00:00

36 lines
1 KiB
Nix

{
self,
...
}:
{
perSystem =
{
self',
pkgs,
craneLib,
...
}:
{
packages = {
rocksdb = pkgs.callPackage ./rocksdb.nix { };
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
# for features configuration see `default` package which enables http3 by default
# example: different compilation profile and different target_cpu
max-perf-haswell = self'.packages.default.override {
# compiles explicitly for haswell arch cpus
target_cpu = "haswell";
# compiles slower but with more thorough optimizations
profile = "release-max-perf";
};
};
};
}