From 6a870a788482465adcd2d1150e9f0a9def3674b1 Mon Sep 17 00:00:00 2001 From: Yurii Kolesnykov Date: Thu, 7 Feb 2019 00:09:33 +0200 Subject: [PATCH] vulkan-headers 1.1.99 (new formula) Closes #36781. Signed-off-by: FX Coudert --- Formula/vulkan-headers.rb | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 Formula/vulkan-headers.rb diff --git a/Formula/vulkan-headers.rb b/Formula/vulkan-headers.rb new file mode 100644 index 0000000000..caa51a0cad --- /dev/null +++ b/Formula/vulkan-headers.rb @@ -0,0 +1,27 @@ +class VulkanHeaders < Formula + desc "Vulkan Header files and API registry" + homepage "https://github.com/KhronosGroup/Vulkan-Headers" + url "https://github.com/KhronosGroup/Vulkan-Headers/archive/v1.1.99.tar.gz" + sha256 "37506deaf56b254193e4fa83195add2617e881efcac3d2ff5f0cf49353eb9aa8" + + depends_on "cmake" => :build + + def install + system "cmake", ".", *std_cmake_args + system "make", "install" + end + + test do + (testpath/"test.c").write <<~EOS + #include + #include + + int main() { + printf("vulkan version %d", VK_VERSION_1_0); + return 0; + } + EOS + system ENV.cc, "test.c", "-o", "test" + system "./test" + end +end