2019-05-15 00:00:36 +10:00
|
|
|
# Description: API and commands for processing SPIR-V modules
|
|
|
|
# URL: https://www.khronos.org/vulkan/
|
|
|
|
# Maintainer: Danny Rawlins, crux at romster dot me
|
2019-05-15 00:15:44 +10:00
|
|
|
# Depends on: python3 spirv-headers
|
2019-05-15 00:00:36 +10:00
|
|
|
|
|
|
|
name=spirv-tools
|
|
|
|
version=2019.2
|
2019-05-19 01:24:22 +10:00
|
|
|
release=3
|
2019-05-15 00:15:44 +10:00
|
|
|
source=(https://github.com/KhronosGroup/SPIRV-Tools/archive//v$version/SPIRV-Tools-v$version.tar.gz)
|
2019-05-15 00:00:36 +10:00
|
|
|
|
|
|
|
build() {
|
2019-05-19 01:24:22 +10:00
|
|
|
cd SPIRV-Tools-$version
|
2019-05-15 00:00:36 +10:00
|
|
|
|
2019-05-19 01:24:22 +10:00
|
|
|
mkdir build-{shared,static}
|
2019-05-15 00:00:36 +10:00
|
|
|
|
2019-05-19 01:24:22 +10:00
|
|
|
local config="
|
|
|
|
-DCMAKE_INSTALL_PREFIX=/usr \
|
|
|
|
-DCMAKE_INSTALL_LIBDIR=lib \
|
|
|
|
-DCMAKE_BUILD_TYPE=Release \
|
|
|
|
-DSPIRV_WERROR=Off \
|
|
|
|
-DSPIRV-Headers_SOURCE_DIR=/usr"
|
2019-05-15 00:00:36 +10:00
|
|
|
|
2019-05-19 01:24:22 +10:00
|
|
|
(cd build-static
|
|
|
|
cmake .. $config -DBUILD_SHARED_LIBS=OFF
|
|
|
|
make
|
|
|
|
)
|
|
|
|
|
|
|
|
(cd build-shared
|
|
|
|
cmake .. $config -DBUILD_SHARED_LIBS=ON
|
|
|
|
make
|
|
|
|
)
|
|
|
|
|
|
|
|
make -C build-static DESTDIR=$PKG install
|
|
|
|
make -C build-shared DESTDIR=$PKG install
|
2019-05-15 00:00:36 +10:00
|
|
|
}
|