aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--testing/lua-subprocess/APKBUILD60
-rw-r--r--testing/lua-subprocess/makefile.patch12
2 files changed, 72 insertions, 0 deletions
diff --git a/testing/lua-subprocess/APKBUILD b/testing/lua-subprocess/APKBUILD
new file mode 100644
index 0000000000..dd90d2069e
--- /dev/null
+++ b/testing/lua-subprocess/APKBUILD
@@ -0,0 +1,60 @@
+# Contributor: Ted Trask <ttrask01@yahoo.com>
+# Maintainer: Ted Trask <ttrask01@yahoo.com>
+pkgname=lua-subprocess
+pkgver=20121211
+pkgrel=0
+pkgdesc="A Lua module written in C that allows you to create child processes and communicate with them"
+url="https://github.com/xlq/lua-subprocess"
+arch="all"
+license="AS-IS"
+depends=""
+depends_dev=""
+makedepends="$depends_dev lua-dev"
+install=""
+subpackages=""
+source="http://dev.alpinelinux.org/archive/$pkgname/$pkgname-$pkgver.tar.gz
+ makefile.patch"
+_builddir="$srcdir/$pkgname-$pkgver"
+_giturl="git://github.com/xlq/lua-subprocess.git"
+_upload="dev.alpinelinux.org:/archive/$pkgname/"
+
+snapshot() {
+ local _date=$(date +%Y%m%d)
+ local _pkg=$pkgname-$_date.tar.gz
+ mkdir -p "$srcdir"
+ cd "$srcdir"
+ msg "Creating snapshot: $_pkg"
+ rm -rf ${_giturl##*/}
+ git clone --depth=1 --bare $_giturl || return 1
+ git --git-dir ${_giturl##*/} archive -o $_pkg \
+ --prefix=$pkgname-$_date/ HEAD \
+ || return 1
+ msg "Uploading to $_upload"
+ rsync -Lave ssh $_pkg $_upload || return 1
+ cd "$startdir"
+ sed -i -e "s/^pkgver=.*/pkgver=$_date/" \
+ APKBUILD || return 1
+ abuild checksum
+}
+
+prepare() {
+ local i
+ cd "$_builddir"
+ for i in $source; do
+ case $i in
+ *.patch) msg $i; patch -p1 -i "$srcdir"/$i || return 1;;
+ esac
+ done
+}
+
+build() {
+ cd "$_builddir"
+}
+
+package() {
+ cd "$_builddir"
+ make DESTDIR="$pkgdir" install || return 1
+}
+
+md5sums="d26d6acda3bc02b1223476d4a61332ad lua-subprocess-20121211.tar.gz
+cc680a0ec32e0461215ce61a44bbb540 makefile.patch"
diff --git a/testing/lua-subprocess/makefile.patch b/testing/lua-subprocess/makefile.patch
new file mode 100644
index 0000000000..7567ca92ce
--- /dev/null
+++ b/testing/lua-subprocess/makefile.patch
@@ -0,0 +1,12 @@
+--- ./src/lua-subprocess-20121211/Makefile
++++ ./Makefile
+@@ -36,7 +36,8 @@
+
+ .PHONY: install
+ install: subprocess.so
+- $(INSTALL) -m755 subprocess.so $(INSTALL_CMOD)/
++ mkdir -p $(DESTDIR)$(INSTALL_CMOD)/
++ $(INSTALL) -m755 subprocess.so $(DESTDIR)$(INSTALL_CMOD)/
+
+ .PHONY: uninstall
+ uninstall: