Merge pull request #687 from jtcooper10/cmake-default-build-type-fix

pull/790/head
Rémi Verschelde 2022-07-18 13:59:29 +02:00 committed by GitHub
commit 4bd0dab16b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 7 additions and 5 deletions

View File

@ -52,7 +52,7 @@ SET(CMAKE_ARCHIVE_OUTPUT_DIRECTORY_DEBUG "${BUILD_PATH}")
SET(CMAKE_ARCHIVE_OUTPUT_DIRECTORY_RELEASE "${BUILD_PATH}") SET(CMAKE_ARCHIVE_OUTPUT_DIRECTORY_RELEASE "${BUILD_PATH}")
# Default build type is Debug in the SConstruct # Default build type is Debug in the SConstruct
if(CMAKE_BUILD_TYPE STREQUAL "") if("${CMAKE_BUILD_TYPE}" STREQUAL "")
set(CMAKE_BUILD_TYPE Debug) set(CMAKE_BUILD_TYPE Debug)
endif() endif()
@ -66,10 +66,12 @@ if(FLOAT_TYPE EQUAL 64)
set(FLOAT_TYPE_FLAG "double" CACHE STRING "") set(FLOAT_TYPE_FLAG "double" CACHE STRING "")
endif(FLOAT_TYPE EQUAL 64) endif(FLOAT_TYPE EQUAL 64)
if(NOT DEFINED BITS)
set(BITS 32) set(BITS 32)
if(CMAKE_SIZEOF_VOID_P EQUAL 8) if(CMAKE_SIZEOF_VOID_P EQUAL 8)
set(BITS 64) set(BITS 64)
endif(CMAKE_SIZEOF_VOID_P EQUAL 8) endif(CMAKE_SIZEOF_VOID_P EQUAL 8)
endif()
# Input from user for godot headers and the api file # Input from user for godot headers and the api file
set(GODOT_HEADERS_DIR "godot-headers" CACHE STRING "") set(GODOT_HEADERS_DIR "godot-headers" CACHE STRING "")