diff options
author | bill-auger <mr.j.spam.me@gmail.com> | 2020-12-08 00:23:39 -0500 |
---|---|---|
committer | bill-auger <mr.j.spam.me@gmail.com> | 2020-12-09 09:24:02 -0500 |
commit | c2c0afc386592358eb78fa90e02f8b248080ff95 (patch) | |
tree | 30669a0431d363339115cdf133f41d08ef27cadd | |
parent | 30ed8b676db37bdd44ca3c5a41137d4af430ba55 (diff) | |
download | abslibre-c2c0afc386592358eb78fa90e02f8b248080ff95.tar.gz abslibre-c2c0afc386592358eb78fa90e02f8b248080ff95.tar.bz2 abslibre-c2c0afc386592358eb78fa90e02f8b248080ff95.zip |
[blender]: tweak for i686
-rw-r--r-- | libre/blender/PKGBUILD | 30 |
1 files changed, 25 insertions, 5 deletions
diff --git a/libre/blender/PKGBUILD b/libre/blender/PKGBUILD index 252dd20be..6abd605b2 100644 --- a/libre/blender/PKGBUILD +++ b/libre/blender/PKGBUILD @@ -34,9 +34,13 @@ depends=('libpng' 'libtiff' 'openexr' 'python' 'desktop-file-utils' 'python-requ 'jemalloc' 'libspnav' 'ptex' 'opensubdiv' 'openvdb' 'log4cplus' 'sdl2') depends_x86_64=('embree' 'openimagedenoise') depends_i686=('embree') -[[ "${CARCH}" == 'i686' ]] && depends[21]='openimageio=2.1.16.0' # FIXME: special case dep - presently, 'openxr' is only in community-testing; - # but 'community-testing/openimageio' is incompatible with 'openshadinglanguage' makedepends=('cmake' 'boost' 'mesa' 'git' 'llvm' 'ninja') +if [[ "${CARCH}" == 'i686' ]] +then # FIXME: special case deps - presently, 'openxr' is only in [community-testing] + depends[21]='openimageio=2.1.16.0' # but 'community-testing/openimageio' is incompatible with 'openshadinglanguage', so we must specify the one in [community] + depends+=('jsoncpp=1.9.4') # also 'extra/jsoncpp' is incompatible with 'openxr', so we must specify the one in [testing] + makedepends[0]='cmake=3.18.1' # and 'extra/cmake' is incompatible with 'testing/jsoncpp', so we must specify the one in [testing] +fi options=(!strip) source=("git://git.blender.org/blender.git#tag=v$pkgver" "git://git.blender.org/blender-addons.git" @@ -90,18 +94,34 @@ prepare() { # set OS type string sed -i 's|BUILD_PLATFORM;|"GNU/Linux-libre";|' 'source/creator/buildinfo.c' + + # FIXME: error: implicit declaration of function ‘atomic_add_and_fetch_uint64’; + # did you mean ‘atomic_add_and_fetch_uint32’? [-Werror=implicit-function-declaration] + if [[ "${CARCH}" == 'armv7h' ]] || [[ "${CARCH}" == 'i686' ]] + then local sed_cmd='s| atomic_add_and_fetch_uint64(| atomic_add_and_fetch_uint32(|' + sed -i "${sed_cmd}" source/blender/blenlib/intern/session_uuid.c + fi } build() { cd "$pkgname" + # libre changes + local _extra_opts=( -DWITH_CYCLES_CUDA_BINARIES=OFF \ + -DWITH_CYCLES_DEVICE_CUDA=OFF \ + -DWITH_CYCLES_DEVICE_OPTIX=OFF ) + # arch-specific options + case "${CARCH}" in + 'i686' ) _extra_opts+=( -DWITH_RAYOPTIMIZATION=OFF \ + -DWITH_CYCLES_EMBREE=ON ) ;; + 'x86_64') _extra_opts+=( -DWITH_CYCLES_EMBREE=ON ) ;; + esac + cmake . \ -Bbuild \ -GNinja \ -Cbuild_files/cmake/config/blender_release.cmake \ - -DWITH_CYCLES_DEVICE_OPTIX=OFF \ - -DWITH_CYCLES_CUDA_BINARIES='OFF' \ - -DWITH_CYCLES_DEVICE_CUDA='OFF' \ + ${_extra_opts[@]} \ -DCMAKE_INSTALL_PREFIX=/usr \ -DCMAKE_BUILD_TYPE=Release \ -DWITH_INSTALL_PORTABLE=OFF \ |