diff --git a/x11/vulkan/spirv-llvm/actions.py b/x11/vulkan/spirv-llvm/actions.py
index 75d16bb8db..33447ca76d 100644
--- a/x11/vulkan/spirv-llvm/actions.py
+++ b/x11/vulkan/spirv-llvm/actions.py
@@ -10,9 +10,11 @@ from pisi.actionsapi import shelltools
from pisi.actionsapi import get
tools = "-DLLVM_BUILD_TOOLS=OFF" if get.buildTYPE() == "emul32" else "-DLLVM_BUILD_TOOLS=ON"
+libdir = "lib32" if get.buildTYPE() == "emul32" else "lib"
def setup():
- cmaketools.configure("-DBUILD_SHARED_LIBS=ON \
+ options = "-DBUILD_SHARED_LIBS=ON \
+ -DCMAKE_INSTALL_PREFIX=/usr \
-DCMAKE_BUILD_TYPE=Release \
-DCMAKE_POSITION_INDEPENDENT_CODE=ON \
-DCMAKE_SKIP_RPATH=ON \
@@ -20,8 +22,19 @@ def setup():
-DLLVM_INCLUDE_TESTS=ON \
-DLLVM_EXTERNAL_LIT=/usr/bin/lit \
-DLLVM_EXTERNAL_SPIRV_HEADERS_SOURCE_DIR=/usr/include/spirv/ \
+ -DCMAKE_INSTALL_LIBDIR=%s \
%s \
- -Wno-dev" %tools)
+ -Wno-dev" % (libdir, tools)
+
+ if get.buildTYPE() == "emul32":
+ shelltools.export("CC", "gcc -m32")
+ shelltools.export("CXX", "g++ -m32")
+ shelltools.export("PKG_CONFIG_PATH","/usr/lib32/pkgconfig")
+
+ options += " -DLLVM_LIBDIR_SUFFIX=32 \
+ -DCMAKE_INSTALL_BINDIR:PATH=bin32 \
+
+ cmaketools.configure(options)
def build():
cmaketools.make()
@@ -29,4 +42,8 @@ def build():
def install():
cmaketools.rawInstall("DESTDIR=%s" % get.installDIR())
+ if get.buildTYPE() == "emul32":
+ pisitools.removeDir("/usr/bin32")
+ return
+
pisitools.dodoc("LICENSE*", "README*")
diff --git a/x11/vulkan/spirv-llvm/pspec.xml b/x11/vulkan/spirv-llvm/pspec.xml
index 2d2c28cdcd..76ff11cbd4 100644
--- a/x11/vulkan/spirv-llvm/pspec.xml
+++ b/x11/vulkan/spirv-llvm/pspec.xml
@@ -14,12 +14,11 @@
Tool and a library for bi-directional translation between SPIR-V and LLVM IR
https://github.com/KhronosGroup/SPIRV-LLVM-Translator/archive/refs/tags/v15.0.0.tar.gz
- git
+
cmake
python3-devel
llvm-mlir
llvm-libs
- spirv-tools-devel
libxml2-devel
llvm-clang-devel
python3-setuptools
@@ -45,6 +44,7 @@
spirv-tools
+ /usr/bin
/usr/lib
/usr/share/doc
@@ -76,7 +76,6 @@
spirv-llvm
- /usr/bin
/usr/include
/usr/lib/pkgconfig
/usr/lib32/pkgconfig