{ lib, stdenv, fetchCrate, rustPlatform, pkg-config, openssl, Security }: let pname = "cargo-pgrx"; version = "0.9.5"; in rustPlatform.buildRustPackage rec { inherit version pname; src = fetchCrate { inherit version pname; hash = "sha256-GpXQUOBuojAqPXyRR+k8AVW2XzBbn6V0+2dhP4w4Vs8="; }; cargoHash = "sha256-YbwGh3tbt8W9/VOu11fTWO9fRMUlrwJnG4wxUHuyX10="; nativeBuildInputs = [ pkg-config ]; buildInputs = [ openssl ] ++ lib.optionals stdenv.isDarwin [ Security ]; meta = with lib; { description = "Build Postgres Extensions with Rust!"; homepage = "https://github.com/tcdi/pgrx"; changelog = "https://github.com/tcdi/pgrx/releases/tag/v${version}"; license = licenses.mit; maintainers = with maintainers; [ happysalada ]; }; }