Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 625156 - net-mail/cyrus-imapd-3.0.2[perl,caps]: /usr/lib64/perl5/vendor_perl/5.24.1/x86_64-linux-thread-multi/auto/Cyrus/IMAP/IMAP.so: undefined symbol: cap_from_text at /usr/lib64/perl5/5.24.1/x86_64-linux-thread-multi/DynaLoader.pm line 193
Summary: net-mail/cyrus-imapd-3.0.2[perl,caps]: /usr/lib64/perl5/vendor_perl/5.24.1/x8...
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: PATCH
Depends on:
Blocks:
 
Reported: 2017-07-15 05:46 UTC by Guillaume Castagnino
Modified: 2017-08-15 06:23 UTC (History)
2 users (show)

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


Attachments
fix libcap linking in perl module (cyrus-perl-libcap.patch,2.20 KB, patch)
2017-07-15 05:46 UTC, Guillaume Castagnino
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Guillaume Castagnino 2017-07-15 05:46:13 UTC
Created attachment 484686 [details, diff]
fix libcap linking in perl module

When built with libcap support, cyradm (and all perl extension) is broken due to IMAP.so perl extension not linked against libcap:

# cyradm 
Can't load '/usr/lib64/perl5/vendor_perl/5.24.1/x86_64-linux-thread-multi/auto/Cyrus/IMAP/IMAP.so' for module Cyrus::IMAP: /usr/lib64/perl5/vendor_perl/5.24.1/x86_64-linux-thread-multi/auto/Cyrus/IMAP/IMAP.so: undefined symbol: cap_from_text at /usr/lib64/perl5/5.24.1/x86_64-linux-thread-multi/DynaLoader.pm line 193.
 at /usr/lib64/perl5/vendor_perl/5.24.1/x86_64-linux-thread-multi/Cyrus/IMAP/Admin.pm line 43.
Compilation failed in require at /usr/lib64/perl5/vendor_perl/5.24.1/x86_64-linux-thread-multi/Cyrus/IMAP/Admin.pm line 43.
BEGIN failed--compilation aborted at /usr/lib64/perl5/vendor_perl/5.24.1/x86_64-linux-thread-multi/Cyrus/IMAP/Admin.pm line 43.
Compilation failed in require at /usr/lib64/perl5/vendor_perl/5.24.1/x86_64-linux-thread-multi/Cyrus/IMAP/Shell.pm line 59.
BEGIN failed--compilation aborted at /usr/lib64/perl5/vendor_perl/5.24.1/x86_64-linux-thread-multi/Cyrus/IMAP/Shell.pm line 59.
Compilation failed in require at /usr/bin/cyradm line 66.
BEGIN failed--compilation aborted at /usr/bin/cyradm line 66.


# ldd /usr/lib64/perl5/vendor_perl/5.24.1/x86_64-linux-thread-multi/auto/Cyrus/IMAP/IMAP.so
        linux-vdso.so.1 (0x00007fff2476c000)
        libsasl2.so.3 => /usr/lib64/libsasl2.so.3 (0x00007f42d0e80000)
        libssl.so.1.0.0 => /usr/lib64/libssl.so.1.0.0 (0x00007f42d0c09000)
        libcrypto.so.1.0.0 => /usr/lib64/libcrypto.so.1.0.0 (0x00007f42d0788000)
        libuuid.so.1 => /lib64/libuuid.so.1 (0x00007f42d0583000)
        libz.so.1 => /lib64/libz.so.1 (0x00007f42d036c000)
        libpcreposix.so.0 => /usr/lib64/libpcreposix.so.0 (0x00007f42d0167000)
        libc.so.6 => /lib64/libc.so.6 (0x00007f42cfdc7000)
        libdl.so.2 => /lib64/libdl.so.2 (0x00007f42cfbbb000)
        /lib64/ld-linux-x86-64.so.2 (0x000055c0372ba000)
        libpcre.so.1 => /lib64/libpcre.so.1 (0x00007f42cf976000)




It seems that there is a patch playing with libs in gentoo, so I report here and not in upstream.



I fixed the issue by adding the attached patch on top on the Gentoo patch




emerge --info:
# emerge --info cyrus-imapd
Portage 2.3.6 (python 3.5.3-final-0, hardened/linux/amd64/no-multilib, gcc-6.3.0, glibc-2.24-r3, 4.12.0-gentoo x86_64)
=================================================================
                         System Settings
=================================================================
System uname: Linux-4.12.0-gentoo-x86_64-Intel_Core_Processor_-Haswell,_no_TSX-with-gentoo-2.4.1
KiB Mem:     7975680 total,   1653604 free
Timestamp of repository gentoo: Fri, 14 Jul 2017 07:00:01 +0000
Timestamp of repository xwing: Sat, 15 Jul 2017 05:00:06 +0000
sh bash 4.4_p12
ld GNU ld (Gentoo 2.28 p1.2) 2.28
app-shells/bash:          4.4_p12::gentoo
dev-lang/perl:            5.24.1-r2::gentoo
dev-lang/python:          3.5.3::gentoo
dev-util/cmake:           3.8.2::gentoo
dev-util/pkgconfig:       0.29.2::gentoo
sys-apps/baselayout:      2.4.1::gentoo
sys-apps/openrc:          0.28::gentoo
sys-apps/sandbox:         2.10-r4::gentoo
sys-devel/autoconf:       2.69-r3::gentoo
sys-devel/automake:       1.15.1::gentoo
sys-devel/binutils:       2.28-r2::gentoo
sys-devel/gcc:            6.3.0::gentoo
sys-devel/gcc-config:     1.8-r1::gentoo
sys-devel/libtool:        2.4.6-r4::gentoo
sys-devel/make:           4.2.1-r1::gentoo
sys-kernel/linux-headers: 4.10::gentoo (virtual/os-headers)
sys-libs/glibc:           2.24-r3::gentoo
Repositories:

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

xwing
    location: /exports/portage-rsync
    masters: gentoo
    priority: 0

local_portage
    location: /usr/local/portage/local-portage
    masters: gentoo
    priority: 50

Installed sets: @system
ACCEPT_KEYWORDS="amd64 ~amd64"
ACCEPT_LICENSE="* -@EULA"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-march=native -O2 -mtune=native -pipe"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/share/gnupg/qualified.txt /var/bind"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/php/apache2-php7.1/ext-active/ /etc/php/cgi-php7.1/ext-active/ /etc/php/cli-php7.1/ext-active/ /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo"
CXXFLAGS="-march=native -O2 -mtune=native -pipe"
DISTDIR="/usr/portage/distfiles"
EMERGE_DEFAULT_OPTS="--with-bdeps y"
FCFLAGS="-O2 -pipe"
FEATURES="assume-digests binpkg-logs buildsyspkg collision-protect config-protect-if-modified distlocks ebuild-locks fixlafiles merge-sync news parallel-fetch preserve-libs protect-owned sandbox sfperms strict unknown-features-warn unmerge-logs unmerge-orphans userfetch userpriv usersandbox usersync xattr"
FFLAGS="-O2 -pipe"
GENTOO_MIRRORS="http://gentoo.mirrors.ovh.net/gentoo-distfiles/"
LANG="fr_FR.utf8"
LC_ALL="fr_FR.utf8"
LDFLAGS="-Wl,-O1 -Wl,--hash-style=gnu -Wl,--as-needed -Wl,--sort-common"
MAKEOPTS="-j5"
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 --exclude=/.git"
PORTAGE_TMPDIR="/var/tmp"
USE="acl acpi amd64 bash-completion bashlogger bzip2 caps cli cracklib crypt cxx dri fontconfig fpm hardened iconv idn inotify iproute2 ipv6 ithreads jpeg justify ncurses nls nptl openldap openmp openssl pam pax_kernel pcre pie png readline sasl seccomp session sieve ssl ssp tcpd threads tiff unicode urandom vim-syntax xattr xtpax zlib" ABI_X86="64" ALSA_CARDS="ali5451 als4000 atiixp atiixp-modem bt87x ca0106 cmipci emu10k1x ens1370 ens1371 es1938 es1968 fm801 hda-intel intel8x0 intel8x0m maestro3 trident usb-audio via82xx via82xx-modem ymfpci" 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" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" CPU_FLAGS_X86="aes avx avx2 fma3 mmx mmxext popcnt sse sse2 sse3 sse4_1 sse4_2 ssse3" ELIBC="glibc" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock isync itrax mtk3301 nmea ntrip navcom oceanserver oldstyle oncore rtcm104v2 rtcm104v3 sirf skytraq superstar2 timing tsip tripmate tnt ublox ubx" INPUT_DEVICES="libinput keyboard mouse" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LIBREOFFICE_EXTENSIONS="presenter-console presenter-minimizer" LINGUAS="fr" OFFICE_IMPLEMENTATION="libreoffice" PHP_TARGETS="php7-0" POSTGRES_TARGETS="postgres9_5" PYTHON_SINGLE_TARGET="python3_5" PYTHON_TARGETS="python3_5" RUBY_TARGETS="ruby21 ruby22" USERLAND="GNU" VIDEO_CARDS="amdgpu fbdev intel nouveau radeon radeonsi vesa dummy v4l" 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"
USE_PYTHON="3.5"
Unset:  CC, CPPFLAGS, CTARGET, CXX, INSTALL_MASK, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS

=================================================================
                        Package Settings
=================================================================

net-mail/cyrus-imapd-3.0.2::gentoo was built with the following:
USE="caps http pam perl server sieve sqlite ssl tcpd -afs -backup -calalarm -clamav -jmap -kerberos -ldap -lmdb -mysql -nntp -postgres -replication -snmp -sphinx -static-libs -test -xapian"
Comment 1 Maciej S. Szmigiero 2017-08-14 18:17:14 UTC
Hit this issue with cyrus-imapd-3.0.3 and your patch fixed it - thanks Guillaume!

@Package maintainers: can this patch be added to cyrus-imapd ebuild please?
Comment 2 Eray Aslan gentoo-dev 2017-08-15 06:23:03 UTC
Added to the tree in =net-mail/cyrus-imapd-3.0.3-r1.  Thanks for the patch.