--- a/CMakeLists.txt Fri May 17 16:49:28 2019 +0200
+++ b/CMakeLists.txt Fri May 17 16:54:30 2019 +0200
@@ -51,6 +51,14 @@
option(NOVERSIONINFOUPDATE "Disable update of version_info.txt. To be used if source is in a git/repo that is NOT the hedgewars repo" OFF)
+if(BUILD_ENGINE_C AND NOT NOVIDEOREC)
+ if((CMAKE_BUILD_TYPE MATCHES "RELEASE") OR (CMAKE_BUILD_TYPE MATCHES "RELWITHDEBUGINFO"))
+ message("NOTE: Video recorder support disabled. It's incompatible with BUILD_ENGINE_C")
+ set(BUILD_ENGINE_C ON CACHE STRING "Required for BUILD_ENGINE_JS" FORCE)
+ else()
+ message("WARNING: Video recorder support is currently incompatible with BUILD_ENGINE_C, the video recorder won't work (but demos are fine)! See <https://issues.hedgewars.org/show_bug.cgi?id=722>.")
+ endif()
+endif()
if(BUILD_ENGINE_JS)
if(NOT CMAKE_TOOLCHAIN_FILE)
message(FATAL_ERROR "Missing emscripten toolchain file\nClean your cache and rerun cmake with -DCMAKE_TOOLCHAIN_FILE=${CMAKE_SOURCE_DIR}/cmake_modules/Platform/Emscripten.cmake")