$OpenBSD: patch-php_ffmpeg_h,v 1.2 2009/08/17 00:24:38 jolan Exp $ --- php_ffmpeg.h.orig Tue Oct 14 10:45:41 2008 +++ php_ffmpeg.h Sun Aug 16 18:27:37 2009 @@ -43,15 +43,23 @@ * PHP-4 doesn't have the METHOD, ME and MALIAS macros so map them back * to the function macros for PHP-4 */ -#if PHP_MAJOR_VERSION <= 4 + +#if PHP_MAJOR_VERSION <= 4 // PHP4; use FUNCTION macros +#define FFMPEG_PHP_CONSTRUCTOR(a,b) PHP_FUNCTION(a) #define FFMPEG_PHP_METHOD(a,b) PHP_FUNCTION(b) #define FFMPEG_PHP_ME(a,b,c,d) PHP_FE(a,c) -#define FFMPEG_PHP_MALIAS(a,b,c,d,e) PHP_FALIAS(b,c) -#else /* Use METHOD macros for PHP-5 */ +#define FFMPEG_PHP_MALIAS(a,b,c,d,e) PHP_FALIAS(b,c,d) +#define FFMPEG_PHP_END_METHODS {NULL, NULL, NULL} +#else /* PHP5; Use METHOD macros */ +#define FFMPEG_PHP_CONSTRUCTOR(a,b) PHP_METHOD(a,b) #define FFMPEG_PHP_METHOD(a,b) PHP_METHOD(a,b) #define FFMPEG_PHP_ME(a,b,c,d) PHP_ME(a,b,c,d) #define FFMPEG_PHP_MALIAS(a,b,c,d,e) PHP_MALIAS(a,b,c,d,e) +#define FFMPEG_PHP_END_METHODS {NULL, NULL, NULL, 0, 0} #endif + + + #define SAFE_STRING(s) ((s)?(s):"")