sys-libs/glibc: avoid libm-2.26.so symlink clash on merged /usr, bug #627378
The problem in bug #627378 manifests as libm-2.26.so file corruption:
Before the change glibc package contained a 'libm-2.26.so'
symlink from '/usr/lib64' to '/lib64':
$ equery f sys-libs/glibc | sed 's@usr/lib@lib@g' | sort | uniq -d
/lib64/libm-2.26.so
When both are the same directory all depends on the merge order:
- symlink first, then real file. real file overwrites symlink, all is good
- real file first, then symlink. symlink overwrites the file and points to
itself. Binaries linked against libm fail to start.
The change is to get rid of symlink (symlink was a workaround to portage's
QA check) and move 'libm-2.26.a' from '/usr/lib64' to '/usr/lib64/glibc-<pv>'.
Reported-by: Duncan
Fixed-by: Matija Skala
Closes: https://bugs.gentoo.org/627378
Closes: https://github.com/gentoo/gentoo/pull/4268