environment: Add a special error case for getting GNU link.exe

Since I spent three days banging my head against this it seems
reasonable that other people might also run into this problem. It can
happen if you're trying to use microsoft's link.exe, but also have the
dmd bin directory at the tail of your %PATH%, among other reasons.
pull/6207/head
Dylan Baker 5 years ago
parent ab5ea9e8b6
commit 0ae911d893
  1. 5
      mesonbuild/environment.py

@ -781,6 +781,11 @@ class Environment:
for_machine, [], machine=target, exelist=compiler,
prefix=comp_class.LINKER_PREFIX if use_linker_prefix else [],
version=search_version(out))
elif 'GNU coreutils' in o:
raise EnvironmentException(
"Found GNU link.exe instead of MSVC link.exe. This link.exe "
"is not a linker. You may need to reorder entries to your "
"%PATH% variable to resolve this.")
raise EnvironmentException('Unable to determine dynamic linker')
def _guess_nix_linker(self, compiler: typing.List[str], comp_class: typing.Type[Compiler],

Loading…
Cancel
Save