diff --git a/CMakeLists.txt b/CMakeLists.txt index 0412482..94ab5f4 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -5,11 +5,4 @@ set(CMAKE_C_STANDARD_REQUIRED ON) set(CMAKE_C_EXTENSIONS OFF) project(CubeAscii) - -cmake_policy(SET CMP0079 NEW) - add_subdirectory(${PROJECT_NAME}) - -if (WIN32) - target_link_libraries(${PROJECT_NAME} PRIVATE winmm.lib) -endif () \ No newline at end of file diff --git a/CubeAscii/CMakeLists.txt b/CubeAscii/CMakeLists.txt index 63649ac..6ada2ed 100644 --- a/CubeAscii/CMakeLists.txt +++ b/CubeAscii/CMakeLists.txt @@ -1,5 +1,9 @@ -add_executable(CubeAscii main.c) +add_executable(${PROJECT_NAME} main.c) if (UNIX) - target_link_libraries(CubeAscii m) + target_link_libraries(${PROJECT_NAME} m) endif (UNIX) + +if (WIN32) + target_link_libraries(${PROJECT_NAME} PRIVATE winmm.lib) +endif () \ No newline at end of file