generated from Patagia/template-nix
Compare commits
1 commit
dd55bc50ed
...
90d7c9092a
Author | SHA1 | Date | |
---|---|---|---|
90d7c9092a |
3 changed files with 13 additions and 19 deletions
11
Cargo.lock
generated
11
Cargo.lock
generated
|
@ -1161,7 +1161,6 @@ dependencies = [
|
|||
"clap",
|
||||
"dropshot",
|
||||
"http",
|
||||
"openssl",
|
||||
"schemars",
|
||||
"serde",
|
||||
"slog",
|
||||
|
@ -1906,15 +1905,6 @@ version = "0.1.5"
|
|||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "ff011a302c396a5197692431fc1948019154afc178baf7d8e37367442a4601cf"
|
||||
|
||||
[[package]]
|
||||
name = "openssl-src"
|
||||
version = "300.4.1+3.4.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "faa4eac4138c62414b5622d1b31c5c304f34b406b013c079c2bbc652fdd6678c"
|
||||
dependencies = [
|
||||
"cc",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "openssl-sys"
|
||||
version = "0.9.104"
|
||||
|
@ -1923,7 +1913,6 @@ checksum = "45abf306cbf99debc8195b66b7346498d7b10c210de50418b5ccd7ceba08c741"
|
|||
dependencies = [
|
||||
"cc",
|
||||
"libc",
|
||||
"openssl-src",
|
||||
"pkg-config",
|
||||
"vcpkg",
|
||||
]
|
||||
|
|
20
flake.nix
20
flake.nix
|
@ -58,23 +58,29 @@
|
|||
];
|
||||
};
|
||||
|
||||
cleanSrc = craneLib.cleanCargoSource ../.;
|
||||
|
||||
commonArgs = {
|
||||
inherit src;
|
||||
inherit src cleanSrc;
|
||||
|
||||
stdenv = pkgs.stdenvAdapters.useMoldLinker pkgs.stdenv;
|
||||
strictDeps = true;
|
||||
cargoArtifacts = craneLib.buildDepsOnly commonArgs;
|
||||
|
||||
nativeBuildInputs = with pkgs; [
|
||||
clang
|
||||
glibc.static
|
||||
mold-wrapped
|
||||
pkg-config
|
||||
];
|
||||
|
||||
# CARGO_BUILD_TARGET = "x86_64-unknown-linux-gnu";
|
||||
# CARGO_BUILD_RUSTFLAGS = "-C target-feature=+crt-static";
|
||||
# OPENSSL_STATIC = "true";
|
||||
BuildInputs = with pkgs; [
|
||||
openssl
|
||||
];
|
||||
|
||||
CARGO_BUILD_TARGET = "x86_64-unknown-linux-gnu";
|
||||
CARGO_BUILD_RUSTFLAGS = "-C target-feature=+crt-static";
|
||||
OPENSSL_STATIC = "true";
|
||||
OPENSSL_DIR = "${pkgs.openssl.dev}";
|
||||
OPENSSL_LIB_DIR = "${pkgs.openssl.out}/lib";
|
||||
OPENSSL_INCLUDE_DIR = "${pkgs.openssl.dev}/include/";
|
||||
};
|
||||
|
||||
buildCrate =
|
||||
|
|
|
@ -21,4 +21,3 @@ serde.workspace = true
|
|||
http.workspace = true
|
||||
zbus_systemd = { version = "0.25701.0", features = ["hostname1", "sysupdate1", "network1", "portable1", "resolve1", "systemd1"] }
|
||||
zbus = "5.4.0"
|
||||
openssl = { version = "0.10.63", features = ["vendored"] }
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue