mirror of
https://gitlab.alpinelinux.org/alpine/aports.git
synced 2026-05-04 20:06:43 +02:00
main/lua-struct: add lua 5.3 and use install_if
This commit is contained in:
parent
1f9c7982d5
commit
fa7eabbbe2
@ -1,10 +1,10 @@
|
||||
# Maintailer: Natanael Copa <ncopa@alpinelinux.org>
|
||||
|
||||
_luaversions="5.1 5.2"
|
||||
_luaversions="5.1 5.2 5.3"
|
||||
|
||||
pkgname=lua-struct
|
||||
pkgver=0.2
|
||||
pkgrel=1
|
||||
pkgrel=2
|
||||
pkgdesc="Library for Converting Data to and from C Structs for Lua"
|
||||
url="http://www.inf.puc-rio.br/~roberto/struct/"
|
||||
arch="all"
|
||||
@ -19,7 +19,6 @@ source="http://www.inf.puc-rio.br/~roberto/struct/struct-$pkgver.tar.gz
|
||||
"
|
||||
|
||||
for _i in $_luaversions; do
|
||||
depends="$depends lua$_i-struct"
|
||||
makedepends="$makedepends lua$_i-dev"
|
||||
subpackages="$subpackages lua$_i-struct:_split${_i/./}"
|
||||
done
|
||||
@ -42,7 +41,7 @@ prepare() {
|
||||
build() {
|
||||
for i in $_luaversions; do
|
||||
cd "$_builddir"/$i
|
||||
make OPT_CFLAGS="$CFLAGS" LUAPC="lua$i" || return 1
|
||||
make OPT_CFLAGS="$CFLAGS -std=c99" LUAPC="lua$i" || return 1
|
||||
done
|
||||
|
||||
}
|
||||
@ -55,6 +54,7 @@ package() {
|
||||
_split() {
|
||||
local _v=$1
|
||||
pkgdesc="$pkgdesc - Lua $_v"
|
||||
install_if="lua$_v $pkgname=$pkgver-r$pkgrel"
|
||||
depends=
|
||||
mkdir -p "$subpkgdir"/usr/lib/lua/$_v
|
||||
install "$srcdir"/$_v/struct.so "$subpkgdir"/usr/lib/lua/$_v/struct.so \
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user