compile error with RC2 and thttpd

From: Date: Sun, 14 May 2000 09:45:55 +0000
Subject: compile error with RC2 and thttpd
Groups: php.version4 
Request: Send a blank email to php-version4+get-14998@lists.php.net to get a copy of this message
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Just got this error, when compiling php4-rc2 for thttpd on FreeBSD 5.0-current: Making all in sapi Making all in thttpd gcc -DHAVE_CONFIG_H -I. -I/usr/src/php-4.0RC2/sapi/thttpd - -I/usr/src/php-4.0RC2 - -I/usr/ports/www/thttpd/work/thttpd-2.16 -I/usr/src/php-4.0RC2/Zend - -I/usr/src/p hp-4.0RC2 -I/usr/src/php-4.0RC2/ext/mysql/libmysql - -I/usr/src/php-4.0RC2/ext/xml /expat/xmltok -I/usr/src/php-4.0RC2/ext/xml/expat/xmlparse - -DXML_BYTE_ORDER=12 - -g -O2 -Wall -c thttpd.c && touch thttpd.lo thttpd.c: In function `thttpd_hash_environment': thttpd.c:175: incompatible type for argument 1 of `__inet_ntoa' *** Error code 1 Stop in /usr/src/php-4.0RC2/sapi/thttpd. *** Error code 1 Stop in /usr/src/php-4.0RC2/sapi/thttpd. *** Error code 1 Stop in /usr/src/php-4.0RC2/sapi. *** Error code 1 Stop in /usr/src/php-4.0RC2. and echo 'PHP_LIBS = -L. -lphp4 -lpam -lm -lcrypt' > /usr/ports/www/thttpd/work/thttpd-2.16/php_makefile; echo 'PHP_LDFLAGS = ' >> /usr/ports/www/thttpd/work/thttpd-2.16/php_makefile; cp /sapi/thttpd/php_thttpd.h libs/libphp4.a /usr/ports/www/thttpd/work/thttpd-2.16; test -f /usr/ports/www/thttpd/work/thttpd-2.16/php_patched || (cd /usr/ports/www/thttpd/work/thttpd-2.16 && patch < /sapi/thttpd/thttpd_patch && touch php_patched) cp: /sapi/thttpd/php_thttpd.h: No such file or directory *** Error code 1 (continuing) My configure-line (shouldn't be important, but...) ./configure --with-thttpd=/usr/ports/www/thttpd/work/thttpd-2.16 - --with-mysql --without-gd --with-ftp --enable-track-vars --enable-trans-sid The following patch fixed the first error for me. I hope, it's the right fix ;) - --- sapi/thttpd/thttpd.c.old Sun May 14 11:37:04 2000 +++ sapi/thttpd/thttpd.c Sun May 14 11:37:14 2000 @@ -174,7 +174,7 @@ snprintf(buf, BUF_SIZE, "/%s", TG(hc)->origfilename); ADD_STRING("SCRIPT_NAME"); - - strncpy(buf, inet_ntoa(TG(hc)->client_addr), BUF_SIZE); + strncpy(buf, inet_ntoa(TG(hc)->client_addr.sa_in.sin_addr), BUF_SIZE); ADD_STRING("REMOTE_ADDR"); ADD_STRING("REMOTE_HOST"); Now to the second error: $abs_srcdir doesn't seem to get set. Dunno how to fix that. Someone who's a *bit* more familiar with the "configure" stuff should check that :) - -- Reg., Jonas Jochum commandline net services - ------------------------------------------------------------------------- tel: 07223-911794 | cmd:~ # Systemadministration, Netzwerkverwaltung fax: 07223-911795 | cmd:~ # Einrichtung von *BSD/Linux-Servern d2 : 0173-5712481 | cmd:~ # Datenbank/Internetprogrammierung jj@commandline.de | cmd:~ # Webdesign www.commandline.de | -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.0.1 (FreeBSD) Comment: Made with pgp4pine iEYEARECAAYFAjkeddYACgkQF1ki3orczCCzNQCfZdoGIUrSs3c7BfwlYDz+xO7P u9gAnimehXFQHreVUOJlgGSeuYlXRrq3 =PjEj -----END PGP SIGNATURE-----

« previous php.version4 (#14998) next »