[GTK][CMake] Add support for building with Clang
authorzandobersek@gmail.com <zandobersek@gmail.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 20 Mar 2014 18:22:54 +0000 (18:22 +0000)
committerzandobersek@gmail.com <zandobersek@gmail.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 20 Mar 2014 18:22:54 +0000 (18:22 +0000)
commitd9a81574bff10e4800111bfcd3f3f549c49cb65c
tree6479560423211ad6f21d6143f3b194553adf5837
parent18bc45007d6659ec9069f82126fa2206c8f66403
[GTK][CMake] Add support for building with Clang
https://bugs.webkit.org/show_bug.cgi?id=130260

Reviewed by Martin Robinson.

.:

* Source/PlatformGTK.cmake: Run the generate-gtkdoc script with the CFLAGS env set
to the list C compiler flags as constructed by CMake.
* Source/cmake/OptionsCommon.cmake: When building with Clang, use the -Qunused-arguments
compiler option to suppress verbose warnings about arguments that went unused by the driver.
* Source/cmake/OptionsGTK.cmake: Use -fno-omit-frame-pointer for both GCC and Clang.
-fno-tree-dce should be used only for GCC.
* Source/cmake/gtest/CMakeLists.txt: When building with Clang the GTest framework
should be built with GTEST_HAS_TR1_TUPLE macro defined to 0 to avoid build failures.

Tools:

* TestWebKitAPI/CMakeLists.txt: When building with Clang TestWebKitAPI should be
built with GTEST_HAS_TR1_TUPLE defined to 0 to avoid build failures occuring in the
included GTest framework headers.
* gtk/generate-gtkdoc:
(prepare_environment_for_gtkdoc_generation): Don't modify the CFLAGS env anymore
in case of using Clang since that is now set by the CMake rule.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@165975 268f45cc-cd09-0410-ab3c-d52691b4dbfc
ChangeLog
Source/PlatformGTK.cmake
Source/cmake/OptionsCommon.cmake
Source/cmake/OptionsGTK.cmake
Source/cmake/gtest/CMakeLists.txt
Tools/ChangeLog
Tools/TestWebKitAPI/CMakeLists.txt
Tools/gtk/generate-gtkdoc