From 076cc3a7d8f68d4e612f042b8241a24cff5f37ee Mon Sep 17 00:00:00 2001 From: Michael Raskin <7c6f434c@mail.ru> Date: Wed, 14 Nov 2007 01:20:17 +0000 Subject: [PATCH] Now SVN Nix builds as a purely alternative Nix choice svn path=/nixpkgs/trunk/; revision=9666 --- pkgs/tools/package-management/nix/custom.nix | 29 +++++++++++++++++--- pkgs/top-level/all-packages.nix | 10 +++++-- 2 files changed, 33 insertions(+), 6 deletions(-) diff --git a/pkgs/tools/package-management/nix/custom.nix b/pkgs/tools/package-management/nix/custom.nix index b5e87119957..2cff9f53d87 100644 --- a/pkgs/tools/package-management/nix/custom.nix +++ b/pkgs/tools/package-management/nix/custom.nix @@ -1,7 +1,15 @@ { stdenv, fetchurl, aterm, db4, perl, curl, bzip2, openssl ? null , storeDir ? "/nix/store" , stateDir ? "/nix/var" -,src +, src +, preConfigure ? "" +, autoconf ? null, automake ? null, libtool ? null +, bison ? null +, flex ? null +, w3m ? null +, docbook5_xsl ? null, libxslt ? null +, docbook5 ? null, docbook_xml_dtd_43 ? null +, configureFlags ? [] }: stdenv.mkDerivation { @@ -9,12 +17,25 @@ stdenv.mkDerivation { inherit src; - buildInputs = [perl curl openssl]; + buildInputs = [perl curl openssl] + ++ (if automake != null then [automake] else []) + ++ (if autoconf != null then [autoconf] else []) + ++ (if libtool != null then [libtool] else []) + ++ (if bison != null then [bison] else []) + ++ (if flex != null then [flex] else []) + ++ (if docbook5_xsl != null then [docbook5_xsl] else []) + ++ (if libxslt != null then [libxslt] else []) + ++ (if docbook5 != null then [docbook5] else []) + ++ (if docbook_xml_dtd_43 != null then [docbook_xml_dtd_43] else []) + ++ (if w3m != null then [w3m] else []) + ; - configureFlags = " + inherit preConfigure; + + configureFlags = [" --with-store-dir=${storeDir} --localstatedir=${stateDir} --with-aterm=${aterm} --with-bdb=${db4} --with-bzip2=${bzip2} - --disable-init-state"; + --disable-init-state"] ++ configureFlags ; meta = { description = "The Nix Deployment System"; diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 1f1721f734e..eb747131bab 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -4524,10 +4524,16 @@ rec { db4 = db45; }; - nixCustomFun = src: (import ../tools/package-management/nix/custom.nix { - inherit fetchurl stdenv perl curl bzip2 openssl src; + nixCustomFun = src: preConfigure: configureFlags : + (import ../tools/package-management/nix/custom.nix { + inherit fetchurl stdenv perl curl bzip2 openssl src preConfigure automake + autoconf libtool configureFlags; + bison = bison23; + flex = flex2533; aterm = aterm242fixes; db4 = db45; + inherit docbook5_xsl libxslt docbook5 docbook_xml_dtd_43 w3m; + }); ntfs3g = import ../misc/ntfs-3g {