Changeset 145560 in webkit


Ignore:
Timestamp:
Mar 12, 2013 10:40:40 AM (11 years ago)
Author:
zandobersek@gmail.com
Message:

[GTK] 'unrecognized command line option "-Wno-c++11-extensions"' warning reported when using gcc
https://bugs.webkit.org/show_bug.cgi?id=111936

Reviewed by Martin Robinson.

  • Source/autotools/SetupCompilerFlags.m4: Only use the -Wno-c++11-extensions warning when building

with Clang as GCC does not support the warning just yet. Also enhance the comment about using libstdc++
as the standard C++ library when compiling with Clang.

Location:
trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/ChangeLog

    r145552 r145560  
     12013-03-12  Zan Dobersek  <zdobersek@igalia.com>
     2
     3        [GTK] 'unrecognized command line option "-Wno-c++11-extensions"' warning reported when using gcc
     4        https://bugs.webkit.org/show_bug.cgi?id=111936
     5
     6        Reviewed by Martin Robinson.
     7
     8        * Source/autotools/SetupCompilerFlags.m4: Only use the -Wno-c++11-extensions warning when building
     9        with Clang as GCC does not support the warning just yet. Also enhance the comment about using libstdc++
     10        as the standard C++ library when compiling with Clang.
     11
    1122013-03-12  Zan Dobersek  <zdobersek@igalia.com>
    213
  • trunk/Source/autotools/SetupCompilerFlags.m4

    r145084 r145560  
    11# Use C99 as the language standard for C code.
    22CFLAGS="$CFLAGS -std=c99"
    3 # Do not warn about C++11 incompatibilities and extensions.
    4 CXXFLAGS="$CXXFLAGS -Wno-c++11-compat -Wno-c++11-extensions"
     3# Do not warn about C++11 incompatibilities.
     4CXXFLAGS="$CXXFLAGS -Wno-c++11-compat"
    55
    66# Clang requires suppression of unused arguments warning.
     
    88    CFLAGS="$CFLAGS -Qunused-arguments"
    99fi
    10 # libstdc++ is at the moment the only option as the C++ standard library.
     10# -Wno-c++11-extensions, currently only usable with Clang, suppresses warnings of C++11 extensions in use.
     11# libstdc++ is at the moment the only option as the C++ standard library when compiling with Clang.
    1112if test "$CXX" = "clang++"; then
    12     CXXFLAGS="$CXXFLAGS -stdlib=libstdc++ -Qunused-arguments"
     13    CXXFLAGS="$CXXFLAGS -Wno-c++11-extensions -stdlib=libstdc++ -Qunused-arguments"
    1314fi
    1415
Note: See TracChangeset for help on using the changeset viewer.