#19212 [Csd]: Socket extension won't compile
| From: | patrickb at buzzimage dot com | Date: | Wed, 04 Sep 2002 15:06:31 +0000 |
| Subject: | #19212 [Csd]: Socket extension won't compile | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-18423@lists.php.net to get a copy of this message | ||
ID: 19212
User updated by: patrickb@buzzimage.com
Reported By: patrickb@buzzimage.com
Status: Closed
Bug Type: Sockets related
Operating System: Irix 6.5.12f
PHP Version: 4.2.2
New Comment:
msopacua@idg.nl:
Here is the struct from the sys/sockets.h file on my system:
#if _SGIAPI
struct msghdr {
caddr_t msg_name; /* optional address */
int msg_namelen; /* size of address */
struct iovec *msg_iov; /* scatter/gather array */
int msg_iovlen; /* # elements in msg_iov */
caddr_t msg_accrights; /* access rights sent/received
*/
int msg_accrightslen;
};
#else
struct msghdr {
void *msg_name; /* optional address */
size_t msg_namelen; /* size of address */
struct iovec *msg_iov; /* scatter/gather array */
int msg_iovlen; /* # elements in msg_iov */
void *msg_control; /* ancillary data */
size_t msg_controllen; /* ancillary data buffer len
*/
int msg_flags; /* flags on rec'd message */
};
#endif /* _SGIAPI */
sniper@php.net:
I'll try the latest stable snapshot in a few hours.
Previous Comments:
------------------------------------------------------------------------
[2002-09-04 09:30:43] sniper@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.
------------------------------------------------------------------------
[2002-09-04 09:00:49] msopacua@idg.nl
Have hunch this is a bug in ext/sockets/config.m4.
After configuring, could you edit:
main/php_config.h
and change:
#undef MISSING_MSGHDR_MSGFLAGS
to:
#define MISSING_MSGHDR_MSGFLAGS 1
------------------------------------------------------------------------
[2002-09-04 08:44:43] msopacua@idg.nl
Hi,
I found a manpage on IRIX 5.3, that had the struct msghdr as follows:
struct msghdr {
caddr_t msg_name; /* optional address */
int msg_namelen; /* size of address */
struct iovec *msg_iov; /* scatter/gather array
*/
int msg_iovlen; /* # elements in msg_iov */
caddr_t msg_accrights; /* access rights sent/received
*/
int msg_accrightslen;
};
Could you check sys/sockets.h on your os, and find that struct
definition?
(it indeed doesn't contain msgflags).
------------------------------------------------------------------------
[2002-09-04 08:11:31] patrickb@buzzimage.com
My mistake, it is the sockets.c file that choked.
------------------------------------------------------------------------
[2002-09-04 08:10:09] patrickb@buzzimage.com
It actually died quicker this time. During the compilation of a Zend
module I think. Didn't even get to the sockets extension. It does die
with the same type of 'msg_flags' error though.
/bin/sh libtool --silent --mode=compile /usr/freeware/bin/gcc
-Iext/sockets/ -I/usr/src/php4-200209040300/ext/sockets/ -DPHP_ATOM_INC
-I/usr/src/php4-200209040300/include -I/usr/src/php4-200209040300/main
-I/usr/src/php4-200209040300 -I/usr/src/php4-200209040300/Zend
-I/usr/local/mysql/include -I/usr/src/php4-200209040300/ext/xml/expat
-D_XPG_IV -DIRIX -DUSE_HSREGEX -DUSE_EXPAT
-I/usr/src/php4-200209040300/TSRM -g -O2 -prefer-pic -c
/usr/src/php4-200209040300/ext/sockets/sockets.c -o
ext/sockets/sockets.lo
/usr/src/php4-200209040300/ext/sockets/sockets.c:34:1: warning:
"__EXTENSIONS__" redefined
<command line>:1:1: warning: this is the location of the previous
definition
/usr/src/php4-200209040300/ext/sockets/sockets.c: In function
`zif_socket_recvmsg':
/usr/src/php4-200209040300/ext/sockets/sockets.c:1539: structure has no
member named `msg_flags'
/usr/src/php4-200209040300/ext/sockets/sockets.c:1556: structure has no
member named `msg_flags'
/usr/src/php4-200209040300/ext/sockets/sockets.c:1598: structure has no
member named `msg_flags'
/usr/src/php4-200209040300/ext/sockets/sockets.c:1617: structure has no
member named `msg_flags'
gmake: *** [ext/sockets/sockets.lo] Error 1
------------------------------------------------------------------------
The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
http://bugs.php.net/19212
--
Edit this bug report at http://bugs.php.net/?id=19212&edit=1