Don't treat spidermonkeydir="" and luadir="" as special.
commit5669a149706727d2d0617000cc494e20ee0f09e5
authorKalle Olavi Niemitalo <kon@iki.fi>
Tue, 10 Jul 2007 10:53:18 +0000 (10 13:53 +0300)
committerKalle Olavi Niemitalo <Kalle@Astalo.kon.iki.fi>
Tue, 10 Jul 2007 10:53:18 +0000 (10 13:53 +0300)
treee2461e85d2febcbde99a6e305c92960c220be7f3
parent899df61a9cfa94411e825ce933fba3a01d12c0cd
Don't treat spidermonkeydir="" and luadir="" as special.

Previously, an empty string as spidermonkeydir or luadir meant
that the LIBS and CFLAGS variables should be used unchanged.  A few
commits ago however, the configure script was changed to require
test -f "$spidermonkeydir$spidermonkeyinclude/jsapi.h" and
test -f "$luadir/include/lua$suffix/lua.h" to succeed.  These
commands interpret spidermonkeydir="" and luadir="" as the root
directory.  This behaviour was inconsistent with the part that
decides whether to add the directory to *_LIBS and *_CFLAGS or not.

The inconsistency could be solved in two ways.  Either (a) add an
exception so that the test -f is skipped if the variable is empty,
or (b) treat an empty string as the root directory throughout.

Because the Makefile of SpiderMonkey always installs to a subdirectory
of the specified include directory, and ELinks uses #include <jsapi.h>
without specifying that subdirectory in source code, it seems unlikely
that the SpiderMonkey header files would ever be in the default
include path.  I am therefore implementing solution (b) here.

I suppose similar considerations apply to Lua but did not check that
carefully.
configure.in