diff options
author | fhajny <fhajny@pkgsrc.org> | 2014-06-13 14:17:07 +0000 |
---|---|---|
committer | fhajny <fhajny@pkgsrc.org> | 2014-06-13 14:17:07 +0000 |
commit | 3db811d500df155bdd5d463c0f092ff3a144d179 (patch) | |
tree | a1e38a9634294b1d4b1371258a4aa47086c34869 /databases | |
parent | 53daa7f47ed8b1a0ebaaf47e967615d0b342985e (diff) | |
download | pkgsrc-3db811d500df155bdd5d463c0f092ff3a144d179.tar.gz |
Add optional support for mysqlnd (MySQL Native Driver). Removes the need to build against and link the mysql-client package.
Diffstat (limited to 'databases')
-rw-r--r-- | databases/php-mysql/Makefile | 18 | ||||
-rw-r--r-- | databases/php-mysqli/Makefile | 16 | ||||
-rw-r--r-- | databases/php-pdo_mysql/Makefile | 15 |
3 files changed, 39 insertions, 10 deletions
diff --git a/databases/php-mysql/Makefile b/databases/php-mysql/Makefile index 1566fec9dfb..dfd293f053f 100644 --- a/databases/php-mysql/Makefile +++ b/databases/php-mysql/Makefile @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.19 2013/03/16 02:00:33 taca Exp $ +# $NetBSD: Makefile,v 1.20 2014/06/13 14:17:07 fhajny Exp $ MODNAME= mysql CATEGORIES+= databases @@ -10,11 +10,21 @@ CONFLICTS= php-mysql-[0-9]* USE_PHP_EXT_PATCHES= yes +PKG_OPTIONS_VAR= PKG_OPTIONS.php-mysql +PKG_SUPPORTED_OPTIONS= mysqlnd +PKG_SUGGESTED_OPTIONS= # empty + +.include "../../mk/bsd.options.mk" + +.if !empty(PKG_OPTIONS:Mmysqlnd) +CONFIGURE_ARGS+= --with-${MODNAME}=shared,mysqlnd +.else EVAL_PREFIX+= MYSQLDIR=mysql-client -CONFIGURE_ARGS+= --with-${MODNAME}=shared,${MYSQLDIR} -CONFIGURE_ENV+= CPP=${CPP:Q} +CONFIGURE_ARGS+= --with-${MODNAME}=shared,${BUILDLINK_PREFIX.mysql-client} LDFLAGS+= ${COMPILER_RPATH_FLAG}${LOCALBASE}/lib/mysql +. include "../../mk/mysql.buildlink3.mk" +.endif +CONFIGURE_ENV+= CPP=${CPP:Q} .include "../../lang/php/ext.mk" -.include "../../mk/mysql.buildlink3.mk" .include "../../mk/bsd.pkg.mk" diff --git a/databases/php-mysqli/Makefile b/databases/php-mysqli/Makefile index bea181aa5ce..bbd2339e12e 100644 --- a/databases/php-mysqli/Makefile +++ b/databases/php-mysqli/Makefile @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.9 2013/03/16 02:00:33 taca Exp $ +# $NetBSD: Makefile,v 1.10 2014/06/13 14:17:07 fhajny Exp $ MODNAME= mysqli CATEGORIES+= databases @@ -8,9 +8,19 @@ MAINTAINER= pkgsrc-users@NetBSD.org CONFLICTS= php-mysqli-[0-9]* +PKG_OPTIONS_VAR= PKG_OPTIONS.php-mysqli +PKG_SUPPORTED_OPTIONS= mysqlnd +PKG_SUGGESTED_OPTIONS= # empty + +.include "../../mk/bsd.options.mk" + +.if !empty(PKG_OPTIONS:Mmysqlnd) +CONFIGURE_ARGS+= --with-${MODNAME}=shared,mysqlnd +.else EVAL_PREFIX+= MYSQLDIR=mysql-client -CONFIGURE_ARGS+= --with-${MODNAME}=${PREFIX}/bin/mysql_config +CONFIGURE_ARGS+= --with-${MODNAME}=shared,${BUILDLINK_PREFIX.mysql-client} +. include "../../mk/mysql.buildlink3.mk" +.endif .include "../../lang/php/ext.mk" -.include "../../mk/mysql.buildlink3.mk" .include "../../mk/bsd.pkg.mk" diff --git a/databases/php-pdo_mysql/Makefile b/databases/php-pdo_mysql/Makefile index b973598e2ed..70c8f923592 100644 --- a/databases/php-pdo_mysql/Makefile +++ b/databases/php-pdo_mysql/Makefile @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.18 2013/04/08 11:17:10 rodent Exp $ +# $NetBSD: Makefile,v 1.19 2014/06/13 14:17:07 fhajny Exp $ MODNAME= pdo_mysql CATEGORIES+= databases @@ -10,9 +10,18 @@ USE_PHP_EXT_PATCHES= yes .include "../../lang/php/ext.mk" -CONFIGURE_ARGS+= --with-${MODNAME} -CONFIGURE_ARGS+= --with-${PKGMODNAME}=shared,${BUILDLINK_PREFIX.mysql-client} +PKG_OPTIONS_VAR= PKG_OPTIONS.php-pdo_mysql +PKG_SUPPORTED_OPTIONS= mysqlnd +PKG_SUGGESTED_OPTIONS= # empty +.include "../../mk/bsd.options.mk" + +.if !empty(PKG_OPTIONS:Mmysqlnd) +CONFIGURE_ARGS+= --with-${MODNAME}=shared,mysqlnd +.else +CONFIGURE_ARGS+= --with-${MODNAME}=shared,${BUILDLINK_PREFIX.mysql-client} .include "../../mk/mysql.buildlink3.mk" +.endif + .include "../../databases/php-pdo/buildlink3.mk" .include "../../mk/bsd.pkg.mk" |