aboutsummaryrefslogtreecommitdiffstats
path: root/community/lua-say/APKBUILD
diff options
context:
space:
mode:
authorJakub Jirutka <jakub@jirutka.cz>2017-03-12 22:11:01 +0100
committerJakub Jirutka <jakub@jirutka.cz>2017-03-12 22:11:34 +0100
commit047a398a26fe9cd772e494fe8b7c6da47be01c18 (patch)
tree6837188b2dbca53b071bf2f8b245885309bcc654 /community/lua-say/APKBUILD
parente33123c47537d161278d85105b1f5f01e672a8be (diff)
downloadaports-047a398a26fe9cd772e494fe8b7c6da47be01c18.tar.bz2
aports-047a398a26fe9cd772e494fe8b7c6da47be01c18.tar.xz
community/lua-say: move from testing
Diffstat (limited to 'community/lua-say/APKBUILD')
-rw-r--r--community/lua-say/APKBUILD37
1 files changed, 37 insertions, 0 deletions
diff --git a/community/lua-say/APKBUILD b/community/lua-say/APKBUILD
new file mode 100644
index 0000000000..83bbc4d5a0
--- /dev/null
+++ b/community/lua-say/APKBUILD
@@ -0,0 +1,37 @@
+# Contributor: Jakub Jirutka <jakub@jirutka.cz>
+# Maintainer: Jakub Jirutka <jakub@jirutka.cz>
+pkgname=lua-say
+pkgver=1.3
+_pkgver=$pkgver-1
+pkgrel=0
+pkgdesc="Lua string hashing library, useful for internationalization"
+url="https://github.com/Olivine-Labs/say"
+arch="noarch"
+license="MIT"
+subpackages=""
+source="$pkgname-$pkgver.tar.gz::https://github.com/Olivine-Labs/say/archive/v$_pkgver.tar.gz"
+builddir="$srcdir/${pkgname#lua-}-$_pkgver"
+# This module needs lua-busted to run tests, but lua-busted depends on
+# lua-say and we wanna avoid circular dependencies.
+options="!check"
+
+_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"
+ install_if="$pkgname=$pkgver-r$pkgrel lua$lver"
+
+ install -m 644 -D "$builddir"/src/init.lua \
+ "$subpkgdir"/usr/share/lua/$lver/say.lua
+}
+
+sha512sums="8d4a360bf0731c2a70c23edb9e6e81cab1e7d9b861aa35103a5c6e521633410860d76c46dc2ea62a06ac8ab3b522bc71c11143d6fe7e26e7fa24dd3f5ea1e5f6 lua-say-1.3.tar.gz"