Bug #17072 Updated: Compilation aborts while compiling ext/mysql/libmysql/libmysql.c
| From: | karl at katzke dot net | Date: | Sun, 12 May 2002 05:17:23 +0000 |
| Subject: | Bug #17072 Updated: Compilation aborts while compiling ext/mysql/libmysql/libmysql.c | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-7464@lists.php.net to get a copy of this message | ||
ID: 17072
Updated by: karl@katzke.net
Reported By: kolmann@zid.tuwien.ac.at
Status: Open
Bug Type: Compile Failure
Operating System: AIX
PHP Version: 4.2.0
New Comment:
Noted while compiling on a linux box (Slack 8, 2.4.5, gcc 2.95) that a
redefinition of ushort threw a warning. Not a fatal error, but may
provide a clue to this other problem.
php_mysql.c:55: warning: redefinition of `ushort'
/usr/include/sys/types.h:145: warning: `ushort' previously declared
here
Previous Comments:
------------------------------------------------------------------------
[2002-05-07 08:30:54] kolmann@zid.tuwien.ac.at
Hi,
we just wanted to compile the new PHP 4.2.0 on an AIX machine and it
crashes while trying to compile the built-in mysql lib:
make[4]: Entering directory
`/home/pkolmann/stuff/php-4.2.0/ext/mysql/libmysql'
gcc -I. -I/u/pkolmann/stuff/php-4.2.0/ext/mysql/libmysql
-I/u/pkolmann/stuff/php-4.2.0/main -I/u/pkolmann/stuff/php-4.2.0
-I/u/pkolmann/stuff/apache_1.3.24/src/include
-I/u/pkolmann/stuff/apache_1.3.24/src/os/unix
-I/u/pkolmann/stuff/php-4.2.0/Zend
-I/u/pkolmann/stuff/php-4.2.0/ext/mysql/libmysql
-I/u/pkolmann/stuff/php-4.2.0/ext/xml/expat
-I/u/pkolmann/stuff/php-4.2.0/TSRM -O2 -c libmysql.c && touch
libmysql.lo
In file included from libmysql.c:5:
global.h:256: warning: redefinition of `uint'
/usr/local/lib/gcc-lib/powerpc-ibm-aix4.3.2.0/2.95.3/include/sys/types.h:471:
warning: `uint' previously declared here
global.h:257: warning: redefinition of `ushort'
/usr/local/lib/gcc-lib/powerpc-ibm-aix4.3.2.0/2.95.3/include/sys/types.h:470:
warning: `ushort' previously declared here
global.h:258: warning: redefinition of `ulong'
/usr/local/lib/gcc-lib/powerpc-ibm-aix4.3.2.0/2.95.3/include/sys/types.h:472:
warning: `ulong' previously declared here
In file included from libmysql.c:5:
global.h:566: conflicting types for `int8'
/usr/include/sys/inttypes.h:622: previous declaration of `int8'
global.h:567: warning: redefinition of `int16'
/usr/include/sys/inttypes.h:623: warning: `int16' previously declared
here
global.h:570: warning: redefinition of `uchar'
/usr/local/lib/gcc-lib/powerpc-ibm-aix4.3.2.0/2.95.3/include/sys/types.h:469:
warning: `uchar' previously declared here
global.h:577: warning: redefinition of `int32'
/usr/include/sys/inttypes.h:624: warning: `int32' previously declared
here
global.h:590: warning: redefinition of `ulong'
global.h:258: warning: `ulong' previously declared here
libmysql.c: In function `connect2':
libmysql.c:192: warning: passing arg 5 of `getsockopt' from
incompatible pointer type
libmysql.c: In function `net_safe_read':
libmysql.c:290: warning: passing arg 2 of `signal' from incompatible
pointer type
libmysql.c: In function `net_field_length_ll':
libmysql.c:397: warning: left shift count >= width of type
libmysql.c: In function `simple_command':
libmysql.c:421: warning: passing arg 2 of `signal' from incompatible
pointer type
libmysql.c: In function `pipe_sig_handler':
libmysql.c:605: warning: passing arg 2 of `signal' from incompatible
pointer type
libmysql.c: In function `end_server':
libmysql.c:622: warning: passing arg 2 of `signal' from incompatible
pointer type
libmysql.c: In function `mysql_real_connect':
libmysql.c:1158: warning: passing arg 2 of `signal' from incompatible
pointer type
make[4]: *** [libmysql.lo] Error 1
make[4]: Leaving directory
`/home/pkolmann/stuff/php-4.2.0/ext/mysql/libmysql'
make[3]: *** [all-recursive] Error 1
make[3]: Leaving directory
`/home/pkolmann/stuff/php-4.2.0/ext/mysql/libmysql'
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory `/home/pkolmann/stuff/php-4.2.0/ext/mysql'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/home/pkolmann/stuff/php-4.2.0/ext'
make: *** [all-recursive] Error 1
The previous version (4.1.2) did compile without troubles. The Problem
seems to be inside the golbal.h file:
pkolmann@mail:~$ diff test/php-4.1.2/ext/mysql/libmysql/global.h
stuff/php-4.2.0/ext/mysql/libmysql/global.h
252a253,255
> #undef uint
> #undef ushort
> #undef ulong
254a258
> typedef unsigned long ulong;
Is there any possibility for a fix?
Thanks a lot
Philipp Kolmann
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=17072&edit=1