File tree Expand file tree Collapse file tree 1 file changed +8
-1
lines changed Expand file tree Collapse file tree 1 file changed +8
-1
lines changed Original file line number Diff line number Diff line change 5
5
# GODOT_GDEXTENSION_DIR: Path to the directory containing GDExtension interface header and API JSON file
6
6
# GODOT_CPP_SYSTEM_HEADERS Mark the header files as SYSTEM. This may be useful to supress warnings in projects including this one.
7
7
# GODOT_CPP_WARNING_AS_ERROR Treat any warnings as errors
8
+ # GODOT_ENABLE_HOT_RELOAD Build with hot reload support. Defaults to YES for Debug-builds and NO for Release-builds.
8
9
# GODOT_CUSTOM_API_FILE: Path to a custom GDExtension API JSON file (takes precedence over `gdextension_dir`)
9
10
# FLOAT_PRECISION: Floating-point precision level ("single", "double")
10
11
#
@@ -43,7 +44,6 @@ project(godot-cpp LANGUAGES CXX)
43
44
option (GENERATE_TEMPLATE_GET_NODE "Generate a template version of the Node class's get_node." ON )
44
45
option (GODOT_CPP_SYSTEM_HEADERS "Expose headers as SYSTEM." ON )
45
46
option (GODOT_CPP_WARNING_AS_ERROR "Treat warnings as errors" OFF )
46
- option (GODOT_ENABLE_HOT_RELOAD "Build with hot reload support" OFF )
47
47
48
48
# Add path to modules
49
49
list ( APPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR} /cmake/" )
@@ -58,6 +58,13 @@ if("${CMAKE_BUILD_TYPE}" STREQUAL "")
58
58
set (CMAKE_BUILD_TYPE Debug )
59
59
endif ()
60
60
61
+ # Hot reload is enabled by default in Debug-builds
62
+ if ("${CMAKE_BUILD_TYPE} " STREQUAL "Debug" )
63
+ option (GODOT_ENABLE_HOT_RELOAD "Build with hot reload support" ON )
64
+ else ()
65
+ option (GODOT_ENABLE_HOT_RELOAD "Build with hot reload support" OFF )
66
+ endif ()
67
+
61
68
if (NOT DEFINED BITS )
62
69
set (BITS 32 )
63
70
if (CMAKE_SIZEOF_VOID_P EQUAL 8 )
You can’t perform that action at this time.
0 commit comments