2021-02-13 14:23:35 +00:00
|
|
|
{ lib
|
|
|
|
, mkDerivation
|
2021-10-17 09:34:42 +00:00
|
|
|
, makeDesktopItem
|
2021-02-13 14:23:35 +00:00
|
|
|
, fetchurl
|
|
|
|
, pkg-config
|
2021-10-17 09:34:42 +00:00
|
|
|
, copyDesktopItems
|
2021-02-13 14:23:35 +00:00
|
|
|
, cairo
|
|
|
|
, freetype
|
|
|
|
, ghostscript
|
|
|
|
, gsl
|
|
|
|
, libjpeg
|
|
|
|
, libpng
|
|
|
|
, libspiro
|
|
|
|
, lua5
|
|
|
|
, qtbase
|
|
|
|
, texlive
|
|
|
|
, zlib
|
2020-04-24 23:36:52 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
mkDerivation rec {
|
2021-02-13 14:23:35 +00:00
|
|
|
pname = "ipe";
|
|
|
|
version = "7.2.23";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
src = fetchurl {
|
2021-02-13 14:23:35 +00:00
|
|
|
url = "https://dl.bintray.com/otfried/generic/ipe/7.2/${pname}-${version}-src.tar.gz";
|
|
|
|
sha256 = "0yvm3zfba1ljyy518vjnvwpyg7lgnmdwm19v5k0wfgz64aca56x1";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
2021-02-13 14:23:35 +00:00
|
|
|
sourceRoot = "${pname}-${version}/src";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2021-10-17 09:34:42 +00:00
|
|
|
nativeBuildInputs = [ pkg-config copyDesktopItems ];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
buildInputs = [
|
2021-02-13 14:23:35 +00:00
|
|
|
cairo
|
|
|
|
freetype
|
|
|
|
ghostscript
|
|
|
|
gsl
|
|
|
|
libjpeg
|
|
|
|
libpng
|
|
|
|
libspiro
|
|
|
|
lua5
|
|
|
|
qtbase
|
|
|
|
texlive
|
|
|
|
zlib
|
2020-04-24 23:36:52 +00:00
|
|
|
];
|
|
|
|
|
2021-10-17 09:34:42 +00:00
|
|
|
IPEPREFIX = placeholder "out";
|
|
|
|
URWFONTDIR = "${texlive}/texmf-dist/fonts/type1/urw/";
|
2021-02-13 14:23:35 +00:00
|
|
|
LUA_PACKAGE = "lua";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2021-10-17 09:34:42 +00:00
|
|
|
qtWrapperArgs = [ "--prefix PATH : ${lib.makeBinPath [ texlive ]}" ];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
enableParallelBuilding = true;
|
|
|
|
|
2021-10-17 09:34:42 +00:00
|
|
|
desktopItems = [
|
|
|
|
(makeDesktopItem {
|
|
|
|
name = pname;
|
|
|
|
desktopName = "Ipe";
|
|
|
|
genericName = "Drawing editor";
|
|
|
|
comment = "A drawing editor for creating figures in PDF format";
|
|
|
|
exec = "ipe";
|
|
|
|
icon = "ipe";
|
2022-03-05 16:20:37 +00:00
|
|
|
mimeTypes = [ "text/xml" "application/pdf" ];
|
|
|
|
categories = [ "Graphics" "Qt" ];
|
|
|
|
startupNotify = true;
|
|
|
|
startupWMClass = "ipe";
|
2021-10-17 09:34:42 +00:00
|
|
|
})
|
|
|
|
];
|
|
|
|
|
|
|
|
postInstall = ''
|
|
|
|
mkdir -p $out/share/icons/hicolor/128x128/apps
|
|
|
|
ln -s $out/share/ipe/${version}/icons/icon_128x128.png $out/share/icons/hicolor/128x128/apps/ipe.png
|
|
|
|
'';
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2021-02-13 14:23:35 +00:00
|
|
|
meta = with lib; {
|
2020-04-24 23:36:52 +00:00
|
|
|
description = "An editor for drawing figures";
|
2021-10-17 09:34:42 +00:00
|
|
|
homepage = "http://ipe.otfried.org"; # https not available
|
2021-02-13 14:23:35 +00:00
|
|
|
license = licenses.gpl3Plus;
|
2020-04-24 23:36:52 +00:00
|
|
|
longDescription = ''
|
|
|
|
Ipe is an extensible drawing editor for creating figures in PDF and Postscript format.
|
|
|
|
It supports making small figures for inclusion into LaTeX-documents
|
|
|
|
as well as presentations in PDF.
|
|
|
|
'';
|
2021-02-13 14:23:35 +00:00
|
|
|
maintainers = with maintainers; [ ttuegel ];
|
|
|
|
platforms = platforms.linux;
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
}
|