nixpkgs/pkgs/applications/science/math/nasc/default.nix

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

86 lines
2.0 KiB
Nix
Raw Normal View History

{ lib, stdenv
2018-03-10 11:21:36 +00:00
, fetchFromGitHub
, pkg-config
, python3
, meson
, ninja
, vala
2018-03-10 11:21:36 +00:00
, gtk3
, glib
2018-08-20 20:31:18 +00:00
, pantheon
2019-02-13 21:47:50 +00:00
, gtksourceview
, libgee
, nix-update-script
, webkitgtk
2018-03-10 11:21:36 +00:00
, libqalculate
, intltool
, gnuplot
, wrapGAppsHook
}:
2018-03-10 11:21:36 +00:00
stdenv.mkDerivation rec {
pname = "nasc";
2021-08-23 21:23:52 +00:00
version = "0.8.0";
2018-03-10 11:21:36 +00:00
src = fetchFromGitHub {
owner = "parnold-x";
repo = pname;
2018-03-10 11:21:36 +00:00
rev = version;
2021-08-23 21:23:52 +00:00
sha256 = "02b9a59a9fzsb6nn3ycwwbcbv04qfzm6x7csq2addpzx5wak6dd8";
fetchSubmodules = true;
2018-03-10 11:21:36 +00:00
};
nativeBuildInputs = [
glib # post_install.py
gtk3 # post_install.py
intltool # for libqalculate
meson
ninja
pkg-config
python3
vala
2018-08-20 20:31:18 +00:00
wrapGAppsHook
2018-03-10 11:21:36 +00:00
];
2018-11-10 13:15:27 +00:00
2018-03-10 11:21:36 +00:00
buildInputs = [
glib
gtk3
2019-02-13 21:47:50 +00:00
gtksourceview
libgee
pantheon.granite
webkitgtk
# We add libqalculate's runtime dependencies because nasc has it as a modified subproject.
] ++ libqalculate.buildInputs ++ libqalculate.propagatedBuildInputs;
postPatch = ''
chmod +x meson/post_install.py
patchShebangs meson/post_install.py
# patch subproject. same code in libqalculate expression
substituteInPlace subprojects/libqalculate/libqalculate/Calculator-plot.cc \
--replace 'commandline = "gnuplot"' 'commandline = "${gnuplot}/bin/gnuplot"' \
--replace '"gnuplot - ' '"${gnuplot}/bin/gnuplot - '
'';
passthru = {
updateScript = nix-update-script { };
};
2018-03-10 11:21:36 +00:00
meta = with lib; {
description = "Do maths like a normal person, designed for elementary OS";
2018-03-10 11:21:36 +00:00
longDescription = ''
Its an app where you do maths like a normal person. It lets you
type whatever you want and smartly figures out what is math and
spits out an answer on the right pane. Then you can plug those
answers in to future equations and if that answer changes, so does
the equations its used in.
'';
homepage = "https://github.com/parnold-x/nasc";
maintainers = teams.pantheon.members;
2018-03-10 11:21:36 +00:00
platforms = platforms.linux;
license = licenses.gpl3Plus;
mainProgram = "com.github.parnold_x.nasc";
2022-09-23 13:33:04 +00:00
broken = true; # at 2022-09-23
2018-03-10 11:21:36 +00:00
};
}