about summary refs log tree commit diff
path: root/pkgs/tools/typesetting/tex/tetex/default.nix
diff options
context:
space:
mode:
authorJason "Don" O'Conal <lovek323@gmail.com>2013-08-27 15:07:32 +1000
committerVladimír Čunát <vcunat@gmail.com>2013-09-06 10:11:54 +0200
commitbcec0454e95856798548b8d051d1496faf4e2690 (patch)
tree15e07ead8a525d0b2941813307668309c27eb08b /pkgs/tools/typesetting/tex/tetex/default.nix
parent782ae254580d055a83aa5e61395d0239fcdcfc71 (diff)
texLive: fix build on darwin
vcunat edit: use ruby19 on all platforms now.
See #700 for discussion related to the changes.
Diffstat (limited to 'pkgs/tools/typesetting/tex/tetex/default.nix')
-rw-r--r--pkgs/tools/typesetting/tex/tetex/default.nix43
1 files changed, 23 insertions, 20 deletions
diff --git a/pkgs/tools/typesetting/tex/tetex/default.nix b/pkgs/tools/typesetting/tex/tetex/default.nix
index bb1e3f8b4b037..5cd3228aced30 100644
--- a/pkgs/tools/typesetting/tex/tetex/default.nix
+++ b/pkgs/tools/typesetting/tex/tetex/default.nix
@@ -15,30 +15,33 @@ stdenv.mkDerivation {
 
   buildInputs = [ flex bison zlib libpng ncurses ed ];
 
+  # fixes "error: conflicting types for 'calloc'", etc.
+  preBuild = stdenv.lib.optionalString stdenv.isDarwin ''
+    sed -i 57d texk/kpathsea/c-std.h
+  '';
+
   patches = [ ./environment.patch ./getline.patch ];
 
   setupHook = ./setup-hook.sh;
 
   configureFlags =
-    [ "--disable-multiplatform"
-      "--without-x11"
-      "--without-xdvik"
-      "--without-oxdvik"
-      "--without-texinfo"
-      "--without-texi2html"
-      "--with-system-zlib"
-      "--with-system-pnglib"
-      "--with-system-ncurses"
-    ];
-
-  postUnpack =
-    ''
-      mkdir -p $out/share/texmf
-      mkdir -p $out/share/texmf-dist
-      gunzip < $texmf | (cd $out/share/texmf-dist && tar xvf -)
-    '';
-
-  meta = {
-    description = "A full-featured (La)TeX distribution";
+    [ "--disable-multiplatform" "--without-x11" "--without-xdvik"
+      "--without-oxdvik" "--without-texinfo" "--without-texi2html"
+      "--with-system-zlib" "--with-system-pnglib" "--with-system-ncurses" ]
+    # couldn't get gsftopk working on darwin
+    ++ stdenv.lib.optional stdenv.isDarwin "--without-gsftopk";
+
+  postUnpack = ''
+    mkdir -p $out/share/texmf
+    mkdir -p $out/share/texmf-dist
+    gunzip < $texmf | (cd $out/share/texmf-dist && tar xvf -)
+  '';
+
+  meta = with stdenv.lib; {
+    description  = "A full-featured (La)TeX distribution";
+    homepage     = http://www.tug.org/tetex/;
+    matintainers = with maintainers; [ lovek323 ];
+    platforms    = platforms.unix;
   };
 }
+