2022-05-05 20:12:31 +01:00
|
|
|
{ stdenv
|
|
|
|
, lib
|
2021-12-08 21:37:56 +00:00
|
|
|
, clang
|
|
|
|
, cmake
|
|
|
|
, fetchFromGitHub
|
|
|
|
, llvmPackages
|
|
|
|
, rustPlatform
|
2022-04-20 15:40:48 +01:00
|
|
|
, testers
|
2022-05-05 20:12:31 +01:00
|
|
|
, Security
|
2021-12-08 21:37:56 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
let
|
|
|
|
pname = "amazon-qldb-shell";
|
2022-02-25 01:29:51 +00:00
|
|
|
version = "2.0.1";
|
2021-12-08 21:37:56 +00:00
|
|
|
package = rustPlatform.buildRustPackage {
|
|
|
|
inherit pname version;
|
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "awslabs";
|
|
|
|
repo = pname;
|
|
|
|
rev = "v${version}";
|
2022-02-25 01:29:51 +00:00
|
|
|
sha256 = "sha256-aXScqJ1LijMSAy9YkS5QyXtTqxd19lLt3BbyVXlbw8o=";
|
2021-12-08 21:37:56 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
nativeBuildInputs = [ clang cmake ];
|
2022-05-05 20:12:31 +01:00
|
|
|
buildInputs = [ llvmPackages.libclang ]
|
|
|
|
++ lib.optional stdenv.isDarwin Security;
|
2021-12-08 21:37:56 +00:00
|
|
|
|
2022-02-25 01:29:51 +00:00
|
|
|
cargoSha256 = "sha256-y3dNEa2U9mwsENPda44zweszlk4UJXGtfeH+er8mi0U=";
|
2021-12-08 21:37:56 +00:00
|
|
|
|
|
|
|
LIBCLANG_PATH = "${llvmPackages.libclang.lib}/lib";
|
|
|
|
|
2022-04-20 15:40:48 +01:00
|
|
|
passthru.tests.version = testers.testVersion { inherit package; };
|
2021-12-08 21:37:56 +00:00
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "An interface to send PartiQL statements to Amazon Quantum Ledger Database (QLDB)";
|
|
|
|
homepage = "https://github.com/awslabs/amazon-qldb-shell";
|
|
|
|
license = licenses.asl20;
|
|
|
|
maintainers = [ maintainers.terlar ];
|
2022-02-25 20:34:27 +00:00
|
|
|
mainProgram = "qldb";
|
2021-12-08 21:37:56 +00:00
|
|
|
};
|
|
|
|
};
|
|
|
|
in
|
|
|
|
package
|