2021-02-05 03:49:49 +01:00
|
|
|
{ lib, rustPlatform, pkg-config, cmake, llvmPackages, openssl, fetchFromGitHub
|
|
|
|
, installShellFiles }:
|
|
|
|
|
|
|
|
rustPlatform.buildRustPackage rec {
|
|
|
|
pname = "tremor";
|
2021-04-25 16:58:20 +02:00
|
|
|
version = "0.11.1";
|
2021-02-05 03:49:49 +01:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "tremor-rs";
|
|
|
|
repo = "tremor-runtime";
|
|
|
|
rev = "v${version}";
|
2021-04-25 16:58:20 +02:00
|
|
|
sha256 = "0aw6m5gklpgv1frrviv1v1ky898dwbcc1crd65d3gldcmnhvg6ap";
|
2021-02-05 03:49:49 +01:00
|
|
|
};
|
|
|
|
|
2021-04-25 16:58:20 +02:00
|
|
|
cargoSha256 = "1lks3xgnzcccv3hiqgxjpfm4v4g97an8yzfnb2kakw7jkfli6kvi";
|
2021-02-05 03:49:49 +01:00
|
|
|
|
|
|
|
nativeBuildInputs = [ cmake pkg-config installShellFiles ];
|
|
|
|
|
|
|
|
buildInputs = [ openssl ];
|
|
|
|
|
2021-04-08 16:34:11 +02:00
|
|
|
# TODO export TREMOR_PATH($out/lib) variable
|
2021-02-05 03:49:49 +01:00
|
|
|
postInstall = ''
|
2021-04-08 16:34:11 +02:00
|
|
|
# Copy the standard library to $out/lib
|
|
|
|
cp -r ${src}/tremor-script/lib/ $out
|
|
|
|
|
2021-02-05 03:49:49 +01:00
|
|
|
installShellCompletion --cmd tremor \
|
|
|
|
--bash <($out/bin/tremor completions bash) \
|
|
|
|
--fish <($out/bin/tremor completions fish) \
|
|
|
|
--zsh <($out/bin/tremor completions zsh)
|
|
|
|
'';
|
|
|
|
|
|
|
|
LIBCLANG_PATH = "${llvmPackages.libclang}/lib";
|
|
|
|
|
|
|
|
# OPENSSL_NO_VENDOR - If set, always find OpenSSL in the system, even if the vendored feature is enabled.
|
|
|
|
OPENSSL_NO_VENDOR = 1;
|
|
|
|
|
2021-04-08 16:34:11 +02:00
|
|
|
cargoBuildFlags = [ "-p tremor-cli" ];
|
2021-02-05 03:49:49 +01:00
|
|
|
|
|
|
|
meta = with lib; {
|
2021-03-08 12:22:41 +01:00
|
|
|
description = "Early stage event processing system for unstructured data with rich support for structural pattern matching, filtering and transformation";
|
2021-02-05 03:49:49 +01:00
|
|
|
homepage = "https://www.tremor.rs/";
|
|
|
|
license = licenses.asl20;
|
|
|
|
platforms = [ "x86_64-linux" ];
|
|
|
|
maintainers = with maintainers; [ humancalico ];
|
|
|
|
};
|
|
|
|
}
|