summaryrefslogtreecommitdiff
path: root/mipsrelease
diff options
context:
space:
mode:
Diffstat (limited to 'mipsrelease')
-rwxr-xr-xmipsrelease21
1 files changed, 19 insertions, 2 deletions
diff --git a/mipsrelease b/mipsrelease
index 400e9f1..140e524 100755
--- a/mipsrelease
+++ b/mipsrelease
@@ -1,11 +1,28 @@
#!/bin/bash
-# Temporary script for uploading mips64el packages to the server
+# Lic: GPLv3+
+# Author: Nicolas Reynolds <fauno@kiwwwi.com.ar>
+# Local release of mips64el packages + clean ABS sync
+# Called by HOOKLOCALRELEASE
+
+# $1 repo
+# $2+ packages
source /etc/makepkg.conf
+repo=$1; shift
+
pushd ${PKGDEST} >/dev/null
-repo-add stage3.db.tar.gz $@
+ repo-add stage3.db.tar.gz $@
+popd >/dev/null
+
+# Get all needed sources
+source PKGBUILD
+makepkg --source
+
+[ ! -d ${WORKDIR}/abs/${CARCH}/${repo} ] && mkdir -p ${WORKDIR}/${CARCH}/${repo} >/dev/null
+pushd ${WORKDIR}/abs/${CARCH}/${repo} >/dev/null
+ tar xvf $SRCPKGDEST/${pkgbase:-${pkgname[0]}}-${pkgver}-${pkgrel}-${CARCH}${SRCEXT}
popd >/dev/null
exit $?