On Mon, Jan 21, 2002 at 04:10:49PM -0500, Victor J. Orlikowski wrote:
> Problem found, but not resolved.
> 
> Turns out that find-dbm-lib in helpers looks for ndbm.h in
> /usr/include/db1 on RH 7.  This is provided in the db1-devel package.
> However, gdbm-devel also provides a ndbm.h, in /usr/include/gdbm.
> 
> The problem at hand: 
> We are going to have users who want to use mod_auth_dbm, and wonder
> why ndbm.h can't be found on their system when it's there, plain as
> day.
> 
> 2 solutions:
> 1) Doc it up. Does the job, but not what I want.
> 2) Fix find-dbm-lib properly, so that it does "The Right Thing" and
> uses whatever dbm it finds.
> 
> I prefer 2, but is it the right thing for 1.3.23 (I would hope that
> thsi would not scrap it)?
> 
> Issues: 
> Are there any GNU licensing issues with linking against gdbm? If so,
> solution 1 will do for now, since we will have to force the user to
> install db1-devel. However, find-dbm-lib has always felt like
> something of a hack to me. 

Moving around on the way that find-dbm-lib looks for the libs works for
me on my Debian box. Is this going to break something else?

-- 
  Thomas Eibner <http://thomas.eibner.dk/> DnsZone <http://dnszone.org/>
  mod_pointer <http://stderr.net/mod_pointer> 

Index: find-dbm-lib
===================================================================
RCS file: /home/cvspublic/apache-1.3/src/helpers/find-dbm-lib,v
retrieving revision 1.12
diff -u -r1.12 find-dbm-lib
--- find-dbm-lib        17 Jan 2002 13:20:51 -0000      1.12
+++ find-dbm-lib        21 Jan 2002 21:44:42 -0000
@@ -13,9 +13,7 @@
            *-linux*)
                # many systems don't have -ldbm
                DBM_LIB=""
-               if ./helpers/TestCompile lib dbm dbm_open; then
-                   DBM_LIB="-ldbm"
-               elif ./helpers/TestCompile lib ndbm dbm_open; then
+               if ./helpers/TestCompile lib ndbm dbm_open; then
                    DBM_LIB="-lndbm"
                    if ./helpers/TestCompile lib db1 dbm_open; then
                        # Red Hat needs this; ndbm.h lives in db1
@@ -25,6 +23,8 @@
                    # For Red Hat 7, if not handled by the ndbm case above
                    DBM_LIB="-ldb1"
                    CFLAGS="$CFLAGS -I/usr/include/db1"
+               elif ./helpers/TestCompile lib dbm dbm_open; then
+                   DBM_LIB="-ldbm"
                fi
                if [ "x$DBM_LIB" != "x" ]; then
                    LIBS="$LIBS $DBM_LIB"

Reply via email to