Commit 30853fe4 authored by dzhioev@chromium.org's avatar dzhioev@chromium.org

Make YCM ignore unknown warning options.

After r290361, '-Wno-undefined-bool-conversion' and
'-Wno-tautological-undefined-compare' are used to build Debug Chromium with
Clang. The problem is these options were introduced in Clang 3.5, and latest YCM
uses Clang 3.4. This caused compilation error "unknown warning option" in YCM
for every "*.cc" file. Fixed by adding '-Wno-unknown-warning-option' to YCM compilation flags.

BUG=none
TEST=manually
NOTRY=true

Review URL: https://codereview.chromium.org/483643004

Cr-Commit-Position: refs/heads/master@{#290635}
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@290635 0039d316-1c4b-4281-b951-d872f2087c98
parent 9d796fa3
......@@ -130,6 +130,12 @@ def GetClangCommandFromNinjaForFilename(chrome_root, filename):
# Chromium's includes are relative to that.
chrome_flags = ['-I' + os.path.join(chrome_root)]
# Version of Clang used to compile Chromium can be newer then version of
# libclang that YCM uses for completion. So it's possible that YCM's libclang
# doesn't know about some used warning options, which causes compilation
# warnings (and errors, because of '-Werror');
chrome_flags.append('-Wno-unknown-warning-option')
# Default file to get a reasonable approximation of the flags for a Blink
# file.
blink_root = os.path.join(chrome_root, 'third_party', 'WebKit')
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment