Compare commits
2 Commits
v1.0
...
6e25741cc9
Author | SHA1 | Date | |
---|---|---|---|
6e25741cc9 | |||
552ca5e6a9 |
@ -25,6 +25,7 @@ project(TrippyCube CXX)
|
|||||||
|
|
||||||
# Binary filename
|
# Binary filename
|
||||||
set(TARGET_NAME "trippy-cube")
|
set(TARGET_NAME "trippy-cube")
|
||||||
|
set(TARGET_VERSION "v2.0")
|
||||||
|
|
||||||
# Use DEBUG by default
|
# Use DEBUG by default
|
||||||
if(NOT CMAKE_BUILD_TYPE)
|
if(NOT CMAKE_BUILD_TYPE)
|
||||||
@ -60,11 +61,13 @@ set(CMAKE_CXX_FLAGS_RELWITHDEBINFO "-g -O3")
|
|||||||
set(CMAKE_CXX_FLAGS_MINSIZEREL "-Os")
|
set(CMAKE_CXX_FLAGS_MINSIZEREL "-Os")
|
||||||
|
|
||||||
if(CMAKE_BUILD_TYPE STREQUAL "debug" OR CMAKE_BUILD_TYPE STREQUAL "relwithdebinfo")
|
if(CMAKE_BUILD_TYPE STREQUAL "debug" OR CMAKE_BUILD_TYPE STREQUAL "relwithdebinfo")
|
||||||
add_definitions(-DDEBUG)
|
add_definitions("-DDEBUG")
|
||||||
else()
|
else()
|
||||||
add_definitions(-DNDEBUG)
|
add_definitions("-DNDEBUG")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
add_definitions("-DVERSION=\"${TARGET_VERSION}\"")
|
||||||
|
|
||||||
add_executable(${TARGET_NAME}
|
add_executable(${TARGET_NAME}
|
||||||
${SRCS})
|
${SRCS})
|
||||||
|
|
||||||
|
@ -27,6 +27,10 @@
|
|||||||
#include <SDL2/SDL.h>
|
#include <SDL2/SDL.h>
|
||||||
#include <GL/gl.h>
|
#include <GL/gl.h>
|
||||||
|
|
||||||
|
#ifndef VERSION
|
||||||
|
# define VERSION "version"
|
||||||
|
#endif
|
||||||
|
|
||||||
#define SCREEN_WIDTH 800
|
#define SCREEN_WIDTH 800
|
||||||
#define SCREEN_HEIGHT 600
|
#define SCREEN_HEIGHT 600
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user