]> git.lizzy.rs Git - nothing.git/blobdiff - CMakeLists.txt
Implement render_text_shaded function
[nothing.git] / CMakeLists.txt
index 951a6f6f7f852c48900f1c6721670c0a8f188ad6..4f550000dd1ca76fbde628b151d4af212f39d631 100644 (file)
@@ -10,67 +10,76 @@ endif()
 set(CMAKE_MODULE_PATH "${CMAKE_SOURCE_DIR}/cmake" ${CMAKE_MODULE_PATH})
 
 find_package(SDL2 REQUIRED)
-
 find_package(SDL2_mixer REQUIRED)
+find_package(SDL2_ttf REQUIRED)
 
 include_directories(src/)
 include_directories(${SDL2_INCLUDE_DIR})
 include_directories(${SDL2_MIXER_INCLUDE_DIR})
+include_directories(${SDL2_TTF_DIR})
 
 set(SOURCE_FILES
-  src/main.c
-  src/game/level/player.c
-  src/game/level/platforms.c
-  src/math/rect.c
-  src/math/point.c
-  src/game/level/camera.c
-  src/error.c
+  src/color.c
   src/game.c
-  src/lt.c
-  src/lt/lt_slot.c
+  src/game/camera.c
   src/game/level.c
+  src/game/level/background.c
+  src/game/level/boxes.c
   src/game/level/goals.c
-  src/renderer.c
-  src/math/triangle.c
-  src/color.c
-  src/game/level/player/rigid_rect.c
-  src/game/level/player/dying_rect.c
   src/game/level/lava.c
   src/game/level/lava/wavy_rect.c
-  src/game/sound_medium.c
-  src/path.c
+  src/game/level/physical_world.c
+  src/game/level/platforms.c
+  src/game/level/player.c
+  src/game/level/player/dying_rect.c
+  src/game/level/player/rigid_rect.c
+  src/game/level/solid.c
+  src/game/sound_samples.c
+  src/main.c
   src/math/mat3x3.c
+  src/math/point.c
   src/math/rand.c
+  src/math/rect.c
+  src/math/triangle.c
+  src/sdl/renderer.c
+  src/system/error.c
+  src/system/lt.c
+  src/system/lt/lt_adapters.c
+  src/system/lt/lt_slot.c
 )
 
 set(HEADER_FILES
-  src/game/level/player.h
-  src/game/level/platforms.h
-  src/math/rect.h
-  src/math/point.h
-  src/game/level/camera.h
-  src/error.h
+  src/color.h
   src/game.h
-  src/lt.h
-  src/lt/lt_slot.h
+  src/game/camera.h
   src/game/level.h
+  src/game/level/background.h
+  src/game/level/boxes.h
   src/game/level/goals.h
-  src/renderer.h
-  src/math/triangle.h
-  src/math/pi.h
-  src/color.h
-  src/game/level/player/rigid_rect.h
-  src/game/level/player/dying_rect.h
   src/game/level/lava.h
   src/game/level/lava/wavy_rect.h
-  src/game/sound_medium.h
-  src/path.h
+  src/game/level/physical_world.c
+  src/game/level/platforms.h
+  src/game/level/player.h
+  src/game/level/player/dying_rect.h
+  src/game/level/player/rigid_rect.h
+  src/game/level/solid.h
+  src/game/sound_samples.h
   src/math/mat3x3.h
+  src/math/pi.h
+  src/math/point.h
   src/math/rand.h
+  src/math/rect.h
+  src/math/triangle.h
+  src/sdl/renderer.h
+  src/system/error.h
+  src/system/lt.h
+  src/system/lt/lt_adapters.h
+  src/system/lt/lt_slot.h
 )
 
 add_executable(nothing ${SOURCE_FILES} ${HEADER_FILES})
-target_link_libraries(nothing ${SDL2_LIBRARY} ${SDL2_MIXER_LIBRARY})
+target_link_libraries(nothing ${SDL2_LIBRARY} ${SDL2_MIXER_LIBRARY} ${SDL2_TTF_LIBRARY})
 
 if(("${CMAKE_CXX_COMPILER_ID}" STREQUAL "GNU") OR ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "CLANG"))
   set(CMAKE_C_FLAGS
@@ -96,6 +105,7 @@ if(("${CMAKE_CXX_COMPILER_ID}" STREQUAL "GNU") OR ("${CMAKE_CXX_COMPILER_ID}" ST
      -Wshadow \
      -Wstrict-prototypes \
      -Wwrite-strings \
+     -Wswitch \
      -fno-common \
      -pedantic \
      -std=c11 \
@@ -107,3 +117,4 @@ if(WIN32)
 endif()
 
 file(COPY ${CMAKE_CURRENT_SOURCE_DIR}/sounds DESTINATION ${CMAKE_CURRENT_BINARY_DIR})
+file(COPY ${CMAKE_CURRENT_SOURCE_DIR}/fonts DESTINATION ${CMAKE_CURRENT_BINARY_DIR})