[crux-commits] ports/compat-32 (3.6): spirv-tools-32: 2020.5-b27b1af -> 2020.7

crux at crux.nu crux at crux.nu
Sat Apr 10 15:54:47 UTC 2021


commit f7cd8d90f7eb3db2090e5ee6e2694866911a2bec
Author: Danny Rawlins <contact at romster.me>
Date:   Sun Apr 11 01:36:09 2021 +1000

    spirv-tools-32: 2020.5-b27b1af -> 2020.7

diff --git a/spirv-tools-32/.signature b/spirv-tools-32/.signature
index c550392..b2792df 100644
--- a/spirv-tools-32/.signature
+++ b/spirv-tools-32/.signature
@@ -1,6 +1,6 @@
 untrusted comment: verify with /etc/ports/compat-32.pub
-RWSwxGo/zH7eXfAkWDyHbR77TCGKCZK6OTs04Jh9TqxFmP6PKKXetQwBImRthGMpll8Xd70O9Ul8QUaKAOVUbQd4iBmtDIF94gk=
-SHA256 (Pkgfile) = 56bfc5d3f850e210445fde2e3bbbda238294290a72d86414a55afd41a32d2ca7
+RWSwxGo/zH7eXfLtRFiI1imwowcx/Vve6sejTmBOERWcGOxkv3nFEnBlKgBCuu0tl6ZmT9yNDOezB+33glTYutrMevOSVHRCGwQ=
+SHA256 (Pkgfile) = e0eef3f5d0a1d7d375f477b1f5cfb46e01f8d10d6b19a4deb5328ab80808c6c3
 SHA256 (.footprint) = 242e30720070a57dd96fadc34548139b480ea807c262e3b5ae6e88851cad8b09
-SHA256 (b27b1afd12d05bf238ac7368bb49de73cd620a8e.zip) = 6a5691e3ac4ad2fae14025be4535cbdf60becc311fd2c07a00019e6167f54222
-SHA256 (spirv-tools-gcc11.patch) = 44962127ac664e437619afdf16c1193b9579d832a9d7c2fae3595f65c3f17923
+SHA256 (SPIRV-Tools-v2020.7.tar.gz) = c06eed1c7a1018b232768481184b5ae4d91d614d7bd7358dc2fe306bd0a39c6e
+SHA256 (SPIRV-Headers-f88a1f98fa7a44ccfcf33d810c72b200e7d9a78a.tar.gz) = 11659b29beeb13b5dc56589f7a933def60bd284ee8955c03a8d7510a465e9f51
diff --git a/spirv-tools-32/Pkgfile b/spirv-tools-32/Pkgfile
index f518ee7..d70dab8 100644
--- a/spirv-tools-32/Pkgfile
+++ b/spirv-tools-32/Pkgfile
@@ -4,32 +4,37 @@
 # Depends on: spirv-tools
 
 name=spirv-tools-32
-version=2020.5-b27b1af
+version=2020.7
+_spirv_headers=f88a1f98fa7a44ccfcf33d810c72b200e7d9a78a
 release=1
-source=(
-	#https://github.com/KhronosGroup/SPIRV-Tools/archive/v$version/SPIRV-Tools-v$version.tar.gz
-	https://github.com/KhronosGroup/SPIRV-Tools/archive/b27b1afd12d05bf238ac7368bb49de73cd620a8e.zip
-	spirv-tools-gcc11.patch)
+source=(https://github.com/KhronosGroup/SPIRV-Tools/archive/v$version/SPIRV-Tools-v$version.tar.gz
+	https://github.com/KhronosGroup/SPIRV-Headers/archive/$_spirv_headers/SPIRV-Headers-$_spirv_headers.tar.gz)
 
 build() {
-	mv SPIRV-Tools-b27b1afd12d05bf238ac7368bb49de73cd620a8e SPIRV-Tools-$version
-
-	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"
-
-	patch -d SPIRV-Tools-$version -p1 -i $SRC/spirv-tools-gcc11.patch
-
-	cmake -Bbuild-static $config -DBUILD_SHARED_LIBS=OFF
+	mv SPIRV-Headers-$_spirv_headers SPIRV-Headers
+	prt-get isinst ninja && PKGMK_SPIRV_TOOLS+=' -G Ninja'
+
+	PKGMK_SPIRV_TOOLS+=" \
+-S SPIRV-Tools-$version \
+-D CMAKE_INSTALL_PREFIX=/usr \
+-D CMAKE_INSTALL_LIBDIR=lib32 \
+-D CMAKE_BUILD_TYPE=Release \
+-D SPIRV_WERROR=OFF \
+-D SPIRV-Headers_SOURCE_DIR=/usr \
+-D PYTHON_EXECUTABLE=/usr/bin/python3 \
+-D SPIRV-Headers_SOURCE_DIR="${SRC}"/SPIRV-Headers \
+-Wno-dev"
+
+	cmake -B build-static $PKGMK_SPIRV_TOOLS \
+		-D CMAKE_C_FLAGS_RELEASE="${CFLAGS}" \
+		-D CMAKE_CXX_FLAGS_RELEASE="${CXXFLAGS}" \
+		-D BUILD_SHARED_LIBS=OFF
 	cmake --build build-static
 
-	cmake -Bbuild-shared $config -DBUILD_SHARED_LIBS=ON
+	cmake -B build-shared $PKGMK_SPIRV_TOOLS \
+		-D CMAKE_C_FLAGS_RELEASE="${CFLAGS}" \
+		-D CMAKE_CXX_FLAGS_RELEASE="${CXXFLAGS}" \
+		-D BUILD_SHARED_LIBS=ON
 	cmake --build build-shared
 
 	DESTDIR=$PKG cmake --build build-static --target install
diff --git a/spirv-tools-32/spirv-tools-gcc11.patch b/spirv-tools-32/spirv-tools-gcc11.patch
deleted file mode 100644
index f5c82da..0000000
--- a/spirv-tools-32/spirv-tools-gcc11.patch
+++ /dev/null
@@ -1,13 +0,0 @@
-diff --git a/source/diagnostic.cpp b/source/diagnostic.cpp
-index edc27c8..77c29d7 100644
---- a/source/diagnostic.cpp
-+++ b/source/diagnostic.cpp
-@@ -37,7 +37,7 @@ spv_diagnostic spvDiagnosticCreate(const spv_position position,
-   diagnostic->position = *position;
-   diagnostic->isTextSource = false;
-   memset(diagnostic->error, 0, length);
--  strncpy(diagnostic->error, message, length);
-+  memcpy(diagnostic->error, message, length);
-   return diagnostic;
- }
- 


More information about the crux-commits mailing list