diff options
author | Dylan Baker <dylan@pnwbakers.com> | 2019-11-26 12:31:46 -0800 |
---|---|---|
committer | Dylan Baker <dylan@pnwbakers.com> | 2019-12-02 16:39:06 -0800 |
commit | 0ae911d893485c4b4c5f90f9d6b5f820dc1f7672 (patch) | |
tree | 9a60be838a917a909f35018a4a3d5a7b2313183f /mesonbuild | |
parent | ab5ea9e8b60f043551a2920f70d6f3a1532d5bf8 (diff) | |
download | meson-0ae911d893485c4b4c5f90f9d6b5f820dc1f7672.tar.gz |
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.
Diffstat (limited to 'mesonbuild')
-rw-r--r-- | mesonbuild/environment.py | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/mesonbuild/environment.py b/mesonbuild/environment.py index 83c693502..4c07e5891 100644 --- a/mesonbuild/environment.py +++ b/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], |