]> source.dussan.org Git - rspamd.git/commitdiff
Restore std=c99 compiler flag.
authorVsevolod Stakhov <vsevolod@rambler-co.ru>
Tue, 20 Dec 2011 16:14:29 +0000 (19:14 +0300)
committerVsevolod Stakhov <vsevolod@rambler-co.ru>
Tue, 20 Dec 2011 16:14:29 +0000 (19:14 +0300)
CMakeLists.txt

index ee4133e925ed84ae56ed5c59e80c4c9ddc8b593e..5eae18c4614c300edbc0f6a7fa8827278709840a 100644 (file)
@@ -565,6 +565,7 @@ CHECK_C_COMPILER_FLAG(-Wno-unused-function SUPPORT_WFUNCTION)
 CHECK_C_COMPILER_FLAG(-Wunused-variable SUPPORT_WUNUSED_VAR)
 CHECK_C_COMPILER_FLAG(-Wno-pointer-sign SUPPORT_WPOINTER_SIGN)
 CHECK_C_COMPILER_FLAG(-pedantic SUPPORT_PEDANTIC_FLAG)
+CHECK_C_COMPILER_FLAG("-std=c99" SUPPORT_STD_FLAG)
 IF(SUPPORT_W)
        SET(CMAKE_C_WARN_FLAGS "${CMAKE_C_WARN_FLAGS} -W")
 ENDIF(SUPPORT_W)
@@ -589,6 +590,9 @@ ENDIF(SUPPORT_WPOINTER_SIGN)
 IF(SUPPORT_PEDANTIC_FLAG)
        SET(CMAKE_C_WARN_FLAGS "${CMAKE_C_WARN_FLAGS} -pedantic")
 ENDIF(SUPPORT_PEDANTIC_FLAG)
+IF(SUPPORT_STD_FLAG)
+       SET(CMAKE_C_WARN_FLAGS "${CMAKE_C_WARN_FLAGS} -std=c99")
+ENDIF(SUPPORT_STD_FLAG)
  
  # Optimization flags
 IF(NOT CMAKE_C_OPT_FLAGS)