Commit 03df0e76 authored by Jakub Jirutka's avatar Jakub Jirutka
Browse files

main/lua-stdlib-normalize: new aport

This aport is needed for recent version of main/lua-lyaml.
parent 8fcda688
# Contributor: Jakub Jirutka <jakub@jirutka.cz>
# Maintainer: Jakub Jirutka <jakub@jirutka.cz>
pkgname=lua-stdlib-normalize
_rockname=std.normalize
pkgver=2.0.1
pkgrel=0
pkgdesc="Normalized Lua functions"
url="https://lua-stdlib.github.io/normalize/"
arch="noarch"
license="MIT"
depends="lua"
subpackages=""
options="!check" # FIXME: requires lua-specl that we don't have yet
source="$pkgname-$pkgver.tar.gz::https://github.com/lua-stdlib/normalize/archive/v$pkgver.tar.gz"
builddir="$srcdir/normalize-$pkgver"
_luaversions="5.1 5.2 5.3"
for _v in $_luaversions; do
subpackages="$subpackages lua$_v-${pkgname#lua-}:_subpackage"
done
package() {
mkdir -p "$pkgdir"
}
_subpackage() {
local lver="${subpkgname:3:3}"
pkgdesc="$pkgdesc (for Lua $lver)"
depends="lua$lver lua$lver-stdlib-debug"
install_if="$pkgname=$pkgver-r$pkgrel lua$lver"
local lmod_dir="$subpkgdir/usr/share/lua/$lver"
local rockdir="$subpkgdir/usr/lib/luarocks/rocks-$lver/$_rockname/$pkgver-1"
mkdir -p "$lmod_dir"
cp -r "$builddir"/lib/std "$lmod_dir"/
mkdir -p "$rockdir"
echo 'rock_manifest = {}' > "$rockdir"/rock_manifest
}
sha512sums="a5dd11d65f613c16dfaae59703f1c296a6d74a56e6dfd12c0e288fa60bb0a344474922a0fe298a8a77d1d18672f45d21c12e1b3fb2ef6b306687975de336cb5c lua-stdlib-normalize-2.0.1.tar.gz"
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment