blob: 3241a5a00373e8e1da9260c71883f588de6efbf5 (
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
|
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=lua-penlight
pkgver=1.3.1
pkgrel=1
pkgdesc="Lua libraries for extended operations on tables, lists and strings"
url="http://penlight.luaforge.net/"
arch="noarch"
license="GPL"
depends="lua-filesystem"
makedepends=""
install=
subpackages="$pkgname-doc lua5.1-penlight:_51 lua5.2-penlight:_52"
source="penlight-$pkgver.tar.gz::https://github.com/stevedonovan/Penlight/archive/$pkgver.tar.gz"
_builddir="$srcdir"/Penlight-$pkgver
build() {
cd "$_builddir"
# fix permissions of scripts
chmod -x lua/pl/*.lua
}
package() {
cd "$_builddir"
mkdir -p "$pkgdir"/usr/share/lua/5.1/ \
"$pkgdir"/usr/share/lua/5.2/ \
"$pkgdir"/usr/share/doc/$pkgname
cp -r lua/pl "$pkgdir"/usr/share/lua/5.2/ || return 1
cp -r examples "$pkgdir"/usr/share/doc/$pkgname/
ln -s ../5.2/pl "$pkgdir"/usr/share/lua/5.1/pl
}
_52() {
depends="$pkgname"
mkdir -p "$subpkgdir"/usr/share/lua/
mv "$pkgdir"/usr/share/lua/5.2 "$subpkgdir"/usr/share/lua/
}
_51() {
replaces="lua-penlight"
depends="lua5.2-penlight"
mkdir -p "$subpkgdir"/usr/share/lua/
mv "$pkgdir"/usr/share/lua/5.1 "$subpkgdir"/usr/share/lua/
}
md5sums="831f8ce7d3d5c872d129ad5db54a8424 penlight-1.3.1.tar.gz"
sha256sums="0f96ef033d9623ffd561a77088ac5adfd87b35a711fbf34815284d671cf4677c penlight-1.3.1.tar.gz"
sha512sums="f37972beb6237b3a04ee3be80f43dd33b1f70cd821b05b88d0e3a8271927b32ab73fd4b51332b196e0f22fad4d929ae3024d64cc342f2c2c1032d982dbc2eecb penlight-1.3.1.tar.gz"
|