diff options
author | Jussi Pakkanen <jpakkane@gmail.com> | 2019-06-10 01:49:16 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-06-10 01:49:16 +0300 |
commit | 06df6e463f3d7f62676f8f9ce0cf81fbb4058eaf (patch) | |
tree | d6e80b4aa73a30e31861d35aa00127fd625fcca8 /mesonbuild/compilers/compilers.py | |
parent | 6b4b601eafc5320e62060f39da5acad7c3007942 (diff) | |
parent | 6d6af46edcb765d7046533fdad4d03b0c0c9cd64 (diff) | |
download | meson-06df6e463f3d7f62676f8f9ce0cf81fbb4058eaf.zip meson-06df6e463f3d7f62676f8f9ce0cf81fbb4058eaf.tar.gz meson-06df6e463f3d7f62676f8f9ce0cf81fbb4058eaf.tar.bz2 |
Merge pull request #4010 from Ericson2314/purge-cross-conditional-preview
Purge much `is_cross` and `<things>_cross` without changing user interfaces---includes on #5263
Diffstat (limited to 'mesonbuild/compilers/compilers.py')
-rw-r--r-- | mesonbuild/compilers/compilers.py | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/mesonbuild/compilers/compilers.py b/mesonbuild/compilers/compilers.py index 3ad80fe..0a228b4 100644 --- a/mesonbuild/compilers/compilers.py +++ b/mesonbuild/compilers/compilers.py @@ -21,7 +21,7 @@ from .. import coredata from .. import mlog from .. import mesonlib from ..mesonlib import ( - EnvironmentException, MesonException, OrderedSet, + EnvironmentException, MachineChoice, MesonException, OrderedSet, version_compare, Popen_safe ) from ..envconfig import ( @@ -871,7 +871,7 @@ class Compiler: # manually searched. internal_libs = () - def __init__(self, exelist, version, **kwargs): + def __init__(self, exelist, version, for_machine: MachineChoice, **kwargs): if isinstance(exelist, str): self.exelist = [exelist] elif isinstance(exelist, list): @@ -889,6 +889,7 @@ class Compiler: self.full_version = kwargs['full_version'] else: self.full_version = None + self.for_machine = for_machine self.base_options = [] def __repr__(self): @@ -2183,7 +2184,7 @@ class ClangCompiler(GnuLikeCompiler): class ArmclangCompiler: def __init__(self, compiler_type): - if not self.is_cross: + if self.is_cross: raise EnvironmentException('armclang supports only cross-compilation.') # Check whether 'armlink.exe' is available in path self.linker_exe = 'armlink.exe' |