[Pkg-owncloud-commits] [SCM] owncloud-client.git branch, master, updated. upstream/1.1.4-47-g6e788ba

Sandro Knauß bugs at sandroknauss.de
Mon Feb 4 03:04:42 UTC 2013


The following commit has been merged in the master branch:
commit c9c92e711e4065af83b2f49aed9ee18e65241822
Author: Sandro Knauß <bugs at sandroknauss.de>
Date:   Mon Feb 4 03:42:55 2013 +0100

    repacking orig.tar to get rid of dlls

diff --git a/debian/changelog b/debian/changelog
index 4648a13..9d9c767 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,9 +1,10 @@
-owncloud-client (1.2.0-0r1) UNRELEASED; urgency=low
+owncloud-client (1.2.0+debian-0r2) UNRELEASED; urgency=low
 
   * New upstream release 
   * Closes: #692872
+  * repacking tarball: source-contains-prebuilt-windows-binary
 
- -- Sandro Knauß <bugs at sandroknauss.de>  Wed, 30 Jan 2013 23:38:47 +0100
+ -- Sandro Knauß <bugs at sandroknauss.de>  Mon, 04 Feb 2013 03:36:54 +0100
 
 owncloud-client (1.1.4-1) UNRELEASED; urgency=low
 
diff --git a/debian/repack.sh b/debian/repack.sh
new file mode 100755
index 0000000..bca9d2d
--- /dev/null
+++ b/debian/repack.sh
@@ -0,0 +1,44 @@
+#!/bin/sh
+# Repackage upstream source to exclude non-distributable files
+# should be called as "repack.sh --upstream-source <ver> <downloaded file>
+# (for example, via uscan)
+
+set -e
+set -u
+
+VER="$2+debian"
+FILE="$3"
+PKG=`dpkg-parsechangelog|grep ^Source:|sed 's/^Source: //'`
+
+REPACK_DIR="$PKG-$VER.orig" # DevRef § 6.7.8.2
+
+echo -e "\nRepackaging $FILE\n"
+
+DIR=`mktemp -d ./tmpRepackXXXXXX`
+trap "rm -rf \"$DIR\"" QUIT INT EXIT
+
+# Create an extra directory to cope with rootless tarballs
+UP_BASE="$DIR/unpack"
+mkdir "$UP_BASE"
+tar xaf "$FILE" -C "$UP_BASE"
+
+if [ `ls -1 "$UP_BASE" | wc -l` -eq 1 ]; then
+	# Tarball does contain a root directory
+	UP_BASE="$UP_BASE/`ls -1 "$UP_BASE"`"
+fi
+
+## Remove stuff
+rm -vfr $UP_BASE/admin
+## End
+
+mv "$UP_BASE" "$DIR/$REPACK_DIR"
+
+# Using a pipe hides tar errors!
+tar cfC "$DIR/repacked.tar" "$DIR" "$REPACK_DIR"
+bzip2 -9 < "$DIR/repacked.tar" > "$DIR/repacked.tar.bz2"
+RESULTING_FILE="$(dirname $FILE)/${PKG}_${VER}.orig.tar.bz2"
+mv "$DIR/repacked.tar.bz2" "$RESULTING_FILE"
+rm -f "$FILE"
+
+echo "*** $FILE repackaged"
+echo "*** Please note that the upstream version must be $VER since we are repackaging the tarball!"
diff --git a/debian/watch b/debian/watch
index b8a9957..3395f83 100644
--- a/debian/watch
+++ b/debian/watch
@@ -5,4 +5,6 @@
 # Compulsory line, this is a version 3 file
 version=3
 
-http://owncloud.org/sync-clients/ http://download.owncloud.com/download/mirall-(.*)\.tar\.bz2
+options="dversionmangle=s/debian[0-9]*//" \
+http://owncloud.org/sync-clients/ http://download.owncloud.com/download/mirall-(.*)\.tar\.bz2 \
+debian sh debian/repack.sh

-- 
owncloud-client.git



More information about the Pkg-owncloud-commits mailing list