# -*- 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 PortSystem 1.0 PortGroup python 1.0 PortGroup deprecated 1.0 name py-oursql python.versions 27 35 36 # TODO: It would be very nice to resolve this bizarre dual-version situation. version [expr {${name} eq ${subport} || ${python.version} < 30 ? {0.9.3.1} : {0.9.3}}] categories-append devel databases license BSD maintainers nomaintainer description Python driver for MySQL long_description oursql is a set of MySQL bindings for python with a focus \ on wrapping the MYSQL_STMT API to provide real \ parameterization and real server-side cursors. homepage https://launchpad.net/oursql distname oursql-${version} use_zip yes deprecated.upstream_support no if {${name} ne ${subport}} { if {${python.version} < 30} { master_sites http://launchpad.net/oursql/trunk/${version}/+download/ checksums md5 ad599ea2d95fc695df7195e9801b45c2 \ rmd160 e38d9566acb3abe513e0cfe92a533f128410db2c \ sha256 a6d8044591b2ecb859b8bf72a1c535d0b33bd249f7fecdbe63d2173855b568b7 } else { master_sites http://launchpad.net/oursql/py3k/py3k-${version}/+download/ patch_sites https://launchpadlibrarian.net/150278854 dist_subdir ${name}-py3k patchfiles patch-oursqlx-oursql.c.diff \ patch-oursqlx-oursql.pyx.diff checksums ${distname}${extract.suffix} \ md5 1c19d9ecbfc96e071f6da463a0fc9109 \ rmd160 259fb68bebf901cee83ffcadfbb17da0ff72be64 \ sha256 778ccbd1cfc80cf22a2245cd63cf715348aa8bbcf1d45fb91b4aa0dd3744dd6f \ patch-oursqlx-oursql.c.diff \ rmd160 c2f8f42c6b1681bc3fc79eee04901207c59e5947 \ sha256 58c12b577804b1d0174536ed075d31d27346aa9efc686482f99b265e5a1fa984 } variant mysql51 conflicts mysql55 mysql56 mariadb percona description {Build with MySQL 5.1} { depends_lib-append port:mysql51 build.env-append MYSQL_CONFIG=${prefix}/lib/mysql51/bin/mysql_config } variant mysql55 conflicts mysql51 mysql56 mariadb percona description {Build with MySQL 5.5} { depends_lib-append port:mysql55 build.env-append MYSQL_CONFIG=${prefix}/lib/mysql55/bin/mysql_config } variant mysql56 conflicts mysql51 mysql55 mariadb percona description {Build with MySQL 5.6} { depends_lib-append port:mysql56 build.env-append MYSQL_CONFIG=${prefix}/lib/mysql56/bin/mysql_config } variant mariadb conflicts mysql51 mysql55 mysql56 percona description {Build with MariaDB} { depends_lib-append port:mariadb build.env-append MYSQL_CONFIG=${prefix}/lib/mariadb/bin/mysql_config } variant percona conflicts mysql51 mysql55 mysql56 mariadb description {Build with Percona} { depends_lib-append port:percona build.env-append MYSQL_CONFIG=${prefix}/lib/percona/bin/mysql_config } proc no_variant_set {} { return [expr {!([variant_isset mysql51] || [variant_isset mysql55] || [variant_isset mysql56] || [variant_isset mariadb] || [variant_isset percona])}] } if {[no_variant_set]} { default_variants +mysql56 } pre-fetch { if {[no_variant_set]} { return -code error "Variant selection required" } } }