summaryrefslogtreecommitdiffstats
path: root/Makefile
diff options
context:
space:
mode:
authorThierry Vignaud <tv@mageia.org>2012-10-17 16:30:26 +0000
committerThierry Vignaud <tv@mageia.org>2012-10-17 16:30:26 +0000
commit6dd4c6a7d75ae8968e404e8baaf24e98f3897f8a (patch)
tree0ce3347f8136db6ec6965f046a7594a356bfc2bc /Makefile
parent04e09645ba90dff73117f52428c8bcd21b816bc5 (diff)
downloaddrakwizard-6dd4c6a7d75ae8968e404e8baaf24e98f3897f8a.tar
drakwizard-6dd4c6a7d75ae8968e404e8baaf24e98f3897f8a.tar.gz
drakwizard-6dd4c6a7d75ae8968e404e8baaf24e98f3897f8a.tar.bz2
drakwizard-6dd4c6a7d75ae8968e404e8baaf24e98f3897f8a.tar.xz
drakwizard-6dd4c6a7d75ae8968e404e8baaf24e98f3897f8a.zip
add dist-git support
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile14
1 files changed, 13 insertions, 1 deletions
diff --git a/Makefile b/Makefile
index 44818ffc..3a56b5b5 100644
--- a/Makefile
+++ b/Makefile
@@ -63,7 +63,16 @@ clean:
dist: clean
find . -maxdepth 2 -name '*.p[lm]' -print0 | xargs -t -0 -n1 perl -cw \
-I/usr/lib/libDrakX > /dev/null 2>&1
- $(MAKE) dist-svn
+ rm -rf ../$(NAME)-$(VERSION).tar*
+ @if [ -e ".svn" ]; then \
+ $(MAKE) dist-svn; \
+ elif [ -e ".git" ]; then \
+ $(MAKE) dist-git; \
+ else \
+ echo "Unknown SCM (not SVN nor GIT)";\
+ exit 1; \
+ fi;
+ $(info $(NAME)-$(VERSION).tar.xz is ready)
dist-svn:
rm -rf $(NAME)-$(VERSION)
@@ -71,6 +80,9 @@ dist-svn:
tar cfa ../$(NAME)-$(VERSION).tar.xz $(NAME)-$(VERSION)
rm -rf $(NAME)-$(VERSION)
+dist-git:
+ @git archive --prefix=$(NAME)-$(VERSION)/ HEAD | xz >../$(NAME)-$(VERSION).tar.xz;
+
log: changelog
changelog:
( svn2cl --authors=../../common/username --accum ; \