cvs: php4 /ext/ming config.m4 ming.c
| From: | Jani Taskinen | Date: | Wed, 12 Dec 2001 15:04:23 +0000 |
| Subject: | cvs: php4 /ext/ming config.m4 ming.c | ||
| Groups: | php.cvs | ||
| Request: | Send a blank email to php-cvs+get-8585@lists.php.net to get a copy of this message | ||
sniper Wed Dec 12 10:04:23 2001 EDT
Modified files:
/php4/ext/ming config.m4 ming.c
Log:
Fixed some compile problems (in ZTS mode)
Index: php4/ext/ming/config.m4
diff -u php4/ext/ming/config.m4:1.9 php4/ext/ming/config.m4:1.10
--- php4/ext/ming/config.m4:1.9 Fri Nov 30 13:59:44 2001
+++ php4/ext/ming/config.m4 Wed Dec 12 10:04:22 2001
@@ -1,5 +1,5 @@
dnl
-dnl $Id: config.m4,v 1.9 2001/11/30 18:59:44 sniper Exp $
+dnl $Id: config.m4,v 1.10 2001/12/12 15:04:22 sniper Exp $
dnl
PHP_ARG_WITH(ming, for MING support,
@@ -16,19 +16,17 @@
AC_MSG_ERROR(Please reinstall libming.so - I cannot find libming.so)
fi
- PHP_ADD_INCLUDE($MING_DIR/include)
-
- PHP_SUBST(MING_SHARED_LIBADD)
- PHP_ADD_LIBRARY_WITH_PATH(ming, $MING_DIR/lib, MING_SHARED_LIBADD)
-
- old_LIBS=$LIBS
- LIBS="$LIBS -L$MING_DIR/lib -lm -ldl"
- AC_CHECK_LIB(ming, Ming_useSWFVersion, [
+ PHP_CHECK_LIBRARY(ming, Ming_useSWFVersion, [
AC_DEFINE(HAVE_MING,1,[ ])
],[
AC_MSG_ERROR(Ming library 0.2a or greater required.)
+ ],[
+ -L$MING_DIR/lib -lm -ldl"
])
- LIBS=$old_LIBS
+
+ PHP_ADD_INCLUDE($MING_DIR/include)
+ PHP_ADD_LIBRARY_WITH_PATH(ming, $MING_DIR/lib, MING_SHARED_LIBADD)
PHP_EXTENSION(ming, $ext_shared)
+ PHP_SUBST(MING_SHARED_LIBADD)
fi
Index: php4/ext/ming/ming.c
diff -u php4/ext/ming/ming.c:1.23 php4/ext/ming/ming.c:1.24
--- php4/ext/ming/ming.c:1.23 Tue Dec 11 10:29:52 2001
+++ php4/ext/ming/ming.c Wed Dec 12 10:04:22 2001
@@ -221,14 +221,13 @@
return newSWFInput_allocedBuffer(buffer, offset);
}
-static SWFInput getInput(zval **zfile)
+static SWFInput getInput(zval **zfile TSRMLS_DC)
{
FILE *file;
int type;
SWFInput input;
- file = (FILE *)zend_fetch_resource(zfile, -1, "File-Handle", &type, 3,
- le_fopen, le_socket, le_popen);
+ file = (FILE *) zend_fetch_resource(zfile TSRMLS_CC, -1, "File-Handle", &type, 3,
php_file_le_fopen(), php_file_le_popen(), php_file_le_socket());
if(type == le_socket)
input = newSWFInput_sock(*(int *)file);
@@ -335,7 +334,7 @@
zend_list_addref(zend_list_insert(input, le_swfinputp));
}
else
- input = getInput(zfile);
+ input = getInput(zfile TSRMLS_CC);
if(zmask != NULL)
{
@@ -346,7 +345,7 @@
zend_list_addref(zend_list_insert(maskinput, le_swfinputp));
}
else
- maskinput = getInput(zmask);
+ maskinput = getInput(zmask TSRMLS_CC);
bitmap = newSWFJpegWithAlpha_fromInput(input, maskinput);
}
@@ -977,7 +976,7 @@
{
zval **zaction, **flags;
SWFAction action;
- SWFDisplayItem item = getDisplayItem(getThis());
+ SWFDisplayItem item = getDisplayItem(getThis() TSRMLS_CC);
if(ZEND_NUM_ARGS() != 2 ||
zend_get_parameters_ex(2, &zaction, &flags) == FAILURE)
@@ -986,7 +985,7 @@
convert_to_object_ex(zaction);
convert_to_long_ex(flags);
- action = (SWFBlock)getAction(*zaction);
+ action = (SWFBlock)getAction(*zaction TSRMLS_CC);
SWFDisplayItem_addAction(item, action, Z_LVAL_PP(flags));
}
@@ -1715,7 +1714,7 @@
zend_list_addref(zend_list_insert(input, le_swfinputp));
}
else
- input = getInput(zfile);
+ input = getInput(zfile TSRMLS_CC);
sound = newSWFSound_fromInput(input);
SWFMovie_setSoundStream(movie, sound);