Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
25 changes: 18 additions & 7 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,17 +1,28 @@
cmake_minimum_required(VERSION 2.8)
cmake_minimum_required(VERSION 4.0.1)

project(craft)

FILE(GLOB SOURCE_FILES src/*.c)

add_executable(
craft
${SOURCE_FILES}
set(SOURCE_FILES
src/auth.c
src/client.c
src/cube.c
src/db.c
src/item.c
src/main.c
src/map.c
src/matrix.c
src/ring.c
src/sign.c
src/util.c
src/world.c
deps/glew/src/glew.c
deps/lodepng/lodepng.c
deps/noise/noise.c
deps/sqlite/sqlite3.c
deps/tinycthread/tinycthread.c)
deps/tinycthread/tinycthread.c
)

add_executable(craft ${SOURCE_FILES})

add_definitions(-std=c99 -O3)

Expand Down
6 changes: 2 additions & 4 deletions deps/glfw/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,8 @@ project(GLFW C)
cmake_minimum_required(VERSION 2.8.12)

if (NOT CMAKE_VERSION VERSION_LESS "3.0")
# Until all major package systems have moved to CMake 3,
# we stick with the older INSTALL_NAME_DIR mechanism
cmake_policy(SET CMP0042 OLD)
# CMake 4.0.1+ requires NEW behavior for CMP0042
cmake_policy(SET CMP0042 NEW)
endif()

set(GLFW_VERSION_MAJOR "3")
Expand Down Expand Up @@ -548,4 +547,3 @@ if (GLFW_INSTALL)
"${GLFW_BINARY_DIR}/cmake_uninstall.cmake")
endif()
endif()