Package: php-imlib
Version: 0.4-3
Severity: normal
Tags: patch

When building 'php-imlib' on amd64/unstable with gcc-4.0,
I get the following error:

make[1]: Entering directory `/php-imlib-0.4'
/bin/sh /php-imlib-0.4/libtool --mode=compile x86_64-linux-gcc  -I. 
-I/php-imlib-0.4 -DPHP_ATOM_INC -I/php-imlib-0.4/include -I/php-imlib-0.4/main 
-I/php-imlib-0.4 -I/usr/include/php4 -I/usr/include/php4/main 
-I/usr/include/php4/Zend -I/usr/include/php4/TSRM  -DHAVE_CONFIG_H  -g -O2   -c 
/php-imlib-0.4/imlib.c -o imlib.lo 
mkdir .libs
 x86_64-linux-gcc -I. -I/php-imlib-0.4 -DPHP_ATOM_INC -I/php-imlib-0.4/include 
-I/php-imlib-0.4/main -I/php-imlib-0.4 -I/usr/include/php4 
-I/usr/include/php4/main -I/usr/include/php4/Zend -I/usr/include/php4/TSRM 
-DHAVE_CONFIG_H -g -O2 -c /php-imlib-0.4/imlib.c  -fPIC -DPIC -o .libs/imlib.o
/php-imlib-0.4/imlib.c:45: error: static declaration of 'third_arg_force_ref' 
follows non-static declaration
/usr/include/php4/Zend/zend_modules.h:35: error: previous declaration of 
'third_arg_force_ref' was here
make[1]: *** [imlib.lo] Error 1
make[1]: Leaving directory `/php-imlib-0.4'
make: *** [build-stamp] Error 2

With the attached patch 'php-imlib' can be compiled
on amd64 using gcc-4.0.

Regards
Andreas Jochens

diff -urN ../tmp-orig/php-imlib-0.4/imlib.c ./imlib.c
--- ../tmp-orig/php-imlib-0.4/imlib.c   2005-03-26 11:05:36.759991141 +0100
+++ ./imlib.c   2005-03-26 11:05:12.806482300 +0100
@@ -42,7 +42,7 @@
 
 ZEND_DECLARE_MODULE_GLOBALS(imlib);
 
-static unsigned char third_arg_force_ref[] = { 3, BYREF_NONE, BYREF_NONE, 
BYREF_FORCE };
+static unsigned char third_arg_force_ref_imlib[] = { 3, BYREF_NONE, 
BYREF_NONE, BYREF_FORCE };
 static unsigned char third_and_fourth_arg_force_ref[] = { 4, BYREF_NONE, 
BYREF_NONE, BYREF_FORCE, BYREF_FORCE };
 static unsigned char second_through_fifth_arg_force_ref[] = { 5, BYREF_NONE, 
BYREF_FORCE, BYREF_FORCE, BYREF_FORCE, BYREF_FORCE };
 static int le_imlib_cr;
@@ -97,8 +97,8 @@
        PHP_FE(imlib_polygon_free,NULL)
        PHP_FE(imlib_polygon_get_bounds,second_through_fifth_arg_force_ref)
        PHP_FE(imlib_polygon_new,NULL)
-       PHP_FE(imlib_save_image,third_arg_force_ref)
-       
PHP_FALIAS(imlib_save_image_with_error_return,imlib_save_image,third_arg_force_ref)
+       PHP_FE(imlib_save_image,third_arg_force_ref_imlib)
+       
PHP_FALIAS(imlib_save_image_with_error_return,imlib_save_image,third_arg_force_ref_imlib)
        PHP_FE(imlib_text_draw,NULL)
        PHP_FE(imlib_get_cache_size,NULL)
        PHP_FE(imlib_set_cache_size,NULL)


-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to