summaryrefslogtreecommitdiffstats
path: root/abs
diff options
context:
space:
mode:
authorBritney Fransen <brfransen@gmail.com>2018-02-24 01:59:54 (GMT)
committerBritney Fransen <brfransen@gmail.com>2018-02-24 01:59:54 (GMT)
commitaf7259e275822eeb9f66ae8078ba185621729e2a (patch)
tree6cae332fc77fb2599e571170c5d96677690bbb63 /abs
parent2700f114424822082eae5868a0fddc8d9213c0ef (diff)
downloadlinhes_pkgbuild-af7259e275822eeb9f66ae8078ba185621729e2a.zip
linhes_pkgbuild-af7259e275822eeb9f66ae8078ba185621729e2a.tar.gz
linhes_pkgbuild-af7259e275822eeb9f66ae8078ba185621729e2a.tar.bz2
argon2: dep of cryptsetup
Diffstat (limited to 'abs')
-rw-r--r--abs/core/argon2/PKGBUILD47
-rw-r--r--abs/core/argon2/argon2.install6
-rw-r--r--abs/core/argon2/libargon2.pc11
3 files changed, 64 insertions, 0 deletions
diff --git a/abs/core/argon2/PKGBUILD b/abs/core/argon2/PKGBUILD
new file mode 100644
index 0000000..531ccfb
--- /dev/null
+++ b/abs/core/argon2/PKGBUILD
@@ -0,0 +1,47 @@
+# Maintainer: Baptiste Jonglez <baptiste--aur at jonglez dot org>
+
+pkgname=argon2
+pkgver=20171227
+pkgrel=3
+pkgdesc='A password-hashing function (reference C implementation)'
+arch=('x86_64')
+url='https://github.com/P-H-C/phc-winner-argon2'
+license=('Apache' 'custom:CC0')
+depends=('glibc')
+install=argon2.install
+source=("https://github.com/P-H-C/phc-winner-argon2/archive/${pkgver}/${pkgname}-${pkgver}.tar.gz"
+ 'libargon2.pc')
+sha256sums=('eaea0172c1f4ee4550d1b6c9ce01aab8d1ab66b4207776aa67991eb5872fdcd8'
+ '4189ce6c183319ceaf2c4ec96facd424deeaa9e2819efb7511893bcf3ef5c836')
+
+prepare() {
+ cd "$srcdir/phc-winner-$pkgname-$pkgver"
+
+ # Copy and prepare custom pkg-config file
+ cp "${srcdir}/libargon2.pc" libargon2.pc
+ sed -i -e "s/@UPSTREAM_VER@/${pkgver}/" libargon2.pc
+}
+
+build() {
+ cd "$srcdir/phc-winner-$pkgname-$pkgver"
+
+ make OPTTARGET=none
+}
+
+check() {
+ cd "$srcdir/phc-winner-$pkgname-$pkgver"
+
+ make OPTTARGET=none test
+}
+
+package() {
+ cd "$srcdir/phc-winner-$pkgname-$pkgver"
+
+ make OPTTARGET=none DESTDIR="$pkgdir" install
+
+ install -D -m0644 LICENSE "${pkgdir}/usr/share/licenses/argon2/LICENSE"
+
+ install -D -m0644 libargon2.pc "${pkgdir}/usr/lib/pkgconfig/libargon2.pc"
+}
+
+# vim:set ts=2 sw=2 et:
diff --git a/abs/core/argon2/argon2.install b/abs/core/argon2/argon2.install
new file mode 100644
index 0000000..65b9e24
--- /dev/null
+++ b/abs/core/argon2/argon2.install
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+post_upgrade() {
+ # clean up upstream soname mess
+ rm -f usr/lib/libargon2.so.0
+}
diff --git a/abs/core/argon2/libargon2.pc b/abs/core/argon2/libargon2.pc
new file mode 100644
index 0000000..c41e1c0
--- /dev/null
+++ b/abs/core/argon2/libargon2.pc
@@ -0,0 +1,11 @@
+prefix=/usr
+exec_prefix=${prefix}
+libdir=${prefix}/lib
+includedir=${prefix}/include
+
+Name: libargon2
+Description: Development libraries for libargon2
+Version: @UPSTREAM_VER@
+Libs: -L${libdir} -largon2 -lrt -ldl
+Cflags:
+URL: https://github.com/P-H-C/phc-winner-argon2