CMakeLists.txt
changeset 11659 870f22de388b
parent 11407 bea08a303cb7
child 11664 71bdf987e41f
--- a/CMakeLists.txt	Tue Apr 19 12:04:21 2016 -0400
+++ b/CMakeLists.txt	Wed Apr 20 14:46:04 2016 -0400
@@ -41,6 +41,7 @@
 option(SKIPBUNDLE "Do not create relocate bundle (off)" OFF)
 
 option(BUILD_ENGINE_C "Compile hwengine as native C (off)" OFF)
+option(BUILD_ENGINE_JS "Compile hwengine as javascript (off)" OFF)
 option(GL2 "Enable OpenGL 2 rendering !!!EXPERIMENTAL - DO NOT USE!!! [default: off)" OFF)
 
 set(GHFLAGS "" CACHE STRING "Additional Haskell flags")
@@ -225,6 +226,9 @@
 else()
     #main pascal engine
     add_subdirectory(hedgewars)
+    if(BUILD_ENGINE_JS)
+        message(FATAL_ERROR "This option needs BUILD_ENGINE_C to be set")
+    endif()
 endif()
 
 #Android related build scripts