moved the OS stuff to the top

This commit is contained in:
jakeg00dwin 2024-03-06 22:01:43 -08:00
parent 47421d2620
commit 36fea871c2
1 changed files with 9 additions and 8 deletions

View File

@ -10,6 +10,14 @@ enable_testing()
set(TARGET_GROUP production CACHE STRING "Group to build")
if(MSVC OR MSYS OR MINGW)
message("### SETUP FOR WINDOWS ###")
add_definitions(-DWINDOWS)
else()
message("### SETUP FOR UNIX ###")
add_definitions(-DUNIX)
endif()
# For being able to used LSP
set(CMAKE_EXPORT_COMPILE_COMMANDS ON)
@ -24,14 +32,6 @@ set(CMAKE_CXX_STANDARD_REQUIRED True)
set(CMAKE_CXX_FLAGS "-Wall -Werror -Wpedantic")
if(MSVC OR MSYS OR MINGW)
message("### SETUP FOR WINDOWS ###")
add_definitions(-DWINDOWS)
else()
message("### SETUP FOR UNIX ###")
add_definitions(-DUNIX)
endif()
# #######################################
# TESTING STUFF
# #######################################
@ -41,6 +41,7 @@ endif()
if (UNIT_TESTING)
message(STATUS "CPPUTEST_LIB: ${CPPUTEST_LIB}")
add_subdirectory(cpputest)
add_subdirectory(tests)
endif()