cmake: Keep warning in sync with Makefile based build system
diff --git a/CMakeLists.txt b/CMakeLists.txt
index ec52939..2202c93 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -33,6 +33,12 @@ set(CMAKE_ARCHIVE_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib)
set(CMAKE_LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib)
set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/bin)
+if (MSVC)
+ add_compile_options(/W4)
+else()
+ add_compile_options(-Wall)
+endif()
+
add_subdirectory(src)
if (BUILD_TESTS)