Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
1{ 2 lib, 3 rustPlatform, 4 fetchFromGitHub, 5 pkg-config, 6 sqlite, 7 zstd, 8 nixosTests, 9}: 10 11rustPlatform.buildRustPackage rec { 12 pname = "wastebin"; 13 version = "3.2.0"; 14 15 src = fetchFromGitHub { 16 owner = "matze"; 17 repo = "wastebin"; 18 rev = version; 19 hash = "sha256-emhPa4VuXOjTZ6AU/4S8acjjz68byBg4x4MW0M5hvD4="; 20 }; 21 22 cargoHash = "sha256-Ub6BQhrLkIoOM9XFVIfm6mI4pP1Rloo3DnZXB8C4CjE="; 23 24 nativeBuildInputs = [ 25 pkg-config 26 ]; 27 28 buildInputs = [ 29 sqlite 30 zstd 31 ]; 32 33 env = { 34 ZSTD_SYS_USE_PKG_CONFIG = true; 35 }; 36 37 passthru.tests = { 38 inherit (nixosTests) wastebin; 39 }; 40 41 meta = with lib; { 42 description = "Wastebin is a pastebin"; 43 homepage = "https://github.com/matze/wastebin"; 44 changelog = "https://github.com/matze/wastebin/blob/${src.rev}/CHANGELOG.md"; 45 license = licenses.mit; 46 maintainers = with maintainers; [ 47 pinpox 48 matthiasbeyer 49 ]; 50 mainProgram = "wastebin"; 51 }; 52}