summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorYen Chi Hsuan2016-05-28 21:07:05 +0800
committerYen Chi Hsuan2016-05-28 21:07:05 +0800
commit778abd91780818d7f5ed3c3977fe6376556ac4a1 (patch)
tree66753a51b605ed556e66704629f2679a64ec8409
downloadaur-778abd91780818d7f5ed3c3977fe6376556ac4a1.tar.gz
New package
-rw-r--r--.SRCINFO31
-rw-r--r--PKGBUILD62
-rw-r--r--python-package.patch14
3 files changed, 107 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 000000000000..a600ffabb7d2
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,31 @@
+# Generated by mksrcinfo v8
+# Sat May 28 13:06:55 UTC 2016
+pkgbase = simpleitk
+ pkgdesc = A simplified layer built on top of ITK, intended to facilitate its use in rapid prototyping, education, interpreted languages.
+ pkgver = 0.9.1
+ pkgrel = 1
+ url = http://www.simpleitk.org/
+ arch = i686
+ arch = x86_64
+ license = Apache
+ makedepends = cmake
+ makedepends = git
+ makedepends = mono
+ makedepends = python
+ makedepends = python-pip
+ makedepends = python-virtualenv
+ makedepends = swig
+ makedepends = tcl
+ makedepends = tk
+ depends = insight-toolkit
+ optdepends = mono: C# bindings
+ optdepends = python: Python bindings
+ optdepends = tcl: Tcl/TK bindings
+ optdepends = tk: Tcl/TK bindings
+ source = https://sourceforge.net/projects/simpleitk/files/SimpleITK/0.9.1/Source/SimpleITK-0.9.1.tar.xz
+ source = python-package.patch
+ md5sums = 3b759cf21b89e213343ac6a4e616cd45
+ md5sums = 1c97647461d932ca2e672606d1687f77
+
+pkgname = simpleitk
+
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 000000000000..79aaac592f7f
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,62 @@
+# Maintainer: Yen Chi Hsuan <yan12125 at gmail.com>
+_pkgname=SimpleITK
+pkgname=simpleitk
+pkgver=0.9.1
+pkgrel=1
+pkgdesc="A simplified layer built on top of ITK, intended to facilitate its use in rapid prototyping, education, interpreted languages."
+arch=('i686' 'x86_64')
+url="http://www.simpleitk.org/"
+license=('Apache')
+depends=('insight-toolkit')
+makedepends=('cmake' 'git' 'mono' 'python' 'python-pip' 'python-virtualenv' 'swig' 'tcl' 'tk')
+optdepends=(
+ 'mono: C# bindings'
+ 'python: Python bindings'
+ 'tcl: Tcl/TK bindings'
+ 'tk: Tcl/TK bindings'
+)
+source=(
+ "https://sourceforge.net/projects/$pkgname/files/$_pkgname/$pkgver/Source/$_pkgname-$pkgver.tar.xz"
+ 'python-package.patch'
+)
+md5sums=('3b759cf21b89e213343ac6a4e616cd45'
+ '1c97647461d932ca2e672606d1687f77')
+
+prepare() {
+ cd "$_pkgname-$pkgver"
+
+ patch -Np1 -i ../python-package.patch
+}
+
+build() {
+ cd "$_pkgname-$pkgver"
+
+ mkdir -p build && cd build
+
+ cmake \
+ -DCMAKE_INSTALL_PREFIX=/usr \
+ -DCMAKE_SKIP_RPATH:BOOL=ON \
+ -DBUILD_SHARED_LIBS:BOOL=ON \
+ -DBUILD_TESTING:BOOL=OFF \
+ -DBUILD_EXAMPLES:BOOL=OFF \
+ -DSimpleITK_PYTHON_WHEEL:BOOL=ON \
+ ..
+
+ make all dist.Python
+}
+
+package() {
+ _builddir="$srcdir/$_pkgname-$pkgver/build"
+
+ cd $_builddir
+
+ make DESTDIR="$pkgdir/" install
+
+ pip install --root="$pkgdir/" --ignore-installed \
+ "$_builddir/Wrapping/dist/$_pkgname-$pkgver-"*"-linux_$CARCH.whl"
+
+ install -Dm755 "$_builddir/bin/SimpleITKLua" "$pkgdir/usr/bin/SimpleITKLua"
+ install -Dm755 "$_builddir/bin/SimpleITKTclsh" "$pkgdir/usr/bin/SimpleITKTclsh"
+ install -Dm755 "$_builddir/Wrapping/CSharpBinaries/libSimpleITKCSharpNative.so" "$pkgdir/usr/lib/libSimpleITKCSharpNative.so"
+ install -Dm755 "$_builddir/Wrapping/CSharpBinaries/SimpleITKCSharpManaged.dll" "$pkgdir/usr/lib/SimpleITKCSharpManaged.dll"
+}
diff --git a/python-package.patch b/python-package.patch
new file mode 100644
index 000000000000..7d49349757f7
--- /dev/null
+++ b/python-package.patch
@@ -0,0 +1,14 @@
+--- a/Wrapping/PythonVirtualEnvInstall.cmake.in 2015-09-29 00:00:08.000000000 +0800
++++ b/Wrapping/PythonVirtualEnvInstall.cmake.in 2016-05-28 15:32:57.008424775 +0800
+@@ -5,10 +5,8 @@
+
+ execute_process(
+ COMMAND "@PYTHON_EXECUTABLE@"
+- "@SimpleITK_SOURCE_DIR@/Utilities/virtualenv/virtualenv.py"
++ "/usr/bin/virtualenv"
+ "--python=@PYTHON_EXECUTABLE@"
+- --no-pip
+- --no-setuptools
+ --clear
+ "@PythonVirtualenvHome@"
+ RESULT_VARIABLE failed