1
1

cmake: Only set -Werror on UNIX

Signed-off-by: Andreas Schneider <asn@cryptomilk.org>
Этот коммит содержится в:
Andreas Schneider 2018-08-13 20:17:00 +02:00
родитель 0656f8a43d
Коммит 6aa9392699

Просмотреть файл

@ -270,7 +270,9 @@ int main(void) {
########################################################### ###########################################################
# For detecting attributes we need to treat warnings as # For detecting attributes we need to treat warnings as
# errors # errors
set(CMAKE_REQUIRED_FLAGS "-Werror") if (UNIX)
set(CMAKE_REQUIRED_FLAGS "-Werror")
endif (UNIX)
check_c_source_compiles(" check_c_source_compiles("
void test_constructor_attribute(void) __attribute__ ((constructor)); void test_constructor_attribute(void) __attribute__ ((constructor));