summarylogtreecommitdiffstats
path: root/PKGBUILD
diff options
context:
space:
mode:
authorLeorize2017-03-04 13:56:54 +0700
committerLeorize2017-03-04 13:56:54 +0700
commitf6e6a0c71a8a2fb30ee6eac17b606ec8e60654b4 (patch)
tree17040ad00127f126caf18cd4affb0bf3964d0aff /PKGBUILD
downloadaur-f6e6a0c71a8a2fb30ee6eac17b606ec8e60654b4.tar.gz
initial commit
Diffstat (limited to 'PKGBUILD')
-rw-r--r--PKGBUILD55
1 files changed, 55 insertions, 0 deletions
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 000000000000..6fe5a3dd3cb7
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,55 @@
+# $Id$
+# Maintainer: L <alaviss0 plus aur at gmail dot com>
+# Contributor: Evangelos Foutras <evangelos@foutrelis.com>
+
+pkgname=openmp-svn
+_pkgname=${pkgname%-svn}
+pkgver=5.0.r296962
+pkgrel=1
+pkgdesc="LLVM OpenMP Runtime Library"
+arch=('i686' 'x86_64')
+url="http://openmp.llvm.org/"
+license=('custom:University of Illinois/NCSA Open Source License')
+depends=('glibc')
+makedepends=('cmake')
+source=("${_pkgname}::svn+https://llvm.org/svn/llvm-project/${_pkgname}/trunk")
+sha512sums=('SKIP')
+
+pkgver() {
+ cd "$_pkgname/runtime"
+
+ # Borrowed from llvm-svn
+ echo $(awk -F 'MAJOR |MINOR |)' \
+ 'BEGIN { ORS="." ; i=0 } \
+ /set\(LIBOMP_VERSION_/ { print $2 ; i++ ; if (i==1) ORS="" } \
+ END { print "\n" }' \
+ CMakeLists.txt).r$(svnversion | tr -d [A-z])
+}
+
+prepare() {
+ cd "$_pkgname"
+ mkdir build
+}
+
+build() {
+ cd "$_pkgname/build"
+
+ cmake \
+ -DCMAKE_BUILD_TYPE=Release \
+ -DCMAKE_INSTALL_PREFIX=/usr \
+ ..
+ make
+}
+
+package() {
+ cd "$_pkgname"
+
+ make -C build DESTDIR="$pkgdir" install
+
+ # libgomp.so is also provided by gcc-libs; remove it to fix the conflict
+ rm "$pkgdir/usr/lib/libgomp.so"
+
+ install -Dm644 LICENSE.txt "$pkgdir/usr/share/licenses/$pkgname/LICENSE"
+}
+
+# vim:set ts=2 sw=2 et: