Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 24 May 2012 21:41:43 +0800 (CST)
From:      Joe Horn <joehorn@gmail.com>
To:        FreeBSD-gnats-submit@FreeBSD.org
Subject:   ports/168302: [MAINTAINER] databases/php-adodb-ext: Fix for building failed with PHP 5.4
Message-ID:  <20120524134143.250754DFC2B@Leo.mi.chu.edu.tw>
Resent-Message-ID: <201205241350.q4ODo2CC083390@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help

>Number:         168302
>Category:       ports
>Synopsis:       [MAINTAINER] databases/php-adodb-ext: Fix for building failed with PHP 5.4
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          maintainer-update
>Submitter-Id:   current-users
>Arrival-Date:   Thu May 24 13:50:02 UTC 2012
>Closed-Date:
>Last-Modified:
>Originator:     Joe Horn
>Release:        FreeBSD 9.0-RELEASE amd64
>Organization:
Taiwanese User
>Environment:
System: FreeBSD joehorn.idv.tw 9.0-RELEASE FreeBSD 9.0-RELEASE #3: Mon Jan  9 22:14:09 CST
>Description:
- Change DEFAULT_PHP_VER to 53
- Fix for building failed with PHP 5.4
- Bupm PORTREVISION

Added file(s):
- files/extra-patch-php54-adodb.c

Generated with FreeBSD Port Tools 0.99_6 (mode: change, diff: ports)
>How-To-Repeat:
>Fix:

--- php-adodb-ext-5.04_2.patch begins here ---
diff -ruN --exclude=CVS /usr/ports/databases/php-adodb-ext/Makefile ./Makefile
--- /usr/ports/databases/php-adodb-ext/Makefile	2012-05-20 14:42:50.000000000 +0800
+++ ./Makefile	2012-05-24 12:00:38.000000000 +0800
@@ -2,12 +2,12 @@
 # Date created:		29 July 2008
 # Whom:			JoeHorn <joehorn@gmail.com>
 #
-# $FreeBSD: ports/databases/php-adodb-ext/Makefile,v 1.4 2012/05/20 06:42:50 ale Exp $
+# $FreeBSD: ports/databases/php-adodb-ext/Makefile,v 1.3 2011/08/08 11:04:45 gabor Exp $
 #
 
 PORTNAME=	adodb-ext
 PORTVERSION=	5.04
-PORTREVISION=	1
+PORTREVISION=	2
 CATEGORIES=	databases
 MASTER_SITES=	http://phplens.com/lens/dl/
 PKGNAMEPREFIX=	php-
@@ -20,10 +20,10 @@
 
 USE_PHP=	yes
 USE_PHPIZE=	yes
-DEFAULT_PHP_VER=53
-IGNORE_WITH_PHP=5
 USE_ZIP=	yes
 
+DEFAULT_PHP_VER=53
+
 CONFIGURE_ARGS=		--with-php-config=${PREFIX}/bin/php-config \
 			--prefix=${PREFIX}/lib/php/${PHP_EXT_DIR}
 SUB_FILES=	pkg-message
@@ -32,7 +32,9 @@
 
 .include <bsd.port.pre.mk>
 
-.if ${PHP_VER} != "52"
+.if ${PHP_VER} == "5"
+EXTRA_PATCHES=	${PATCHDIR}/extra-patch-php54-adodb.c
+.elif ${PHP_VER} != "52"
 EXTRA_PATCHES=	${PATCHDIR}/extra-patch-adodb.c
 .endif
 
diff -ruN --exclude=CVS /usr/ports/databases/php-adodb-ext/files/extra-patch-php54-adodb.c ./files/extra-patch-php54-adodb.c
--- /usr/ports/databases/php-adodb-ext/files/extra-patch-php54-adodb.c	1970-01-01 08:00:00.000000000 +0800
+++ ./files/extra-patch-php54-adodb.c	2012-05-20 23:24:38.000000000 +0800
@@ -0,0 +1,37 @@
+--- adodb.c.orig	2012-05-20 14:42:41.000000000 +0000
++++ adodb.c	2012-05-20 14:41:28.000000000 +0000
+@@ -108,7 +108,7 @@
+ }; 
+ #else
+ /* PHP 5 */
+-function_entry adodb_functions[] = {
++zend_function_entry adodb_functions[] = {
+    	PHP_FE(adodb_movenext,NULL) 
+ 	PHP_FE(adodb_getall,NULL)   
+ 	{NULL, NULL, NULL} 
+@@ -159,11 +159,11 @@
+ 
+ static void adodb_init_zval(zval *v, char *s)
+ {
+-	v->type = IS_STRING;
+-	v->value.str.val = s;
+-	v->value.str.len = strlen(s);
+-	v->is_ref = 0;
+-	v->refcount = 1;
++	Z_TYPE_P(v) = IS_STRING;
++	Z_STRVAL_P(v) = s;
++	Z_STRLEN_P(v) = strlen(s);
++	Z_UNSET_ISREF_P(v);
++	Z_SET_REFCOUNT_P(v, 1);
+ }
+ 
+ /* {{{ PHP_MINIT_FUNCTION
+@@ -277,7 +277,7 @@
+ 	fci.function_table = EG(function_table);
+ 	fci.function_name = &adodb_zvals[zval_ocifetch];
+ 	fci.symbol_table = NULL;
+-	fci.object_pp = NULL;
++	fci.object_ptr = NULL;
+ 	fci.retval_ptr_ptr = &retval;
+ 	fci.param_count = 2;
+ 	fci.params = &params[1];
--- php-adodb-ext-5.04_2.patch ends here ---

>Release-Note:
>Audit-Trail:
>Unformatted:



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20120524134143.250754DFC2B>