summaryrefslogtreecommitdiff
path: root/debian
diff options
context:
space:
mode:
authorJörg Frings-Fürst <debian@jff-webhosting.net>2015-11-06 08:20:09 +0100
committerJörg Frings-Fürst <debian@jff-webhosting.net>2015-11-06 08:20:09 +0100
commit6b0760d6c6b41943b55183b10719344960fb22b0 (patch)
tree124c935bf99f633c89ad6a864580183d9ff228fb /debian
parent52e75e72866b45f1fe63df132bc4bf9bc923b4b7 (diff)
Move download and repack from debian/rules to uscan
Diffstat (limited to 'debian')
-rw-r--r--debian/changelog4
-rwxr-xr-xdebian/repack.sh56
-rwxr-xr-xdebian/rules16
-rw-r--r--debian/watch2
4 files changed, 61 insertions, 17 deletions
diff --git a/debian/changelog b/debian/changelog
index 30e405c..95d9a69 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -2,6 +2,10 @@ argyll (1.8.3+repack-1) UNRELEASED; urgency=medium
* New upstream release.
* Refresh patches.
+ * Move download and repack from debian/rules to uscan:
+ - Add debian debian/repack.sh to debian/watch.
+ - New debian/repack.sh.
+ - Remove get-orig-source from debian/rules.
-- Jörg Frings-Fürst <debian@jff-webhosting.net> Fri, 06 Nov 2015 07:19:48 +0100
diff --git a/debian/repack.sh b/debian/repack.sh
new file mode 100755
index 0000000..4b986be
--- /dev/null
+++ b/debian/repack.sh
@@ -0,0 +1,56 @@
+#!/bin/sh -e
+# Repackaging script to be called by Uscan
+
+echo "Repackaging ..."
+TMP="../"
+PKG="`dpkg-parsechangelog|sed 's/^Source: //p;d'`_$2+repack.orig"
+
+
+echo "Extracting tarball ..."
+echo "$3 -->> $2"
+tar xzf "$3" -C "$TMP"
+cd "$TMP"
+
+echo "Rename source dir"
+ls -l
+mv Argyll_V$2 argyll_$2
+
+echo "Removing unwanted stuff ..."
+cd argyll_$2
+ls -l
+rm -f yajl/yajl_test.exe yajl/yajl_test.obj
+rm -fr usb/bin
+rm -fr jpeg
+rm -fr tiff
+rm -fr zlib
+rm -fr png
+chmod -R -x+X *
+ls -l
+#cd ..
+
+echo "Creating repack tarball ..."
+tar -caf "../argyll_$2+repack.orig.tar.xz" *
+
+cd ..
+echo "Clean tmp dir ..."
+rm -rf argyll_$2
+
+echo "Clean uscan files ..."
+rm -rf Argyll_V$2_src.zip
+#rm -rf argyll_$2.orig.tar.gz
+
+echo "Repackaged tarball created"
+
+
+
+ unzip ../Argyll_V${VERSION}_src.zip -d ../
+ mv ../Argyll_V${VERSION} ../argyll_${VERSION}
+ rm -f ../argyll_${VERSION}/yajl/yajl_test.exe ../argyll_${VERSION}/yajl/yajl_test.obj
+ rm -fr ../argyll_${VERSION}/usb/bin
+ rm -fr ../argyll_${VERSION}/jpeg
+ rm -fr ../argyll_${VERSION}/tiff
+ rm -fr ../argyll_${VERSION}/zlib
+ rm -fr ../argyll_${VERSION}/png
+ chmod -R -x+X ../argyll_${VERSION}/*
+ tar cJf ../argyll_${VERSION}+repack.orig.tar.xz ../argyll_${VERSION}
+ rm -fr ../argyll_${VERSION} ../Argyll_V${VERSION}_src.zip
diff --git a/debian/rules b/debian/rules
index 50d805e..1569aca 100755
--- a/debian/rules
+++ b/debian/rules
@@ -104,19 +104,3 @@ build-manpages:
help2man -N --no-discard-stderr --name="View gamuts." debian/tmp/usr/bin/viewgam > debian/man/viewgam.1
help2man -N --no-discard-stderr --name="Translate colors through an xicc." debian/tmp/usr/bin/xicclu > debian/man/xicclu.1
help2man -N --no-discard-stderr --name="Convert LightSpace raw RGB device profile data to Argyll CGATS dat" debian/tmp/usr/bin/ls2ti3 > debian/man/ls2ti3.1
-
-VERSION = $(shell head -n1 debian/changelog | sed -e 's/.*(//;s/+.*).*//;s/\+/\-/')
-
-get-orig-source:
- wget http://www.argyllcms.com/Argyll_V${VERSION}_src.zip -O ../Argyll_V${VERSION}_src.zip
- unzip ../Argyll_V${VERSION}_src.zip -d ../
- mv ../Argyll_V${VERSION} ../argyll_${VERSION}
- rm -f ../argyll_${VERSION}/yajl/yajl_test.exe ../argyll_${VERSION}/yajl/yajl_test.obj
- rm -fr ../argyll_${VERSION}/usb/bin
- rm -fr ../argyll_${VERSION}/jpeg
- rm -fr ../argyll_${VERSION}/tiff
- rm -fr ../argyll_${VERSION}/zlib
- rm -fr ../argyll_${VERSION}/png
- chmod -R -x+X ../argyll_${VERSION}/*
- tar cJf ../argyll_${VERSION}+repack.orig.tar.xz ../argyll_${VERSION}
- rm -fr ../argyll_${VERSION} ../Argyll_V${VERSION}_src.zip
diff --git a/debian/watch b/debian/watch
index fddab5e..c0798c5 100644
--- a/debian/watch
+++ b/debian/watch
@@ -2,4 +2,4 @@ version=3
#opts="dversionmangle=s/\+repack\d+$//" http://www.argyllcms.com/downloadsrc.html Argyll_V(.*)_src\.zip
opts=dversionmangle=s/\+repack(.*)// \
-http://www.argyllcms.com/downloadsrc.html Argyll_V(.*)_src\.zip
+http://www.argyllcms.com/downloadsrc.html Argyll_V(.*)_src\.zip debian debian/repack.sh