[Pkg-jed-commit] r717 - jed/branches/0.99.19/debian
Rafael Laboissiere
rafael at alioth.debian.org
Fri May 18 16:41:14 UTC 2007
Author: rafael
Date: 2007-05-18 16:41:14 +0000 (Fri, 18 May 2007)
New Revision: 717
Modified:
jed/branches/0.99.19/debian/rules
Log:
Rewrote get-orig-source rule such that it works from any directory,
not only from the top dir of the package source. Instead of parsing
debian/changelog, the SVN sources are exported and the
trunk/changes.txt file is parsed in order to extract the latest micro
revision number. This number is used to compose the Debian package version,
which contains the ".+pre" string. Before building the upstream
tarball, we rename the trunk directory into jed-$VER, but do it only
when the directory does not exist already in the current working dir.
Modified: jed/branches/0.99.19/debian/rules
===================================================================
--- jed/branches/0.99.19/debian/rules 2007-05-18 16:31:49 UTC (rev 716)
+++ jed/branches/0.99.19/debian/rules 2007-05-18 16:41:14 UTC (rev 717)
@@ -177,9 +177,22 @@
fi
get-orig-source:
- svn export svn://svn.gna.org/svn/jed/trunk jed-$(JED_VER)
- rm -rf jed-$(JED_VER)/info
- tar czf jed_$(JED_VER).orig.tar.gz jed-$(JED_VER)
- rm -rf jed-$(JED_VER)
+ svn export svn://svn.gna.org/svn/jed/trunk
+ REV=$$(perl -n -e 'last if /{{{ Previous Versions/; \
+ $$v{$$1} = 1 if /^(\d+)\./; \
+ END { print ((sort {$$b <=> $$a} keys %v) [0]) }' \
+ < trunk/changes.txt ) ; \
+ rm -rf trunk/info ; \
+ PKG_VER=0.99.19.+pre$$REV ; \
+ SRC_DIR=jed-$$PKG_VER ; \
+ if [ -d $$SRC_DIR ] ; then \
+ echo Directory $$SRC_DIR exists, move it away! >&2 ; \
+ rm -rf trunk ; \
+ exit 1 ; \
+ else \
+ mv trunk jed-$$PKG_VER ; \
+ tar czf jed_$$PKG_VER.orig.tar.gz jed-$$PKG_VER ; \
+ rm -rf jed-$$PKG_VER ; \
+ fi
.PHONY: build clean binary binary-arch binary-indep get-orig-source
More information about the Pkg-jed-commit
mailing list