Add defines to put the storage for a DispatchLoaderDynamic in a DLL.

This commit is contained in:
Markus Tavenrath
2020-06-25 13:07:30 +02:00
parent 7cda7d45ac
commit 34076925af
7 changed files with 191 additions and 7 deletions

View File

@@ -4595,15 +4595,25 @@ namespace VULKAN_HPP_NAMESPACE
# endif
#endif
#if defined( _WIN32 ) && defined( VULKAN_HPP_STORAGE_SHARED )
# ifdef VULKAN_HPP_STORAGE_SHARED_EXPORT
# define VULKAN_HPP_STORAGE_API __declspec( dllexport )
# else
# define VULKAN_HPP_STORAGE_API __declspec( dllimport )
# endif
#else
# define VULKAN_HPP_STORAGE_API
#endif
#if !defined( VULKAN_HPP_DEFAULT_DISPATCHER )
# if VULKAN_HPP_DISPATCH_LOADER_DYNAMIC == 1
# define VULKAN_HPP_DEFAULT_DISPATCHER ::VULKAN_HPP_NAMESPACE::defaultDispatchLoaderDynamic
# define VULKAN_HPP_DEFAULT_DISPATCH_LOADER_DYNAMIC_STORAGE \
namespace VULKAN_HPP_NAMESPACE \
{ \
DispatchLoaderDynamic defaultDispatchLoaderDynamic; \
# define VULKAN_HPP_DEFAULT_DISPATCH_LOADER_DYNAMIC_STORAGE \
namespace VULKAN_HPP_NAMESPACE \
{ \
VULKAN_HPP_STORAGE_API DispatchLoaderDynamic defaultDispatchLoaderDynamic; \
}
extern DispatchLoaderDynamic defaultDispatchLoaderDynamic;
extern VULKAN_HPP_STORAGE_API DispatchLoaderDynamic defaultDispatchLoaderDynamic;
# else
# define VULKAN_HPP_DEFAULT_DISPATCHER ::VULKAN_HPP_NAMESPACE::DispatchLoaderStatic()
# define VULKAN_HPP_DEFAULT_DISPATCH_LOADER_DYNAMIC_STORAGE