[khronos-opencl-headers] 02/07: add "tarball" target to generate upstream snapshot tarballs
Andreas Beckmann
anbe at moszumanska.debian.org
Fri Jan 12 23:04:13 UTC 2018
This is an automated email from the git hooks/post-receive script.
anbe pushed a commit to branch master
in repository khronos-opencl-headers.
commit dd396a4af31cb2f4c6bbd32906f0e16d3fda16fd
Author: Andreas Beckmann <anbe at debian.org>
Date: Fri Jan 12 21:28:40 2018 +0100
add "tarball" target to generate upstream snapshot tarballs
---
debian/changelog | 2 ++
debian/rules | 9 +++++++++
2 files changed, 11 insertions(+)
diff --git a/debian/changelog b/debian/changelog
index 91c44a2..c56dfd1 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,6 +1,8 @@
khronos-opencl-headers (2.1-2) UNRELEASED; urgency=medium
[ Andreas Beckmann ]
+ * d/rules: Add "tarball" target to generate upstream snapshot tarballs from
+ the upstream git repository.
* Set Priority to optional.
* Bump Standards-Version to 4.1.0.
diff --git a/debian/rules b/debian/rules
index 413321b..f8f8e3f 100755
--- a/debian/rules
+++ b/debian/rules
@@ -9,3 +9,12 @@ override_dh_auto_test:
override_dh_auto_clean:
$(MAKE) -C debian/t clean
+tarball: COMMIT_TIME = $(shell git log --format=format:%ct -1 $(COMMIT))
+tarball: COMMIT_DATE = $(shell git log --format=format:%cd --date=format:%Y.%m.%d -1 $(COMMIT))
+tarball: PREFIX = khronos-opencl-headers-$(MAJOR).$(MINOR)~$(COMMIT_DATE)-g$(shell git describe --always $(COMMIT))
+tarball:
+ test -n "$(COMMIT)"
+ test -n "$(MAJOR)"
+ test -n "$(MINOR)"
+ faketime @$(COMMIT_TIME) git archive --prefix $(PREFIX)/ $(COMMIT):opencl$(MAJOR)$(MINOR)/CL/ | xz > $(PREFIX).tar.xz
+ touch -d @$(COMMIT_TIME) $(PREFIX).tar.xz
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-opencl/khronos-opencl-headers.git
More information about the Pkg-opencl-commits
mailing list