aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--libar2/PKGBUILD53
-rw-r--r--libar2simplified/PKGBUILD53
-rw-r--r--libblake/PKGBUILD40
3 files changed, 114 insertions, 32 deletions
diff --git a/libar2/PKGBUILD b/libar2/PKGBUILD
index b1f5a90..0485b05 100644
--- a/libar2/PKGBUILD
+++ b/libar2/PKGBUILD
@@ -1,29 +1,60 @@
# Maintainer: Mattias Andrée <`base64 -d`(bWFhbmRyZWUK)@kth.se>
-pkgname=libar2
+pkgbase=libar2
+pkgname=($pkgbase $pkgbase-doc $pkgbase-musl)
pkgver=1.1
-pkgrel=1
-pkgdesc="Library for the Argon2-family of hashing functions"
+pkgrel=2
+_pkgdesc="Library for the Argon2-family of hashing functions"
+pkgdesc="${_pkgdesc}"
arch=(i686 x86_64)
url="https://github.com/maandree/libar2"
license=('custom:ISC')
-depends=(libblake)
-checkdepends=()
-makedepends=()
-source=($pkgname-$pkgver.tar.gz::$url/archive/$pkgver.tar.gz)
+depends=()
+checkdepends=(glibc musl libblake libblake-musl)
+_compiler=gcc
+makedepends=(glibc musl libblake libblake-musl ${_compiler})
+source=($pkgbase-$pkgver.tar.gz::$url/archive/$pkgver.tar.gz)
sha256sums=(f94e871b6e4b6a23e9019b3ff606836f05eb1ca8ec3eacd466c171cd0f0abd1a)
build() {
- cd "$srcdir/$pkgname-$pkgver"
+ cd -- "$srcdir"
+ cp -r -- "$pkgbase-$pkgver" "$pkgbase-$pkgver-musl"
+ cd -- "$pkgbase-$pkgver"
make PREFIX=/usr
+ cd -- "../$pkgbase-$pkgver-musl"
+ make PREFIX=/usr/lib/musl CC="musl-${_compiler} -std=c11"
}
check() {
- cd "$srcdir/$pkgname-$pkgver"
+ cd -- "$srcdir/$pkgbase-$pkgver"
make check
+ cd -- "../$pkgbase-$pkgver-musl"
+ make CC="musl-${_compiler} -std=c11" check
}
-package() {
- cd "$srcdir/$pkgname-$pkgver"
+package_libar2() {
+ pkgdesc="${_pkgdesc}"
+ depends=(glibc libblake)
+
+ cd -- "$srcdir/$pkgbase-$pkgver"
+ make PREFIX=/usr DESTDIR="$pkgdir" install
+ rm -r -- "${pkgdir}/usr/share"
+}
+
+package_libar2-doc() {
+ pkgdesc="${_pkgdesc} (documentation)"
+
+ cd -- "$srcdir/$pkgbase-$pkgver"
make PREFIX=/usr DESTDIR="$pkgdir" install
+ rm -r -- "${pkgdir}/usr/lib"
+ rm -r -- "${pkgdir}/usr/include"
+}
+
+package_libar2-musl() {
+ pkgdesc="${_pkgdesc} (musl version)"
+ depends=(musl libblake-musl)
+
+ cd -- "$srcdir/$pkgbase-$pkgver-musl"
+ make PREFIX=/usr/lib/musl DESTDIR="$pkgdir" install
+ rm -r -- "${pkgdir}/usr/lib/musl/share"
}
diff --git a/libar2simplified/PKGBUILD b/libar2simplified/PKGBUILD
index 2542b6d..c37a731 100644
--- a/libar2simplified/PKGBUILD
+++ b/libar2simplified/PKGBUILD
@@ -1,29 +1,60 @@
# Maintainer: Mattias Andrée <`base64 -d`(bWFhbmRyZWUK)@kth.se>
-pkgname=libar2simplified
+pkgbase=libar2simplified
+pkgname=($pkgbase $pkgbase-doc $pkgbase-musl)
pkgver=1.1
-pkgrel=1
-pkgdesc="Facade for libar2"
+pkgrel=2
+_pkgdesc="Facade for libar2"
+pkgdesc="${_pkgdesc}"
arch=(i686 x86_64)
url="https://github.com/maandree/libar2simplified"
license=('custom:ISC')
-depends=(libblake libar2)
-checkdepends=()
-makedepends=()
-source=($pkgname-$pkgver.tar.gz::$url/archive/$pkgver.tar.gz)
+depends=()
+checkdepends=(libar2 libar2-musl)
+_compiler=gcc
+makedepends=(libar2 libar2-musl ${_compiler})
+source=($pkgbase-$pkgver.tar.gz::$url/archive/$pkgver.tar.gz)
sha256sums=(2aa80e1a4e43dfa8d1f03220f5ee29049ed739e4d740c399d4ac3b9b58409cd4)
build() {
- cd "$srcdir/$pkgname-$pkgver"
+ cd -- "$srcdir"
+ cp -r -- "$pkgbase-$pkgver" "$pkgbase-$pkgver-musl"
+ cd -- "$pkgbase-$pkgver"
make PREFIX=/usr
+ cd -- "../$pkgbase-$pkgver-musl"
+ make PREFIX=/usr/lib/musl CC="musl-${_compiler} -std=c11"
}
check() {
- cd "$srcdir/$pkgname-$pkgver"
+ cd -- "$srcdir/$pkgbase-$pkgver"
make check
+ cd -- "../$pkgbase-$pkgver-musl"
+ make CC="musl-${_compiler} -std=c11" check
}
-package() {
- cd "$srcdir/$pkgname-$pkgver"
+package_libar2simplified() {
+ pkgdesc="${_pkgdesc}"
+ depends=(libar2)
+
+ cd -- "$srcdir/$pkgbase-$pkgver"
+ make PREFIX=/usr DESTDIR="$pkgdir" install
+ rm -r -- "${pkgdir}/usr/share"
+}
+
+package_libar2simplified-doc() {
+ pkgdesc="${_pkgdesc} (documentation)"
+
+ cd -- "$srcdir/$pkgbase-$pkgver"
make PREFIX=/usr DESTDIR="$pkgdir" install
+ rm -r -- "${pkgdir}/usr/lib"
+ rm -r -- "${pkgdir}/usr/include"
+}
+
+package_libar2simplified-musl() {
+ pkgdesc="${_pkgdesc} (musl version)"
+ depends=(libar2-musl)
+
+ cd -- "$srcdir/$pkgbase-$pkgver-musl"
+ make PREFIX=/usr/lib/musl DESTDIR="$pkgdir" install
+ rm -r -- "${pkgdir}/usr/lib/musl/share"
}
diff --git a/libblake/PKGBUILD b/libblake/PKGBUILD
index 5e63864..8299330 100644
--- a/libblake/PKGBUILD
+++ b/libblake/PKGBUILD
@@ -1,29 +1,49 @@
# Maintainer: Mattias Andrée <`base64 -d`(bWFhbmRyZWUK)@kth.se>
-pkgname=libblake
+pkgbase=libblake
+pkgname=($pkgbase $pkgbase-musl)
pkgver=1.0
-pkgrel=1
-pkgdesc="Library for the BLAKE-family of hashing functions"
+pkgrel=2
+_pkgdesc="Library for the BLAKE-family of hashing functions"
+pkgdesc="${_pkgdesc}"
arch=(i686 x86_64)
url="https://github.com/maandree/libblake"
license=('custom:ISC')
depends=()
-checkdepends=()
-makedepends=()
-source=($pkgname-$pkgver.tar.gz::$url/archive/$pkgver.tar.gz)
+checkdepends=(glibc musl)
+_compiler=gcc
+makedepends=(glibc musl ${_compiler})
+source=($pkgbase-$pkgver.tar.gz::$url/archive/$pkgver.tar.gz)
sha256sums=(4e435aba4f4edef18a1e09b3c20f4618daaa8c9cc4057e3136199ab91c1ba8eb)
build() {
- cd "$srcdir/$pkgname-$pkgver"
+ cd -- "$srcdir"
+ cp -r -- "$pkgbase-$pkgver" "$pkgbase-$pkgver-musl"
+ cd -- "$pkgbase-$pkgver"
make PREFIX=/usr
+ cd -- "../$pkgbase-$pkgver-musl"
+ make PREFIX=/usr/lib/musl CC="musl-${_compiler} -std=c11"
}
check() {
- cd "$srcdir/$pkgname-$pkgver"
+ cd -- "$srcdir/$pkgbase-$pkgver"
make check
+ cd -- "../$pkgbase-$pkgver-musl"
+ make CC="musl-${_compiler} -std=c11" check
}
-package() {
- cd "$srcdir/$pkgname-$pkgver"
+package_libblake() {
+ pkgdesc="${_pkgdesc}"
+ depends=(glibc)
+
+ cd -- "$srcdir/$pkgbase-$pkgver"
make PREFIX=/usr DESTDIR="$pkgdir" install
}
+
+package_libblake-musl() {
+ pkgdesc="${_pkgdesc} (musl version)"
+ depends=(musl)
+
+ cd -- "$srcdir/$pkgbase-$pkgver-musl"
+ make PREFIX=/usr/lib/musl DESTDIR="$pkgdir" install
+}