Merge #122322: eukleides: Fix build, expose tex package
This commit is contained in:
commit
9de0430aac
1 changed files with 40 additions and 12 deletions
|
@ -1,26 +1,54 @@
|
||||||
{ lib, stdenv, fetchurl, bison, flex, texinfo, readline, texLive }:
|
{ lib, stdenv, fetchurl, bison, flex, makeWrapper, texinfo, readline, texLive }:
|
||||||
|
|
||||||
let
|
lib.fix (eukleides: stdenv.mkDerivation rec {
|
||||||
name = "eukleides";
|
pname = "eukleides";
|
||||||
version = "1.5.4";
|
version = "1.5.4";
|
||||||
in
|
|
||||||
stdenv.mkDerivation {
|
|
||||||
name = "${name}-${version}";
|
|
||||||
|
|
||||||
src = fetchurl {
|
src = fetchurl {
|
||||||
url = "http://www.eukleides.org/files/${name}-${version}.tar.bz2";
|
url = "http://www.eukleides.org/files/${pname}-${version}.tar.bz2";
|
||||||
sha256 = "0s8cyh75hdj89v6kpm3z24i48yzpkr8qf0cwxbs9ijxj1i38ki0q";
|
sha256 = "0s8cyh75hdj89v6kpm3z24i48yzpkr8qf0cwxbs9ijxj1i38ki0q";
|
||||||
};
|
};
|
||||||
|
|
||||||
buildInputs = [bison flex texinfo readline texLive];
|
nativeBuildInputs = [ bison flex texinfo makeWrapper ];
|
||||||
|
|
||||||
preConfigure = "sed -i 's/ginstall-info/install-info/g' doc/Makefile";
|
buildInputs = [ readline texLive ];
|
||||||
installPhase = "mkdir -p $out/bin ; make PREFIX=$out install";
|
|
||||||
|
preConfigure = ''
|
||||||
|
substituteInPlace Makefile \
|
||||||
|
--replace mktexlsr true
|
||||||
|
|
||||||
|
substituteInPlace doc/Makefile \
|
||||||
|
--replace ginstall-info install-info
|
||||||
|
|
||||||
|
substituteInPlace Config \
|
||||||
|
--replace '/usr/local' "$out" \
|
||||||
|
--replace '$(SHARE_DIR)/texmf' "$tex"
|
||||||
|
'';
|
||||||
|
|
||||||
|
preInstall = ''
|
||||||
|
mkdir -p $out/bin
|
||||||
|
'';
|
||||||
|
|
||||||
|
postInstall = ''
|
||||||
|
wrapProgram $out/bin/euktoeps \
|
||||||
|
--set-default TEXINPUTS : \
|
||||||
|
--prefix TEXINPUTS : "$tex/tex/latex/eukleides" \
|
||||||
|
--prefix PATH : "${texLive}/bin"
|
||||||
|
wrapProgram $out/bin/euktopdf \
|
||||||
|
--set-default TEXINPUTS : \
|
||||||
|
--prefix TEXINPUTS : "$tex/tex/latex/eukleides" \
|
||||||
|
--prefix PATH : "${texLive}/bin"
|
||||||
|
'';
|
||||||
|
|
||||||
|
outputs = [ "out" "doc" "tex" ];
|
||||||
|
|
||||||
|
passthru.tlType = "run";
|
||||||
|
passthru.pkgs = [ eukleides.tex ];
|
||||||
|
|
||||||
meta = {
|
meta = {
|
||||||
description = "Geometry Drawing Language";
|
description = "Geometry Drawing Language";
|
||||||
homepage = "http://www.eukleides.org/";
|
homepage = "http://www.eukleides.org/";
|
||||||
license = lib.licenses.gpl2;
|
license = lib.licenses.gpl3Plus;
|
||||||
|
|
||||||
longDescription = ''
|
longDescription = ''
|
||||||
Eukleides is a computer language devoted to elementary plane
|
Eukleides is a computer language devoted to elementary plane
|
||||||
|
@ -34,4 +62,4 @@ stdenv.mkDerivation {
|
||||||
platforms = lib.platforms.linux;
|
platforms = lib.platforms.linux;
|
||||||
maintainers = [ lib.maintainers.peti ];
|
maintainers = [ lib.maintainers.peti ];
|
||||||
};
|
};
|
||||||
}
|
})
|
||||||
|
|
Loading…
Reference in a new issue