forked from github/server
fix clang builds
This commit is contained in:
parent
4fc747fd83
commit
7d874f1606
|
@ -17,10 +17,12 @@ set_source_files_properties(kernel/version.c PROPERTIES
|
|||
COMPILE_DEFINITIONS ERESSEA_VERSION="${ERESSEA_VERSION}")
|
||||
ENDIF()
|
||||
|
||||
IF(CMAKE_COMPILER_IS_GNUCC OR CMAKE_COMPILER_IS_CLANG)
|
||||
IF (CMAKE_COMPILER_IS_GNUCC)
|
||||
SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-error=unused-but-set-variable")
|
||||
ENDIF()
|
||||
IF (CMAKE_COMPILER_IS_GNUCC OR CMAKE_C_COMPILER_ID MATCHES "Clang")
|
||||
# SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wconversion -Wno-sign-conversion")
|
||||
SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -pedantic -Wsign-compare -Wall -Werror -Wno-unknown-pragmas -Wstrict-prototypes -Wpointer-arith -Wno-char-subscripts -Wno-long-long")
|
||||
SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-error=unused-but-set-variable")
|
||||
SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -std=c99")
|
||||
add_definitions(-DHAVE__BOOL)
|
||||
ELSEIF(MSVC)
|
||||
|
|
|
@ -75,3 +75,4 @@ CuSuite *get_messages_suite(void) {
|
|||
SUITE_ADD_TEST(suite, test_message);
|
||||
return suite;
|
||||
}
|
||||
|
||||
|
|
|
@ -23,3 +23,4 @@ extern "C" {
|
|||
#endif
|
||||
|
||||
#endif
|
||||
|
||||
|
|
|
@ -52,3 +52,4 @@ void register_function(pf_generic fun, const char *name)
|
|||
void free_functions(void) {
|
||||
cb_clear(&cb_functions);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue