Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 555122 - net-mail/cyrus-imapd berkely DB library include/lib mismatch
Summary: net-mail/cyrus-imapd berkely DB library include/lib mismatch
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Net-Mail Packages
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-07-16 22:27 UTC by Joe Harvell
Modified: 2015-07-22 14:35 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Joe Harvell 2015-07-16 22:27:18 UTC
Runtime error with all cyrus-imapd executables as follows:

juil. 16 14:07:50 akita master[27077]: about to exec /usr/lib64/cyrus/imapd
juil. 16 14:07:50 akita imaps[27077]: incorrect version of Berkeley db: compiled against 6.0.30, linked against 4.8.30

cyrus-imapd version is 2.4.17-r1

Root cause of problem is ebuild explicitly selects include directory but fails to correctly select library.  The upstream configure script selects the library to link against by attempting to link a test program one by one using different -l options to the linker.  The first library it uses is the one specified by --with-db, but the ebuild passes the value 'yes' instead of the corect libname to link against.  The configure script is supposed to continue in succession trying each libname, but in fact it does not seem to behave as intended.  In any case, the solution is to use the db-use eclass utilites that already exist to find the libname corresponding to the include directory

Patch to 2.4.17-r1 ebuild below sovled the problem for me.

[code]
joey@akita /opt/portage/net-mail/cyrus-imapd $ diff -u /usr/portage/net-mail/cyrus-imapd/cyrus-imapd-2.4.17-r1.ebuild cyrus-imapd-2.4.17-r1.ebuild 
--- /usr/portage/net-mail/cyrus-imapd/cyrus-imapd-2.4.17-r1.ebuild      2015-06-26 13:01:15.000000000 -0500
+++ cyrus-imapd-2.4.17-r1.ebuild        2015-07-16 16:03:12.125774495 -0500
@@ -1,3 +1,4 @@
+
 # Copyright 1999-2015 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
 # $Header: /var/cvsroot/gentoo-x86/net-mail/cyrus-imapd/cyrus-imapd-2.4.17-r1.ebuild,v 1.5 2015/06/26 17:33:50 grknight Exp $
@@ -108,6 +109,7 @@
        fi
        if use berkdb ; then
                myconf+=" --with-bdb-incdir=$(db_includedir)"
+                myconf+=" --with-bdb=$(db_libname)"
        fi
        econf \
                --enable-murder \
@@ -124,7 +126,6 @@
                --with-zlib \
                $(use_enable afs) \
                $(use_enable afs krb5afspts) \
-               $(use_with berkdb bdb) \
                $(use_enable nntp) \
                $(use_enable replication) \
                $(use_enable kerberos gssapi) \

[/code]
Comment 1 Joe Harvell 2015-07-16 22:28:20 UTC
joey@akita ~ $ emerge --info
Portage 2.2.20 (python 3.3.5-final-0, default/linux/amd64/13.0/desktop/kde, gcc-4.9.3, glibc-2.20-r2, 4.0.0-5b745e654d+ x86_64)
=================================================================
System uname: Linux-4.0.0-5b745e654d+-x86_64-Intel-R-_Core-TM-_i7-3770K_CPU_@_3.50GHz-with-gentoo-2.2
KiB Mem:    32896560 total,   1462900 free
KiB Swap:    4194300 total,   4089252 free
Timestamp of repository gentoo: Tue, 14 Jul 2015 17:45:01 +0000
sh bash 4.3_p39
ld GNU ld (Gentoo git) 2.25.51.20150716
app-shells/bash:          4.3_p39::gentoo
dev-java/java-config:     2.2.0::gentoo
dev-lang/perl:            5.22.0::gentoo
dev-lang/python:          2.7.10::gentoo, 3.2.5-r3::gentoo, 3.3.5-r1::gentoo, 3.4.3::gentoo
dev-util/cmake:           3.2.3::gentoo
dev-util/pkgconfig:       0.28-r3::gentoo
sys-apps/baselayout:      2.2::gentoo
sys-apps/openrc:          0.17::gentoo
sys-apps/sandbox:         2.6-r1::gentoo
sys-devel/autoconf:       2.13::gentoo, 2.69-r1::gentoo
sys-devel/automake:       1.11.6-r1::gentoo, 1.12.6::gentoo, 1.14.1::gentoo, 1.15::gentoo
sys-devel/binutils:       2.25-r1::gentoo, 9999::gentoo
sys-devel/gcc:            4.7.4::gentoo, 4.8.3::gentoo, 4.9.3::gentoo
sys-devel/gcc-config:     1.8::gentoo
sys-devel/libtool:        2.4.6-r1::gentoo
sys-devel/make:           4.1-r1::gentoo
sys-kernel/linux-headers: 4.1::gentoo (virtual/os-headers)
sys-libs/glibc:           2.20-r2::gentoo
Repositories:

gentoo
    location: /usr/portage
    sync-type: rsync
    sync-uri: rsync://rsync.us.gentoo.org/gentoo-portage
    priority: -1000

akita
    location: /opt/portage
    priority: 0

ACCEPT_KEYWORDS="amd64 ~amd64"
ACCEPT_LICENSE="* -@EULA AdobeFlash-11.x Oracle-BCLA-JavaSE QUAKE4 skype-4.0.0.7-copyright"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-O3 -pipe -march=native -ggdb -flto=10 -floop-interchange -ftree-loop-distribution -floop-strip-mine -floop-block -ftree-vectorize"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /etc/stunnel/stunnel.conf /usr/lib64/libreoffice/program/sofficerc /usr/share/config /usr/share/gnupg/qualified.txt /usr/share/maven-bin-3.2/conf /var/bind"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/dconf /etc/env.d /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo"
CXXFLAGS="-O3 -pipe -march=native -ggdb -flto=10 -floop-interchange -ftree-loop-distribution -floop-strip-mine -floop-block -ftree-vectorize"
DISTDIR="/usr/portage/distfiles"
EMERGE_DEFAULT_OPTS="--autounmask-write --jobs=10 --load-average 30"
FCFLAGS="-O2 -pipe"
FEATURES="assume-digests binpkg-logs config-protect-if-modified distlocks ebuild-locks fixlafiles merge-sync news parallel-fetch parallel-install preserve-libs protect-owned sandbox sfperms splitdebug strict unknown-features-warn unmerge-logs unmerge-orphans userfetch userpriv usersandbox usersync xattr"
FFLAGS="-O2 -pipe"
GENTOO_MIRRORS="http://gentoo.mirrors.tds.net/gentoo http://mirror.espri.arizona.edu/gentoo/ http://gentoo.mirrors.easynews.com/linux/gentoo/"
LANG="fr_FR.UTF-8"
LC_ALL="en_US.UTF-8"
LDFLAGS="-flto=10 -fuse-ld=gold -fuse-linker-plugin"
MAKEOPTS="--jobs=10 --load-average=30"
PKGDIR="/usr/portage/packages"
PORTAGE_CONFIGROOT="/"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --omit-dir-times --compress --force --whole-file --delete --stats --human-readable --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages"
PORTAGE_TMPDIR="/var/tmp"
USE="X a52 aac acl acpi alsa amd64 berkdb bluetooth bluray branding bzip2 c++0x cairo caps cdda cdr cli cracklib crypt cups cxx dbus declarative dri dts dvd dvdr emboss encode exif fam fftw firefox firmware flac fortran fuse gdbm geoip gif git glamor gpm gtk iconv ipv6 java joystick jpeg kde kipi lcms ldap libass libav libnotify lm_sensors lvm lxc lzo mad mercurial mmx mmxext mng modules mp3 mp4 mpeg multilib ncurses nfsv41 nls nptl nsplugin ogg openal opengl openmp pam pango pcre pdf perl phonon plasma png policykit ppds python qt3support qt4 quicktime readline sasl sdl semantic-desktop session spell spice sse sse2 sse3 sse4 ssl ssse3 startup-notification subversion svg systemd tcpd tiff truetype udev udisks unicode upower usb vdpau vorbis wayland wxwidgets x264 xattr xcb xcomposite xinerama xml xscreensaver xv xvid zlib" ABI_X86="64" ALSA_CARDS="hda-intel" APACHE2_MODULES="authn_core authz_core socache_shmcb unixd actions alias auth_basic authn_alias authn_anon authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache cgi cgid dav dav_fs dav_lock deflate dir disk_cache env expires ext_filter file_cache filter headers include info log_config logio mem_cache mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias" CALLIGRA_FEATURES="kexi words flow plan sheets stage tables krita karbon braindump author" CAMERAS="ptp2" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" CPU_FLAGS_X86="aes avx mmx mmxext popcnt sse sse2 sse3 sse4_1 sse4_2 ssse3" ELIBC="glibc" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock itrax mtk3301 nmea ntrip navcom oceanserver oldstyle oncore rtcm104v2 rtcm104v3 sirf superstar2 timing tsip tripmate tnt ublox ubx" INPUT_DEVICES="joystick" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LIBREOFFICE_EXTENSIONS="presenter-console presenter-minimizer" LINGUAS="en_US fr_FR en fr" OFFICE_IMPLEMENTATION="libreoffice" PHP_TARGETS="php5-5" PYTHON_SINGLE_TARGET="python2_7" PYTHON_TARGETS="python2_7 python3_3" RUBY_TARGETS="ruby19 ruby20" USERLAND="GNU" VIDEO_CARDS="nvidia" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipset ipp2p iface geoip fuzzy condition tee tarpit sysrq steal rawnat logmark ipmark dhcpmac delude chaos account"
Unset:  CPPFLAGS, CTARGET, INSTALL_MASK, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS, USE_PYTHON
Comment 2 Eray Aslan gentoo-dev 2015-07-22 14:35:47 UTC
Should be fixed in net-mail/cyrus-imapd-2.5.4.  Please let me know if you still have a problem.