2012-05-14 23:43:46 +02:00
|
|
|
{ stdenv, fetchurl, pkgconfig, gtk, zathura_core, girara, djvulibre, gettext }:
|
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
2017-12-31 02:06:17 +01:00
|
|
|
name = "zathura-djvu-0.2.7";
|
2012-05-14 23:43:46 +02:00
|
|
|
|
|
|
|
src = fetchurl {
|
|
|
|
url = "http://pwmt.org/projects/zathura/plugins/download/${name}.tar.gz";
|
2017-12-31 02:06:17 +01:00
|
|
|
sha256 = "1sbfdsyp50qc85xc4458sn4w1rv1qbygdwmcr5kjlfpsmdq98vhd";
|
2012-05-14 23:43:46 +02:00
|
|
|
};
|
|
|
|
|
2017-09-05 23:26:13 +02:00
|
|
|
nativeBuildInputs = [ pkgconfig ];
|
|
|
|
buildInputs = [ djvulibre gettext zathura_core gtk girara ];
|
2012-05-14 23:43:46 +02:00
|
|
|
|
|
|
|
patches = [ ./gtkflags.patch ];
|
|
|
|
|
2018-02-15 08:44:40 +01:00
|
|
|
postPatch = stdenv.lib.optionalString stdenv.isDarwin ''
|
2018-02-14 20:52:15 +01:00
|
|
|
string1='-shared ''${LDFLAGS} -o $@ ''$(OBJECTS) ''${LIBS}'
|
|
|
|
string2='-Wl,-dylib_install_name,''${PLUGIN}.dylib -Wl,-bundle_loader,${zathura_core}/bin/.zathura-wrapped -bundle ''${LDFLAGS} -o $@ ''${OBJECTS} ''${LIBS}'
|
|
|
|
makefileC1=$(sed -r 's/\.so/.dylib/g' Makefile)
|
|
|
|
echo "''${makefileC1/$string1/$string2}" > Makefile
|
|
|
|
'';
|
|
|
|
|
2016-08-26 02:42:08 +02:00
|
|
|
makeFlags = [ "PREFIX=$(out)" "PLUGINDIR=$(out)/lib" ];
|
2012-05-14 23:43:46 +02:00
|
|
|
|
2016-08-26 02:42:08 +02:00
|
|
|
meta = with stdenv.lib; {
|
2012-08-16 16:33:25 +02:00
|
|
|
homepage = http://pwmt.org/projects/zathura/;
|
2012-05-14 23:43:46 +02:00
|
|
|
description = "A zathura DJVU plugin";
|
|
|
|
longDescription = ''
|
2016-08-26 02:42:08 +02:00
|
|
|
The zathura-djvu plugin adds DjVu support to zathura by using the
|
|
|
|
djvulibre library.
|
2012-05-14 23:43:46 +02:00
|
|
|
'';
|
2016-08-26 02:42:08 +02:00
|
|
|
license = licenses.zlib;
|
2018-02-14 20:52:15 +01:00
|
|
|
platforms = platforms.unix;
|
2016-08-26 02:42:08 +02:00
|
|
|
maintainers = with maintainers; [ garbas ];
|
2012-05-14 23:43:46 +02:00
|
|
|
};
|
|
|
|
}
|
|
|
|
|