aboutsummaryrefslogtreecommitdiff
path: root/mesonbuild/compilers
diff options
context:
space:
mode:
Diffstat (limited to 'mesonbuild/compilers')
-rw-r--r--mesonbuild/compilers/c.py4
-rw-r--r--mesonbuild/compilers/compilers.py4
-rw-r--r--mesonbuild/compilers/cpp.py4
3 files changed, 6 insertions, 6 deletions
diff --git a/mesonbuild/compilers/c.py b/mesonbuild/compilers/c.py
index c8e473a..a6ae4af 100644
--- a/mesonbuild/compilers/c.py
+++ b/mesonbuild/compilers/c.py
@@ -1179,7 +1179,7 @@ class GnuCCompiler(GnuCompiler, CCompiler):
['none', 'c89', 'c99', 'c11',
'gnu89', 'gnu99', 'gnu11'],
'none')})
- if self.compiler_type == CompilerType.GCC_MINGW:
+ if self.compiler_type.is_windows_compiler:
opts.update({
'c_winlibs': coredata.UserArrayOption('c_winlibs', 'Standard Win libraries to link against',
gnu_winlibs), })
@@ -1193,7 +1193,7 @@ class GnuCCompiler(GnuCompiler, CCompiler):
return args
def get_option_link_args(self, options):
- if self.compiler_type == CompilerType.GCC_MINGW:
+ if self.compiler_type.is_windows_compiler:
return options['c_winlibs'].value[:]
return []
diff --git a/mesonbuild/compilers/compilers.py b/mesonbuild/compilers/compilers.py
index 68fbbfa..137b3f7 100644
--- a/mesonbuild/compilers/compilers.py
+++ b/mesonbuild/compilers/compilers.py
@@ -1482,13 +1482,13 @@ class GnuCompiler(GnuLikeCompiler):
raise RuntimeError('Module definitions file should be str')
# On Windows targets, .def files may be specified on the linker command
# line like an object file.
- if self.compiler_type in (CompilerType.GCC_CYGWIN, CompilerType.GCC_MINGW):
+ if self.compiler_type.is_windows_compiler:
return [defsfile]
# For other targets, discard the .def file.
return []
def get_gui_app_args(self, value):
- if self.compiler_type in (CompilerType.GCC_CYGWIN, CompilerType.GCC_MINGW) and value:
+ if self.compiler_type.is_windows_compiler and value:
return ['-mwindows']
return []
diff --git a/mesonbuild/compilers/cpp.py b/mesonbuild/compilers/cpp.py
index ac44676..9dc2876 100644
--- a/mesonbuild/compilers/cpp.py
+++ b/mesonbuild/compilers/cpp.py
@@ -202,7 +202,7 @@ class GnuCPPCompiler(GnuCompiler, CPPCompiler):
'cpp_debugstl': coredata.UserBooleanOption('cpp_debugstl',
'STL debug mode',
False)})
- if self.compiler_type == CompilerType.GCC_MINGW:
+ if self.compiler_type.is_windows_compiler:
opts.update({
'cpp_winlibs': coredata.UserArrayOption('cpp_winlibs', 'Standard Win libraries to link against',
gnu_winlibs), })
@@ -218,7 +218,7 @@ class GnuCPPCompiler(GnuCompiler, CPPCompiler):
return args
def get_option_link_args(self, options):
- if self.compiler_type == CompilerType.GCC_MINGW:
+ if self.compiler_type.is_windows_compiler:
return options['cpp_winlibs'].value[:]
return []