Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 530924 - sys-libs/glibc-2.20: no ldconfig with sh linked to zsh
Summary: sys-libs/glibc-2.20: no ldconfig with sh linked to zsh
Status: RESOLVED INVALID
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Core system (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Gentoo Toolchain Maintainers
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-11-28 00:32 UTC by tokiclover
Modified: 2014-11-28 15:53 UTC (History)
1 user (show)

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


Attachments
environment.bz2 (of ebuild $EBUILD configure) (environment.bz2,33.12 KB, application/x-bzip)
2014-11-28 00:36 UTC, tokiclover
Details
build.log.bz2 (of ebuild $EBUILD configure) (build.log.bz2,4.43 KB, application/x-bzip)
2014-11-28 00:36 UTC, tokiclover
Details
package files (installed files of glibc-2.20) (glibc-pkg-list.bz2,6.75 KB, application/x-bzip)
2014-11-28 00:39 UTC, tokiclover
Details

Note You need to log in before you can comment on or make changes to this bug.
Description tokiclover 2014-11-28 00:32:21 UTC
I've just updated glibc and it brokes my system because there is no ldconfig binary. I was just surprised to see that any further compilation or simply running any commands failed because of missings libraries... So I made a few links manually, namely libgcc_s.so and libstd++.so to `/usr/lib' to be able to run a few commands...

Well, to make a short story short, I've decompressed sys-libs/glibc-2.19-r1 to be able to keep my system alive for now and I'm looking for a solution.

I've alreay recompiled the package and nothing changed. I've checked the tbz2 and no ldconfig to be found. Maybe other components are missing but I have no clue on that.

I mau manually remove at hand glibc-2.20 and /var/db/pkg/sys-libs/glibc-2.20 and trick a recompilation of 2.19.

Reproducible: Always




emerge --info

Portage 2.2.14 (python 2.7.8-final-0, hardened/linux/amd64, gcc-4.8.3, glibc-2.20, 3.17.2-git x86_64)
=================================================================
System uname: Linux-3.17.2-git-x86_64-Intel-R-_Core-TM-_i7-4700HQ_CPU_@_2.40GHz-with-gentoo-2.2
KiB Mem:    16378480 total,   5532832 free
KiB Swap:          0 total,         0 free
Timestamp of tree: Thu, 27 Nov 2014 00:45:01 +0000
ld GNU ld (Gentoo 2.24 p1.4) 2.24
app-shells/bash:          4.3_p30
dev-java/java-config:     2.2.0
dev-lang/perl:            5.20.1-r1
dev-lang/python:          2.7.8, 3.3.5-r1, 3.4.2
dev-util/cmake:           3.0.2
dev-util/pkgconfig:       0.28-r2
sys-apps/baselayout:      2.2
sys-apps/openrc:          0.13.1
sys-apps/sandbox:         2.6-r1
sys-devel/autoconf:       2.13, 2.69
sys-devel/automake:       1.11.6, 1.14.1
sys-devel/binutils:       2.24-r3
sys-devel/gcc:            4.8.3
sys-devel/gcc-config:     1.8
sys-devel/libtool:        2.4.3-r2
sys-devel/make:           4.1-r1
sys-kernel/linux-headers: 3.17-r1 (virtual/os-headers)
sys-libs/glibc:           2.20
Repositories: gentoo mpd x11 bar multimedia
Installed sets: @X, @archive, @daw, @fonts, @gtk, @multimedia, @openbox, @portage, @sys, @themes, @vim
ACCEPT_KEYWORDS="amd64 ~amd64"
ACCEPT_LICENSE="* -@EULA"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-O2 -march=native -pipe -floop-interchange -ftree-loop-distribution -floop-strip-mine -floop-block -ftree-vectorize"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/share/gnupg/qualified.txt /var/lib/hsqldb"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/env.d/java/ /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo /etc/texmf/language.dat.d /etc/texmf/language.def.d /etc/texmf/updmap.d /etc/texmf/web2c"
CXXFLAGS="-O2 -march=native -pipe -floop-interchange -ftree-loop-distribution -floop-strip-mine -floop-block -ftree-vectorize"
DISTDIR="/var/src"
FCFLAGS="-O2 -pipe"
FEATURES="assume-digests binpkg-logs buildpkg 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="ftp://ftp.free.fr/mirrors/ftp.gentoo.org/ ftp://mirror.ovh.net/gentoo-distfiles/ http://gentoo.mneisen.org/ ftp://mirror.mdfnet.se/gentoo ftp://de-mirror.org/gentoo/"
INSTALL_MASK="/etc/systemd /lib*/systemd /usr/lib*/systemd"
LANG="en_US.UTF-8"
LDFLAGS="-Wl,-O1 -Wl,--as-needed"
MAKEOPTS="-j8"
PKGDIR="/var/pkg"
PORTAGE_CONFIGROOT="/"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/var/portage"
PORTDIR_OVERLAY="/var/lib/layman/mpd /var/lib/layman/x11 /var/lib/layman/bar /var/lib/layman/multimedia"
SYNC="rsync://rsync.europe.gentoo.org/gentoo-portage"
USE="X a52 aac acl acpi alsa amd64 atlas audiofile avi avx avx2 bash-completion berkdb blas bzip2 cairo caps cdda cddb cdr cjk clang cleartype cli cracklib crypt css cups curl cxx dbus device-mapper directfb djvu dri dv dvd dvdr exif expat fbcon ffmpeg fftw flac fltk fontconfig fontforge ftp gd gdbm gif git glut gpm graphite graphviz gtk gtk2 gzip hardened hddtemp iconv icu idn ieee1394 imagemagick imlib infinality ipv6 jack java javascript jbig jpeg jpeg2k justify kerberos ladspa lame lapack lash lcms libass libnotify libsamplerate lm_sensors lto lua luajit lz4 lzma lzo lzop mad matroska mbox mmx mng modplug modules mp3 mp4 mpeg multilib musepack ncurses nls nptl nsplugin ntp ogg opengl openldap openmp openssl openvg oss pam pax_kernel pcre pdf perl png postscript python readline savedconfig session smp sndfile snmp sockets sqlite sse sse2 sse3 sse4_1 sse4_2 ssl ssse3 startup-notification svg symlink tcpd theora threads tiff truetype udev unicode urandom usb vaapi vdpau vim vim-syntax vorbis wavpack wayland wifi x264 xattr xft xinerama xinetd xml xorg xpm xtpax xv xvid xvmc xz zip zlib zsh-completion" ABI_X86="64" ALSA_CARDS="cmipci hda-intel usb-audio" 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" 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" GRUB_PLATFORMS="emu efi-32 efi-64 qemu pc" INPUT_DEVICES="evdev mouse keyboard synaptics vmmouse" KERNEL="linux" LCD_DEVICES="lcdm001 mtxorb ncurses text" LIBREOFFICE_EXTENSIONS="scripting-javascript nlpsolver wiki-publisher" LINGUAS="en fr" OFFICE_IMPLEMENTATION="libreoffice" PHP_TARGETS="php5-5" PYTHON_SINGLE_TARGET="python2_7" PYTHON_TARGETS="python2_7 python3_3" QEMU_SOFTMMU_TARGETS="aarch64 arm i386 ppc ppc64 sparc sparc64 s390x" QEMU_USER_TARGETS="aarch64 arm i386 ppc ppc64 sparc sparc64 s390x" RUBY_TARGETS="ruby21" SANE_BACKENDS="canon canon630 canon_dr" USERLAND="GNU" VIDEO_CARDS="intel i915 i965 nouveau vesa vmware" XTABLES_ADDONS="ipv4options ipset iface ipmark dhcpmac"
Unset:  CPPFLAGS, CTARGET, EMERGE_DEFAULT_OPTS, LC_ALL, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS, USE_PYTHON
Comment 1 tokiclover 2014-11-28 00:36:15 UTC
Created attachment 390436 [details]
environment.bz2 (of ebuild $EBUILD configure)
Comment 2 tokiclover 2014-11-28 00:36:52 UTC
Created attachment 390438 [details]
build.log.bz2 (of ebuild $EBUILD configure)
Comment 3 tokiclover 2014-11-28 00:39:06 UTC
Created attachment 390440 [details]
package files (installed files of glibc-2.20)
Comment 4 Mike Gilbert gentoo-dev 2014-11-28 02:31:49 UTC
Do you have a full build log for glibc-2.20? It would be interesting to see if ldconfig even gets built.

If you don't have a full log, please generate one. Add PORT_LOGDIR="/var/log/portage" to make.conf, and then do emerge --buildpkgonly sys-libs/glibc. Your log will be saved in /var/log/portage.
Comment 5 Mike Gilbert gentoo-dev 2014-11-28 02:36:10 UTC
I found bug 180259. What is your /bin/sh linked to?
Comment 6 tokiclover 2014-11-28 09:31:56 UTC
(In reply to Mike Gilbert from comment #5)
> I found bug 180259. What is your /bin/sh linked to?

You guess... I was going to rebuild 2.20 for the third time with sh linked to bash.

There are a few annoying packages that does have bashisms in the build scripts without any explicit bash requirement. Notably media-video/ffmpeg with 6k lines hand written configure script with a nasty issue. (I looked at it two times already without any hint of the issue even with `emulate sh; setopt SH_WORD_SPLIT' addition.)

I managed managed to bring back glibc-2.19-r1 plus a dozen recompilation.
Comment 7 tokiclover 2014-11-28 09:45:59 UTC
Thanks for the hint Mike!

glibc des require bash to build the package.

PS:
I created `/etc/portage/package.bashism' and added:
--
pre_pkg_setup() {
  ...
  if grep -q "${CATEGORY}/${PN}" /etc/portage/package.bashism &&
    [[ "${SHELL}" == "/bin/zsh" ]]; then
    ln -f -s /bin/bash /bin/sh
  fi
  ..
}
--
in `/etc/portage/bashrc'. Well, the remaining issue is making that link back to zsh... because there is no safe post installation function that I can use without overriding a possible defined function.
Comment 8 tokiclover 2014-11-28 10:15:08 UTC
Darn, now the system cannot find libgcc_s and libstd++ if I remove the links I had put `/usr/lib'. I already runned `. /etc/profile; env-update' a coule of time to regenerate `/etc/ld.so.cache' to no avail.
Comment 9 tokiclover 2014-11-28 10:20:20 UTC
`/etc/ld.so.conf.d/05gcc-x86_64-pc-linux-gnu.conf' is completly empty. What does maintain it?
Comment 10 tokiclover 2014-11-28 10:22:55 UTC
gcc-config obviously. FIXED at last.
Comment 11 Mike Gilbert gentoo-dev 2014-11-28 15:53:29 UTC
I think you are misusing the term "bashism" here. I don't think building glibc actually requires bash as /bin/sh; it requires a shell which conforms to POSIX. It would probably work fine with dash or mksh.

I would highly recommend that you change your /bin/sh to a POSIX conforming shell rather than try to work around each package that happens to fail with zsh.

If you are going to intentionally break your system, then please be aware of this before filing future bug reports.