From d7d700b3478bfeb441168924d2f21d467eb28344 Mon Sep 17 00:00:00 2001 From: Amine Khaldi Date: Sun, 7 Sep 2014 12:36:26 +0000 Subject: [PATCH] [CMAKE/CLANG] * Fix Clang def file handling. * Clang doesn't have -Wold-style-declaration (yet?). svn path=/trunk/; revision=64060 --- reactos/cmake/gcc.cmake | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/reactos/cmake/gcc.cmake b/reactos/cmake/gcc.cmake index 2dc7d484dc1..cd5d542d440 100644 --- a/reactos/cmake/gcc.cmake +++ b/reactos/cmake/gcc.cmake @@ -34,11 +34,16 @@ endif() if(CMAKE_C_COMPILER_ID STREQUAL "Clang") add_compile_flags_language("-std=gnu89" "C") add_compile_flags("-Wno-microsoft") + set(CMAKE_LINK_DEF_FILE_FLAG "") endif() if(DBG) - add_compile_flags_language("-Wold-style-declaration -Wdeclaration-after-statement" "C") + if(NOT CMAKE_C_COMPILER_ID STREQUAL "Clang") + add_compile_flags_language("-Wold-style-declaration" "C") + endif() + add_compile_flags_language("-Wdeclaration-after-statement" "C") endif() + add_compile_flags_language("-fno-rtti -fno-exceptions" "CXX") #bug