[34152] trunk/dports/python/py25-mysql
ryandesign at macports.org
ryandesign at macports.org
Fri Feb 15 15:53:08 PST 2008
Revision: 34152
http://trac.macosforge.org/projects/macports/changeset/34152
Author: ryandesign at macports.org
Date: 2008-02-15 15:53:07 -0800 (Fri, 15 Feb 2008)
Log Message:
-----------
py25-mysql:
* Fix patchfile names to match guidelines
* Add variant descriptions
* Remove mysql5-devel variant which was added in r31499 because hyphens are illegal in variant names and also because we should not depend on -devel ports
* Add mysql5 variant which depends on ${prefix}/bin/mysql_config5 so that the mysql5-devel port would also satisfy the dependency
* Make mysql5 the default variant, if mysql3 or mysql4 have not been selected
* Fix mysql3 variant (was broken because it depended on mysql port which does not exist; port is called mysql3)
* Issue a warning if none of mysql3, mysql4 or mysql5 are selected (user would have to go out of their way to make this happen)
* mark mysql3, mysql4 and mysql5 as conflicting with one another
Closes #13410 (maintainer timeout)
Modified Paths:
--------------
trunk/dports/python/py25-mysql/Portfile
Added Paths:
-----------
trunk/dports/python/py25-mysql/files/patch-_mysql.c.diff
trunk/dports/python/py25-mysql/files/patch-setup_posix.py.diff
Removed Paths:
-------------
trunk/dports/python/py25-mysql/files/patch-_mysql.c
trunk/dports/python/py25-mysql/files/patch-setup_posix.py
Modified: trunk/dports/python/py25-mysql/Portfile
===================================================================
--- trunk/dports/python/py25-mysql/Portfile 2008-02-15 23:38:17 UTC (rev 34151)
+++ trunk/dports/python/py25-mysql/Portfile 2008-02-15 23:53:07 UTC (rev 34152)
@@ -15,25 +15,29 @@
master_sites sourceforge:mysql-python
distname MySQL-python-${version}
checksums md5 532268f02870bea18c1d465e88afff30
-patchfiles patch-setup_posix.py patch-_mysql.c
+patchfiles patch-_mysql.c.diff
-depends_lib-append port:mysql5 port:py25-setuptools
+depends_lib-append port:py25-setuptools
-variant mysql3 {
- patchfiles-delete patch-setup_posix.py
- depends_lib-delete port:mysql5
- depends_lib-append port:mysql
+variant mysql3 conflicts mysql4 mysql5 description {Build with MySQL 3} {
+ depends_lib-append port:mysql3
}
-variant mysql4 {
- patchfiles-delete patch-setup_posix.py
- depends_lib-delete port:mysql5
+variant mysql4 conflicts mysql3 mysql5 description {Build with MySQL 4} {
depends_lib-append port:mysql4
}
-variant mysql5-devel {
- patchfiles-delete patch-setup_posix.py
- depends_lib-delete port:mysql5
- depends_lib-append port:mysql5-devel
+variant mysql5 conflicts mysql3 mysql4 description {Build with MySQL 5 (default)} {
+ patchfiles-append patch-setup_posix.py.diff
+ depends_lib-append path:${prefix}/bin/mysql_config5:mysql5
}
+if {![variant_isset mysql3] && ![variant_isset mysql4]} {
+ default_variants +mysql5
+}
+
+pre-fetch {
+ if {![variant_isset mysql3] && ![variant_isset mysql4] && ![variant_isset mysql5]} {
+ return -code error "you must select either mysql3, mysql4 or mysql5"
+ }
+}
Deleted: trunk/dports/python/py25-mysql/files/patch-_mysql.c
===================================================================
--- trunk/dports/python/py25-mysql/files/patch-_mysql.c 2008-02-15 23:38:17 UTC (rev 34151)
+++ trunk/dports/python/py25-mysql/files/patch-_mysql.c 2008-02-15 23:53:07 UTC (rev 34152)
@@ -1,23 +0,0 @@
---- _mysql.c.orig 2007-02-27 18:35:56.000000000 -0800
-+++ _mysql.c 2007-11-25 21:54:09.000000000 -0800
-@@ -34,9 +34,6 @@
- #else
- #include "my_config.h"
- #endif
--#ifndef uint
--#define uint unsigned int
--#endif
- #include "mysql.h"
- #include "mysqld_error.h"
- #include "errmsg.h"
-@@ -481,8 +478,8 @@
- #endif
- char *host = NULL, *user = NULL, *passwd = NULL,
- *db = NULL, *unix_socket = NULL;
-- uint port = MYSQL_PORT;
-- uint client_flag = 0;
-+ unsigned int port = MYSQL_PORT;
-+ unsigned int client_flag = 0;
- static char *kwlist[] = { "host", "user", "passwd", "db", "port",
- "unix_socket", "conv",
- "connect_timeout", "compress",
Copied: trunk/dports/python/py25-mysql/files/patch-_mysql.c.diff (from rev 34135, trunk/dports/python/py25-mysql/files/patch-_mysql.c)
===================================================================
--- trunk/dports/python/py25-mysql/files/patch-_mysql.c.diff (rev 0)
+++ trunk/dports/python/py25-mysql/files/patch-_mysql.c.diff 2008-02-15 23:53:07 UTC (rev 34152)
@@ -0,0 +1,23 @@
+--- _mysql.c.orig 2007-02-27 18:35:56.000000000 -0800
++++ _mysql.c 2007-11-25 21:54:09.000000000 -0800
+@@ -34,9 +34,6 @@
+ #else
+ #include "my_config.h"
+ #endif
+-#ifndef uint
+-#define uint unsigned int
+-#endif
+ #include "mysql.h"
+ #include "mysqld_error.h"
+ #include "errmsg.h"
+@@ -481,8 +478,8 @@
+ #endif
+ char *host = NULL, *user = NULL, *passwd = NULL,
+ *db = NULL, *unix_socket = NULL;
+- uint port = MYSQL_PORT;
+- uint client_flag = 0;
++ unsigned int port = MYSQL_PORT;
++ unsigned int client_flag = 0;
+ static char *kwlist[] = { "host", "user", "passwd", "db", "port",
+ "unix_socket", "conv",
+ "connect_timeout", "compress",
Deleted: trunk/dports/python/py25-mysql/files/patch-setup_posix.py
===================================================================
--- trunk/dports/python/py25-mysql/files/patch-setup_posix.py 2008-02-15 23:38:17 UTC (rev 34151)
+++ trunk/dports/python/py25-mysql/files/patch-setup_posix.py 2008-02-15 23:53:07 UTC (rev 34152)
@@ -1,11 +0,0 @@
---- setup_posix.py.orig 2007-05-06 12:30:17.000000000 -0700
-+++ setup_posix.py 2007-05-06 12:31:30.000000000 -0700
-@@ -23,7 +23,7 @@
- if ret/256 > 1:
- raise EnvironmentError, "%s not found" % mysql_config.path
- return data
--mysql_config.path = "mysql_config"
-+mysql_config.path = "mysql_config5"
-
- def get_config():
- import os, sys
Copied: trunk/dports/python/py25-mysql/files/patch-setup_posix.py.diff (from rev 34135, trunk/dports/python/py25-mysql/files/patch-setup_posix.py)
===================================================================
--- trunk/dports/python/py25-mysql/files/patch-setup_posix.py.diff (rev 0)
+++ trunk/dports/python/py25-mysql/files/patch-setup_posix.py.diff 2008-02-15 23:53:07 UTC (rev 34152)
@@ -0,0 +1,11 @@
+--- setup_posix.py.orig 2007-05-06 12:30:17.000000000 -0700
++++ setup_posix.py 2007-05-06 12:31:30.000000000 -0700
+@@ -23,7 +23,7 @@
+ if ret/256 > 1:
+ raise EnvironmentError, "%s not found" % mysql_config.path
+ return data
+-mysql_config.path = "mysql_config"
++mysql_config.path = "mysql_config5"
+
+ def get_config():
+ import os, sys
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.macosforge.org/pipermail/macports-changes/attachments/20080215/4b938504/attachment.html
More information about the macports-changes
mailing list