2017-07-31 07:48:37 +01:00
|
|
|
{ stdenv, fetchurl, glibc, sane-backends, qtbase, qtsvg, libXext, libX11, libXdmcp, libXau, libxcb }:
|
|
|
|
let
|
2017-11-01 20:13:11 +00:00
|
|
|
version = "4.3.61";
|
2017-07-31 07:48:37 +01:00
|
|
|
in
|
|
|
|
stdenv.mkDerivation {
|
|
|
|
name = "masterpdfeditor-${version}";
|
|
|
|
src = fetchurl {
|
|
|
|
url = "http://get.code-industry.net/public/master-pdf-editor-${version}_qt5.amd64.tar.gz";
|
2017-11-01 20:13:11 +00:00
|
|
|
sha256 = "1g6mx8nch6ypf78h6xsb673wim19wn5ni5840armzg0pvi3sfknm";
|
2017-07-31 07:48:37 +01:00
|
|
|
};
|
|
|
|
libPath = stdenv.lib.makeLibraryPath [
|
|
|
|
stdenv.cc.cc
|
|
|
|
glibc
|
|
|
|
sane-backends
|
|
|
|
qtbase
|
|
|
|
qtsvg
|
|
|
|
libXext
|
|
|
|
libX11
|
|
|
|
libXdmcp
|
|
|
|
libXau
|
|
|
|
libxcb
|
|
|
|
];
|
|
|
|
dontStrip = true;
|
|
|
|
installPhase = ''
|
2017-11-01 21:15:09 +00:00
|
|
|
mkdir -p $out/bin $out/share/applications $out/share/pixmaps
|
|
|
|
|
|
|
|
substituteInPlace masterpdfeditor4.desktop \
|
|
|
|
--replace 'Exec=/opt/master-pdf-editor-4' "Exec=$out/bin" \
|
|
|
|
--replace 'Path=/opt/master-pdf-editor-4' "Path=$out/bin" \
|
|
|
|
--replace 'Icon=/opt/master-pdf-editor-4' "Icon=$out/share/pixmaps"
|
|
|
|
|
2017-07-31 07:48:37 +01:00
|
|
|
cp -v masterpdfeditor4 $out/bin/masterpdfeditor4
|
2017-11-01 21:15:09 +00:00
|
|
|
cp -v masterpdfeditor4.png $out/share/pixmaps/
|
|
|
|
cp -v masterpdfeditor4.desktop $out/share/applications
|
|
|
|
|
2017-07-31 07:48:37 +01:00
|
|
|
cp -v -r stamps $out/bin/stamps
|
|
|
|
cp -v -r templates $out/bin/templates
|
|
|
|
cp -v -r lang $out/bin/lang
|
|
|
|
cp -v -r fonts $out/bin/fonts
|
2017-11-01 21:15:09 +00:00
|
|
|
install -D license.txt $out/share/$name/LICENSE
|
|
|
|
|
2017-07-31 07:48:37 +01:00
|
|
|
patchelf --interpreter "$(cat $NIX_CC/nix-support/dynamic-linker)" \
|
|
|
|
--set-rpath $libPath \
|
|
|
|
$out/bin/masterpdfeditor4
|
|
|
|
'';
|
|
|
|
meta = with stdenv.lib; {
|
2017-11-01 20:13:11 +00:00
|
|
|
description = "Master PDF Editor";
|
2017-07-31 07:48:37 +01:00
|
|
|
homepage = "https://code-industry.net/free-pdf-editor/";
|
|
|
|
license = licenses.unfreeRedistributable;
|
2017-11-01 22:58:54 +00:00
|
|
|
platforms = with platforms; [ "x86_64-linux" ];
|
2017-11-01 20:13:11 +00:00
|
|
|
maintainers = with maintainers; [ cmcdragonkai flokli ];
|
2017-07-31 07:48:37 +01:00
|
|
|
};
|
|
|
|
}
|