summaryrefslogtreecommitdiffstats
path: root/main/lua-rex/APKBUILD
diff options
context:
space:
mode:
authorFabian Affolter <fabian@bernewireless.net>2011-07-05 19:40:43 +0200
committerFabian Affolter <fabian@bernewireless.net>2011-07-05 19:40:43 +0200
commit7f9851115264bca9bce3926ddb29e533a23929dd (patch)
treeb0426fc489e4dad582f34b25d6f93354a65f5c0f /main/lua-rex/APKBUILD
parent5dac3f219058736f6e19b7bec2b1cc2b1b300981 (diff)
parent269fc1049583d36e07153215fe535f88947ea98b (diff)
downloadaports-7f9851115264bca9bce3926ddb29e533a23929dd.tar.bz2
aports-7f9851115264bca9bce3926ddb29e533a23929dd.tar.xz
Merge branch 'master' of git://git.alpinelinux.org/aports
Diffstat (limited to 'main/lua-rex/APKBUILD')
-rw-r--r--main/lua-rex/APKBUILD48
1 files changed, 48 insertions, 0 deletions
diff --git a/main/lua-rex/APKBUILD b/main/lua-rex/APKBUILD
new file mode 100644
index 000000000..744570ceb
--- /dev/null
+++ b/main/lua-rex/APKBUILD
@@ -0,0 +1,48 @@
+# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
+pkgname=lua-rex
+pkgver=2.5.2
+pkgrel=1
+pkgdesc="Lua bindings to regular expression library pcre and posix"
+url="http://lrexlib.luaforge.net/"
+arch="all"
+license="MIT"
+depends="lua-rex-pcre lua-rex-posix"
+makedepends="pcre-dev lua-dev"
+install=
+subpackages="$pkgname-pcre $pkgname-posix"
+source="http://luaforge.net/frs/download.php/4685/lrexlib-2.5.2.zip"
+
+_builddir="$srcdir"/lrexlib-$pkgver
+
+prepare() {
+ cd "$_builddir"
+ sed -i -e "s/^MYCFLAGS.*/MYCFLAGS = $CFLAGS -fPIC/" src/defaults.mak
+ sed -i -e "s/^LD .*/LD = gcc/" \
+ src/common.mak
+}
+
+build() {
+ cd "$_builddir"
+ make -j1 -C src/pcre
+ make -j1 -C src/posix
+}
+
+package() {
+ mkdir -p "$pkgdir"
+}
+
+pcre() {
+ pkgdesc="Lua bindings to pcre regular expressions library"
+ cd "$_builddir"
+ install -d "$subpkgdir"/usr/lib/lua/5.1
+ cp -a src/pcre/rex_pcre.so* "$subpkgdir"/usr/lib/lua/5.1
+}
+
+posix() {
+ pkgdesc="Lua bindings to posix regular expressions library"
+ cd "$_builddir"
+ install -d "$subpkgdir"/usr/lib/lua/5.1
+ cp -a src/posix/rex_posix.so* "$subpkgdir"/usr/lib/lua/5.1
+}
+
+md5sums="f622dbbd4f552e8edfd3c9250ebb7e92 lrexlib-2.5.2.zip"