diff options
| -rw-r--r-- | .gitmodules | 2 | ||||
| -rw-r--r-- | CMakeLists.txt | 1 | ||||
| -rw-r--r-- | externals/CMakeLists.txt | 6 | ||||
| m--------- | externals/VulkanMemoryAllocator | 0 | ||||
| m--------- | externals/vma/VulkanMemoryAllocator | 0 | ||||
| -rw-r--r-- | src/video_core/CMakeLists.txt | 6 | ||||
| -rw-r--r-- | src/video_core/vulkan_common/vma.cpp (renamed from externals/vma/vma.cpp) | 0 |
7 files changed, 10 insertions, 5 deletions
diff --git a/.gitmodules b/.gitmodules index 9f96b70be..361f4845b 100644 --- a/.gitmodules +++ b/.gitmodules | |||
| @@ -56,5 +56,5 @@ | |||
| 56 | path = externals/nx_tzdb/tzdb_to_nx | 56 | path = externals/nx_tzdb/tzdb_to_nx |
| 57 | url = https://github.com/lat9nq/tzdb_to_nx.git | 57 | url = https://github.com/lat9nq/tzdb_to_nx.git |
| 58 | [submodule "VulkanMemoryAllocator"] | 58 | [submodule "VulkanMemoryAllocator"] |
| 59 | path = externals/vma/VulkanMemoryAllocator | 59 | path = externals/VulkanMemoryAllocator |
| 60 | url = https://github.com/GPUOpen-LibrariesAndSDKs/VulkanMemoryAllocator.git | 60 | url = https://github.com/GPUOpen-LibrariesAndSDKs/VulkanMemoryAllocator.git |
diff --git a/CMakeLists.txt b/CMakeLists.txt index 7f8febb90..bf76282e1 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt | |||
| @@ -281,6 +281,7 @@ find_package(LLVM MODULE COMPONENTS Demangle) | |||
| 281 | find_package(lz4 REQUIRED) | 281 | find_package(lz4 REQUIRED) |
| 282 | find_package(nlohmann_json 3.8 REQUIRED) | 282 | find_package(nlohmann_json 3.8 REQUIRED) |
| 283 | find_package(Opus 1.3 MODULE) | 283 | find_package(Opus 1.3 MODULE) |
| 284 | find_package(VulkanMemoryAllocator CONFIG) | ||
| 284 | find_package(ZLIB 1.2 REQUIRED) | 285 | find_package(ZLIB 1.2 REQUIRED) |
| 285 | find_package(zstd 1.5 REQUIRED) | 286 | find_package(zstd 1.5 REQUIRED) |
| 286 | 287 | ||
diff --git a/externals/CMakeLists.txt b/externals/CMakeLists.txt index 4ff588851..1f7cd598e 100644 --- a/externals/CMakeLists.txt +++ b/externals/CMakeLists.txt | |||
| @@ -144,9 +144,9 @@ endif() | |||
| 144 | add_subdirectory(nx_tzdb) | 144 | add_subdirectory(nx_tzdb) |
| 145 | 145 | ||
| 146 | # VMA | 146 | # VMA |
| 147 | add_library(vma vma/vma.cpp) | 147 | if (NOT TARGET GPUOpen::VulkanMemoryAllocator) |
| 148 | target_include_directories(vma PUBLIC ./vma/VulkanMemoryAllocator/include) | 148 | add_subdirectory(VulkanMemoryAllocator) |
| 149 | target_link_libraries(vma PRIVATE Vulkan::Headers) | 149 | endif() |
| 150 | 150 | ||
| 151 | if (NOT TARGET LLVM::Demangle) | 151 | if (NOT TARGET LLVM::Demangle) |
| 152 | add_library(demangle demangle/ItaniumDemangle.cpp) | 152 | add_library(demangle demangle/ItaniumDemangle.cpp) |
diff --git a/externals/VulkanMemoryAllocator b/externals/VulkanMemoryAllocator new file mode 160000 | |||
| Subproject 9b0fc3e7b02afe97895eb3e945fe800c3a7485a | |||
diff --git a/externals/vma/VulkanMemoryAllocator b/externals/vma/VulkanMemoryAllocator deleted file mode 160000 | |||
| Subproject 0aa3989b8f382f185fdf646cc83a1d16fa31d6a | |||
diff --git a/src/video_core/CMakeLists.txt b/src/video_core/CMakeLists.txt index 3b2fe01da..7f79111e0 100644 --- a/src/video_core/CMakeLists.txt +++ b/src/video_core/CMakeLists.txt | |||
| @@ -274,6 +274,7 @@ add_library(video_core STATIC | |||
| 274 | vulkan_common/vulkan_wrapper.h | 274 | vulkan_common/vulkan_wrapper.h |
| 275 | vulkan_common/nsight_aftermath_tracker.cpp | 275 | vulkan_common/nsight_aftermath_tracker.cpp |
| 276 | vulkan_common/nsight_aftermath_tracker.h | 276 | vulkan_common/nsight_aftermath_tracker.h |
| 277 | vulkan_common/vma.cpp | ||
| 277 | ) | 278 | ) |
| 278 | 279 | ||
| 279 | create_target_directory_groups(video_core) | 280 | create_target_directory_groups(video_core) |
| @@ -291,7 +292,7 @@ target_link_options(video_core PRIVATE ${FFmpeg_LDFLAGS}) | |||
| 291 | 292 | ||
| 292 | add_dependencies(video_core host_shaders) | 293 | add_dependencies(video_core host_shaders) |
| 293 | target_include_directories(video_core PRIVATE ${HOST_SHADERS_INCLUDE}) | 294 | target_include_directories(video_core PRIVATE ${HOST_SHADERS_INCLUDE}) |
| 294 | target_link_libraries(video_core PRIVATE sirit Vulkan::Headers vma) | 295 | target_link_libraries(video_core PRIVATE sirit Vulkan::Headers GPUOpen::VulkanMemoryAllocator) |
| 295 | 296 | ||
| 296 | if (ENABLE_NSIGHT_AFTERMATH) | 297 | if (ENABLE_NSIGHT_AFTERMATH) |
| 297 | if (NOT DEFINED ENV{NSIGHT_AFTERMATH_SDK}) | 298 | if (NOT DEFINED ENV{NSIGHT_AFTERMATH_SDK}) |
| @@ -324,6 +325,9 @@ else() | |||
| 324 | 325 | ||
| 325 | # xbyak | 326 | # xbyak |
| 326 | set_source_files_properties(macro/macro_jit_x64.cpp PROPERTIES COMPILE_OPTIONS "-Wno-conversion;-Wno-shadow") | 327 | set_source_files_properties(macro/macro_jit_x64.cpp PROPERTIES COMPILE_OPTIONS "-Wno-conversion;-Wno-shadow") |
| 328 | |||
| 329 | # VMA | ||
| 330 | set_source_files_properties(vulkan_common/vma.cpp PROPERTIES COMPILE_OPTIONS "-Wno-conversion;-Wno-unused-variable;-Wno-unused-parameter;-Wno-missing-field-initializers") | ||
| 327 | endif() | 331 | endif() |
| 328 | 332 | ||
| 329 | if (ARCHITECTURE_x86_64) | 333 | if (ARCHITECTURE_x86_64) |
diff --git a/externals/vma/vma.cpp b/src/video_core/vulkan_common/vma.cpp index 1fe2cf52b..1fe2cf52b 100644 --- a/externals/vma/vma.cpp +++ b/src/video_core/vulkan_common/vma.cpp | |||