From 025f04bd066c62d70acffd91bf6abb86dff4d751 Mon Sep 17 00:00:00 2001 From: ale Date: Tue, 7 Nov 2006 15:58:20 +0000 Subject: Fix compilation with php 5.2.0. --- sysutils/pecl-fileinfo/Makefile | 1 + sysutils/pecl-fileinfo/files/patch-fileinfo.c | 24 ++++++++++++++++++++++++ 2 files changed, 25 insertions(+) create mode 100644 sysutils/pecl-fileinfo/files/patch-fileinfo.c (limited to 'sysutils') diff --git a/sysutils/pecl-fileinfo/Makefile b/sysutils/pecl-fileinfo/Makefile index bff8e8e..af9e935 100644 --- a/sysutils/pecl-fileinfo/Makefile +++ b/sysutils/pecl-fileinfo/Makefile @@ -7,6 +7,7 @@ PORTNAME= fileinfo PORTVERSION= 1.0.3 +PORTREVISION= 1 CATEGORIES= sysutils pear MASTER_SITES= http://pecl.php.net/get/ PKGNAMEPREFIX= pecl- diff --git a/sysutils/pecl-fileinfo/files/patch-fileinfo.c b/sysutils/pecl-fileinfo/files/patch-fileinfo.c new file mode 100644 index 0000000..e4cca19 --- /dev/null +++ b/sysutils/pecl-fileinfo/files/patch-fileinfo.c @@ -0,0 +1,24 @@ +--- fileinfo.c.orig 2005/12/20 19:17:00 ++++ fileinfo.c 2006/10/10 09:52:06 +@@ -121,10 +121,17 @@ + /* {{{ finfo_class_functions + */ + function_entry finfo_class_functions[] = { +- ZEND_ME_MAPPING(finfo, finfo_open, NULL) +- ZEND_ME_MAPPING(set_flags, finfo_set_flags,NULL) +- ZEND_ME_MAPPING(file, finfo_file, NULL) +- ZEND_ME_MAPPING(buffer, finfo_buffer, NULL) ++#if PHP_VERSION_ID >= 50200 ++ ZEND_ME_MAPPING(finfo, finfo_open, NULL, ZEND_ACC_PUBLIC) ++ ZEND_ME_MAPPING(set_flags, finfo_set_flags,NULL, ZEND_ACC_PUBLIC) ++ ZEND_ME_MAPPING(file, finfo_file, NULL, ZEND_ACC_PUBLIC) ++ ZEND_ME_MAPPING(buffer, finfo_buffer, NULL, ZEND_ACC_PUBLIC) ++#else ++ ZEND_ME_MAPPING(finfo, finfo_open, NULL) ++ ZEND_ME_MAPPING(set_flags, finfo_set_flags,NULL) ++ ZEND_ME_MAPPING(file, finfo_file, NULL) ++ ZEND_ME_MAPPING(buffer, finfo_buffer, NULL) ++#endif + {NULL, NULL, NULL} + }; + /* }}} */ -- cgit v1.1