update vulkan-validationlayers (#632)

* update vulkan-validationlayers

* improve ci
pull/635/head
Hoildkv 3 years ago committed by GitHub
parent 4f71b37e1b
commit a214b6dabf
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 4
      .github/workflows/archlinux.yml
  2. 4
      .github/workflows/fedora.yml
  3. 0
      .github/workflows/ubuntu.yml
  4. 23
      packages/v/vulkan-validationlayers/xmake.lua

@ -18,6 +18,10 @@ jobs:
steps:
- name: Installation
run: |
sudo rm -rf /usr/share/dotnet
sudo rm -rf /opt/ghc
sudo rm -rf /usr/local/share/boost
sudo rm -rf "$AGENT_TOOLSDIRECTORY"
pacman -Sy --noconfirm --needed git base-devel perl make unzip
pacman -Sy --noconfirm --needed mesa gcc-fortran glu
- uses: actions/checkout@v1

@ -19,6 +19,10 @@ jobs:
- name: Installation
run: |
uname -a
sudo rm -rf /usr/share/dotnet
sudo rm -rf /opt/ghc
sudo rm -rf /usr/local/share/boost
sudo rm -rf "$AGENT_TOOLSDIRECTORY"
dnf -y install gfortran
dnf -y install mesa-libGL-devel mesa-libGLU-devel
dnf -y install @development-tools @rpm-development-tools

@ -5,6 +5,7 @@ package("vulkan-validationlayers")
set_license("Apache-2.0")
add_urls("https://github.com/KhronosGroup/Vulkan-ValidationLayers/archive/sdk-$(version).tar.gz", {version = function (version) return version:gsub("%+", ".") end})
add_versions("1.2.189+1", "d169ae71ae3ba12159df355b58f86f5635062c695d1deac9b97d5653561d517d")
add_versions("1.2.162+0", "80aa9e180b3900598121d7a3ea613665b99aae21bb40268ecafd82df8016c6f5")
add_versions("1.2.154+0", "8898ab05d0d8dec04fbba03d0ed2e79a1eb5c0382e5c89d4c737b45a6648f7f9")
@ -15,6 +16,7 @@ package("vulkan-validationlayers")
if is_plat("windows") then
add_syslinks("Advapi32")
elseif is_plat("linux") then
add_extsources("apt::vulkan-validationlayers-dev")
add_deps("ninja")
add_deps("wayland", "libxrandr", "libxcb", "libxkbcommon")
end
@ -22,6 +24,9 @@ package("vulkan-validationlayers")
on_load("windows", "linux", function (package)
local sdkver = package:version():split("%+")[1]
package:add("deps", "vulkan-headers " .. sdkver)
if package:version():ge("1.2.189") then
package:add("deps", "robin-hood-hashing")
end
end)
on_install("windows", "linux", function (package)
@ -45,18 +50,18 @@ package("vulkan-validationlayers")
end
local configs = {"-DBUILD_TESTS=OFF"}
local vulkan_headers = package:dep("vulkan-headers")
local glslang = package:dep("glslang")
local spirv_headers = package:dep("spirv-headers")
local spirv_tools = package:dep("spirv-tools")
table.insert(configs, "-DVULKAN_HEADERS_INSTALL_DIR=" .. vulkan_headers:installdir())
table.insert(configs, "-DGLSLANG_INSTALL_DIR=" .. glslang:installdir())
table.insert(configs, "-DSPIRV_HEADERS_INSTALL_DIR=" .. spirv_headers:installdir())
table.insert(configs, "-DSPIRV_TOOLS_INSTALL_DIR=" .. spirv_tools:installdir())
table.insert(configs, "-DVULKAN_HEADERS_INSTALL_DIR=" .. package:dep("vulkan-headers"):installdir())
table.insert(configs, "-DGLSLANG_INSTALL_DIR=" .. package:dep("glslang"):installdir())
table.insert(configs, "-DSPIRV_HEADERS_INSTALL_DIR=" .. package:dep("spirv-headers"):installdir())
table.insert(configs, "-DSPIRV_TOOLS_INSTALL_DIR=" .. package:dep("spirv-tools"):installdir())
if package:version():ge("1.2.189") then
io.replace("CMakeLists.txt", "/src/include", "/include", {plain = true})
table.insert(configs, "-DROBIN_HOOD_HASHING_INSTALL_DIR=" .. package:dep("robin-hood-hashing"):installdir())
end
if package:is_plat("windows") then
cmake.install(package, configs, {buildir = os.tmpfile() .. ".dir"})
elseif is_plat("linux") then
elseif package:is_plat("linux") then
cmake.install(package, configs, {buildir = os.tmpfile() .. ".dir", cmake_generator = "Ninja", envs = envs})
end
os.mv("layers", package:installdir("include"))

Loading…
Cancel
Save