aboutsummaryrefslogtreecommitdiffstats
path: root/utils/libcxx/compiler.py
diff options
context:
space:
mode:
Diffstat (limited to 'utils/libcxx/compiler.py')
-rw-r--r--utils/libcxx/compiler.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/utils/libcxx/compiler.py b/utils/libcxx/compiler.py
index 983bc26c80bd..e908e26089b0 100644
--- a/utils/libcxx/compiler.py
+++ b/utils/libcxx/compiler.py
@@ -24,6 +24,7 @@ class CXXCompiler(object):
modules_flags=None, use_modules=False,
use_ccache=False, use_warnings=False, compile_env=None,
cxx_type=None, cxx_version=None):
+ self.source_lang = 'c++'
self.path = path
self.flags = list(flags or [])
self.compile_flags = list(compile_flags or [])
@@ -108,7 +109,7 @@ class CXXCompiler(object):
if out is not None:
cmd += ['-o', out]
if input_is_cxx:
- cmd += ['-x', 'c++']
+ cmd += ['-x', self.source_lang]
if isinstance(source_files, list):
cmd += source_files
elif isinstance(source_files, str):