#18794 [NEW]: inappropriate if logic in configure --with-nsapi
| From: | vlb at gene dot com | Date: | Wed, 07 Aug 2002 21:00:03 +0000 |
| Subject: | #18794 [NEW]: inappropriate if logic in configure --with-nsapi | ||
| Groups: | php.bugs | ||
| Request: | Send a blank email to php-bugs+get-16215@lists.php.net to get a copy of this message | ||
From: vlb@gene.com
Operating system: Tru64 Unix (but n/a)
PHP version: 4.2.2
PHP Bug Type: *Configuration Issues
Bug description: inappropriate if logic in configure --with-nsapi
Configure options
configure --with-nsapi=/usr/prop/netscape/server4/
configure succeeds; make exits with
cc: Severe: nsapi.c, line 50: Cannot find file "nsapi.h" specified in
#include directive. (noinclfilef)
#include "nsapi.h"
-^
Reason:
Configure script contains this if block:
if test -d $PHP_NSAPI/include ; then
NSAPI_INCLUDE=$PHP_NSAPI/include
echo "$ac_t""Netscape-Enterprise/3.x style" 1>&6
elif test -d $PHP_NSAPI/plugins/include ; then
NSAPI_INCLUDE=$PHP_NSAPI/plugins/include
echo "$ac_t""iPlanet/4.x style" 1>&6
else
{ echo "configure: error: Please check you have nsapi.h in either
DIR/include
DIR/plugins/include" 1>&2; exit 1; }
fi
There are two things wrong here:
1) it is inappropriate to check for $PHP_NSAPI/include; the appropriate
test should be for the _file_ $PHP_NSAPI/include/nsapi.h
In our case, both $PHP_NSAPI/include and $PHP_NSAPI/plugins/include exist
(this has also been the case for at least one of the other bugs filed; see
#5233).
Configure should not assume a file exists simply because a directory it
might be in happens to exist.
2) In the error message, `DIR' is meaningless. The error should use
$PHP_NSAPI, not the literal string `DIR'.
See also bug 11446 and several others, closed as "bogus" or "not a bug in
PHP". While that is technically true, the bug is nonetheless in the PHP
configuration script, and it should be addressed by the php team.
--
Edit bug report at http://bugs.php.net/?id=18794&edit=1
--
Fixed in CVS: http://bugs.php.net/fix.php?id=18794&r=fixedcvs
Fixed in release: http://bugs.php.net/fix.php?id=18794&r=alreadyfixed
Need backtrace: http://bugs.php.net/fix.php?id=18794&r=needtrace
Try newer version: http://bugs.php.net/fix.php?id=18794&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=18794&r=support
Expected behavior: http://bugs.php.net/fix.php?id=18794&r=notwrong
Not enough info: http://bugs.php.net/fix.php?id=18794&r=notenoughinfo
Submitted twice: http://bugs.php.net/fix.php?id=18794&r=submittedtwice
register_globals: http://bugs.php.net/fix.php?id=18794&r=globals