about summary refs log tree commit diff
path: root/pkgs
diff options
context:
space:
mode:
authorEelco Dolstra <eelco.dolstra@logicblox.com>2008-10-06 13:38:45 +0000
committerEelco Dolstra <eelco.dolstra@logicblox.com>2008-10-06 13:38:45 +0000
commit781bb5a6e158c85a1c8fa73510889c358e03bd80 (patch)
tree0009256fbe426ca5af6440ed70d5e227052f82b4 /pkgs
parent487a8ddb9e287cd95e1e12494b08b6ee0765942a (diff)
downloadnixlib-781bb5a6e158c85a1c8fa73510889c358e03bd80.tar
nixlib-781bb5a6e158c85a1c8fa73510889c358e03bd80.tar.gz
nixlib-781bb5a6e158c85a1c8fa73510889c358e03bd80.tar.bz2
nixlib-781bb5a6e158c85a1c8fa73510889c358e03bd80.tar.lz
nixlib-781bb5a6e158c85a1c8fa73510889c358e03bd80.tar.xz
nixlib-781bb5a6e158c85a1c8fa73510889c358e03bd80.tar.zst
nixlib-781bb5a6e158c85a1c8fa73510889c358e03bd80.zip
* Apache httpd: build against apr, aputil and pcre instead of using
  its own copies.

svn path=/nixpkgs/trunk/; revision=12971
Diffstat (limited to 'pkgs')
-rw-r--r--pkgs/applications/version-management/subversion-1.4.x/default.nix24
-rw-r--r--pkgs/applications/version-management/subversion-1.5.x/default.nix7
-rw-r--r--pkgs/development/libraries/apr-util/default.nix6
-rw-r--r--pkgs/development/libraries/apr/default.nix13
-rw-r--r--pkgs/servers/http/apache-httpd/default.nix29
-rw-r--r--pkgs/servers/http/apache-modules/mod_python/builder.sh7
-rw-r--r--pkgs/servers/http/apache-modules/mod_python/default.nix22
-rw-r--r--pkgs/top-level/all-packages.nix3
8 files changed, 51 insertions, 60 deletions
diff --git a/pkgs/applications/version-management/subversion-1.4.x/default.nix b/pkgs/applications/version-management/subversion-1.4.x/default.nix
index 3170fca9f204..e036595ad2e9 100644
--- a/pkgs/applications/version-management/subversion-1.4.x/default.nix
+++ b/pkgs/applications/version-management/subversion-1.4.x/default.nix
@@ -10,7 +10,7 @@
 }:
 
 assert bdbSupport -> aprutil.bdbSupport;
-assert httpServer -> httpd != null && httpd.expat == expat;
+assert httpServer -> httpd != null && httpd.apr == apr && httpd.aprutil == aprutil;
 assert pythonBindings -> swig != null && swig.pythonSupport;
 assert javahlBindings -> jdk != null;
 assert sslSupport -> neon.sslSupport;
@@ -30,32 +30,28 @@ stdenv.mkDerivation rec {
 
   buildInputs =
     [expat zlib]
-    ++ (if pythonBindings then [swig.python] else [])
-    ++ (if perlBindings then [swig.perl] else [])
-	;
+    ++ stdenv.lib.optional pythonBindings swig.python
+    ++ stdenv.lib.optional perlBindings swig.perl
+    ;
 
-  configureFlags = "
+  configureFlags = ''
     --without-gdbm --disable-static
     --with-apr=${apr} -with-apr-util=${aprutil} --with-neon=${neon}
     --disable-keychain
     ${if bdbSupport then "--with-berkeley-db" else "--without-berkeley-db"}
-    ${if httpServer then
-        "--with-apxs=${httpd}/bin/apxs --with-apr=${httpd} --with-apr-util=${httpd}"
-      else
-        "--without-apxs"}
-    ${if (pythonBindings || perlBindings) then "--with-swig=${swig}" else "--without-swig"}
+    ${if httpServer then "--with-apxs=${httpd}/bin/apxs" else "--without-apxs"}
+    ${if pythonBindings || perlBindings then "--with-swig=${swig}" else "--without-swig"}
     ${if javahlBindings then "--enable-javahl --with-jdk=${jdk}" else ""}
     --disable-neon-version-check
-  ";
+  '';
 
   inherit httpServer pythonBindings javahlBindings perlBindings;
+  
   patches = [ ./subversion-respect_CPPFLAGS_in_perl_bindings.patch ];
 
   passthru = {
     inherit perlBindings pythonBindings;
-    python = if ( swig != null ) && (swig ? python) then 
-        swig.python 
-      else null;
+    python = if swig != null && swig ? python then swig.python else null;
   };
 
   meta = {
diff --git a/pkgs/applications/version-management/subversion-1.5.x/default.nix b/pkgs/applications/version-management/subversion-1.5.x/default.nix
index 16cb43a0ddca..2fca0994f17f 100644
--- a/pkgs/applications/version-management/subversion-1.5.x/default.nix
+++ b/pkgs/applications/version-management/subversion-1.5.x/default.nix
@@ -11,7 +11,7 @@
 }:
 
 assert bdbSupport -> aprutil.bdbSupport;
-assert httpServer -> httpd != null && httpd.expat == expat;
+assert httpServer -> httpd != null && httpd.apr == apr && httpd.aprutil == aprutil;
 assert pythonBindings -> swig != null && swig.pythonSupport;
 assert javahlBindings -> jdk != null;
 assert sslSupport -> neon.sslSupport;
@@ -37,10 +37,7 @@ stdenv.mkDerivation rec {
     --disable-static
     --disable-keychain
     ${if bdbSupport then "--with-berkeley-db" else "--without-berkeley-db"}
-    ${if httpServer then
-        "--with-apxs=${httpd}/bin/apxs --with-apr=${httpd} --with-apr-util=${httpd}"
-      else
-        "--without-apxs"}
+    ${if httpServer then "--with-apxs=${httpd}/bin/apxs" else "--without-apxs"}
     ${if pythonBindings || perlBindings then "--with-swig=${swig}" else "--without-swig"}
     ${if javahlBindings then "--enable-javahl --with-jdk=${jdk}" else ""}
     --disable-neon-version-check
diff --git a/pkgs/development/libraries/apr-util/default.nix b/pkgs/development/libraries/apr-util/default.nix
index 967408e0cb43..8c745fd75a22 100644
--- a/pkgs/development/libraries/apr-util/default.nix
+++ b/pkgs/development/libraries/apr-util/default.nix
@@ -5,11 +5,11 @@
 assert bdbSupport -> db4 != null;
 
 stdenv.mkDerivation {
-  name = "apr-util-1.2.12";
+  name = "apr-util-1.3.4";
   
   src = fetchurl {
-    url = http://archive.apache.org/dist/apr/apr-util-1.2.12.tar.bz2;
-    sha256 = "152xwaxikp22acz7ypqsvlyjxhak6p40805wwbw7hcg1gyg2scyl";
+    url = mirror://apache/apr/apr-util-1.3.4.tar.bz2;
+    sha256 = "1kin1yh42sk7hw81x3aynjf2g0k07n6707426c2mi6fh6lr0lys4";
   };
   
   configureFlags = ''
diff --git a/pkgs/development/libraries/apr/default.nix b/pkgs/development/libraries/apr/default.nix
index ceae8a1d12a9..2c62232a490d 100644
--- a/pkgs/development/libraries/apr/default.nix
+++ b/pkgs/development/libraries/apr/default.nix
@@ -1,13 +1,20 @@
 {stdenv, fetchurl}:
 
 stdenv.mkDerivation {
-  name = "apr-1.2.12";
+  name = "apr-1.3.3";
   
   src = fetchurl {
-    url = http://archive.apache.org/dist/apr/apr-1.2.12.tar.bz2;
-    sha256 = "0d11wa2hlhb5lnny5rcazca056b35kgccx94cd38bazw1d6b68nv";
+    url = mirror://apache/apr/apr-1.3.3.tar.bz2;
+    sha256 = "0dyxw3km88f0li1d39vyr09670yb12xn8j1h8dq331kc6rw3npyr";
   };
 
+  # For now, disable detection of epoll to ensure that Apache still
+  # runs on Linux 2.4 kernels.  Once we've dropped support for 2.4 in
+  # Nixpkgs, this can go.  In general, it's a problem that APR
+  # detects characteristics of the build system's kernel to decide
+  # what to use at runtime, since it's impure.
+  #apr_cv_epoll = "no";
+
   meta = {
     homepage = http://apr.apache.org/;
     description = "The Apache Portable Runtime library";
diff --git a/pkgs/servers/http/apache-httpd/default.nix b/pkgs/servers/http/apache-httpd/default.nix
index a4a76f9b4cb2..853ed3b301a2 100644
--- a/pkgs/servers/http/apache-httpd/default.nix
+++ b/pkgs/servers/http/apache-httpd/default.nix
@@ -1,10 +1,9 @@
-{ stdenv, fetchurl, openssl, db4, expat, perl, zlib
-, sslSupport, db4Support, proxySupport ? true
+{ stdenv, fetchurl, openssl, perl, zlib
+, sslSupport, proxySupport ? true
+, apr, aprutil, pcre
 }:
 
 assert sslSupport -> openssl != null;
-assert db4Support -> db4 != null;
-assert expat != null && perl != null;
 
 stdenv.mkDerivation {
   name = "apache-httpd-2.2.9";
@@ -14,23 +13,18 @@ stdenv.mkDerivation {
     md5 = "3afa8137dc1999be695a20b62fdf032b";
   };
 
-  #inherit sslSupport db4Support;
+  #inherit sslSupport;
 
-  buildInputs = [expat perl] ++
-    stdenv.lib.optional sslSupport openssl ++
-    stdenv.lib.optional db4Support db4;
+  buildInputs = [perl apr aprutil pcre] ++
+    stdenv.lib.optional sslSupport openssl;
 
   configureFlags = ''
-    --with-expat=${expat}
     --with-z=${zlib}
+    --with-pcre=${pcre}
     --enable-mods-shared=all
     --enable-authn-alias
     ${if proxySupport then "--enable-proxy" else ""}
-    --without-gdbm
-    --enable-threads
-    --with-devrandom=/dev/urandom
     ${if sslSupport then "--enable-ssl --with-ssl=${openssl}" else ""}
-    ${if db4Support then "--with-berkeley-db=${db4}" else ""}
   '';
 
   postInstall = ''
@@ -38,15 +32,8 @@ stdenv.mkDerivation {
     rm -rf $out/manual
   '';
 
-  # For now, disable detection of epoll to ensure that Apache still
-  # runs on Linux 2.4 kernels.  Once we've dropped support for 2.4 in
-  # Nixpkgs, this can go.  In general, it's a problem that APR
-  # detects characteristics of the build system's kernel to decide
-  # what to use at runtime, since it's impure.
-  apr_cv_epoll = "no";
-
   passthru = {
-    inherit expat sslSupport db4Support proxySupport;
+    inherit apr aprutil sslSupport proxySupport;
   };
   
   meta = {
diff --git a/pkgs/servers/http/apache-modules/mod_python/builder.sh b/pkgs/servers/http/apache-modules/mod_python/builder.sh
deleted file mode 100644
index 77377caa854f..000000000000
--- a/pkgs/servers/http/apache-modules/mod_python/builder.sh
+++ /dev/null
@@ -1,7 +0,0 @@
-source $stdenv/setup
-
-installFlags="LIBEXECDIR=$out/modules $installFlags"
-
-ensureDir $out/modules
-
-genericBuild
diff --git a/pkgs/servers/http/apache-modules/mod_python/default.nix b/pkgs/servers/http/apache-modules/mod_python/default.nix
index 4c83070e9cab..a59fa60c4c7b 100644
--- a/pkgs/servers/http/apache-modules/mod_python/default.nix
+++ b/pkgs/servers/http/apache-modules/mod_python/default.nix
@@ -3,15 +3,27 @@
 stdenv.mkDerivation {
   name = "mod_python-3.3.1";
 
-  builder = ./builder.sh;
-
   src = fetchurl {
-    url = http://archive.eu.apache.org/dist/httpd/modpython/mod_python-3.3.1.tgz;
+    url = mirror://apache/httpd/modpython/mod_python-3.3.1.tgz;
     sha256 = "0sss2xi6l1a2z8y6ji0cp8vgyvnhq8zrg0ilkvpj1mygbzyk28xd";
   };
 
-  patches = [./install.patch];
+  patches = [
+    ./install.patch
+
+    # See http://bugs.gentoo.org/show_bug.cgi?id=230211
+    (fetchurl {
+      url = "http://bugs.gentoo.org/attachment.cgi?id=160400";
+      sha256 = "0yx6x9c5rg5kn6y8vsi4xj3nvg016rrfk553ca1bw796v383xkyj";
+    })
+  ];
+
+  preInstall = ''
+    installFlags="LIBEXECDIR=$out/modules $installFlags"
+    ensureDir $out/modules
+  '';
 
-  inherit apacheHttpd;
+  passthru = { inherit apacheHttpd; };
+  
   buildInputs = [apacheHttpd python];
 }
diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix
index 42d53df6aef3..e5e4bab3ea49 100644
--- a/pkgs/top-level/all-packages.nix
+++ b/pkgs/top-level/all-packages.nix
@@ -4648,9 +4648,8 @@ let
 
 
   apacheHttpd = import ../servers/http/apache-httpd {
-    inherit fetchurl stdenv perl openssl db4 expat zlib;
+    inherit fetchurl stdenv perl openssl zlib apr aprutil pcre;
     sslSupport = true;
-    db4Support = true;
   };
 
   bind = builderDefsPackage (selectVersion ../servers/dns/bind "9.5.0") {