OSDN Git Service

Linux build fix
authorAlexis Hetu <sugoi@google.com>
Wed, 17 Oct 2018 17:18:04 +0000 (13:18 -0400)
committerAlexis Hétu <sugoi@google.com>
Thu, 18 Oct 2018 14:17:43 +0000 (14:17 +0000)
commite70c3514e5a0019a94260557c0ace269321e9a02
tree696f5836858491bd8b5d5c1fdeba8414689db4c1
parentb83d4911baaeb514eb9376c16f5250ef2bdba68d
Linux build fix

On linux, clang is unable to find the Cast() function used in the
templated destroy() function unless it has already been defined
before the template function. This forces us to make sure all
Cast() functions are available, but simply adding the vulkan objects'
header files in VkMemory.h would cause a circular dependency, which,
while it would be properly guarded by the preprocessor directives,
wouldn't guarantee any include order, due to the nature of circular
dependencies. So, to fix the issue, a new header file, called
VkDestroy.h was added, which can depend on all vulkan objects' header
files without creating a circular dependency.

Also fixed some warnings.

Change-Id: I1f343a8c476d6308d4555009848a234b0695661e
Reviewed-on: https://swiftshader-review.googlesource.com/c/21668
Reviewed-by: Nicolas Capens <nicolascapens@google.com>
Tested-by: Alexis Hétu <sugoi@google.com>
31 files changed:
CMakeLists.txt
src/D3D8/D3D8.vcxproj
src/D3D9/D3D9.vcxproj
src/OpenGL/compiler/Compiler.vcxproj
src/OpenGL/compiler/preprocessor/preprocessor.vcxproj
src/OpenGL/libEGL/libEGL.vcxproj
src/OpenGL/libGLES_CM/libGLES_CM.vcxproj
src/OpenGL/libGLESv2/libGLESv2.vcxproj
src/Reactor/Reactor.vcxproj
src/Reactor/ReactorUnitTests.vcxproj
src/Reactor/Subzero.vcxproj
src/Reactor/SubzeroLLVMDependencies.vcxproj
src/SwiftShader/SwiftShader.vcxproj
src/Vulkan/VkDestroy.h [new file with mode: 0644]
src/Vulkan/VkDevice.cpp
src/Vulkan/VkInstance.cpp
src/Vulkan/VkInstance.hpp
src/Vulkan/VkMemory.cpp
src/Vulkan/VkMemory.h
src/Vulkan/VkObject.hpp
src/Vulkan/VkPhysicalDevice.cpp
src/Vulkan/VkQueue.hpp
src/Vulkan/libVulkan.cpp
src/Vulkan/vulkan.vcxproj
src/Vulkan/vulkan.vcxproj.filters
tests/fuzzers/VertexRoutineFuzzer.vcxproj
third_party/PowerVR_SDK/Examples/Advanced/ChameleonMan/OGLES2/Build/WindowsVC2010/OGLES2ChameleonMan.vcxproj
third_party/PowerVR_SDK/Examples/Beginner/01_HelloAPI/OGLES2/Build/WindowsVC2010/OGLES2HelloAPI.vcxproj
third_party/PowerVR_SDK/Examples/Beginner/04_BasicTnL/OGLES/Build/WindowsVC2010/OGLESBasicTnL.vcxproj
third_party/PowerVR_SDK/Examples/Intermediate/ColourGrading/OGLES3/Build/WindowsVC2010/OGLES3ColourGrading.vcxproj
third_party/PowerVR_SDK/Examples/Intermediate/DisplacementMap/OGLES2/Build/WindowsVC2010/OGLES2DisplacementMap.vcxproj