Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 662148 - dev-db/mongodb: [All Versions] Incorrect RDEPEND list results in missing packages on binary package install.
Summary: dev-db/mongodb: [All Versions] Incorrect RDEPEND list results in missing pack...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Lujeni
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2018-07-26 00:16 UTC by Neil Semmel
Modified: 2018-08-02 07:34 UTC (History)
4 users (show)

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


Attachments
Modified mongodb-3.6.2-r1 ebuild. (mongodb-3.6.5-r2.ebuild,4.34 KB, text/plain)
2018-07-26 00:16 UTC, Neil Semmel
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Neil Semmel 2018-07-26 00:16:36 UTC
Created attachment 541082 [details]
Modified mongodb-3.6.2-r1 ebuild.

In all versions of dev-db/mongodb, multiple packages are listed in DEPEND when they should be listed in RDEPEND. This is causing packages to be missing when installing from a binary package of mongodb (tested on 3.6.5-r1, but other ebuilds exhibit the same issues).

Emerge command for all tests:

emerge -qv --autounmask-write --autounmask-continue --jobs =dev-db/mongodb-3.6.5-r1 --usepkg --buildpkg

When running for the very first time (no packages cached), the following list of packages are installed:

[ebuild  N    ] dev-libs/snowball-stemmer-0.20140325  USE="-static-libs"
[ebuild  N    ] dev-lang/go-1.10.3  USE="(-gccgo)"
[ebuild  N    ] dev-db/lmdb-0.9.18  USE="-static-libs"
[ebuild  N    ] net-libs/libssh2-1.8.0-r1  USE="zlib -gcrypt -libressl -static-libs {-test}"
[ebuild  N    ] app-crypt/rhash-1.3.5  USE="nls ssl -debug -libressl -static-libs"
[ebuild  N    ] dev-util/scons-2.5.1  USE="-doc" PYTHON_TARGETS="python2_7 (-pypy)"
[ebuild  N    ] dev-python/pyyaml-3.12  USE="-examples -libyaml" PYTHON_TARGETS="python2_7 python3_5 (-pypy) (-pypy3) -python3_4 -python3_6"
[ebuild  N    ] dev-python/markdown-2.6.8  USE="-doc -pygments {-test}" PYTHON_TARGETS="python2_7 python3_5 (-pypy) (-pypy3) -python3_4 -python3_6"
[ebuild  N    ] dev-python/cheetah-2.4.4-r1  PYTHON_TARGETS="python2_7"
[ebuild  N    ] dev-python/typing-3.6.2-r1  PYTHON_TARGETS="python2_7 (-pypy) -python3_4"
[ebuild  N    ] virtual/python-typing-0-r1  PYTHON_TARGETS="python2_7 python3_5 (-pypy) (-pypy3) -python3_4 -python3_6 (-python3_7)"
[ebuild  N    ] net-mail/mailbase-1.1  USE="pam"
[ebuild  N    ] app-arch/libarchive-3.3.1  USE="acl bzip2 e2fsprogs iconv lzma threads xattr zlib -expat -libressl -lz4 -lzo -nettle -static-libs"
[ebuild  N    ] net-libs/libpcap-1.8.1  USE="usb -bluetooth -dbus -netlink -static-libs"
[ebuild  N    ] dev-libs/libev-4.23  USE="-static-libs"
[ebuild  N    ] dev-libs/libverto-0.2.5-r1  USE="libev threads -glib -libevent -static-libs -tevent"
[ebuild  N    ] app-crypt/mit-krb5-1.16-r2  USE="keyutils nls pkinit threads -doc -libressl -openldap (-selinux) {-test} -xinetd"
[ebuild  N    ] virtual/krb5-0-r1
[ebuild  N    ] dev-libs/cyrus-sasl-2.1.26-r9  USE="berkdb gdbm kerberos pam ssl -authdaemond -java -ldapdb -mysql -openldap -postgres -sample (-selinux) -sqlite -srp -static-libs -urandom"
[ebuild  N    ] app-admin/mongo-tools-4.0.0  USE="sasl ssl"
[ebuild  N    ] net-nds/openldap-2.4.44  USE="berkdb crypt gnutls ipv6 kerberos samba sasl ssl syslog tcpd -cxx -debug -experimental -iodbc -kinit -libressl -minimal -odbc -overlays -perl (-selinux) -slp -smbkrb5passwd -static-libs"
[ebuild  N    ] net-misc/curl-7.61.0  USE="ipv6 kerberos ldap samba ssh ssl threads -adns -brotli -http2 -idn -metalink -rtmp -static-libs {-test}" CURL_SSL="openssl -axtls -gnutls -libressl -mbedtls -nss (-winssl)"
[ebuild  N    ] dev-util/cmake-3.9.6  USE="ncurses -doc -emacs -qt5 -server -system-jsoncpp {-test}"
[ebuild  N    ] app-arch/snappy-1.1.7  USE="(-static-libs) {-test}"
[ebuild  N    ] dev-cpp/yaml-cpp-0.6.2  USE="{-test}"
[ebuild  N    ] dev-db/mongodb-3.6.5-r1  USE="kerberos ssl tools -debug -libressl -mms-agent {-test}" PYTHON_TARGETS="python2_7"

This properly installs as expected.

The next time a system attempts to install mongodb (using the packages generated from this build), only the following packages are installed:

[binary  N    ] dev-cpp/yaml-cpp-0.6.2-1  USE="{-test}"
[binary  N    ] net-libs/libpcap-1.8.1-1  USE="usb -bluetooth -dbus -netlink -static-libs"
[binary  N    ] app-arch/snappy-1.1.7-1  USE="(-static-libs) {-test}"
[binary  N    ] dev-libs/snowball-stemmer-0.20140325-1  USE="-static-libs"
[binary  N    ] app-admin/mongo-tools-4.0.0-1  USE="sasl ssl"
[binary  N    ] dev-db/mongodb-3.6.5-r1-1  USE="kerberos ssl tools -debug -libressl -mms-agent {-test}" PYTHON_TARGETS="python2_7"

Obviously, it shouldn't need to install build deps (scons, etc) on later runs. However, at minimum 'dev-libs/cyrus-sasl' needs to be present, as mongodb dynamically links against libsasl2 and fails to launch. (I'm not familiar enough with mongodb, or scons to determine the exact extent of packages missing.)

Fix: 

At minimum, 'dev-libs/cyrus-sasl' needs to be moved from DEPEND to RDEPEND, and possibly other packages as well. I have confirmed that moving the 'cyrus-sasl' dependency into RDEPEND fixes the runtime linker issue when installing from binary packages (mongodb-3.6.5-r2.ebuild attached for reference). 

I fixed this locally by moving "kerberos? ( dev-libs/cyrus-sasl[kerberos] )" from DEPEND into RDEPEND (See attached).
Comment 1 Ultrabug gentoo-dev 2018-08-02 07:34:02 UTC
Fixed on newer ebuilds by Tomáš Mózes

Thanks!