Add 'make run' target

This commit is contained in:
Riyyi
2020-12-30 17:17:21 +01:00
parent 40667ec056
commit c6634f1231
+10 -1
View File
@@ -5,6 +5,15 @@
set(ENGINE "inferno") set(ENGINE "inferno")
# Set project name # Set project name
set(GAME "game") set(GAME "game")
# Set debugging, ON/OFF
set(DEBUG "ON")
# ------------------------------------------
# Add 'make run' target
add_custom_target(run
COMMAND ${GAME}
)
# ------------------------------------------ # ------------------------------------------
@@ -13,7 +22,7 @@ cmake_minimum_required(VERSION 3.1)
set(CMAKE_EXPORT_COMPILE_COMMANDS ON) set(CMAKE_EXPORT_COMPILE_COMMANDS ON)
# Check if the build should include debugging symbols # Check if the build should include debugging symbols
option(DEBUG "" ON) option(DEBUG "" ${DEBUG})
if(DEBUG) if(DEBUG)
# cmake -DDEBUG=on .. && make # cmake -DDEBUG=on .. && make
message("--- Debug ---") message("--- Debug ---")