On a CentOS 6 system, which uses a glibc version 2.12, the system libcrypt.so (provided by glibc and therefore not prefix) has the following symbols: NSSLOWHASH_Update@@NSSRAWHASH_3.12.3 NSSLOWHASH_NewContext@@NSSRAWHASH_3.12.3 NSSLOWHASH_End@@NSSRAWHASH_3.12.3 NSSLOW_Init@@NSSRAWHASH_3.12.3 NSSLOW_Shutdown@@NSSRAWHASH_3.12.3 NSSLOWHASH_Destroy@@NSSRAWHASH_3.12.3 NSSLOWHASH_Begin@@NSSRAWHASH_3.12.3 libcrypt.so relies on libfreebl3.so providing those symbols, and libfreebl3.so is provided by dev-libs/nss in the Prefix. The NSSRAWHASH symbols are provided by nsslowhash.{h,c} which is only built if FREEBL_LOWHASH is set. Normally this is set automatically by a Makefile, but only if FREEBL_NO_DEPEND is already set. Gentoo's ebuild sets FREEBL_NO_DEPEND=1, skipping the block that would also normally set FREEBL_LOWHASH=1. My recommendation is to also set FREEBL_LOWHASH=1 right after FREEBL_NO_DEPEND=1 is set. Reproducible: Always Steps to Reproduce: 1. Ensure 'less /usr/lib*/libcrypt.so' has a libfreebl3.so NEEDED entry, and some "*UND*" NSSRAWHASH_3.12.3 symbols. 1. emerge -1v dev-libs/nss, then inspect ${EPREFIX}/usr/lib/libfreebl3.so to ensure that NSSRAWHASH_3.12.3 smybols are not mentioned. 2. emerge -1v util-linux There should be a complaint about readline missing, but really it's a domino effect from libcrypt missing symbols. (A quick check in the config.log will confirm this.) # emerge --info Portage 2.3.11-prefix (python 3.5.2-final-0, prefix/linux/amd64, gcc-5.3.0, unavailable, 2.6.32-696.10.3.el6.x86_64 x86_64) ================================================================= System uname: Linux-2.6.32-696.10.3.el6.x86_64-x86_64-Intel-R-_Xeon-R-_CPU_X5355_@_2.66GHz-with-centos-6.9-Final KiB Mem: 14620696 total, 8485036 free KiB Swap: 4112380 total, 4112380 free Timestamp of repository gentoo_prefix: Wed, 04 Oct 2017 14:27:04 +0000 sh bash 4.3_p48-r1 ld GNU ld (Gentoo 2.28.1 p1.0) 2.28.1 ccache version 3.1.6 [disabled] app-shells/bash: 4.3_p48-r1::gentoo_prefix dev-lang/perl: 5.24.3::gentoo_prefix dev-lang/python: 2.7.12::Gentoo-Prefix-Overlay, 3.5.2::Gentoo-Prefix-Overlay dev-util/cmake: 3.9.3::gentoo_prefix dev-util/pkgconfig: 0.29.1::gentoo_prefix sys-devel/autoconf: 2.13::gentoo_prefix, 2.69-r4::gentoo_prefix sys-devel/automake: 1.14.1-r1::gentoo_prefix, 1.15.1-r1::gentoo_prefix sys-devel/binutils: 2.28.1::gentoo_prefix sys-devel/gcc: 5.3.0::gentoo_prefix sys-devel/gcc-config: 1.8-r01.1::gentoo_prefix sys-devel/libtool: 2.4.6-r4::gentoo_prefix sys-devel/make: 4.2.1-r1::gentoo_prefix sys-kernel/linux-headers: 4.13::gentoo_prefix (virtual/os-headers) Repositories: gentoo_prefix location: /home/test/gentoo/usr/portage sync-type: rsync sync-uri: rsync://rsync.prefix.bitzolder.nl/gentoo-portage-prefix priority: -1000 sync-rsync-extra-opts: Gentoo-Prefix-Overlay location: /home/test/gentoo-prefix-overlay masters: gentoo_prefix priority: 0 ACCEPT_KEYWORDS="~amd64-linux" ACCEPT_LICENSE="* -@EULA" CBUILD="x86_64-pc-linux-gnu" CFLAGS="-O2 -pipe -O2 -pipe" CHOST="x86_64-pc-linux-gnu" CONFIG_PROTECT="/etc" CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/terminfo" CXXFLAGS="-O2 -pipe -O2 -pipe" DISTDIR="/home/test/gentoo/usr/portage/distfiles" FCFLAGS="-O2 -pipe" FEATURES="assume-digests binpkg-logs collision-protect config-protect-if-modified distlocks ebuild-locks fixlafiles force-prefix merge-sync news parallel-fetch preserve-libs protect-owned sfperms strict unknown-features-warn unmerge-logs unmerge-orphans unprivileged" FFLAGS="-O2 -pipe" GENTOO_MIRRORS="http://distfiles.gentoo.org" LDFLAGS="-Wl,-O1" MAKEOPTS="-j5" PKGDIR="/home/test/gentoo/usr/portage/packages" PORTAGE_CONFIGROOT="/home/test/gentoo/" 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="/home/test/gentoo/var/tmp" USE="amd64 berkdb bindist bzip2 cli cracklib crypt cxx dri fortran gdbm iconv ipv6 modules ncurses nls nptl openmp pcre prefix prefix-guest readline seccomp session ssl tcpd unicode 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="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="libinput keyboard mouse" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LIBREOFFICE_EXTENSIONS="presenter-console presenter-minimizer" OFFICE_IMPLEMENTATION="libreoffice" PHP_TARGETS="php5-6" POSTGRES_TARGETS="postgres9_5" PYTHON_SINGLE_TARGET="python3_5" PYTHON_TARGETS="python2_7 python3_5" RUBY_TARGETS="ruby22 ruby24" USERLAND="GNU" 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: CC, CPPFLAGS, CTARGET, CXX, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LANG, LC_ALL, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS
Suggested patch is pretty simple: --- a/nss-3.33.ebuild 2017-09-21 18:08:10.000000000 -0400 +++ b/nss-3.33.ebuild 2017-10-09 18:02:32.171471643 -0400 @@ -182,6 +182,7 @@ export NSDISTMODE=copy export NSS_ENABLE_ECC=1 export FREEBL_NO_DEPEND=1 + export FREEBL_LOWHASH=1 export ASFLAGS="" local d
Created attachment 498390 [details] build.log from "emerge -1v util-linux"
Created attachment 498392 [details] config.log from "emerge -1v util-linux"
Adding mozilla team per xdej's suggestion on IRC
I don't feel qualified enough to evaluate this decision; it seems simple enough but I don't know enough about NSS to know what drawbacks there would be to exposing these additional symbols on all of the regular (non-prefix) installs out there. Is it sufficient to add FREEBL_NOHASH to your prefix's make.conf? if that's the case it might be better to see if it can be added to the prefix profiles instead of adjusting the ebuilds The other option might be to see if you can somehow use the prefix-installed libc (and therefore libcrypt) instead of CentOS's -- some sort of LD_PRELOAD adjustment perhaps? Again, I'm not familiar enough with the viability of doing this to know if it would just crash everything or not.
Is this still an issue with (as I hope you would be using) CentOS 7?
(In reply to Jacob Godserv from comment #1) > Suggested patch is pretty simple: > > --- a/nss-3.33.ebuild 2017-09-21 18:08:10.000000000 -0400 > +++ b/nss-3.33.ebuild 2017-10-09 18:02:32.171471643 -0400 > @@ -182,6 +182,7 @@ > export NSDISTMODE=copy > export NSS_ENABLE_ECC=1 > export FREEBL_NO_DEPEND=1 > + export FREEBL_LOWHASH=1 > export ASFLAGS="" > > local d Has been pushed to the mozilla overlay for testing. Please use from there until we move to tree please.