Kai Pastor 8397227251
[vulkan-sdk-components] Use separate port for the SDK (#35742)
* [vulkan-sdk] Separate port

* Update ci.baseline.txt

* [hikogui] Using glslc from shaderc

* [vulkan] Drop LICENSE.txt

* [vulkan-sdk-components] Avoid vulkan-sdk name

* [vulkan] Fixup copyright text
2023-12-29 00:21:45 -08:00

27 lines
903 B
CMake

set(VCPKG_POLICY_EMPTY_PACKAGE enabled)
set(components COMPONENTS glslang)
if(VCPKG_TARGET_IS_WINDOWS)
list(APPEND components dxc)
endif()
set(vulkan_result_file "${CURRENT_BUILDTREES_DIR}/vulkan-${TARGET_TRIPLET}.cmake.log")
vcpkg_cmake_configure(
SOURCE_PATH "${CURRENT_INSTALLED_DIR}/share/vulkan/detect-vulkan"
OPTIONS
"-DVCPKG_VULKAN_VERSION=${VERSION}"
"-DVCPKG_VULKAN_COMPONENTS=${components}"
OPTIONS_RELEASE
"-DOUTFILE=${vulkan_result_file}"
)
include("${vulkan_result_file}")
if(NOT DETECTED_Vulkan_FOUND)
message(FATAL_ERROR "The Vulkan SDK wasn't found.")
endif()
find_file(vulkan_license NAMES LICENSE.txt PATHS ${DETECTED_Vulkan_INCLUDE_DIRS} "${CURRENT_PORT_DIR}" PATH_SUFFIXES "..")
vcpkg_install_copyright(FILE_LIST "${vulkan_license}")
file(INSTALL "${CMAKE_CURRENT_LIST_DIR}/usage" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}")