configure should not prefer ld.lld over ld.gold on Linux
Summary
As first reported indirectly in #22195 (closed), configure (m4/find_ld.m4) always prefers the lld linker over gold or bfd. I don't think this is a good choice on Linux, at least if one is using a GNU toolchain.
Steps to reproduce
Run ./configure on Linux with lld (and ld.gold) installed: stage0 is configured to use ld.lld instead of ld.gold.
Expected behavior
ld.gold to be preferred on Linux.
Environment
- GHC version used: ghc-9.4
Optional:
- Operating System: Fedora Linux
- System Architecture: x86_64