Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(27)

Unified Diff: infra/bots/recipe_modules/skia/gn_flavor.py

Issue 2193203002: GN: ccache+clang needs -Qunused-arguments (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Whoops, there it is. Created 4 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | infra/bots/recipes/swarm_compile.expected/Build-Ubuntu-Clang-x86_64-Debug-GN.json » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: infra/bots/recipe_modules/skia/gn_flavor.py
diff --git a/infra/bots/recipe_modules/skia/gn_flavor.py b/infra/bots/recipe_modules/skia/gn_flavor.py
index c4988fbe16a6df7962e4159ee3eb340fe894e1ed..7b60b9a1a0fd603d5a30ca7d512c48aae7abc9c7 100644
--- a/infra/bots/recipe_modules/skia/gn_flavor.py
+++ b/infra/bots/recipe_modules/skia/gn_flavor.py
@@ -18,15 +18,22 @@ class GNFlavorUtils(default_flavor.DefaultFlavorUtils):
is_debug = 'is_debug=false'
gn_args = [is_debug]
+ is_clang = 'Clang' in self._skia_api.builder_name
+ is_gcc = 'GCC' in self._skia_api.builder_name
+
cc, cxx = 'cc', 'c++'
- if 'Clang' in self._skia_api.builder_name:
+ if is_clang:
cc, cxx = 'clang', 'clang++'
- elif 'GCC' in self._skia_api.builder_name:
+ elif is_gcc:
cc, cxx = 'gcc', 'g++'
ccache = self._skia_api.ccache()
if ccache:
cc, cxx = '%s %s' % (ccache, cc), '%s %s' % (ccache, cxx)
+ if is_clang:
+ # Stifle "argument unused during compilation: ..." warnings.
+ stifle = '-Qunused-arguments'
+ cc, cxx = '%s %s' % (cc, stifle), '%s %s' % (cxx, stifle)
gn_args += [ 'cc="%s"' % cc, 'cxx="%s"' % cxx ]
« no previous file with comments | « no previous file | infra/bots/recipes/swarm_compile.expected/Build-Ubuntu-Clang-x86_64-Debug-GN.json » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698