diff options
author | Christoph Behle <behlec@gmail.com> | 2017-12-16 14:52:08 +0100 |
---|---|---|
committer | Christoph Behle <behlec@gmail.com> | 2017-12-16 14:52:08 +0100 |
commit | c6acf75617a8c200f8c8cbe11c3342228842be05 (patch) | |
tree | 00ef82b6f4927b21cae6d71d5685fc03f8dc7b2e /mesonbuild/compilers/compilers.py | |
parent | cc952b055a8ae882a07019731a015f41b62d1f31 (diff) | |
download | meson-c6acf75617a8c200f8c8cbe11c3342228842be05.zip meson-c6acf75617a8c200f8c8cbe11c3342228842be05.tar.gz meson-c6acf75617a8c200f8c8cbe11c3342228842be05.tar.bz2 |
More version information for compilers.
See issue #2762
Adds full_version to class Compiler. If set full_version will be printed
additionally.
Added support for CCompiler and CPPCompiler
Added support for gcc/g++, clang/clang++, icc.
Diffstat (limited to 'mesonbuild/compilers/compilers.py')
-rw-r--r-- | mesonbuild/compilers/compilers.py | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/mesonbuild/compilers/compilers.py b/mesonbuild/compilers/compilers.py index 011c222..6941649 100644 --- a/mesonbuild/compilers/compilers.py +++ b/mesonbuild/compilers/compilers.py @@ -598,7 +598,7 @@ class Compiler: # compiler or the C library. Currently only used for MSVC. ignore_libs = () - def __init__(self, exelist, version): + def __init__(self, exelist, version, **kwargs): if isinstance(exelist, str): self.exelist = [exelist] elif isinstance(exelist, list): @@ -612,6 +612,10 @@ class Compiler: self.can_compile_suffixes = set(self.file_suffixes) self.default_suffix = self.file_suffixes[0] self.version = version + if 'full_version' in kwargs: + self.full_version = kwargs['full_version'] + else: + self.full_version = None self.base_options = [] def __repr__(self): |