commit: 6b116320b6cbd7edc3a56c4ff85b4a7b23f7d3ea Author: Sam James <sam <AT> gentoo <DOT> org> AuthorDate: Thu Nov 6 12:22:38 2025 +0000 Commit: Sam James <sam <AT> gentoo <DOT> org> CommitDate: Thu Nov 6 12:22:38 2025 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=6b116320
sys-devel/binutils: don't try -static-pie at all in the sanity check rcrt1.o isn't always available and static-pie support can be buggy (which is why it's interesting to test, but if we can't rely on it being available, we also can't rely on it at least without some checking being OK in some glibc version too). Need to try again with a has_version check for glibc[static-pie] at least and possibly more. Closes: https://bugs.gentoo.org/965478 Signed-off-by: Sam James <sam <AT> gentoo.org> sys-devel/binutils/binutils-2.45-r1.ebuild | 3 ++- sys-devel/binutils/binutils-2.45.9999.ebuild | 3 ++- sys-devel/binutils/binutils-2.45.ebuild | 3 ++- sys-devel/binutils/binutils-9999.ebuild | 3 ++- 4 files changed, 8 insertions(+), 4 deletions(-) diff --git a/sys-devel/binutils/binutils-2.45-r1.ebuild b/sys-devel/binutils/binutils-2.45-r1.ebuild index 4f892fd2f3c3..d4beb896bc17 100644 --- a/sys-devel/binutils/binutils-2.45-r1.ebuild +++ b/sys-devel/binutils/binutils-2.45-r1.ebuild @@ -553,7 +553,8 @@ binutils_sanity_check() { local opt opt2 # TODO: test multilib variants? for opt in '' '-O2' ; do - for opt2 in '-static' '-static-pie' '-fno-PIE -no-pie' ; do + # TODO: add static-pie? we need to check if support exists, though (bug #965478) + for opt2 in '-static' '-fno-PIE -no-pie' ; do $(tc-getCC) ${opt} ${opt2} -B"${ED}${BINPATH}" "${T}"/number.c "${T}"/test.c -o "${T}"/test if "${T}"/test | grep -q "Hello Gentoo! Your magic number is: 42" ; then :; diff --git a/sys-devel/binutils/binutils-2.45.9999.ebuild b/sys-devel/binutils/binutils-2.45.9999.ebuild index 813f206a020f..6bef4f37b48f 100644 --- a/sys-devel/binutils/binutils-2.45.9999.ebuild +++ b/sys-devel/binutils/binutils-2.45.9999.ebuild @@ -557,7 +557,8 @@ binutils_sanity_check() { local opt opt2 # TODO: test multilib variants? for opt in '' '-O2' ; do - for opt2 in '-static' '-static-pie' '-fno-PIE -no-pie' ; do + # TODO: add static-pie? we need to check if support exists, though (bug #965478) + for opt2 in '-static' '-fno-PIE -no-pie' ; do $(tc-getCC) ${opt} ${opt2} -B"${ED}${BINPATH}" "${T}"/number.c "${T}"/test.c -o "${T}"/test if "${T}"/test | grep -q "Hello Gentoo! Your magic number is: 42" ; then :; diff --git a/sys-devel/binutils/binutils-2.45.ebuild b/sys-devel/binutils/binutils-2.45.ebuild index 6218370c5763..ca5584f86d46 100644 --- a/sys-devel/binutils/binutils-2.45.ebuild +++ b/sys-devel/binutils/binutils-2.45.ebuild @@ -555,7 +555,8 @@ binutils_sanity_check() { local opt opt2 # TODO: test multilib variants? for opt in '' '-O2' ; do - for opt2 in '-static' '-static-pie' '-fno-PIE -no-pie' ; do + # TODO: add static-pie? we need to check if support exists, though (bug #965478) + for opt2 in '-static' '-fno-PIE -no-pie' ; do $(tc-getCC) ${opt} ${opt2} -B"${ED}${BINPATH}" "${T}"/number.c "${T}"/test.c -o "${T}"/test if "${T}"/test | grep -q "Hello Gentoo! Your magic number is: 42" ; then :; diff --git a/sys-devel/binutils/binutils-9999.ebuild b/sys-devel/binutils/binutils-9999.ebuild index 813f206a020f..6bef4f37b48f 100644 --- a/sys-devel/binutils/binutils-9999.ebuild +++ b/sys-devel/binutils/binutils-9999.ebuild @@ -557,7 +557,8 @@ binutils_sanity_check() { local opt opt2 # TODO: test multilib variants? for opt in '' '-O2' ; do - for opt2 in '-static' '-static-pie' '-fno-PIE -no-pie' ; do + # TODO: add static-pie? we need to check if support exists, though (bug #965478) + for opt2 in '-static' '-fno-PIE -no-pie' ; do $(tc-getCC) ${opt} ${opt2} -B"${ED}${BINPATH}" "${T}"/number.c "${T}"/test.c -o "${T}"/test if "${T}"/test | grep -q "Hello Gentoo! Your magic number is: 42" ; then :;
