summaryrefslogtreecommitdiffstats
path: root/source/l/spirv-llvm-translator
diff options
context:
space:
mode:
author Patrick J Volkerding <volkerdi@slackware.com>2021-10-15 20:47:13 +0000
committer Eric Hameleers <alien@slackware.com>2021-10-16 09:04:20 +0200
commitaadd8167b60785f4ee2cc4368e1faa018900a387 (patch)
treef91b6de5d9fba92a6f44420557f5a08a09123b91 /source/l/spirv-llvm-translator
parentbd6ff8d439f656e50de1d6f7d43464bd5dcc3bab (diff)
downloadcurrent-aadd8167b60785f4ee2cc4368e1faa018900a387.tar.gz
current-aadd8167b60785f4ee2cc4368e1faa018900a387.tar.xz
Fri Oct 15 20:47:13 UTC 202120211015204713
ap/htop-3.1.1-x86_64-1.txz: Upgraded. d/automake-1.16.2-noarch-4.txz: Rebuilt. The GNU toolchain is making it increasingly impossible to use our usual "${ARCH}-slackware-linux" host, erroring out with a host mismatch on at least GTK+2. So, we'll drop back to this version of automake for now, with a fix applied for detecting Python 3.10. More than likely we'll be changing the host to "${ARCH}-slackware-linux-gnu" to satisfy upstream, but that will have to wait for the next devel cycle. d/llvm-13.0.0-x86_64-1.txz: Upgraded. Shared library .so-version bump. d/rust-1.55.0-x86_64-2.txz: Rebuilt. Recompiled against llvm-13.0.0. kde/kdevelop-5.6.2-x86_64-6.txz: Rebuilt. Recompiled against llvm-13.0.0. kde/plasma-workspace-5.23.0-x86_64-2.txz: Rebuilt. Applied upstream patch: [PATCH] sddm-theme: fix missing password field on "Other" page. Thanks to USUARIONUEVO and LuckyCyborg. l/libclc-13.0.0-x86_64-1.txz: Upgraded. Recompiled against llvm-13.0.0. l/python-pillow-8.4.0-x86_64-1.txz: Upgraded. l/qt5-5.15.3_20211013_5c7c3af5-x86_64-1.txz: Upgraded. Upgraded to latest git (might as well) and compiled against llvm-13.0.0. l/spirv-llvm-translator-20210920_098034ea-x86_64-1.txz: Upgraded. Recompiled against llvm-13.0.0. x/mesa-21.2.4-x86_64-1.txz: Upgraded. Compiled against llvm-13.0.0. xap/pidgin-2.14.8-x86_64-1.txz: Upgraded.
Diffstat (limited to 'source/l/spirv-llvm-translator')
-rwxr-xr-xsource/l/spirv-llvm-translator/fetch-SPIRV-LLVM-Translator.sh52
-rwxr-xr-xsource/l/spirv-llvm-translator/spirv-llvm-translator.SlackBuild6
2 files changed, 58 insertions, 0 deletions
diff --git a/source/l/spirv-llvm-translator/fetch-SPIRV-LLVM-Translator.sh b/source/l/spirv-llvm-translator/fetch-SPIRV-LLVM-Translator.sh
new file mode 100755
index 000000000..ee5f62e45
--- /dev/null
+++ b/source/l/spirv-llvm-translator/fetch-SPIRV-LLVM-Translator.sh
@@ -0,0 +1,52 @@
+#!/bin/sh
+
+# Copyright 2021 Patrick J. Volkerding, Sebeka, Minnesota, USA
+# All rights reserved.
+#
+# Redistribution and use of this script, with or without modification, is
+# permitted provided that the following conditions are met:
+#
+# 1. Redistributions of this script must retain the above copyright
+# notice, this list of conditions and the following disclaimer.
+#
+# THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR IMPLIED
+# WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
+# MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO
+# EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
+# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
+# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
+# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
+# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
+# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+
+PKGNAM=SPIRV-LLVM-Translator
+
+# Pull a stable branch + patches
+BRANCH=${1:-llvm_release_130}
+
+# Clear download area:
+rm -rf ${PKGNAM}
+
+# Clone repository:
+git clone https://github.com/KhronosGroup/${PKGNAM}
+
+# checkout $BRANCH:
+( cd ${PKGNAM}
+ git checkout $BRANCH || exit 1
+)
+
+HEADISAT="$( cd ${PKGNAM} && git log -1 --format=%h )"
+DATE="$( cd ${PKGNAM} && git log -1 --format=%cd --date=format:%Y%m%d )"
+LONGDATE="$( cd ${PKGNAM} && git log -1 --format=%cd --date=format:%c )"
+# Cleanup. We're not packing up the whole git repo.
+( cd ${PKGNAM} && find . -type d -name ".git*" -exec rm -rf {} \; 2> /dev/null )
+mv ${PKGNAM} ${PKGNAM}-${DATE}_${HEADISAT}
+tar cf ${PKGNAM}-${DATE}_${HEADISAT}.tar ${PKGNAM}-${DATE}_${HEADISAT}
+plzip -9 -f ${PKGNAM}-${DATE}_${HEADISAT}.tar
+rm -rf ${PKGNAM}-${DATE}_${HEADISAT}
+touch -d "$LONGDATE" ${PKGNAM}-${DATE}_${HEADISAT}.tar.lz
+echo
+echo "${PKGNAM} branch $BRANCH with HEAD at $HEADISAT packaged as ${PKGNAM}-${DATE}_${HEADISAT}.tar.lz"
+echo
diff --git a/source/l/spirv-llvm-translator/spirv-llvm-translator.SlackBuild b/source/l/spirv-llvm-translator/spirv-llvm-translator.SlackBuild
index 78ca6cab2..aa32098ff 100755
--- a/source/l/spirv-llvm-translator/spirv-llvm-translator.SlackBuild
+++ b/source/l/spirv-llvm-translator/spirv-llvm-translator.SlackBuild
@@ -83,6 +83,11 @@ find . \
\( -perm 666 -o -perm 664 -o -perm 600 -o -perm 444 -o -perm 440 -o -perm 400 \) \
-exec chmod 644 {} \+
+# This git pull needs a specific set of headers. These were obtained by letting
+# the build download them, and then tarring them up and pointing to them with
+# the -DLLVM_EXTERNAL_SPIRV_HEADERS_SOURCE_DIR option below.
+tar xf $CWD/SPIRV-Headers.tar.lz
+
# Build and install:
mkdir -p build
cd build
@@ -97,6 +102,7 @@ cd build
-DLIB_SUFFIX=${LIBDIRSUFFIX} \
-DBUILD_SHARED_LIBS=ON \
-DCMAKE_BUILD_TYPE=Release \
+ -DLLVM_EXTERNAL_SPIRV_HEADERS_SOURCE_DIR=$TMP/SPIRV-LLVM-Translator-$VERSION/SPIRV-Headers \
..
make $NUMJOBS || make || exit 1
make $NUMJOBS llvm-spirv || make llvm-spirv || exit 1