diff options
author | Tomaz Canabrava <tomaz.canabrava@intel.com> | 2015-12-16 14:30:56 -0200 |
---|---|---|
committer | Dirk Hohndel <dirk@hohndel.org> | 2015-12-16 09:21:07 -0800 |
commit | 85946700eb300b1061b8e226b552295d3e8e90d6 (patch) | |
tree | d27c66115db05bb060fe54c867c0a263d9a1d09f /CMakeLists.txt | |
parent | 9d805bea4a01c54f44ea2304e70535526b41a5ed (diff) | |
download | subsurface-85946700eb300b1061b8e226b552295d3e8e90d6.tar.gz |
Complain if no Correct App version was passed to be build
Signed-off-by: Tomaz Canabrava <tomaz.canabrava@intel.com>
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r-- | CMakeLists.txt | 16 |
1 files changed, 6 insertions, 10 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index 8a4fab23c..87e927c20 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -35,26 +35,22 @@ option(FTDISUPPORT "enable support for libftdi based serial" OFF) # Options regarding What should we build on subsurface option(MAKE_TESTS "Make the tests" ON) -SET(SUBSURFACE_TARGET_PLATFORM "Desktop" CACHE STRING "The target that Subsurface will be build") -LIST(APPEND SUBSURFACE_ACCEPTED_PLATFORMS "Desktop" "Android" "iOS" "AndroidEmulator" "iOSEmulator") -SET_PROPERTY(CACHE SUBSURFACE_TARGET_PLATFORM PROPERTY STRINGS ${SUBSURFACE_ACCEPTED_PLATFORMS}) +#Extra features +option(SMARTTRAK_IMPORT "enable building SmartTrak divelogs import tool (requires glib2 and libmdb)" OFF) SET(SUBSURFACE_TARGET_EXECUTABLE "DesktopExecutable" CACHE STRING "The type of application, DesktopExecutable or MobileExecutable") LIST(APPEND SUBSURFACE_ACCEPTED_EXECUTABLES "DesktopExecutable" "MobileExecutable") SET_PROPERTY(CACHE SUBSURFACE_TARGET_PLATFORM PROPERTY STRINGS ${SUBSURFACE_ACCEPTED_EXECUTABLES}) -#Extra features -option(SMARTTRAK_IMPORT "enable building SmartTrak divelogs import tool (requires glib2 and libmdb)" OFF) - #verify if Platform is correct and warn on wxit with example. -list (FIND SUBSURFACE_ACCEPTED_PLATFORMS ${SUBSURFACE_TARGET_PLATFORM} _index) +list (FIND SUBSURFACE_ACCEPTED_EXECUTABLES ${SUBSURFACE_TARGET_EXECUTABLE} _index) if (${_index} EQUAL -1) message(FATAL_ERROR "Requested platform not supported, please use one of the following: - ${SUBSURFACE_ACCEPTED_PLATFORMS} + ${SUBSURFACE_ACCEPTED_EXECUTABLES} - inputted value was: ${SUBSURFACE_TARGET_PLATFORM} + inputted value was: ${SUBSURFACE_TARGET_EXECUTABLE} - Example: -DSUBSURFACE_TARGET_PLATFORM=Desktop") + Example: -DSUBSURFACE_TARGET_EXECUTABLE=DesktopApplication") endif() add_definitions(-DSUBSURFACE_SOURCE="${CMAKE_SOURCE_DIR}") |