cmake: Add -Wno-c++98-compat if building for C++11.

On clang, this is default on, and with C++11 we use override, which
is not C++98 compatible.