Feed Clang a pragma to ignore -Wc++11-extensions to let it build Skia on Mac.
Tested: CXX=clang++ ./gyp_skia && ninja -C out/Debug && CXX=G++ ./gyp_skia && ninja -C out/Debug && echo "ok" Got to ok. BUG= R=bungeman@google.com Author: mtklein@google.com Review URL: https://chromiumcodereview.appspot.com/14365009 git-svn-id: http://skia.googlecode.com/svn/trunk@8799 2bbb7eff-a529-9590-31e7-b0007b416f81
This commit is contained in:
parent
7dfbb0720a
commit
aa2c2ffe5a
@ -322,6 +322,11 @@
|
||||
#if defined(_MSC_VER)
|
||||
#define SK_OVERRIDE override
|
||||
#elif defined(__clang__) && !defined(SK_BUILD_FOR_IOS)
|
||||
// Clang defaults to C++03 and warns about using override. Squelch that. Intentionally no
|
||||
// push/pop here so all users of SK_OVERRIDE ignore the warning too. This is like passing
|
||||
// -Wno-c++11-extensions, except that GCC won't die (because it won't see this pragma).
|
||||
#pragma clang diagnostic ignored "-Wc++11-extensions"
|
||||
|
||||
#if __has_feature(cxx_override_control)
|
||||
// Some documentation suggests we should be using __attribute__((override)),
|
||||
// but it doesn't work.
|
||||
|
Loading…
Reference in New Issue
Block a user