commit: 55b55f614b0ff516547d4ffd111a7a9efa27097a
Author: Andreas K. Hüttel <dilfridge <AT> gentoo <DOT> org>
AuthorDate: Sat Jan 29 17:49:35 2022 +0000
Commit: Andreas K. Hüttel <dilfridge <AT> gentoo <DOT> org>
CommitDate: Sat Jan 29 17:49:46 2022 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=55b55f61
sys-libs/glibc: Run sanity tests after setting up the environment
It makes no sense to use the wrong compiler, for example.
Package-Manager: Portage-3.0.30, Repoman-3.0.3
Signed-off-by: Andreas K. Hüttel <dilfridge <AT> gentoo.org>
sys-libs/glibc/glibc-9999.ebuild | 15 ++++++---------
1 file changed, 6 insertions(+), 9 deletions(-)
diff --git a/sys-libs/glibc/glibc-9999.ebuild b/sys-libs/glibc/glibc-9999.ebuild
index f47aef2712e1..b97550bf18f0 100644
--- a/sys-libs/glibc/glibc-9999.ebuild
+++ b/sys-libs/glibc/glibc-9999.ebuild
@@ -260,8 +260,8 @@ do_compile_test() {
rm -f glibc-test*
printf '%b' "$*" > glibc-test.c
- # Most of the time CC is already set, but not in early sanity checks.
- nonfatal emake glibc-test CC="${CC-$(tc-getCC ${CTARGET})}"
+ # We assume CC is already set up.
+ nonfatal emake glibc-test
ret=$?
popd >/dev/null
@@ -743,7 +743,7 @@ sanity_prechecks() {
ebegin "Checking that IA32 emulation is enabled in the
running kernel"
echo 'int main(){return 0;}' >
"${T}/check-ia32-emulation.c"
local STAT
- if "${CC-${CHOST}-gcc}" ${CFLAGS_x86}
"${T}/check-ia32-emulation.c" -o "${T}/check-ia32-emulation.elf32"; then
+ if ${CC-${CHOST}-gcc} ${CFLAGS_x86}
"${T}/check-ia32-emulation.c" -o "${T}/check-ia32-emulation.elf32"; then
"${T}/check-ia32-emulation.elf32"
STAT=$?
else
@@ -809,9 +809,6 @@ upgrade_warning() {
# pkg_pretend
pkg_pretend() {
- # All the checks...
- einfo "Checking general environment sanity."
- sanity_prechecks
upgrade_warning
}
@@ -823,13 +820,13 @@ pkg_setup() {
# src_unpack
src_unpack() {
- # Consistency is not guaranteed between pkg_ and src_ ...
+ setup_env
+
+ einfo "Checking general environment sanity."
sanity_prechecks
use multilib-bootstrap && unpack
gcc-multilib-bootstrap-${GCC_BOOTSTRAP_VER}.tar.xz
- setup_env
-
if [[ ${PV} == 9999* ]] ; then
EGIT_REPO_URI="https://anongit.gentoo.org/git/proj/toolchain/glibc-patches.git"
EGIT_CHECKOUT_DIR=${WORKDIR}/patches-git