aboutsummaryrefslogtreecommitdiffstats
path: root/src/Makefile
diff options
context:
space:
mode:
authorsconklin <sconklin@ef72aa8b-4018-0410-8976-d6e080ef94d8>2006-07-12 19:17:06 +0000
committersconklin <sconklin@ef72aa8b-4018-0410-8976-d6e080ef94d8>2006-07-12 19:17:06 +0000
commitb7e0351d69f561d2c25878dc5269bdeb290ed059 (patch)
tree35910635986055e7ca9cf7632158b9e205a7dc00 /src/Makefile
parent8521ca3b4db9775c09ae29af336abba99e939a2b (diff)
downloadsos-b7e0351d69f561d2c25878dc5269bdeb290ed059.tar.gz
Initial import, moved project from internal server to 108
git-svn-id: svn+ssh://svn.fedorahosted.org/svn/sos/trunk@5 ef72aa8b-4018-0410-8976-d6e080ef94d8
Diffstat (limited to 'src/Makefile')
-rw-r--r--src/Makefile46
1 files changed, 46 insertions, 0 deletions
diff --git a/src/Makefile b/src/Makefile
new file mode 100644
index 00000000..e6387672
--- /dev/null
+++ b/src/Makefile
@@ -0,0 +1,46 @@
+#
+# Makefile for sos system support tools
+#
+
+NAME = sos
+VERSION = $(shell awk '/define version/ { print $$3 }' sos.spec)
+RELEASE = $(shell awk '/define release/ { print $$3 }' sos.spec)
+CVSTAG = r$(subst .,-,$(VERSION)-$(RELEASE))
+CVSROOT = $(shell cat CVS/Root)
+
+
+all:
+
+changelog:
+ @rcs2log | sed "s|@.*redhat\.com|@redhat.com|" | sed "s|@.*redhat\.de|@redhat.com|" | sed "s|@redhat\.de|@redhat.com|" | sed "s|@@|@|" | \
+ sed "s|/usr/local/CVS/$(NAME)/||g" | sed "s|/cvs/rhl/$(NAME)/||g" > changenew
+ mv ChangeLog ChangeLog.old
+ cat changenew ChangeLog.old > ChangeLog
+ rm -f changenew
+
+tag-archive:
+ @cvs -Q tag -F $(CVSTAG)
+ echo "$(CVSTAG)"
+
+create-archive: tag-archive
+ @rm -rf /tmp/$(NAME)
+ @cd /tmp; cvs -Q -d $(CVSROOT) export -r$(CVSTAG) $(NAME) || echo GRRRrrrrr -- ignore [export aborted]
+ @mv /tmp/$(NAME) /tmp/$(NAME)-$(VERSION)
+ @cd /tmp; tar --bzip2 -cSpf $(NAME)-$(VERSION).tar.bz2 $(NAME)-$(VERSION)
+ @rm -rf /tmp/$(NAME)-$(VERSION)
+ @cp /tmp/$(NAME)-$(VERSION).tar.bz2 .
+ @rm -f /tmp/$(NAME)-$(VERSION).tar.bz2
+ @echo " "
+ @echo "The final archive is ./$(NAME)-$(VERSION).tar.bz2."
+
+archive: clean tag-archive create-archive
+
+install:
+ python setup.py install
+
+version:
+ @echo "The version is $(NAME)-$(VERSION)-$(RELEASE)"
+
+
+clean:
+ @rm -fv *~ .*~ changenew ChangeLog.old $(NAME)-$(VERSION)-$(RELEASE).tar.bz2