Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 643322 - net-libs/courier-authlib - /etc/init.d/courier-authlib fails on new no-lib-symlink multilib profiles
Summary: net-libs/courier-authlib - /etc/init.d/courier-authlib fails on new no-lib-sy...
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Net-Mail Packages
Depends on:
Blocks: no-symlink-lib
  Show dependency tree
Reported: 2018-01-03 20:27 UTC by Michael Edenfield
Modified: 2018-12-21 19:29 UTC (History)
2 users (show)

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

0001-net-libs-courier-authlib-Fix-libexecdir-to-work-with.patch (0001-net-libs-courier-authlib-Fix-libexecdir-to-work-with.patch,1.59 KB, patch)
2018-06-17 06:38 UTC, Michał Górny
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Michael Edenfield 2018-01-03 20:27:40 UTC
After switching to the new 17.1 profiles, and converting to the no-symlink layout, courier-authlib no longer starts.

    basement /etc/init.d # /etc/init.d/courier-authlib start
     * Starting courier-authlib: authdaemond ...
    basement /etc/init.d # ps aux | grep authdaemon
    root     27704  0.0  0.0   8528   920 pts/2    S+   15:33   0:00 grep --colour=auto authdaemon
    basement /etc/init.d # /etc/init.d/courier-authlib stop
     * Stopping courier-authlib: authdaemond ...
     * start-stop-daemon: no matching processes found
    basement /etc/init.d # grep exec /var/log/mail.log
    Jan  3 13:57:01 basement authdaemond: exec: No such file or directory
    Jan  3 13:57:28 basement authdaemond: exec: No such file or directory
    Jan  3 15:33:44 basement authdaemond: exec: No such file or directory

The init script has a hard-coded reference to /usr/lib to locate authdemond:

    setauth() {
            . /etc/courier/authlib/authdaemonrc

Manually editing this value to "/usr/lib64/courier/courier-authlib" allows the daemon to start.
Comment 1 Michael Edenfield 2018-01-03 21:50:26 UTC
Portage 2.3.19 (python 3.5.4-final-0, default/linux/amd64/17.1/hardened, gcc-7.2.0, glibc-2.26-r3, 4.8.9-hardened-basement-0 x86_64)
System uname: Linux-4.8.9-hardened-basement-0-x86_64-AMD_Athlon-tm-_64_X2_Dual_Core_Processor_4400+-with-gentoo-2.4.1
KiB Mem:     1987340 total,    176520 free
KiB Swap:    2008120 total,   2004572 free
Timestamp of repository gentoo: Mon, 01 Jan 2018 03:00:01 +0000
Head commit of repository gentoo: 0d371529adae7990e77f0eb567d44b33cbd2a831
sh bash 4.4_p12
ld GNU ld (Gentoo 2.29.1 p3) 2.29.1
app-shells/bash:          4.4_p12::gentoo
dev-lang/perl:            5.26.1-r1::gentoo
dev-lang/python:          2.7.14-r1::gentoo, 3.5.4-r1::gentoo, 3.6.3-r1::gentoo
dev-util/cmake:           3.10.1::gentoo
dev-util/pkgconfig:       0.29.2::gentoo
sys-apps/baselayout:      2.4.1-r2::gentoo
sys-apps/openrc:          0.34.11::gentoo
sys-apps/sandbox:         2.12::gentoo
sys-devel/autoconf:       2.69-r4::gentoo
sys-devel/automake:       1.14.1-r1::gentoo, 1.15.1-r1::gentoo
sys-devel/binutils:       2.29.1-r1::gentoo
sys-devel/gcc:            7.2.0::gentoo
sys-devel/gcc-config:     1.9.1::gentoo
sys-devel/libtool:        2.4.6-r4::gentoo
sys-devel/make:           4.2.1-r1::gentoo
sys-kernel/linux-headers: 4.14::gentoo (virtual/os-headers)
sys-libs/glibc:           2.26-r3::gentoo

    location: /var/portage
    sync-type: rsync
    sync-uri: rsync://
    priority: -1000

Installed sets: @system
ACCEPT_KEYWORDS="amd64 ~amd64"
CFLAGS="-march=athlon64 -fomit-frame-pointer -O2 -pipe"
CONFIG_PROTECT="/etc /usr/share/gnupg/qualified.txt /var/bind"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/gconf /etc/gentoo-release /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo"
CXXFLAGS="-march=athlon64 -fomit-frame-pointer -O2 -pipe"
FCFLAGS="-O2 -pipe"
FEATURES="assume-digests binpkg-logs config-protect-if-modified distlocks ebuild-locks fixlafiles merge-sync multilib-strict news parallel-fetch preserve-libs protect-owned sandbox sfperms split-elog strict unknown-features-warn unmerge-logs unmerge-orphans userfetch userpriv usersandbox usersync xattr"
FFLAGS="-O2 -pipe"
LDFLAGS="-Wl,-O1 -Wl,--as-needed"
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"
USE="acl amd64 bash-completion bzip2 cracklib crypt cxx hardened iconv ipv6 multilib ncurses nls nptl openmp pam pcre pie readline samba seccomp ssl ssp unicode vim-syntax xattr xtpax zlib" ABI_X86="64" APACHE2_MODULES="alias authn_core authz_core authz_host cgid deflate dir env filter log_config mime rewrite socache_shmcb status unixd userdir" APACHE2_MPMS="worker" 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="mmx mmxext sse sse2" 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="keyboard mouse evdev" KERNEL="linux" L10N="en_US" LIBREOFFICE_EXTENSIONS="presenter-console presenter-minimizer" LINGUAS="en" OFFICE_IMPLEMENTATION="libreoffice" PHP_TARGETS="php5-6 php7-0" POSTGRES_TARGETS="postgres9_5" PYTHON_SINGLE_TARGET="python3_6" PYTHON_TARGETS="python2_7 python3_6" RUBY_TARGETS="ruby22" SANE_BACKENDS="net" USERLAND="GNU" VIDEO_CARDS="fbdev nv vesa vga" 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"
Comment 2 Michael Edenfield 2018-01-03 21:52:07 UTC
Sorry, forgot, I'm using the latest: courier-authlib-0.68.0-r1 but I think this problem is version-agnostic.  The init script in the files folder in the portage tree has the problem.
Comment 3 Kostas Kavourakis 2018-01-07 16:32:56 UTC
I just stumbled into the same issue, the hardcoded init script causes startup failure. The path is hardcoded as the init script itself is the file "courier-authlib-r1" in the files folder of the ebuild.
Comment 4 Michał Górny archtester Gentoo Infrastructure gentoo-dev Security 2018-06-17 06:34:29 UTC
The solution would probably be to stop forcing this silly $(get_libdir) for libexecdir.  I'm going to attach a patch trying to achieve this but I'll need someone to test it in a real deployment.
Comment 5 Michał Górny archtester Gentoo Infrastructure gentoo-dev Security 2018-06-17 06:38:08 UTC
Created attachment 536072 [details, diff]
Comment 6 Hanno Böck gentoo-dev 2018-12-18 09:26:30 UTC
I'm wondering if these files belong to "lib" at all.
The default seems to be to place them in /usr/libexec/, which from my understanding is more in line with standards [1].

So unless there are any objections I'd just change to use upstream defaults here.

Comment 7 Larry the Git Cow gentoo-dev 2018-12-21 19:29:26 UTC
The bug has been closed via the following commit(s):

commit 3894ca5794aa573ed1943e735637a9e1f287b6b2
Author:     Hanno <>
AuthorDate: 2018-12-21 19:28:54 +0000
Commit:     Hanno <>
CommitDate: 2018-12-21 19:28:54 +0000

    net-libs/courier-authlib: Version bump.
    Change libexecdir to courier default (avoids problems with
    no-symlink profiles).
    Remove unneeded .la files.
    Change mysql dependency.
    Update to EAPI=7.
    Signed-off-by: Hanno Boeck <>
    Package-Manager: Portage-2.3.52, Repoman-2.3.12

 net-libs/courier-authlib/Manifest                  |   1 +
 .../courier-authlib/courier-authlib-0.69.0.ebuild  | 150 +++++++++++++++++++++
 net-libs/courier-authlib/files/courier-authlib-r2  |  40 ++++++
 3 files changed, 191 insertions(+)