Explorar o código

Prevent editor compilation with regex module disabled, which is not supported

PouleyKetchoupp %!s(int64=6) %!d(string=hai) anos
pai
achega
a1a0fb1467
Modificáronse 1 ficheiros con 7 adicións e 0 borrados
  1. 7 0
      SConstruct

+ 7 - 0
SConstruct

@@ -484,6 +484,13 @@ if selected_platform in platform_list:
     if env['minizip']:
     if env['minizip']:
         env.Append(CPPDEFINES=['MINIZIP_ENABLED'])
         env.Append(CPPDEFINES=['MINIZIP_ENABLED'])
 
 
+    editor_module_list = ['regex']
+    for x in editor_module_list:
+        if not env['module_' + x + '_enabled']:
+            if env['tools']:
+                print("Build option 'module_" + x + "_enabled=no' cannot be used with 'tools=yes' (editor), only with 'tools=no' (export template).")
+                sys.exit(255)
+
     if not env['verbose']:
     if not env['verbose']:
         methods.no_verbose(sys, env)
         methods.no_verbose(sys, env)