Fwd: Re: [PHP-DEV] -lresolv problems on OpenBSD
| From: | Melvyn Sopacua | Date: | Sun, 24 Mar 2002 22:58:35 +0000 |
| Subject: | Fwd: Re: [PHP-DEV] -lresolv problems on OpenBSD | ||
| Groups: | php.qa | ||
| Request: | Send a blank email to php-qa+get-4704@lists.php.net to get a copy of this message | ||
Something worth noticing - I'll translate:
Date: Sun, 24 Mar 2002 22:17:59 +0100 To: Melvyn Sopacua <msopacua@idg.nl> Subject: Re: [PHP-DEV] -lresolv problems on OpenBSD User-Agent: Mutt/1.3.22i From: Peter Blokland <peter@desk.nl> opvallend detail : de oude libphp4.so (4.0.6, zelfde config behalve xlst en sablot) was 1.4Mb. de nieuwe 4.2.0rc1 zonder patch was 7.0Mb, de nieuwe 4.2.0rc1 _met_ jouw patch is 5.8Mb.Remarkable detail: the old libphp4.so (4.0.6 same config, except for xslt and sablot) was 1.4Mb, the new 4.2.0rc without patch was 7.0Mb, the new 4.2.0rc1 _with_ your patch is 5.8Mb. The 'patch' refered to, involves: -- moving libresolv.a to libresolv.a.disabled -- applying a patch on configure.in that looks for res_search and inet_aton in libc. From a 'qa' point of view - I'm now thinking, that looking for those functions in libc __first__ is the way to go, since it saves a lot on the php shared lib size. The patch first looks into -lresolv, when looking for inet_aton, then checks libc for res_search (then socket/resolv), which would cause libresolv to be included (hence the libresolv.disabled). Platforms I know of, that have these functions in libc are BSDi 4.x and OpenBSD 3.0. What do you all think about it? As a side note, without the patch - as mentioned before - getmxrr breaks on BSDi. $ type php php is hashed (/home/mdev/local/bin/php) mdev@server6 ~/ftp/php-4.2.0RC1 $ php -f ./testgetmxrr.php Warning: getmxrr() is not supported in this PHP build in ./testgetmxrr.php on line 3 array(0) { } mdev@server6 ~/ftp/php-4.2.0RC1 $ ./sapi/cli/php -f ./testgetmxrr.php array(1) { [0]=> string(10) "tmp.idg.nl" } mdev@server6 ~/ftp/php-4.2.0RC1 $ cat testgetmxrr.php <?php $mx=array(); $ok=getmxrr('idg.nl', $mx); var_dump($mx); ?> Met vriendelijke groeten / With kind regards, IDG.nl Melvyn Sopacua Webmaster