# -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:ft=tcl:et:sw=4:ts=4:sts=4
# $Id: Portfile 38416 2008-07-19 07:45:19Z jmr@macports.org $

PortSystem 1.0

name            mod_wsgi
version         2.3
categories      www python
platforms       darwin
maintainers     nomaintainer
description     Python WSGI adapter module for Apache.
long_description The aim of mod_wsgi is to implement a simple \
to use Apache module which can host any Python application \
which supports the Python WSGI interface. The module would be \
suitable for use in hosting high performance production web \
sites, as well as your average self managed personal sites \
running on web hosting services.

homepage        http://www.modwsgi.org/
master_sites    http://modwsgi.googlecode.com/files/
checksums       md5 c686e1c498dbe5753fe491c3cf61cff4 \
                sha1 7a28710b1ce02a48e4dc77189e37dcbffa0ed26b
                
depends_lib     port:apache2 port:python25

configure.cppflags-append \
                "-I${prefix}/include/python2.5"
configure.ldflags-append \
                "-Wl,-F${prefix}/Library/Frameworks"
configure.args \
                --with-apxs=${prefix}/apache2/bin/apxs \
                --with-python=${prefix}/bin/python2.5

destroot.violate_mtree yes
pre-destroot {
    xinstall -d -m 755 ${destroot}${prefix}/apache2/modules
}

post-install {
    ui_msg "########################################################"
    ui_msg "# To enable mod_wsgi add"
    ui_msg "#  LoadModule wsgi_module modules/mod_wsgi.so"
    ui_msg "# to your apache2 config file:"
    ui_msg "#  ${prefix}/apache2/conf/httpd.conf"
    ui_msg "########################################################"
}

