2022-08-12 12:06:08 +00:00
|
|
|
{ lib
|
|
|
|
, stdenv
|
2020-08-20 17:08:02 +00:00
|
|
|
, fetchurl
|
2021-02-05 17:12:51 +00:00
|
|
|
, pkg-config
|
2020-08-20 17:08:02 +00:00
|
|
|
, gettext
|
|
|
|
, gtk3
|
|
|
|
, glib
|
|
|
|
, libxml2
|
|
|
|
, libsecret
|
|
|
|
, poppler
|
|
|
|
, itstool
|
|
|
|
, hicolor-icon-theme
|
|
|
|
, texlive
|
|
|
|
, mate
|
|
|
|
, wrapGAppsHook
|
2022-08-12 12:06:08 +00:00
|
|
|
, enableEpub ? true
|
|
|
|
, webkitgtk
|
|
|
|
, enableDjvu ? true
|
|
|
|
, djvulibre
|
|
|
|
, enablePostScript ? true
|
|
|
|
, libspectre
|
|
|
|
, enableXps ? true
|
|
|
|
, libgxps
|
2020-08-20 17:08:02 +00:00
|
|
|
, enableImages ? false
|
2021-04-25 03:57:28 +00:00
|
|
|
, mateUpdateScript
|
2020-08-20 17:08:02 +00:00
|
|
|
}:
|
|
|
|
|
2020-04-24 23:36:52 +00:00
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
pname = "atril";
|
2023-05-24 13:37:59 +00:00
|
|
|
version = "1.26.1";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
src = fetchurl {
|
2021-01-17 00:15:33 +00:00
|
|
|
url = "https://pub.mate-desktop.org/releases/${lib.versions.majorMinor version}/${pname}-${version}.tar.xz";
|
2023-05-24 13:37:59 +00:00
|
|
|
sha256 = "pTphOsuXAaGK1nG/WQJU0c6Da6CuG+LAvYlI/fa0kaQ=";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
nativeBuildInputs = [
|
2021-02-05 17:12:51 +00:00
|
|
|
pkg-config
|
2020-04-24 23:36:52 +00:00
|
|
|
gettext
|
|
|
|
wrapGAppsHook
|
|
|
|
];
|
|
|
|
|
|
|
|
buildInputs = [
|
|
|
|
gtk3
|
|
|
|
glib
|
|
|
|
itstool
|
|
|
|
libsecret
|
|
|
|
libxml2
|
|
|
|
poppler
|
|
|
|
mate.caja
|
|
|
|
mate.mate-desktop
|
|
|
|
hicolor-icon-theme
|
2022-08-12 12:06:08 +00:00
|
|
|
texlive.bin.core # for synctex, used by the pdf back-end
|
2020-08-20 17:08:02 +00:00
|
|
|
]
|
2023-05-24 13:37:59 +00:00
|
|
|
++ lib.optionals enableDjvu [ djvulibre ]
|
|
|
|
++ lib.optionals enableEpub [ webkitgtk ]
|
|
|
|
++ lib.optionals enablePostScript [ libspectre ]
|
|
|
|
++ lib.optionals enableXps [ libgxps ]
|
2020-08-20 17:08:02 +00:00
|
|
|
;
|
|
|
|
|
|
|
|
configureFlags = [ ]
|
2023-05-24 13:37:59 +00:00
|
|
|
++ lib.optionals (enableDjvu) [ "--enable-djvu" ]
|
|
|
|
++ lib.optionals (enableEpub) [ "--enable-epub" ]
|
|
|
|
++ lib.optionals (enablePostScript) [ "--enable-ps" ]
|
|
|
|
++ lib.optionals (enableXps) [ "--enable-xps" ]
|
|
|
|
++ lib.optionals (enableImages) [ "--enable-pixbuf" ];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2023-03-04 12:14:45 +00:00
|
|
|
env.NIX_CFLAGS_COMPILE = "-I${glib.dev}/include/gio-unix-2.0";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
makeFlags = [ "cajaextensiondir=$$out/lib/caja/extensions-2.0" ];
|
|
|
|
|
|
|
|
enableParallelBuilding = true;
|
|
|
|
|
2022-10-06 18:32:54 +00:00
|
|
|
passthru.updateScript = mateUpdateScript { inherit pname; };
|
2021-04-25 03:57:28 +00:00
|
|
|
|
2021-01-15 22:18:51 +00:00
|
|
|
meta = with lib; {
|
2020-04-24 23:36:52 +00:00
|
|
|
description = "A simple multi-page document viewer for the MATE desktop";
|
|
|
|
homepage = "https://mate-desktop.org";
|
2021-04-25 03:57:28 +00:00
|
|
|
license = licenses.gpl2Plus;
|
2020-04-24 23:36:52 +00:00
|
|
|
platforms = platforms.unix;
|
2021-09-23 15:35:13 +00:00
|
|
|
maintainers = teams.mate.members;
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
}
|