summary refs log tree commit diff
path: root/pkgs/servers/http/apache-modules/mod_wsgi/default.nix
blob: b5073428754c2be9ff9f988ac53690ff5fc755ff (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
{ stdenv, fetchurl, apacheHttpd, python }:

stdenv.mkDerivation {
  name = "mod_wsgi-3.3";

  src = fetchurl {
    url = "http://modwsgi.googlecode.com/files/mod_wsgi-3.3.tar.gz";
    sha256 = "0hrjksym0dlqn1ka1yf3x6ar801zqxfykwcxazjwz104k5w10vnr";
  };

  buildInputs = [ apacheHttpd python ];

  patchPhase = ''
    sed -r -i -e "s|^LIBEXECDIR=.*$|LIBEXECDIR=$out/modules|" \
      ${if stdenv.isDarwin then "-e 's|/usr/bin/lipo|lipo|'" else ""} \
      configure
  '';

  meta = {
    homepage = "http://code.google.com/p/modwsgi/";
    description = "Host Python applications in Apache through the WSGI interface";
    license = "ASL2.0";

    platforms = stdenv.lib.platforms.unix;
    maintainers = [ stdenv.lib.maintainers.simons ];
  };
}