2021-06-04 09:07:49 +00:00
|
|
|
{ lib
|
|
|
|
, fetchFromGitHub
|
2021-09-23 15:35:13 +00:00
|
|
|
, gcc
|
|
|
|
, gmp, mpfr, libmpc
|
2021-06-04 09:07:49 +00:00
|
|
|
, rustPlatform
|
|
|
|
}:
|
|
|
|
rustPlatform.buildRustPackage rec {
|
|
|
|
pname = "kalker";
|
2022-01-13 20:06:32 +00:00
|
|
|
version = "1.1.0";
|
2021-06-04 09:07:49 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "PaddiM8";
|
|
|
|
repo = pname;
|
|
|
|
rev = "v${version}";
|
2022-01-13 20:06:32 +00:00
|
|
|
sha256 = "sha256-NnX4+VmV4oZg/8Z3ZCWHGZ6dqDfvH30XErnrvKMxyls=";
|
2021-06-04 09:07:49 +00:00
|
|
|
};
|
|
|
|
|
2022-01-13 20:06:32 +00:00
|
|
|
cargoSha256 = "sha256-nSLbe3EhcLYylvyzOWuLIehBnD6mMofsNpFQVEybV8k=";
|
2021-06-04 09:07:49 +00:00
|
|
|
|
2021-09-23 15:35:13 +00:00
|
|
|
buildInputs = [ gmp mpfr libmpc ];
|
2021-06-04 09:07:49 +00:00
|
|
|
|
|
|
|
outputs = [ "out" "lib" ];
|
|
|
|
|
|
|
|
postInstall = ''
|
|
|
|
moveToOutput "lib" "$lib"
|
|
|
|
'';
|
|
|
|
|
2021-09-23 15:35:13 +00:00
|
|
|
CARGO_FEATURE_USE_SYSTEM_LIBS = "1";
|
|
|
|
|
2021-06-04 09:07:49 +00:00
|
|
|
meta = with lib; {
|
|
|
|
homepage = "https://kalker.strct.net";
|
|
|
|
changelog = "https://github.com/PaddiM8/kalker/releases/tag/v${version}";
|
|
|
|
description = "A command line calculator";
|
|
|
|
longDescription = ''
|
|
|
|
A command line calculator that supports math-like syntax with user-defined
|
|
|
|
variables, functions, derivation, integration, and complex numbers
|
|
|
|
'';
|
|
|
|
license = licenses.mit;
|
|
|
|
maintainers = with maintainers; [ lovesegfault ];
|
|
|
|
};
|
|
|
|
}
|