summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorbartus2020-06-11 17:11:25 +0200
committerbartus2020-06-11 17:14:20 +0200
commitb7c04585a1c9d09d55b964971c4f1131ce56cc38 (patch)
tree208eb1b817d261820c996a0114b87c76f8ccb991
parent79a302076621aab0d3e6a487d5932fd275993c5e (diff)
downloadaur-b7c04585a1c9d09d55b964971c4f1131ce56cc38.tar.gz
Add env vars configuration.
* DISABLE_OPENCL=1 :> turn off opencl kernel.
-rw-r--r--.SRCINFO5
-rw-r--r--PKGBUILD21
2 files changed, 16 insertions, 10 deletions
diff --git a/.SRCINFO b/.SRCINFO
index f9eb42247b6..5dff56d7ef6 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -6,12 +6,13 @@ pkgbase = luxcorerender
url = https://www.luxcorerender.org/
arch = x86_64
license = Apache
+ makedepends = opencl-headers
makedepends = boost
makedepends = git
makedepends = doxygen
makedepends = cmake
makedepends = pyside2-tools
- makedepends = opencl-headers
+ depends = opencl-icd-loader
depends = openimagedenoise
depends = openimageio
depends = boost-libs
@@ -19,11 +20,9 @@ pkgbase = luxcorerender
depends = embree
depends = glfw
depends = gtk3
- depends = opencl-icd-loader
optdepends = opencl-driver: for gpu acceleration
optdepends = pyside2: for pyluxcoretools gui
provides = luxrays
- conflicts = luxrays-hg
source = https://github.com/LuxCoreRender/LuxCore/archive/luxcorerender_v2.2.tar.gz
source = python.patch
source = glfw.patch
diff --git a/PKGBUILD b/PKGBUILD
index c8399ab0181..8aeb3d0cfa7 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -1,5 +1,14 @@
#!/hint/bash
# Maintainer : bartus <arch-user-repoᘓbartus.33mail.com>
+
+# Configuration
+((DISABLE_OPENCL)) || {
+ depends+=(opencl-icd-loader)
+ makedepends+=(opencl-headers)
+ optdepends+=("opencl-driver: for gpu acceleration")
+ CMAKE_FLAGS+=("-DLUXRAYS_DISABLE_OPENCL=ON")
+}
+
pkgname=luxcorerender
pkgver=2.2
_name=LuxCore-${pkgname}_v${pkgver}
@@ -11,11 +20,9 @@ pkgdesc="LuxCoreRender is a physically correct, unbiased rendering engine."
arch=('x86_64')
url="https://www.luxcorerender.org/"
license=('Apache')
-depends=(openimagedenoise openimageio boost-libs blosc embree glfw gtk3 opencl-icd-loader)
-optdepends=("opencl-driver: for gpu acceleration"
- "pyside2: for pyluxcoretools gui")
-makedepends=(boost git doxygen cmake pyside2-tools opencl-headers)
-conflicts=(luxrays-hg)
+depends+=(openimagedenoise openimageio boost-libs blosc embree glfw gtk3)
+optdepends+=("pyside2: for pyluxcoretools gui")
+makedepends+=(boost git doxygen cmake pyside2-tools)
provides=(luxrays)
source=("https://github.com/LuxCoreRender/LuxCore/archive/${pkgname}_v${_pkgver}.tar.gz"
"python.patch"
@@ -37,8 +44,8 @@ prepare() {
build() {
_pyver=$(python -c "from sys import version_info; print(\"%d%d\" % (version_info[0],version_info[1]))")
- mkdir -p build && cd build
- cmake -DPYTHON_V=${_pyver} ${srcdir}/${_name}
+ CMAKE_FLAGS+=("-DPYTHON_V=${_pyver}")
+ cmake "${CMAKE_FLAGS[@]}" -S "${srcdir}"/${_name} -B build
make
}