vulkan: Fix windows api conflict
It must be undefined in the header too
Fixes: e487ae1b
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8975>
This commit is contained in:
@@ -56,6 +56,9 @@ if with_xlib_lease
|
|||||||
vulkan_wsi_deps += [dep_xlib_xrandr]
|
vulkan_wsi_deps += [dep_xlib_xrandr]
|
||||||
vulkan_wsi_list += ['xlib_xrandr']
|
vulkan_wsi_list += ['xlib_xrandr']
|
||||||
endif
|
endif
|
||||||
|
if with_platform_windows
|
||||||
|
vulkan_wsi_args += ['-DVK_USE_PLATFORM_WIN32_KHR']
|
||||||
|
endif
|
||||||
|
|
||||||
|
|
||||||
subdir('util')
|
subdir('util')
|
||||||
|
@@ -52,6 +52,16 @@ TEMPLATE_H = Template(COPYRIGHT + """\
|
|||||||
|
|
||||||
#include "vk_extensions.h"
|
#include "vk_extensions.h"
|
||||||
|
|
||||||
|
/* Windows api conflict */
|
||||||
|
#ifdef _WIN32
|
||||||
|
#ifdef CreateSemaphore
|
||||||
|
#undef CreateSemaphore
|
||||||
|
#endif
|
||||||
|
#ifdef CreateEvent
|
||||||
|
#undef CreateEvent
|
||||||
|
#endif
|
||||||
|
#endif
|
||||||
|
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
extern "C" {
|
extern "C" {
|
||||||
#endif
|
#endif
|
||||||
@@ -195,16 +205,6 @@ TEMPLATE_C = Template(COPYRIGHT + """\
|
|||||||
#include "util/macros.h"
|
#include "util/macros.h"
|
||||||
#include "string.h"
|
#include "string.h"
|
||||||
|
|
||||||
/* Windows api conflict */
|
|
||||||
#ifdef _WIN32
|
|
||||||
#ifdef CreateSemaphore
|
|
||||||
#undef CreateSemaphore
|
|
||||||
#endif
|
|
||||||
#ifdef CreateEvent
|
|
||||||
#undef CreateEvent
|
|
||||||
#endif
|
|
||||||
#endif
|
|
||||||
|
|
||||||
<%def name="load_dispatch_table(type, VkType, ProcAddr, entrypoints)">
|
<%def name="load_dispatch_table(type, VkType, ProcAddr, entrypoints)">
|
||||||
void
|
void
|
||||||
vk_${type}_dispatch_table_load(struct vk_${type}_dispatch_table *table,
|
vk_${type}_dispatch_table_load(struct vk_${type}_dispatch_table *table,
|
||||||
|
Reference in New Issue
Block a user