[111087] trunk/dports/python/py-oursql
larryv at macports.org
larryv at macports.org
Sat Sep 14 14:00:49 PDT 2013
Revision: 111087
https://trac.macports.org/changeset/111087
Author: larryv at macports.org
Date: 2013-09-14 14:00:45 -0700 (Sat, 14 Sep 2013)
Log Message:
-----------
py2*-oursql: Update to 0.9.3.1.
py3*-oursql: New subports at 0.9.3.
Also remove mysql4 variant and add mysql5*, mariadb, and percona variants.
(#39510)
Modified Paths:
--------------
trunk/dports/python/py-oursql/Portfile
Added Paths:
-----------
trunk/dports/python/py-oursql/files/
trunk/dports/python/py-oursql/files/patch-oursqlx-oursql.pyx.diff
Modified: trunk/dports/python/py-oursql/Portfile
===================================================================
--- trunk/dports/python/py-oursql/Portfile 2013-09-14 14:17:22 UTC (rev 111086)
+++ trunk/dports/python/py-oursql/Portfile 2013-09-14 21:00:45 UTC (rev 111087)
@@ -1,47 +1,86 @@
+# -*- 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$
-PortSystem 1.0
-PortGroup python 1.0
+PortSystem 1.0
+PortGroup python 1.0
name py-oursql
-version 0.9.2
-categories python devel databases
+python.versions 26 27 31 32 33
+version [expr {${python.version} < 30 ? {0.9.3.1} : {0.9.3}}]
+
+categories-append devel databases
+platforms darwin
+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.
-platforms darwin
homepage https://launchpad.net/oursql
-master_sites http://launchpad.net/oursql/trunk/${version}/+download/
+
distname oursql-${version}
-use_bzip2 yes
-checksums sha1 d3d82bc5f6bf646f37853020171fed48e9920d9e \
- rmd160 0f38d57b34ce5194c8ad5a9717e5cf3fe2dcd7af
+use_zip yes
-python.versions 26 27
-python.default_version 27
+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
-variant mysql4 conflicts mysql5 description {Build with MySQL 4} {
- if {$subport != $name} {
- depends_lib-append port:mysql4
- build.env MYSQL_CONFIG=mysql_config4
- }
+ dist_subdir ${name}-py3k
+ patchfiles patch-oursqlx-oursql.c.diff \
+ patch-oursqlx-oursql.pyx.diff
+
+ checksums [suffix ${distname}] \
+ md5 1c19d9ecbfc96e071f6da463a0fc9109 \
+ rmd160 259fb68bebf901cee83ffcadfbb17da0ff72be64 \
+ sha256 778ccbd1cfc80cf22a2245cd63cf715348aa8bbcf1d45fb91b4aa0dd3744dd6f \
+ patch-oursqlx-oursql.c.diff \
+ rmd160 c2f8f42c6b1681bc3fc79eee04901207c59e5947 \
+ sha256 58c12b577804b1d0174536ed075d31d27346aa9efc686482f99b265e5a1fa984
}
-variant mysql5 conflicts mysql4 description {Build with MySQL 5} {
- if {$subport != $name} {
- depends_lib-append path:bin/mysql_config5:mysql5
- build.env MYSQL_CONFIG=mysql_config5
+if {${subport} ne ${name}} {
+ variant mysql5 conflicts mysql51 mysql55 mysql56 mariadb percona description {Build with MySQL 5} {
+ depends_lib-append port:mysql5
+ build.env-append MYSQL_CONFIG=${prefix}/lib/mysql5/bin/mysql_config
}
-}
+ variant mysql51 conflicts mysql5 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 mysql5 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 mysql5 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 mysql5 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 mysql5 mysql51 mysql55 mysql56 mariadb description {Build with Percona} {
+ depends_lib-append port:percona
+ build.env-append MYSQL_CONFIG=${prefix}/lib/percona/bin/mysql_config
+ }
-if {![variant_isset mysql4]} {
- default_variants +mysql5
-}
-
-pre-fetch {
- if {![variant_isset mysql4] && ![variant_isset mysql5]} {
- return -code error "you must select either mysql4 or mysql5"
+ proc no_variant_set {} {
+ return [expr {!([variant_isset mysql5] || [variant_isset mysql51] ||
+ [variant_isset mysql55] || [variant_isset mysql56] ||
+ [variant_isset mariadb] || [variant_isset percona])}]
}
+ if {[no_variant_set]} {
+ default_variants +mysql5
+ }
+ pre-fetch {
+ if {[no_variant_set]} {
+ return -code error "Variant selection required"
+ }
+ }
}
Added: trunk/dports/python/py-oursql/files/patch-oursqlx-oursql.pyx.diff
===================================================================
--- trunk/dports/python/py-oursql/files/patch-oursqlx-oursql.pyx.diff (rev 0)
+++ trunk/dports/python/py-oursql/files/patch-oursqlx-oursql.pyx.diff 2013-09-14 21:00:45 UTC (rev 111087)
@@ -0,0 +1,11 @@
+--- oursqlx/oursql.pyx.orig 2013-09-14 15:19:58.000000000 -0400
++++ oursqlx/oursql.pyx 2013-09-14 15:14:58.000000000 -0400
+@@ -5,7 +5,7 @@
+ """
+
+ __author__ = 'Aaron Gallagher <habnabit at gmail.com>'
+-__version__ = '0.9.2'
++__version__ = '0.9.3'
+
+ include "oursql.pxi"
+ include "nogil.pyx"
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/macports-changes/attachments/20130914/0cdb3248/attachment.html>
More information about the macports-changes
mailing list