Explorar o código

Don't treat warnings as errors

When enet is included as a child CMake project in a parent that has warnings treated as errors, enet fails to build. This ensures that the compiler doesn't treat warnings as errors for enet.
Cong %!s(int64=7) %!d(string=hai) anos
pai
achega
90560cd471
Modificáronse 1 ficheiros con 2 adicións e 0 borrados
  1. 2 0
      CMakeLists.txt

+ 2 - 0
CMakeLists.txt

@@ -20,6 +20,8 @@ check_type_size("socklen_t" HAS_SOCKLEN_T BUILTIN_TYPES_ONLY)
 unset(CMAKE_EXTRA_INCLUDE_FILES)
 unset(CMAKE_EXTRA_INCLUDE_FILES)
 if(MSVC)
 if(MSVC)
 	add_definitions(-W3)
 	add_definitions(-W3)
+else()
+	add_definitions(-Wno-error)
 endif()
 endif()
  
  
 if(HAS_FCNTL)
 if(HAS_FCNTL)