diff --git a/CMakeLists.txt b/CMakeLists.txt index cfddbfb..39bf88c 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -26,10 +26,10 @@ if (NOT MSVC) endif () if (NOT MSVC) - add_definitions ("-Wall") + add_compile_options ("-Wall") else () # Show level 4 warnings. - add_definitions ("-W4") + add_compile_options ("-W4") endif () option(UNICODE "Compile with UNICODE support" OFF) @@ -44,6 +44,7 @@ option(TESTSUITE "Compile with TESTSUITE support" OFF) if (TESTSUITE) message (STATUS "Compile with TESTSUITE support") add_definitions ("-DTESTSUITE") + add_subdirectory (tests) else () message (STATUS "Compile without TESTSUITE support") endif () @@ -54,7 +55,9 @@ if (NOT MSVC) set_target_properties ("MemoryModule" PROPERTIES PREFIX "") endif () -add_subdirectory (example) -add_subdirectory (tests) +option(MEMORY_MODULE_EXAMPLES "Include the MemoryModule examples" ON) +if (MEMORY_MODULE_EXAMPLES) + add_subdirectory (example) +endif () enable_language (RC)