Subject: pkg/26167: cyrus-imapd22 fails to build on boostrapped pkgsrc on linux (db4 problem)
To: None <gnats-bugs@gnats.NetBSD.org>
From: None <adrianp@stindustries.net>
List: pkgsrc-bugs
Date: 07/05/2004 15:33:15
>Number:         26167
>Category:       pkg
>Synopsis:       cyrus-imapd22 fails to build on boostrapped pkgsrc on linux (db4 problem)
>Confidential:   no
>Severity:       serious
>Priority:       low
>Responsible:    pkg-manager
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Mon Jul 05 15:34:00 UTC 2004
>Closed-Date:
>Last-Modified:
>Originator:     Adrian Portelli
>Release:        1.6 i386
>Organization:
STIndustries
>Environment:
Linux xxx 2.4.26 #4 Sun Jul 4 15:11:00 BST 2004 i686 i686 i386 GNU/Linux
>Description:
pkgsrc bootrapped on a RedHat Linux 9.0 box. 
(pkgsrc was checked out from CVS @1:00PM BST 06072004)

The gcc-2.95.3nb5 package is installed with the following in my mk.conf:

CC=/usr/pkg/gcc-2.95.3/bin/gcc
CPP=/usr/pkg/gcc-2.95.3/bin/cpp
CXX=/usr/pkg/gcc-2.95.3/bin/g++

bmake install on cyrus-imapd22 pulls in both db4 and cyrus-sasl2 as requirements which appear to build and install OK.

When making cyrus-imapd22 I constantly get "gcc: unrecognized option `-R/usr/pkg/lib'" through the make process
e.g.

gcc -L/usr/pkg/lib -R/usr/pkg/lib -L/usr/pkg/gcc-2.95.3/lib/gcc-lib/i386-pc-linux/2.95.3 -Wl,-R/usr/pkg/gcc-2.95.3/lib/gcc-lib/i386-pc-linux/2.95.3 -L/usr/pkg/gcc-2.95.3/lib -Wl,-R/usr/pkg/gcc-2.95.3/lib -L/usr/pkg/lib -Wl,-R/usr/pkg/lib -L/usr/lib -Wl,-R/usr/lib -L/usr/lib -o notifyd  ../master/service.o notifyd.o notify_null.o notify_log.o notify_mailto.o notify_zephyr.o ../imap/mutex_fake.o ../imap/libimap.a ../lib/libcyrus.a ../lib/libcyrus_min.a -L/usr/pkg/lib  -R/usr/pkg/lib -lsasl2  -lfl  -lresolv   -ldb-4.0 -lssl -lcrypto -lfl  -lresolv   -ldb-4.0 -lssl -lcrypto -lcom_err -lwrap -lnsl
gcc: unrecognized option `-R/usr/pkg/lib'

There are lots more of these "gcc: unrecognized option `-R/usr/pkg/lib'" . Email me if you need the full log.

It still compiles and installs OK but cyrus-imapd fails to start with:

Jul  5 14:36:00 xxx imaps[9945]: incorrect version of Berkeley db: 
compiled against 4.2.52 (pkgsrc), linked against 4.0.14 (linux)

A rpm -qa reveals that "db4-4.0.14-20" is installed.  It looks like the package is getting confused between the db4 in the base OS and the db4 from pkgsrc.  I can't remove the db4 from the base OS as it's required for basic functionality.




>How-To-Repeat:
bootstrap pkgsrc on a RedHat Linux 9.0 box and try to install cyrus-imapd22.
>Fix:
Dunno.
>Release-Note:
>Audit-Trail:
>Unformatted: