summaryrefslogtreecommitdiff
path: root/eclass
diff options
context:
space:
mode:
authorSam James <sam@gentoo.org>2022-07-14 06:41:21 +0100
committerSam James <sam@gentoo.org>2022-07-26 05:41:22 +0100
commit2884a7d0131749f8c54c9dac3ee63ef62e4afbf1 (patch)
tree83971dea21bdf0ebf4badbd8970ce03645ee6226 /eclass
parentflag-o-matic.eclass: add bug references re -Qunused-arguments (diff)
downloadgentoo-2884a7d0131749f8c54c9dac3ee63ef62e4afbf1.tar.gz
gentoo-2884a7d0131749f8c54c9dac3ee63ef62e4afbf1.tar.bz2
gentoo-2884a7d0131749f8c54c9dac3ee63ef62e4afbf1.zip
flag-o-matic.eclass: respect -fuse-ld in test-flags-CCLD
Closes: https://bugs.gentoo.org/832377 Signed-off-by: Sam James <sam@gentoo.org>
Diffstat (limited to 'eclass')
-rw-r--r--eclass/flag-o-matic.eclass9
1 files changed, 9 insertions, 0 deletions
diff --git a/eclass/flag-o-matic.eclass b/eclass/flag-o-matic.eclass
index 14dbd2bf37de..7319326c7ad8 100644
--- a/eclass/flag-o-matic.eclass
+++ b/eclass/flag-o-matic.eclass
@@ -574,6 +574,15 @@ _test-flag-PROG() {
c+ld)
in_ext='c'
in_src='int main(void) { return 0; }'
+
+ if is-ldflagq -fuse-ld=* ; then
+ # Respect linker chosen by user so we don't
+ # end up giving false results by checking
+ # with default linker. bug #832377
+ fuse_ld_value=$(get-flag -fuse-ld=*)
+ cmdline_extra+=(${fuse_ld_value})
+ fi
+
cmdline_extra+=(-xc)
;;
esac