@@ -0,0 +1,36 @@
1+{ lib
2+, rustPlatform
3+, fetchFromGitHub
4+, pkg-config
5+, openssl
6+, stdenv
7+, Security
8+}:
9+
10+rustPlatform.buildRustPackage rec {
11+ pname = "synth";
12+ version = "0.5.6";
13+
14+ src = fetchFromGitHub {
15+ owner = "getsynth";
16+ repo = pname;
17+ rev = "v${version}";
18+ sha256 = "06kgzaja04553gaxrfz6d1rqi3xwa6ijl0q6425fg0mqq9ifv7xk";
19+ };
20+
21+ cargoSha256 = "sha256-bjda4uE5K+cJkS2TsTv7FN3H6q3cElRr674FTKaIexA=";
22+
23+ nativeBuildInputs = [ pkg-config ];
24+
25+ buildInputs = [ openssl ] ++ lib.optional stdenv.isDarwin Security;
26+
27+ # requires unstable rust features
28+ RUSTC_BOOTSTRAP = 1;
29+
30+ meta = with lib; {
31+ description = "A tool for generating realistic data using a declarative data model";
32+ homepage = "https://github.com/getsynth/synth";
33+ license = licenses.asl20;
34+ maintainers = with maintainers; [ figsoda ];
35+ };
36+}