Ticket #18586: Portfile.4

File Portfile.4, 1.9 KB (added by nerdling (Jeremy Lavergne), 15 years ago)
Line 
1# -*- 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
2# $Id$
3
4PortSystem          1.0
5PortGroup           python26 1.0
6
7name                psycopg2
8version             2.0.9
9categories          databases
10maintainers         snc openmaintainer
11description         A python DBAPI-2.0 ompliant database adapter for postgresql
12long_description    Psycopg2 is a postgresql database adapter for python. \
13                    It's fully compliant to pythons DBAPI-2.0. psycopg is \
14                    designed for heavily multi-threaded applications \
15                    featuring connection pooling.
16homepage            http://www.initd.org/software/initd/psycopg/
17
18platforms           darwin freebsd
19depends_lib-append  port:openssl
20
21master_sites        http://initd.org/pub/software/psycopg/ \
22                    http://initd.org/pub/software/psycopg/PSYCOPG-2-0/
23
24checksums           md5 885e5bd372afafd14cfd914b000462e7 \
25                    sha1 d6aca4b96b69207a795934623de60e9c9ce32378 \
26                    rmd160 3194fbae1c69a3734e4db91e21db4b688de1d630
27
28pre-patch {
29    if {![variant_isset postgresql83] && ![variant_isset postgresql82]} {
30        return -code error \
31            "You have to choose either +postgresql82 or +postgresql83"
32    }
33}
34patchfiles          patch-setup.cfg.diff
35
36
37variant postgresql82 description "Build using postgresql v8.2" {
38    depends_lib-append  port:postgresql82
39   
40    post-patch {
41        reinplace \
42            s|@PG_CONFIG@|${prefix}/lib/postgresql82/bin/pg_config|g \
43            ${worksrcpath}/setup.cfg
44    }
45}
46
47variant postgresql83 description "Build using postgresql v8.3" {
48    depends_lib-append  port:postgresql83
49   
50    post-patch {
51        reinplace \
52            s|@PG_CONFIG@|${prefix}/lib/postgresql83/bin/pg_config|g \
53            ${worksrcpath}/setup.cfg
54    }
55}