diff --git a/ref_vk/wscript b/ref_vk/wscript index 4df3f0d6..0e67741e 100644 --- a/ref_vk/wscript +++ b/ref_vk/wscript @@ -9,6 +9,10 @@ top = '.' def options(opt): grp = opt.add_option_group('ref_vk options') + + grp.add_option('--disable-vulkan', action='store_false', dest='VK', default=True, + help = 'disable vulkan [default: vulkan is enabled]') + grp.add_option('', '--aftermath', action='store', dest = 'NSIGHT_AFTERMATH_SDK', default = None, help = 'Path to Nvidia Nsight Aftermath SDK (optional)') @@ -17,8 +21,9 @@ def configure(conf): if conf.options.DEDICATED: return - # Vulkan is not supported on Android yet for CI reasons: requres NDK>12, glslc lookup etc. - if conf.env.DEST_OS == 'android': + conf.env.VK = conf.options.VK + + if not conf.env.VK: return conf.load('glslc') @@ -55,6 +60,9 @@ def configure(conf): conf.env.GLSLCFLAGS += ['-g'] def build(bld): + if not bld.env.VK: + return + libs = [ 'public', 'M' ] defines = [] libpath = [] @@ -77,11 +85,8 @@ def build(bld): if bld.env.HAVE_AFTERMATH: defines.append('USE_AFTERMATH') libs.append('AFTERMATH') - # includes.append(bld.env.AFTERMATH_INCLUDE) - # libs.append(bld.env.AFTERMATH_LIB) - # libpath.append(bld.env.AFTERMATH_LIBDIR) - #bld.env.CFLAGS += ["/WX"] + #FIXME bld.env.CFLAGS += ["/WX"] bld.shlib( source = source, @@ -100,6 +105,6 @@ def build(bld): features = 'glsl', # includes = 'shaders/', # write your includes here # defines = 'TEST', # write your C preprocessor defines here - install_path = bld.env.LIBDIR + '/valve' # TEMPORARY!!!! + install_path = bld.env.LIBDIR + '/valve' # FIXME TEMPORARY!!!! ) diff --git a/wscript b/wscript index ef0fac93..f6fed8c0 100644 --- a/wscript +++ b/wscript @@ -131,11 +131,14 @@ def configure(conf): conf.options.NANOGL = True conf.options.GLWES = True conf.options.GL = False + # Vulkan is not supported on Android yet for CI reasons: requres NDK>12, glslc lookup etc. + conf.options.VK = False elif conf.env.MAGX: conf.options.USE_SELECT = True conf.options.SDL12 = True conf.options.NO_VGUI = True conf.options.GL = False + conf.options.VK = False conf.options.LOW_MEMORY = 1 conf.options.SINGLE_BINARY = True conf.options.NO_ASYNC_RESOLVE = True