Issue 36 - Error compiling OpenLDAP 1.1.2 with DB 2.3.16
Summary: Error compiling OpenLDAP 1.1.2 with DB 2.3.16
Status: VERIFIED FIXED
Alias: None
Product: OpenLDAP
Classification: Unclassified
Component: slapd (show other issues)
Version: unspecified
Hardware: All All
: --- normal
Target Milestone: ---
Assignee: OpenLDAP project
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 1999-01-08 06:10 UTC by Yusuf Goolamabbas
Modified: 2014-08-01 21:06 UTC (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this issue.
Description Yusuf Goolamabbas 1999-01-08 06:10:16 UTC
Platform FreeBSD 3.0-RELEASE
Installed Berkeley DB via 
pkg_add ftp://ftp.freebsd.org/pub/FreeBSD/packages-stable/All/db-2.3.16.tgz

env CPPFLAGS="-I/usr/local/include" LDFLAGS="-L/usr/local/lib" \
./configure --prefix=/usr/local/site/ldap >foo 2>&1

Relevant section from file foo

checking for DB2 library... checking for db_open in -ldb... no
no
checking for db.h... yes
checking if db.h is DB2... yes
checking for Berkeley DB2... no
checking for Berkeley DB library... checking for dbopen... yes
yes
checking for db_185.h... yes
checking for Berkeley DB... yes

make depend
make

 
  Entering subdirectory libldbm
gcc -g -O2 -I../../include -I../../include   -I/usr/local/include -DHAVE_CONFIG_H  -c ldbm.c
ldbm.c: In function `ldbm_open':
ldbm.c:61: `BTREEINFO' undeclared (first use this function)
ldbm.c:61: (Each undeclared identifier is reported only once
ldbm.c:61: for each function it appears in.)
ldbm.c:61: parse error before `binfo'
ldbm.c:62: `HASHINFO' undeclared (first use this function)
ldbm.c:65: `hinfo' undeclared (first use this function)
ldbm.c:69: `binfo' undeclared (first use this function)
ldbm.c:76: warning: assignment makes pointer from integer without a cast
ldbm.c: In function `ldbm_close':
ldbm.c:89: too few arguments to function
ldbm.c: In function `ldbm_fetch':
ldbm.c:136: warning: passing arg 2 from incompatible pointer type
ldbm.c:136: too few arguments to function
ldbm.c: In function `ldbm_store':
ldbm.c:156: warning: passing arg 2 from incompatible pointer type
ldbm.c:156: warning: passing arg 4 makes pointer from integer without a cast
ldbm.c:156: too few arguments to function
ldbm.c: In function `ldbm_delete':
ldbm.c:173: warning: passing arg 2 from incompatible pointer type
ldbm.c:173: too few arguments to function
ldbm.c: In function `ldbm_firstkey':
ldbm.c:216: structure has no member named `seq'
ldbm.c:216: `R_FIRST' undeclared (first use this function)
ldbm.c: In function `ldbm_nextkey':
ldbm.c:251: structure has no member named `seq'
ldbm.c:251: `R_NEXT' undeclared (first use this function)
*** Error code 1

Stop.
*** Error code 1

Stop.
*** Error code 1

Stop.
Comment 1 Kurt Zeilenga 1999-01-08 07:45:48 UTC
Check config.log for details on why db_open() does not appear
to be in -ldb.
Comment 2 Kurt Zeilenga 1999-01-08 07:45:56 UTC
changed state Open to Feedback
Comment 3 Yusuf Goolamabbas 1999-01-08 07:48:32 UTC
Hi Kurt, I just did a 
nm /usr/local/lib/libdb.a | grep db_open

/usr/libexec/elf/nm: cxx_txn.o: File format not recognized

Could be some issue with a.out and ELF format

I shall try the ports (though, I recollect doing it and getting the same
error)

-- 
Yusuf Goolamabbas
yusufg@huge.net
Comment 4 Yusuf Goolamabbas 1999-01-08 07:57:39 UTC
Compiling out of ports
cd /usr/ports/database/db ; make

Then recompiling openldap-1.1.2

Everything just flies
I guess the package was designed for a.out stuff and not for ELF
thingies. Should check with the portmaister at FreeBSD on this

I consider this report closed

-- 
Yusuf Goolamabbas
yusufg@huge.net
Comment 5 Kurt Spanier 1999-01-08 08:11:50 UTC
Yusuf,

have you made a make veryclean and ./configure anew. When there remain old
config.cache files, the build will not perform correctly.

Another point I could mention is, that I always use the LIBS environment
variable instead of LDFLAGS. Switching from one DB version to the other is
no problem, then.

Please  make really sure that you start with the new DB from scratch.


Regards,
Kurt


On Fri, 8 Jan 1999 yusufg@huge.net wrote:

> Date: Fri, 8 Jan 1999 06:13:18 GMT
> From: yusufg@huge.net
> To: openldap-its@OpenLDAP.org
> Subject: Error compiling OpenLDAP 1.1.2 with DB 2.3.16  (ITS#36)
> 
> Platform FreeBSD 3.0-RELEASE
> Installed Berkeley DB via 
> pkg_add ftp://ftp.freebsd.org/pub/FreeBSD/packages-stable/All/db-2.3.16.tgz
> 
> env CPPFLAGS="-I/usr/local/include" LDFLAGS="-L/usr/local/lib" \
> .../configure --prefix=/usr/local/site/ldap >foo 2>&1
> 
> Relevant section from file foo
> 
> checking for DB2 library... checking for db_open in -ldb... no
> no
> checking for db.h... yes
> checking if db.h is DB2... yes
> checking for Berkeley DB2... no
> checking for Berkeley DB library... checking for dbopen... yes
> yes
> checking for db_185.h... yes
> checking for Berkeley DB... yes
> 
> make depend
> make
> 
>  
>   Entering subdirectory libldbm
> gcc -g -O2 -I../../include -I../../include   -I/usr/local/include -DHAVE_CONFIG_H  -c ldbm.c
> ldbm.c: In function `ldbm_open':
> ldbm.c:61: `BTREEINFO' undeclared (first use this function)
> ldbm.c:61: (Each undeclared identifier is reported only once
> ldbm.c:61: for each function it appears in.)
> ldbm.c:61: parse error before `binfo'
> ldbm.c:62: `HASHINFO' undeclared (first use this function)
> ldbm.c:65: `hinfo' undeclared (first use this function)
> ldbm.c:69: `binfo' undeclared (first use this function)
> ldbm.c:76: warning: assignment makes pointer from integer without a cast
> ldbm.c: In function `ldbm_close':
> ldbm.c:89: too few arguments to function
> ldbm.c: In function `ldbm_fetch':
> ldbm.c:136: warning: passing arg 2 from incompatible pointer type
> ldbm.c:136: too few arguments to function
> ldbm.c: In function `ldbm_store':
> ldbm.c:156: warning: passing arg 2 from incompatible pointer type
> ldbm.c:156: warning: passing arg 4 makes pointer from integer without a cast
> ldbm.c:156: too few arguments to function
> ldbm.c: In function `ldbm_delete':
> ldbm.c:173: warning: passing arg 2 from incompatible pointer type
> ldbm.c:173: too few arguments to function
> ldbm.c: In function `ldbm_firstkey':
> ldbm.c:216: structure has no member named `seq'
> ldbm.c:216: `R_FIRST' undeclared (first use this function)
> ldbm.c: In function `ldbm_nextkey':
> ldbm.c:251: structure has no member named `seq'
> ldbm.c:251: `R_NEXT' undeclared (first use this function)
> *** Error code 1
> 
> Stop.
> *** Error code 1
> 
> Stop.
> *** Error code 1
> 
> Stop.
> 
> 


----------==========#########>>>>>ZDV<<<<<#########==========----------

X.500:                                              Tel.:
   Kurt Spanier, Zentrum fuer Datenverarbeitung,      +49 7071 29-70334
   Universitaet Tuebingen, DE
SMTP-Mail:                                          FAX.:
   kurt.spanier@zdv.uni-tuebingen.de                   +49 7071 29-5912
Snail-Mail:
   Dr. Kurt Spanier, Zentrum fuer Datenverarbeitung,
   Universitaet Tuebingen, Waechterstrasse 76, D-72074 Tuebingen
PGP-Public-Key:
   finger "Kurt Spanier"@x500.uni-tuebingen.de

----------==========##########>>>>>@<<<<<##########==========----------


Comment 6 Yusuf Goolamabbas 1999-01-08 08:16:30 UTC
Hi Kurt (The other Kurt helped me by asking me to look why db_open was
not found, so I did a nm /usr/local/lib/libdb. and I got an error
stating that file format not recognized)

so, I deleted the package and built it from scratch from the ports
now nm gives no such errors, and the build proceeds smoothly.

I have sent a message to freebsd-ports asking for some information about
this package

> Yusuf,
> 
> have you made a make veryclean and ./configure anew. When there remain old
> config.cache files, the build will not perform correctly.
> 
> Another point I could mention is, that I always use the LIBS environment
> variable instead of LDFLAGS. Switching from one DB version to the other is
> no problem, then.
> 
> Please  make really sure that you start with the new DB from scratch.
> 
> 
> Regards,
> Kurt
> 
Comment 7 Kurt Zeilenga 1999-01-08 18:17:54 UTC
changed notes
changed state Feedback to Closed
Comment 8 OpenLDAP project 2014-08-01 21:06:05 UTC
DB2 was not installed properly.