summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorMagnus Lång2017-08-26 13:27:07 +0200
committerMagnus Lång2017-08-26 14:20:39 +0200
commit2dff56337ee65b03479774c6045948d71b6a3d2b (patch)
treedbc8afa1faed0267f59e90bfd529e08c7de1d2d8
downloadaur-2dff56337ee65b03479774c6045948d71b6a3d2b.tar.gz
Inital commit
-rw-r--r--.SRCINFO18
-rw-r--r--PKGBUILD46
2 files changed, 64 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 00000000000..01b7be9ea50
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,18 @@
+pkgbase = nidhugg-git
+ pkgdesc = A bug-finding tool for concurrency and weak-memory bugs in C and C++ programs
+ pkgver = 0.2.r21.ea22422
+ pkgrel = 1
+ url = https://github.com/nidhugg/nidhugg
+ arch = x86_64
+ arch = i686
+ license = GPL
+ makedepends = boost
+ depends = python
+ depends = clang
+ provides = nidhugg=0.2.r21.ea22422
+ conflicts = nidhugg
+ source = git://github.com/nidhugg/nidhugg.git#branch=master
+ sha256sums = SKIP
+
+pkgname = nidhugg-git
+
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 00000000000..c0a905aea48
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,46 @@
+# Maintainer: Magnus Lång <magnus.lang@it.uu.se>
+pkgname=nidhugg-git
+pkgver=0.2.r21.ea22422
+pkgrel=1
+pkgdesc="A bug-finding tool for concurrency and weak-memory bugs in C and C++ programs"
+arch=('x86_64' 'i686')
+url="https://github.com/nidhugg/nidhugg"
+license=('GPL')
+depends=('python' 'clang')
+makedepends=('llvm'
+ 'boost') # For check() only
+provides=("nidhugg=$pkgver")
+conflicts=('nidhugg')
+source=("git://github.com/nidhugg/nidhugg.git#branch=master")
+sha256sums=('SKIP')
+
+pkgver() {
+ cd nidhugg
+ # Versions are tracked not with git, but by updating the configure.ac file.
+ _vercommit="$(git blame --porcelain configure.ac | head -1 | cut -d' ' -f1)"
+ printf "%s.r%s.%s" \
+ "$(head -1 configure.ac | sed 's/AC_INIT(\[Nidhugg\], \[\([^]]*\)\].*/\1/')" \
+ "$(git rev-list --count $_vercommit..HEAD)" \
+ "$(git rev-parse --short $_vercommit)"
+}
+
+build() {
+ cd nidhugg
+ autoreconf -fi
+ export CXXFLAGS="$CXXFLAGS -isystem /usr/lib/libffi-3.2.1/include/"
+ export CFLAGS="$CFLAGS -isystem /usr/lib/libffi-3.2.1/include/"
+ ./configure --prefix=/usr
+ make
+}
+
+check() {
+ cd "$srcdir/nidhugg"
+ make test
+}
+
+package() {
+ cd "$srcdir/nidhugg"
+ make DESTDIR="$pkgdir/" install
+}
+
+# vim:set ts=2 sw=2 et: