• Home
  • Raw
  • Download

Lines Matching +full:compiler +full:- +full:version

27 from distutils.version import LooseVersion
79 # Query the compiler about its preprocessor directives and return all of them as
82 args = [env['compiler']]
83 # Pass the CXXFLAGS varables to the compile, in case we've used "-m32" to
87 args += ['-E', '-dM', '-']
89 # Instruct the compiler to dump all its preprocessor macros.
101 # Filter out non-matches.
105 # Query the target architecture of the compiler. The 'target' architecture of
106 # the compiler used to build VIXL is considered to be the 'host' architecture of
121 # Class representing the compiler toolchain and version.
128 self.compiler = 'clang'
129 self.version = '{}.{}'.format(major, minor)
133 self.compiler = 'gcc'
134 self.version = '{}.{}'.format(major, minor)
137 # need to teach this class how to extract version information in order to
139 self.compiler = None
140 self.version = None
143 return "{}-{}".format(self.compiler, self.version)
150 # - Equality
152 # If the description does not have a version number, then we compare the
153 # compiler names. For instance, "clang-3.6" is still equal to "clang" but of
156 # - Ordering
158 # Asking whether a compiler is lower than another depends on the version
160 # "Is my compiler in the allowed range?". So with this in mind, comparing
162 # same, then the version numbers are compared. Of course, we cannot use
163 # ordering operators if no version number is provided.
169 # The user may not have provided a version, let's see if it matches the
170 # compiler.
171 return self.compiler == description
189 # "{compiler}-{major}.{minor}". The comparison is done using the provided
192 match = re.search('^(\S+)-(.*?)$', description)
194 raise Exception("A version number is required when comparing compilers")
195 compiler, version = match.group(1), match.group(2)
197 # version numbers.
198 return self.compiler == compiler and \
199 operator(LooseVersion(self.version), LooseVersion(version))