diff options
author | Rémi Verschelde <rverschelde@gmail.com> | 2019-04-05 12:51:15 +0200 |
---|---|---|
committer | Rémi Verschelde <rverschelde@gmail.com> | 2019-04-05 12:51:15 +0200 |
commit | e4a96164b6e52dac6aff7ddad05bd3ed735840a9 (patch) | |
tree | 33505e08440533b93dda6d676e6ae74c06eabd95 /methods.py | |
parent | 6a33727cb1ae9fe73432912ca07b583cd523a00f (diff) |
SCons: add `methods.using_clang` to check used compiler
Also rename `use_gcc` to `using_gcc` to make it clear that it returns
a config but does not alter it.
Diffstat (limited to 'methods.py')
-rw-r--r-- | methods.py | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/methods.py b/methods.py index 7465962187..5bc30dc643 100644 --- a/methods.py +++ b/methods.py @@ -668,5 +668,8 @@ def get_compiler_version(env): else: return None -def use_gcc(env): +def using_gcc(env): return 'gcc' in os.path.basename(env["CC"]) + +def using_clang(env): + return 'clang' in os.path.basename(env["CC"]) |