ref_vk: attempt to fix win32 glslc path

This commit is contained in:
Ivan Avdeev 2021-06-07 09:55:33 -07:00
parent c9539f33f4
commit cb7fb0a1c5
2 changed files with 10 additions and 5 deletions

View File

@ -26,17 +26,18 @@ def configure(conf):
if not conf.env.VK:
return
conf.load('glslc')
conf.define('REF_DLL', 1)
if conf.env.DEST_OS == 'win32':
conf.start_msg('Vulkan SDK available?')
if not 'VULKAN_SDK' in conf.environ:
Logs.warn('VULKAN_SDK environment variable is not available, ref_vk will not be built')
conf.error('VULKAN_SDK environment variable is not available, ref_vk will not be built')
conf.end_msg('no')
conf.env.VULKAN_SDK = conf.environ['VULKAN_SDK']
conf.end_msg('found at ' + conf.env.VULKAN_SDK)
conf.load('glslc')
conf.define('REF_DLL', 1)
if conf.options.NSIGHT_AFTERMATH_SDK:
conf.start_msg('Nvidia Nsight Aftermath SDK')
conf.env.HAVE_AFTERMATH = 1

View File

@ -6,7 +6,11 @@ from waflib import *
from waflib.Tools import c_preproc, ccroot
def configure(conf):
conf.find_program('glslc')
if conf.env.DEST_OS == 'win32':
conf.find_program('glslc', path_list=[os.path.join(conf.env.VULKAN_SDK, 'Bin')])
else:
conf.find_program('glslc')
conf.add_os_flags('GLSLCPPFLAGS', dup=False)
conf.add_os_flags('GLSLCFLAGS', dup=False)