nvrhi-unbundle-libs.patch 1.1 KB

12345678910111213141516171819202122232425262728293031323334353637383940
  1. --- a/CMakeLists.txt
  2. +++ b/CMakeLists.txt
  3. @@ -55,7 +55,7 @@ endif()
  4. set(CMAKE_MODULE_PATH ${CMAKE_CURRENT_SOURCE_DIR}/cmake)
  5. if (NVRHI_WITH_VULKAN)
  6. - add_subdirectory(thirdparty/Vulkan-Headers)
  7. + find_package(VulkanHeaders REQUIRED)
  8. endif()
  9. if (NVRHI_WITH_RTXMU)
  10. @@ -66,14 +66,15 @@ if (NVRHI_WITH_RTXMU)
  11. option(RTXMU_WITH_VULKAN "" ${NVRHI_WITH_VULKAN})
  12. option(RTXMU_WITH_D3D12 "" ${NVRHI_WITH_DX12})
  13. - add_subdirectory(rtxmu)
  14. + find_package(rtxmu REQUIRED)
  15. endif()
  16. if (NVRHI_WITH_SHADER_COMPILER)
  17. option(CXXOPTS_BUILD_EXAMPLES OFF)
  18. option(CXXOPTS_BUILD_TESTS OFF)
  19. option(CXXOPTS_ENABLE_INSTALL OFF)
  20. - add_subdirectory(thirdparty/cxxopts)
  21. + find_package(cxxopts REQUIRED)
  22. + include_directories(${CXXOPTS_INCLUDE_DIRS})
  23. add_subdirectory(tools/shaderCompiler)
  24. endif()
  25. @@ -309,7 +310,7 @@ if (NVRHI_WITH_VULKAN)
  26. target_link_libraries(${nvrhi_vulkan_target} rtxmu)
  27. endif()
  28. - target_link_libraries(${nvrhi_vulkan_target} Vulkan-Headers)
  29. + target_link_libraries(${nvrhi_vulkan_target} INTERFACE Vulkan::Headers)
  30. endif()