php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #26105 argument format specified for non-function
Submitted: 2003-11-03 21:39 UTC Modified: 2003-11-04 15:39 UTC
Votes:1
Avg. Score:5.0 ± 0.0
Reproduced:1 of 1 (100.0%)
Same Version:1 (100.0%)
Same OS:0 (0.0%)
From: simon dot boulet at divahost dot net Assigned:
Status: Closed Package: Compile Failure
PHP Version: 4.3.4 OS: Linux/gcc 3.0.4
Private report: No CVE-ID: None
View Add Comment Developer Edit
Anyone can comment on a bug. Have a simpler test case? Does it work for you on a different platform? Let us know!
Just going to say 'Me too!'? Don't clutter the database with that please !
Your email address:
MUST BE VALID
Solve the problem:
21 + 45 = ?
Subscribe to this entry?

 
 [2003-11-03 21:39 UTC] simon dot boulet at divahost dot net
Description:
------------
The new version on PHP fails to compile. I was previously using version 4.3.3 and it was compiling fine.

Configure flags:
--with-mysql --with-apxs --with-gd -with-zlib --with-jpeg-dir=/usr --with-apxs=/usr/local/apache/bin/apxs

`make` fails straight at the beginning with:

/bin/sh /root/php-4.3.4/libtool --silent --preserve-dup-deps --mode=compile gcc  -Iext/zlib/ -I/root/php-4.3.4/ext/zlib/ -DPHP_ATOM_INC -I/root/php-4.3.4/include -I/root/php-4.3.4/main -I/root/php-4.3.4 -I/root/php-4.3.4/Zend -I/root/php-4.3.4/ext/xml/expat  -I/root/php-4.3.4/TSRM  -g -O2  -prefer-pic -c /root/php-4.3.4/ext/zlib/zlib.c -o ext/zlib/zlib.lo 
In file included from /root/php-4.3.4/main/php.h:34,
                 from /root/php-4.3.4/ext/zlib/zlib.c:28:
/root/php-4.3.4/Zend/zend.h:311: argument format specified for non-function `error_function'
/root/php-4.3.4/Zend/zend.h:312: argument format specified for non-function `printf_function'
/root/php-4.3.4/Zend/zend.h:444: argument format specified for non-function `zend_printf'
/root/php-4.3.4/Zend/zend.h:451: argument format specified for non-function `zend_error_cb'
make: *** [ext/zlib/zlib.lo] Error 1

I am far from being a C expert, but I think it as something to do with GCC version checking in Zend/zend.h near line 155.

I was able to compile just fine with:

#define ZEND_ATTRIBUTE_PTR_FORMAT(type, idx, first)

instead of:

# define ZEND_ATTRIBUTE_PTR_FORMAT(type, idx, first) __attribute__ ((format(type, idx, first)))

that would be defined with ZEND_GCC_VERSION >= 3000.





Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2003-11-04 15:39 UTC] iliaa@php.net
This bug has been fixed in CVS.

In case this was a PHP problem, snapshots of the sources are packaged
every three hours; this change will be in the next snapshot. You can
grab the snapshot at http://snaps.php.net/.
 
In case this was a documentation problem, the fix will show up soon at
http://www.php.net/manual/.

In case this was a PHP.net website problem, the change will show
up on the PHP.net site and on the mirror sites in short time.
 
Thank you for the report, and for helping us make PHP better.


 [2003-11-19 23:54 UTC] patrickdotsaunders at visy dot com dot au
I have also experienced same issue on following platform:

* HP-UX  B.11.00 U 9000/800 
* gcc version 3.0.1

Making suggested modification to zend.h on line 155 as suggested allowed the "make" to work successfuly.

I have not tried building 4.3.3 on HPUX.

Patrick.
 [2004-02-22 22:38 UTC] david dot beecher at mho dot com
This problem also happens on Solaris 8 SPARC with gcc 3.0.3 and php 4.3.4.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Fri Apr 19 22:01:28 2024 UTC