This is an auto-filled bug because app-misc/ondir calls cc directly.
The issue was originally discovered on amd64, but it may be reproducible on other arches as well.
If you think that a different summary clarifies the issue better, feel free to change it.
Attached build log and emerge --info.
If you think it doesn't make sense fix these type of issues, I'd like to point out that won't be possible use a different CC implementation (like clang) by setting the CC variable. So this issue has been reproduced by setting the CC variable to x86_64-pc-linux-gnu-gcc and by removing the /usr/bin/cc - /usr/bin/gcc binaries.
Created attachment 637868 [details]
build log and emerge --info
The bug has been closed via the following commit(s):
Author: Patrice Clement <email@example.com>
AuthorDate: 2020-06-21 07:45:03 +0000
Commit: Patrice Clement <firstname.lastname@example.org>
CommitDate: 2020-06-21 07:54:52 +0000
app-misc/ondir: honour CFLAGS, LD and LDFLAGS.
Package-Manager: Portage-2.3.99, Repoman-2.3.22
Signed-off-by: Patrice Clement <email@example.com>
app-misc/ondir/ondir-0.2.4.ebuild | 10 ++++++----
1 file changed, 6 insertions(+), 4 deletions(-)