added community/openimageio

This commit is contained in:
Kevin Mihelich 2013-05-21 20:28:53 +00:00
parent e01bdb1c23
commit 004af38b32
3 changed files with 93 additions and 0 deletions

View file

@ -0,0 +1,52 @@
# $Id: PKGBUILD 90071 2013-05-06 19:38:49Z foutrelis $
# Contributor: SpepS <dreamspepser at yahoo dot it>
# Maintainer: Sven-Hendrik Haase <sh@lutzhaase.com>
# ALARM: Kevin Mihelich <kevin@archlinuxarm.org>
# - removed intel-tbb from deps, set -DUSE_TBB=0
# - patch to block out x86 asm (https://github.com/OpenImageIO/oiio/pull/546)
pkgname=openimageio
pkgver=1.1.10
pkgrel=2
pkgdesc="A library for reading and writing images, including classes, utilities, and applications"
arch=(i686 x86_64)
url="http://www.openimageio.org/"
license=('custom')
depends=('openexr' 'boost-libs' 'jasper' 'glew' 'libtiff' 'opencolorio')
makedepends=('cmake' 'qt4' 'python2' 'boost' 'mesa')
optdepends=('qt4: iv image viewer'
'python2: bindings support')
source=(https://github.com/OpenImageIO/oiio/tarball/Release-$pkgver
arm.patch)
md5sums=('e5c5cd77238f74c3a6a3610c211430f2'
'7cf2d71031c5f970edf481f55a594ecc')
build() {
cd "$srcdir"/$_pkgname*
patch -p1 -i "$srcdir"/arm.patch
cd src
[[ -d build ]] && rm -r build
mkdir build && cd build
cmake \
-DCMAKE_INSTALL_PREFIX=/usr \
-DPYLIB_INSTALL_DIR=lib/python2.7/site-packages \
-DUSE_EXTERNAL_TBB=ON \
-DUSE_TBB=0 \
..
make
}
package() {
cd "$srcdir"/$_pkgname*/src/build
make DESTDIR="$pkgdir" install
# license
cd ../..
install -Dm644 LICENSE "$pkgdir/usr/share/licenses/$pkgname/LICENSE"
}

View file

@ -0,0 +1,28 @@
diff -urN a/src/include/thread.h b/src/include/thread.h
--- a/src/include/thread.h 2013-04-12 21:30:27.000000000 -0500
+++ b/src/include/thread.h 2013-05-21 15:15:04.021631910 -0500
@@ -338,7 +338,11 @@
__TBB_Pause(delay);
#elif defined(__GNUC__)
for (int i = 0; i < delay; ++i) {
+#if defined __arm__
+ __asm__ __volatile__("NOP;");
+#else
__asm__ __volatile__("pause;");
+#endif
}
#elif defined(_MSC_VER)
for (int i = 0; i < delay; ++i) {
@@ -453,7 +457,12 @@
// Disallow copy construction by making private and unimplemented.
atomic (atomic const &);
+
+#if defined __arm__
+} __attribute__((aligned(8)));
+#else
};
+#endif
#endif /* ! USE_TBB */

View file

@ -0,0 +1,13 @@
--- orig/src/libutil/SHA1.cpp 2012-11-17 01:02:42.000000000 +0200
+++ fixed/src/libutil/SHA1.cpp 2012-12-14 14:37:37.552042793 +0200
@@ -8,9 +8,9 @@
// If compiling with MFC, you might want to add #include "StdAfx.h"
+#include "SHA1.h"
#include "hash.h"
#include "dassert.h"
-#include "SHA1.h"
#ifdef SHA1_UTILITY_FUNCTIONS
#define SHA1_MAX_FILE_BUFFER 8000