[libcodesize-java] 01/04: Update get-orig-source target for Github.
Markus Koschany
apo-guest at moszumanska.debian.org
Wed Oct 22 17:48:32 BST 2014
This is an automated email from the git hooks/post-receive script.
apo-guest pushed a commit to branch master
in repository libcodesize-java.
commit fc1d3e4a10dc64bbc10b0d118a50041d92451b1f
Author: Markus Koschany <apo at gambaru.de>
Date: Wed Oct 22 18:28:08 2014 +0200
Update get-orig-source target for Github.
---
debian/changelog | 2 +-
debian/rules | 32 +++++++++++++++++++++++++++-----
2 files changed, 28 insertions(+), 6 deletions(-)
diff --git a/debian/changelog b/debian/changelog
index 033c6ab..3e5f64f 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,4 +1,4 @@
-libcodesize-java (1.1-1) unstable; urgency=low
+libcodesize-java (1.1+git20130603-1) unstable; urgency=low
* Initial release. (Closes: #766256)
diff --git a/debian/rules b/debian/rules
index 4f91b7d..a02098d 100755
--- a/debian/rules
+++ b/debian/rules
@@ -1,9 +1,12 @@
#!/usr/bin/make -f
# export DH_VERBOSE=1
-PKD = $(abspath $(dir $(MAKEFILE_LIST)))
-VER ?= $(shell dpkg-parsechangelog -l$(PKD)/changelog | perl -ne 'print $$1 if m{^Version:\s*([\d\.]+)}')
export JAVA_HOME=/usr/lib/jvm/default-java
export CLASSPATH=/usr/share/java/bcel.jar
+PKD = $(abspath $(dir $(MAKEFILE_LIST)))
+VER = $(shell dpkg-parsechangelog -l$(PKD)/changelog -SVersion | cut -d- -f1)
+PKG = libcodesize-java
+UURL = https://github.com/robo-code/codesize.git
+COMMIT = 2d99a8bbcda84cc5e87bfb58fc98f36ffb6269f7
%:
dh $@ --parallel --with javahelper,jh_maven_repo_helper
@@ -11,9 +14,28 @@ export CLASSPATH=/usr/share/java/bcel.jar
override_dh_auto_build:
jh_build --javadoc codesize-$(VER).jar codesize
-get-orig-source:
- uscan --verbose --repack --compression xz --force-download
-
get-orig-pom:
wget -O debian/pom.xml \
http://central.maven.org/maven2/net/sf/robocode/codesize/$(VER)/codesize-$(VER).pom
+
+.PHONY: get-orig-source
+## http://wiki.debian.org/onlyjob/get-orig-source
+get-orig-source: $(PKG)_$(VER).orig.tar.xz
+ @
+
+$(PKG)_$(VER).orig.tar.xz:
+ @echo "# Cloning upstream git repository..."
+ git clone $(UURL) $(PKG)-$(VER)
+ @echo "# Clean-up..."
+ cd $(PKG)-$(VER) \
+ && git checkout -b debiansource $(COMMIT) \
+ && for F in $$(git ls-tree -r --name-only HEAD); \
+ do touch --no-dereference -d "$$(git log -1 --format="%ai" -- "$$F")" "$$F"; done \
+ && git log --pretty --numstat --summary | git2cl > ChangeLog \
+ && $(RM) -r -v \
+ .git/
+ @echo "# Packing..."
+ find -L "$(PKG)-$(VER)" -xdev -type f -print | sort \
+ | XZ_OPT="-6v" tar -caf "$(PKG)_$(VER).orig.tar.xz" -T- --owner=root --group=root --mode=a+rX \
+ && $(RM) -r "$(PKG)-$(VER)"
+
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-java/libcodesize-java.git
More information about the pkg-java-commits
mailing list