Add nightly warning (#5202)

Nightly build Warning
This commit is contained in:
3djc
2017-09-10 17:25:04 +02:00
committed by Bertrand Songis
parent 67817918f4
commit 2910488a30
3 changed files with 11 additions and 2 deletions
+6 -1
View File
@@ -44,6 +44,7 @@ option(TRACE_LUA_INTERNALS "Turn on traces for Lua internals" OFF)
option(BINDING_OPTIONS "Allow advanced frsky bindings" OFF)
option(FRSKY_STICKS "Reverse sticks for FrSky sticks" OFF)
option(NANO "Use nano newlib and binalloc")
option(NIGHTLY_BUILD_WARNING "Warn this is a nightly build" OFF)
# since we reset all default CMAKE compiler flags for firmware builds, provide an alternate way for user to specify additional flags.
set(FIRMWARE_C_FLAGS "" CACHE STRING "Additional flags for firmware target c compiler (note: all CMAKE_C_FLAGS[_*] are ignored for firmware/bootloader).")
@@ -347,6 +348,10 @@ if(EEPROM_VARIANT_NEEDED)
add_definitions(-DEEPROM_VARIANT=${EEPROM_VARIANT})
endif()
if(NIGHTLY_BUILD_WARNING)
add_definitions(-DNIGHTLY_BUILD_WARNING)
endif(NIGHTLY_BUILD_WARNING)
set(SRC
${SRC}
opentx.cpp
@@ -486,7 +491,7 @@ if(NOT MSVC)
set(SRC ${SRC} bin_allocator.cpp)
endif()
if(PCB STREQUAL X9D OR PCB STREQUAL X9D+ OR PCB STREQUAL X9E OR PCB STREQUAL X7 OR PCB STREQUAL X7S)
add_subdirectory(targets/${TARGET_DIR}/bootloader)
include_directories(${CMAKE_CURRENT_BINARY_DIR}/targets/${TARGET_DIR}/bootloader)
+4
View File
@@ -1911,6 +1911,10 @@ void opentxStart(OPENTX_START_ARGS)
}
#endif
#if defined(NIGHTLY_BUILD_WARNING)
ALERT("NIGHTLY", "Version not safe to fly", AU_ERROR);
#endif
#if defined(GUI)
if (calibration_needed) {
chainMenu(menuFirstCalib);