PHP 4.0 Bug #8468 Updated: sockets.c compile failure

From: Date: Wed, 03 Jan 2001 18:09:07 +0000
Subject: PHP 4.0 Bug #8468 Updated: sockets.c compile failure
Groups: php.dev 
Request: Send a blank email to php-dev+get-42857@lists.php.net to get a copy of this message
ID: 8468 Updated by: jon Reported By: jon@csh.rit.edu Old-Status: Open Status: Closed Bug Type: Sockets related Assigned To: Comments: Fixed with this patch (committed to 4.0.5): --- sockets.c.orig Wed Jan 3 12:47:34 2001 +++ sockets.c Wed Jan 3 12:55:43 2001 @@ -26,9 +26,14 @@ /* This hopefully will fix some compile errors on other platforms -- * the usage of msg_control/msg_controllen are X/Open Extended attributes, - * or so it seems, by reading HP/UX 10.20 manual pages. */ + * or so it seems, by reading HP/UX 10.20 manual pages. + * + * The second two defines are for Solaris 8 with the Sun WorkShop compiler. + */ #define _XOPEN_SOURCE_EXTENDED +#define _XPG4_2 +#define __EXTENSIONS__ #include "ext/standard/info.h" #include "php_sockets.h" @@ -64,6 +69,12 @@ #else #define MSG_WAITALL 0x00000000 #endif +#endif + +/* Solaris 8 doesn't appear to define SUN_LEN in <sys/un.h> */ +#ifndef SUN_LEN +#define SUN_LEN(su) \ + (sizeof(*(su)) - sizeof((su)->sun_path) + strlen((su)->sun_path)) #endif /* Use the read() wrapper, stopping at '\n', '\r', or '\0'. */ Previous Comments: --------------------------------------------------------------------------- [2000-12-28 19:36:58] jon@csh.rit.edu Build environment: Solaris 8 WorkShop Compilers 5.0 98/12/15 C 5.0 PHP 4.0.4 configure invocation: ./configure --with-apxs=/web/servers/apache/sbin/apxs --with-config-file-path=/web/servers/apache/conf --with-db3=/usr/local --enable-ftp --with-imap=../imap-2000a --with-mysql --with-pgsql --enable-sockets --enable-sysvsem --enable-sysvshm --with-zlib --enable-xml --enable-yp Compiler errors: "sockets.c", line 1728: undefined struct/union member: msg_control "sockets.c", line 1728: warning: improper pointer/integer combination: op "=" "sockets.c", line 1729: undefined struct/union member: msg_controllen "sockets.c", line 1731: undefined struct/union member: msg_control "sockets.c", line 1732: undefined struct/union member: msg_controllen "sockets.c", line 1735: undefined struct/union member: msg_flags "sockets.c", line 1741: undefined struct/union member: msg_control "sockets.c", line 1750: warning: improper pointer/integer combination: arg #3 "sockets.c", line 1754: undefined struct/union member: msg_controllen "sockets.c", line 1755: improper member use: msg_flags "sockets.c", line 1787: undefined struct/union member: msg_control "sockets.c", line 1787: warning: improper pointer/integer combination: op "=" "sockets.c", line 1788: undefined struct/union member: msg_controllen "sockets.c", line 1790: undefined struct/union member: msg_control "sockets.c", line 1791: undefined struct/union member: msg_controllen "sockets.c", line 1794: undefined struct/union member: msg_flags "sockets.c", line 1800: undefined struct/union member: msg_control "sockets.c", line 1810: warning: improper pointer/integer combination: arg #3 "sockets.c", line 1812: undefined struct/union member: msg_controllen "sockets.c", line 1814: improper member use: msg_flags cc: acomp failed for sockets.c --------------------------------------------------------------------------- Full Bug description available at: http://bugs.php.net/?id=8468

« previous php.dev (#42857) next »