From owner-freebsd-bugs Fri Jul 5 9:50:13 2002 Delivered-To: freebsd-bugs@hub.freebsd.org Received: from mx1.FreeBSD.org (mx1.FreeBSD.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 1BB2537B400 for ; Fri, 5 Jul 2002 09:50:07 -0700 (PDT) Received: from freefall.freebsd.org (freefall.FreeBSD.org [216.136.204.21]) by mx1.FreeBSD.org (Postfix) with ESMTP id C90B143E09 for ; Fri, 5 Jul 2002 09:50:06 -0700 (PDT) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (gnats@localhost [127.0.0.1]) by freefall.freebsd.org (8.12.4/8.12.4) with ESMTP id g65Go6JU053110 for ; Fri, 5 Jul 2002 09:50:06 -0700 (PDT) (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.12.4/8.12.4/Submit) id g65Go6BI053109; Fri, 5 Jul 2002 09:50:06 -0700 (PDT) Date: Fri, 5 Jul 2002 09:50:06 -0700 (PDT) Message-Id: <200207051650.g65Go6BI053109@freefall.freebsd.org> To: freebsd-bugs@FreeBSD.org Cc: From: Alex Zbyslaw Subject: Re: bin/21659: Berkeley db library is statically compiled into libc, which make use of newer BDB very difficult, if possible at all Reply-To: Alex Zbyslaw Sender: owner-freebsd-bugs@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.org The following reply was made to PR bin/21659; it has been noted by GNATS. From: Alex Zbyslaw To: freebsd-gnats-submit@FreeBSD.org, matrix@ipform.ru Cc: Subject: Re: bin/21659: Berkeley db library is statically compiled into libc, which make use of newer BDB very difficult, if possible at all Date: Fri, 05 Jul 2002 17:45:14 +0100 FreeBSD-4.4-RELEASE. If anything has materially changed since 4.4 then please advise me (I found nothing in the release notes). Surely it is possible to both have BDB 1.85 in libc, use 1.85 for library function and *still* allow newer versions to be installed an used successfully. Background: libc contains Berekeley DB 1.85 routines and these are used by some library functions (e.g. getpwent and friends). You can install a newer version of Berekeley DB (e.g. 2.7.7) as libdb2 and link applications against it, but if that application also links against libc (pretty likely) *and* uses any libc routine which expects BDB 1.85 then you are in trouble. An obvious example of such an application is Perl. A version of Perl which links against libdb2 cannot do any getpwent (and related) system calls because the file format of /etc/pwd.db is incompatible with BDB versions other than 1.85 and the library functions pick up dbmopen etc. from libdb2. However, there is no need for the *libc* routines which use BDB to use the standard function names. A parallel version of 1.85 with function names changed in some standard way (say by prefixing k_, or appending _185) could be used by the library functions themselves. The standard dbmopen etc. can stay in libc because they can easily be overridden by linking against a newer BDB library. It's not pretty, but I don't believe it's as impractical as the original reply stated. --Alex -- Email: xfb52@dial.pipex.com To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-bugs" in the body of the message