+ChangeLog:
+ head -1 $@ | grep -q "to v$(shell echo $$(($(VERSION) - 1)))"
+ @ mv $@ $@.tmp
+ @ echo "Summary of changes from v$(shell echo $$(($(VERSION) - 1))) to v$(VERSION)" >> $@
+ @ echo "============================================" >> $@
+ @ echo >> $@
+ @ git log --pretty=short $(shell echo $$(($(VERSION) - 1)))..HEAD | git shortlog >> $@
+ @ echo >> $@
+ @ cat $@
+ @ cat $@.tmp >> $@
+ @ rm $@.tmp
+ head -1 $@ | grep -q "to v$(VERSION)"
+.PHONY: ChangeLog
+.PRECIOUS: ChangeLog
+
+release:
+ $(Q) - rm -f udev-$(VERSION).tar.gz
+ $(Q) - rm -f udev-$(VERSION).tar.bz2
+ head -1 ChangeLog | grep -q "to v$(VERSION)"
+ head -1 RELEASE-NOTES | grep -q "udev $(VERSION)"
+ git commit -a -m "release $(VERSION)"
+ cat .git/refs/heads/master > .git/refs/tags/$(VERSION)
+ @ echo
+ git-archive --format=tar --prefix=udev-$(VERSION)/ HEAD | gzip -9v > udev-$(VERSION).tar.gz
+ git-archive --format=tar --prefix=udev-$(VERSION)/ HEAD | bzip2 -9v > udev-$(VERSION).tar.bz2
+.PHONY: release
+
+dist:
+ git-archive --format=tar --prefix=udev-$(VERSION)/ HEAD | gzip -9v > udev-$(VERSION).tar.gz
+ git-archive --format=tar --prefix=udev-$(VERSION)/ HEAD | bzip2 -9v > udev-$(VERSION).tar.bz2
+.PHONY: dist
+
+patch:
+ git diff $(shell echo $$(($(VERSION) - 1))) HEAD > udev-git-HEAD.patch
+.PHONY: patch
+