Author: ludo
Date: 2010-06-06 22:39:28 +0000 (Sun, 06 Jun 2010)
New Revision: 22162

You can view the changes in this commit at:
   https://svn.nixos.org/viewvc/nix?rev=22162&view=rev

Modified:
   nixpkgs/trunk/pkgs/applications/editors/emacs-modes/proofgeneral/default.nix
   nixpkgs/trunk/pkgs/top-level/all-packages.nix

Log:
Proof General: Build and install via the makefile.

Changes:

Modified: 
nixpkgs/trunk/pkgs/applications/editors/emacs-modes/proofgeneral/default.nix
===================================================================
--- 
nixpkgs/trunk/pkgs/applications/editors/emacs-modes/proofgeneral/default.nix    
    2010-06-06 21:52:34 UTC (rev 22161)
+++ 
nixpkgs/trunk/pkgs/applications/editors/emacs-modes/proofgeneral/default.nix    
    2010-06-06 22:39:28 UTC (rev 22162)
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, emacs, perl }:
+{ stdenv, fetchurl, emacs, texinfo, texLive, perl, which, automake }:
 
 let
   pname = "ProofGeneral";
@@ -15,28 +15,32 @@
     sha256 = 
"ae430590d6763618df50a662a37f0627d3c3c8f31372f6f0bb2116b738fc92d8";
   };
 
-  buildInputs = [ emacs perl ];
-
   sourceRoot = name;
 
-  postPatch = "EMACS=emacs make clean";
+  buildInputs = [ emacs texinfo texLive perl which ];
 
-  # Skip building ...
-  buildPhase = "true";
+  patchPhase =
+    '' sed -i "Makefile" \
+           -e "s|^\(\(DEST_\)\?PREFIX\)=.*$|\1=$out|g ; \
+               s|/sbin/install-info|install-info|g"
 
-  installPhase = ''
-    DEST=$out/share/emacs/site-lisp/ProofGeneral
-    ensureDir $DEST
-    cp -a * $DEST
-  '';
+       sed -i "bin/proofgeneral" -e's/which/type -p/g'
+    '';
 
+  installPhase =
+    # Copy `texinfo.tex' in the right place so that `texi2pdf' works.
+    '' cp -v "${automake}/share/"automake-*/texinfo.tex doc
+       make install install-doc
+    '';
+
   meta = {
-    description = "A generic front-end for proof assistants";
+    description = "Proof General, an Emacs front-end for proof assistants";
     longDescription = ''
       Proof General is a generic front-end for proof assistants (also known as
       interactive theorem provers), based on the customizable text editor 
Emacs.
     '';
     homepage = website;
-    license = "GPL";
+    license = "GPLv2+";
+    platforms = stdenv.lib.platforms.gnu;  # arbitrary choice
   };
 }

Modified: nixpkgs/trunk/pkgs/top-level/all-packages.nix
===================================================================
--- nixpkgs/trunk/pkgs/top-level/all-packages.nix       2010-06-06 21:52:34 UTC 
(rev 22161)
+++ nixpkgs/trunk/pkgs/top-level/all-packages.nix       2010-06-06 22:39:28 UTC 
(rev 22162)
@@ -7665,7 +7665,7 @@
     };
 
     proofgeneral = import ../applications/editors/emacs-modes/proofgeneral {
-       inherit stdenv fetchurl emacs perl;
+      inherit stdenv fetchurl emacs texinfo texLive perl which automake;
     };
 
     quack = import ../applications/editors/emacs-modes/quack {

_______________________________________________
nix-commits mailing list
[email protected]
http://mail.cs.uu.nl/mailman/listinfo/nix-commits

Reply via email to