The following commit has been merged in the master branch:
commit 7ada1fa2039c4d5efe823f479a9a1729ec5b1fa0
Author: Lucas Nussbaum <lu...@debian.org>
Date:   Sat Dec 1 18:02:02 2012 +0100

    Add get-orig-source target

diff --git a/debian/rules b/debian/rules
index db79ac9..e5abdf8 100755
--- a/debian/rules
+++ b/debian/rules
@@ -92,4 +92,18 @@ binary-arch: build install
        dh_builddeb -s
 
 binary: binary-indep binary-arch
-.PHONY: build clean binary-indep binary-arch binary install configure
+
+# see https://launchpad.net/ocamlbricks/trunk
+PACKAGE = ocamlbricks
+SRC_VERSION := $(shell dpkg-parsechangelog | sed -ne 's/^Version: 
\(\([0-9]\+\):\)\?\(.*\)-.*/\3/p')
+BZR_REVISION := $(shell echo $(SRC_VERSION) | awk -F"+" '{ print $$2 }' | sed 
's/bzr//' )
+TARBALL = $(PACKAGE)_$(SRC_VERSION).orig.tar.gz
+get-orig-source:
+       rm -rf get-orig-source $(TARBALL)
+       mkdir get-orig-source
+       bzr branch -r $(BZR_REVISION) lp:$(PACKAGE)/trunk 
get-orig-source/$(PACKAGE)-$(SRC_VERSION).orig
+       GZIP=--best tar czf $(TARBALL) -C get-orig-source 
$(PACKAGE)-$(SRC_VERSION).orig
+       rm -rf get-orig-source
+       echo "  "$(TARBALL)" created; move it to the right destination to build 
the package"
+
+.PHONY: build clean binary-indep binary-arch binary install configure 
get-orig-source

-- 
ocamlbricks packaging

_______________________________________________
Pkg-ocaml-maint-commits mailing list
Pkg-ocaml-maint-commits@lists.alioth.debian.org
http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/pkg-ocaml-maint-commits

Reply via email to