Skip to content
Permalink
Browse files

spirv-tools: new port

  • Loading branch information...
eintw1ck authored and pmetzger committed Jul 8, 2019
1 parent 09508d6 commit d50d714f5fe856605f928269546693fa7463e4b7
Showing with 56 additions and 0 deletions.
  1. +56 −0 graphics/spirv-tools/Portfile
@@ -0,0 +1,56 @@
# -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:ft=tcl:et:sw=4:ts=4:sts=4

PortSystem 1.0
PortGroup github 1.0
PortGroup cmake 1.1

github.setup KhronosGroup SPIRV-Tools 2019.3 v
name spirv-tools

categories graphics
platforms darwin
license Apache-2

maintainers {itanimul.li:josh @eintw1ck} openmaintainer
description Various SPIRV tools
long_description SPIRV assembler, binary module parser, disassembler, validator, and optimizer


homepage https://vulkan.lunarg.com

use_zip no
checksums SPIRV-Tools-2019.3.tar.gz \
rmd160 d6e361bb4f027f5ab78476e4bf9cfd9d337a5c4b \
sha256 921830ce15f2de8ff9062eb149c9082998653ce90c03b7dda0a1894ca0e473d6 \
size 1613535 \
SPIRV-Headers-de99d4d834aeb51dd9f099baa285bd44fd04bb3d.tar.gz \
rmd160 2598c9789988590edc78b04f9a88e437de6c22be \
sha256 e4c5af53ed10a90a8d665a09a575c9dea845fa6e13785417303a33617b9a2568 \
size 365208

depends_build-append \
port:python37

pre-configure {
file mkdir ${workpath}/bin
file link -symbolic ${workpath}/bin/python ${prefix}/bin/python3.7
configure.env-append PATH="${workpath}/bin:$::env(PATH)"
}

set submodules {
KhronosGroup SPIRV-Headers de99d4d834aeb51dd9f099baa285bd44fd04bb3d external/spirv-headers
}

foreach {sub_author sub_project sub_commit sub_dest} ${submodules} {
master_sites-append https://github.com/${sub_author}/${sub_project}/archive/${sub_commit}.tar.gz?dummy=:${sub_project}
distfiles-append ${sub_project}-${sub_commit}.tar.gz:${sub_project}
}

post-extract {
ln -s {*}[glob -directory ${workpath} -tails ${github.project}-*] ${worksrcpath}
foreach {sub_author sub_project sub_commit sub_dest} ${submodules} {
ln -s {*}[glob ${workpath}/${sub_project}-*] ${worksrcpath}/${sub_dest}
}
}

configure.args-append -DSPIRV_WERROR=OFF

0 comments on commit d50d714

Please sign in to comment.
You can’t perform that action at this time.