blob: f0adcabc3e6bec3772fffdbe3a941017204b683d (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
|
# Maintainer: Arzet Ro <arzeth0@gmail.com>
# Contributor: Antonio Rojas <arojas@archlinux.org>
# Contributor: Lex Black <autumn-wind@web.de>
# Contributor: Jesin <Jesin00@gmail.com>
_pkgbasename=libb2
pkgname=lib32-libb2
pkgver=0.98.1
pkgrel=4
arch=(x86_64)
pkgdesc='C library providing BLAKE2b, BLAKE2s, BLAKE2bp, BLAKE2sp hash functions'
url='https://blake2.net/'
license=(CC0-1.0)
depends=(lib32-gcc-libs
lib32-glibc libb2)
makedepends=(git)
source=(git+https://github.com/BLAKE2/libb2#tag=v$pkgver)
sha256sums=('eb6b596bc30918427d1e792914f454c1d3e61fef3d4499f6605ede78f835cc1b')
# libb2's build system discards the $CFLAGS variable.
# We can get around this by putting those flags in $CC.
export CC="gcc -m32 $CFLAGS"
prepare() {
cd "$_pkgbasename"
autoreconf -vi
}
build() {
export ASMFLAGS="-m32"
export PKG_CONFIG_PATH="/usr/lib32/pkgconfig"
cd "$_pkgbasename"
./configure \
--prefix=/usr \
--libdir=/usr/lib32 \
--disable-static \
--enable-shared \
--disable-native \
--enable-fat
make
}
check() {
cd "$_pkgbasename"
make check
}
package() {
cd "$_pkgbasename"
make DESTDIR="$pkgdir" install
rm -rf "${pkgdir}"/usr/{include,share,bin}
mkdir -p "$pkgdir/usr/share/licenses"
ln -s $_pkgbasename "$pkgdir/usr/share/licenses/$pkgname"
}
|