mirror of
https://github.com/w23/xash3d-fwgs
synced 2024-12-16 14:10:11 +01:00
auto-detect VULKAN_SDK path on windows
This commit is contained in:
parent
5e3f1e52d6
commit
ded8442993
@ -275,7 +275,7 @@ static vk_buffer_alloc_t renderBufferAlloc( uint32_t unit_size, uint32_t count )
|
||||
}
|
||||
|
||||
ret.buffer_offset_in_units = offset / unit_size;
|
||||
ret.ptr = g_render.buffer.mapped + offset;
|
||||
ret.ptr = ((byte*)g_render.buffer.mapped) + offset;
|
||||
|
||||
g_render.stat.align_holes_size += offset - g_render.buffer_free_offset;
|
||||
g_render.buffer_free_offset = offset + alloc_size;
|
||||
|
@ -17,6 +17,14 @@ def configure(conf):
|
||||
|
||||
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.end_msg('no')
|
||||
conf.env.VULKAN_SDK = conf.environ['VULKAN_SDK']
|
||||
conf.end_msg('found at ' + conf.env.VULKAN_SDK)
|
||||
|
||||
def build(bld):
|
||||
libs = [ 'public', 'M' ]
|
||||
|
||||
@ -31,6 +39,9 @@ def build(bld):
|
||||
'../common',
|
||||
'../pm_shared' ]
|
||||
|
||||
if bld.env.DEST_OS == 'win32':
|
||||
includes.append(bld.env.VULKAN_SDK + '\\Include')
|
||||
|
||||
bld.shlib(
|
||||
source = source,
|
||||
target = 'ref_vk',
|
||||
|
Loading…
Reference in New Issue
Block a user