2019-04-21 12:51:45 +10:00
|
|
|
# Description: API and commands for processing SPIR-V modules
|
|
|
|
# URL: https://www.khronos.org/vulkan/
|
|
|
|
# Maintainer: CRUX compat-32 Team, compat-32-ports at crux dot nu
|
|
|
|
# Depends on: spirv-tools
|
|
|
|
|
|
|
|
name=spirv-tools-32
|
2021-02-28 00:03:59 +11:00
|
|
|
version=2020.5-b27b1af
|
2020-07-24 18:35:06 +10:00
|
|
|
release=1
|
2020-11-01 16:47:07 +11:00
|
|
|
source=(
|
|
|
|
#https://github.com/KhronosGroup/SPIRV-Tools/archive/v$version/SPIRV-Tools-v$version.tar.gz
|
2021-02-28 00:03:59 +11:00
|
|
|
https://github.com/KhronosGroup/SPIRV-Tools/archive/b27b1afd12d05bf238ac7368bb49de73cd620a8e.zip
|
|
|
|
spirv-tools-gcc11.patch)
|
2019-04-21 12:51:45 +10:00
|
|
|
|
|
|
|
build() {
|
2021-02-28 00:03:59 +11:00
|
|
|
mv SPIRV-Tools-b27b1afd12d05bf238ac7368bb49de73cd620a8e SPIRV-Tools-$version
|
2020-11-01 16:47:07 +11:00
|
|
|
|
|
|
|
local config="
|
|
|
|
-SSPIRV-Tools-$version \
|
|
|
|
-DCMAKE_INSTALL_PREFIX=/usr \
|
|
|
|
-DCMAKE_INSTALL_LIBDIR=lib32 \
|
|
|
|
-DCMAKE_BUILD_TYPE=Release \
|
|
|
|
-DSPIRV_WERROR=OFF \
|
|
|
|
-DSPIRV-Headers_SOURCE_DIR=/usr \
|
|
|
|
-DPYTHON_EXECUTABLE=/usr/bin/python3 \
|
|
|
|
-GNinja"
|
|
|
|
|
2021-02-28 00:03:59 +11:00
|
|
|
patch -d SPIRV-Tools-$version -p1 -i $SRC/spirv-tools-gcc11.patch
|
2020-11-01 16:47:07 +11:00
|
|
|
|
|
|
|
cmake -Bbuild-static $config -DBUILD_SHARED_LIBS=OFF
|
|
|
|
cmake --build build-static
|
|
|
|
|
|
|
|
cmake -Bbuild-shared $config -DBUILD_SHARED_LIBS=ON
|
|
|
|
cmake --build build-shared
|
|
|
|
|
|
|
|
DESTDIR=$PKG cmake --build build-static --target install
|
|
|
|
DESTDIR=$PKG cmake --build build-shared --target install
|
2019-08-30 19:21:51 +10:00
|
|
|
|
|
|
|
rm -r $PKG/usr/{bin,include}
|
2019-04-21 12:51:45 +10:00
|
|
|
}
|