blob: 4bd1ab182eeb250371ffd856423524b50b563f71 (
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
58
59
60
61
62
63
64
65
66
67
68
69
|
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
_luaversions="5.1 5.2 5.3"
pkgname=lua-augeas
pkgver=0.1.2
pkgrel=4
pkgdesc="Lua bindings for Augeas"
url="https://git.alpinelinux.org/cgit/lua-augeas/"
arch="all"
license="LGPL"
depends=""
install=
makedepends="augeas-dev"
subpackages=""
for _i in $_luaversions; do
makedepends="$makedepends lua$_i-dev"
subpackages="$subpackages lua$_i-augeas:split_${_i/./_}"
done
source="https://dev.alpinelinux.org/archive/lua-augeas/lua-augeas-$pkgver.tar.bz2
0001-support-for-Lua-5.2.patch"
_sdir="$srcdir"/lua-augeas-$pkgver
prepare() {
cd "$_sdir"
for i in $source; do
case $i in
*.patch) msg $i; patch -p1 -i "$srcdir"/$i || return 1;;
esac
done
for _i in $_luaversions; do
cp -r "$_sdir" "$srcdir"/build-$_i
done
}
build() {
for _i in $_luaversions; do
cd "$srcdir"/build-$_i
make LUAPC=lua$_i || return 1
done
}
package() {
for _i in $_luaversions; do
install -D "$srcdir"/build-$_i/augeas.so \
"$pkgdir"/usr/lib/lua/$_i/augeas.so || return 1
done
}
_split() {
local d= _ver=$1
pkgdesc="Lua $_i bindings for Augeas"
replaces="$pkgname"
install_if="lua$_ver $pkgname=$pkgver-r$pkgrel"
depends=
for d in usr/lib/lua usr/share/lua; do
if [ -d "$pkgdir"/$d/$_ver ]; then
mkdir -p "$subpkgdir"/$d
mv "$pkgdir"/$d/$_ver "$subpkgdir"/$d/ || return 1
fi
done
}
split_5_1() { _split 5.1; }
split_5_2() { _split 5.2; }
split_5_3() { _split 5.3; }
sha512sums="3ccbb32d4d71a9d390e814084a91fc26d51f25d31a1ff3a1e9927c494d196fdbc3954ae763b18e3b6e938bba9090773e4ac5fdb93ebc6d3293dc6be351485459 lua-augeas-0.1.2.tar.bz2
35ce609c0f34d88b3cd3a2edc6b7bc4332de9b06ad9b57a2fcc54c655399ad8e426b224e064d86146ccc1258ae7cb58a33d6187e7d5f396888a1d5a61637c940 0001-support-for-Lua-5.2.patch"
|