Re[2]: [Exim] compile fails at dbmbuild...

Top Pagina
Delete this message
Reply to this message
Auteur: Philip Hazel
Datum:  
Aan: Bradley D. Thornton
CC: Philip Hazel
Onderwerp: Re[2]: [Exim] compile fails at dbmbuild...
On Thu, 20 Jun 2002, Bradley D. Thornton wrote:

> Here's the combinations I've tried so far to no avail...


> LOOKUP_DBM=yes
> LOOKUP_LSEARCH=yes
> USE_DB=yes
> DBMLIB=-ldb


That's the one I would have expected to be most likely.

> >I've fiddled with the Makefile in the build-linux-i386 directory and got=
> it
> >to build against db1 by changing this:
> >
> ># From OS/Makefile-Linux
> >BASENAME_COMMAND=3Dlook_for_it
> >CFLAGS=3D-O -I/usr/include/db1/ -L/usr/lib/            <- changed
> >DBMLIB =3D -ldb1                                                  <- =
> changed
> >USE_DB =3D yes
> >LIBS =3D -lnsl -lcrypt

>
> >haven't tested it in anger (yet).


There's never any need to fiddle with the Makefile directly. You should
be able to specify all these things in your Local/Makefile.

> gcc -c 3D-O -I/usr/include/db1/ -L/usr/lib/ -DCOMPILE_UTILITY -o util-spool_in.o spool_in.c
> gcc: cannot specify -o with -c or -S and multiple compilations
> make[1]: *** [util-spool_in.o] Error 1
> make[1]: Leaving directory `/home/tallship/downloads/exim/exim-4.05/build-Linux-i386'
> make: *** [go] Error 2


*That* looks like a screw-up in the options for gcc. What's that "3D"
doing there?

> Thanks for your patience Phil, any suggestions?


I seem to recall you said you also installed DB 4. The problem may be
that just saying

DBMLIB=-ldb

isn't enough, because it doesn't say which version of DB. I have all of
DB 1,2,3,4 installed on my testing box. Here is an extract from my
Local/Makefile:

----------------------------------------------------------------------
# All these 3 required for native mode DB 1.85; the second
# 2 only for compatibility mode.

#USE_DB=yes
#INCLUDE=-I/opt/local/include/db-1.85
#DBMLIB=/opt/local/lib/db-1.85/libdb.a

# All these 3 required for native mode DB 2.x; the second
# 2 only for compatibility mode.

#USE_DB=yes
#INCLUDE=-I/opt/local/include/db-2
#DBMLIB=/opt/local/lib/db-2/libdb.a

# All these 3 required for native mode DB 3.x; the second
# 2 only for compatibility mode.

#USE_DB=yes
#INCLUDE=-I/opt/local/include/db-3
#DBMLIB=/opt/local/lib/db-3/libdb.a

# All these 3 required for native mode DB 4.x; the second
# 2 only for compatibility mode.

USE_DB=yes
INCLUDE=-I/opt/local/include/db-4
DBMLIB=/opt/local/lib/db-4/libdb.a

# All these 3 required for native mode gdbm; the second
# 2 only for compability mode.

#USE_GDBM=yes
#INCLUDE=-I/opt/local/include/gdbm
#DBMLIB=-R/opt/local/lib -L/opt/local/lib -lgdbm
----------------------------------------------------------------------

I uncomment the one I want today. Now, the file names won't be the same
on your box, but I hope you get the idea: you need to tell Exim where
the relevant include files are, and also where the right library is, not
just by -ldb, but with a longer path name.

Search around on your box for where DB 4 got installed; it's probably
in something under /usr/local. Then try something like my example above.
A possible alternative formulation for DBMLIB is

DBMLIB=-L/opt/local/lib/db-4 -ldb


--
Philip Hazel            University of Cambridge Computing Service,
ph10@???      Cambridge, England. Phone: +44 1223 334714.