mirror of
https://codeberg.org/demostf/cleanup.git
synced 2026-06-03 10:04:10 +02:00
31 lines
564 B
Nix
31 lines
564 B
Nix
{
|
|
rustPlatform,
|
|
lib,
|
|
openssl,
|
|
pkg-config,
|
|
}: let
|
|
inherit (lib.sources) sourceByRegex;
|
|
inherit (builtins) fromTOML readFile;
|
|
src = sourceByRegex ../. ["Cargo.*" "(src)(/.*)?"];
|
|
cargoPackage = (fromTOML (readFile ../Cargo.toml)).package;
|
|
in
|
|
rustPlatform.buildRustPackage {
|
|
pname = cargoPackage.name;
|
|
inherit (cargoPackage) version;
|
|
|
|
inherit src;
|
|
|
|
buildInputs = [
|
|
openssl
|
|
];
|
|
|
|
nativeBuildInputs = [
|
|
pkg-config
|
|
];
|
|
|
|
cargoLock = {
|
|
lockFile = ../Cargo.lock;
|
|
};
|
|
|
|
meta.mainProgram = "cleanup";
|
|
}
|