DEVEL15-unix-mkvers-xml-20090526
authorDerrick Brashear <shadow@dementia.org>
Wed, 27 May 2009 03:13:02 +0000 (03:13 +0000)
committerDerrick Brashear <shadow@dementia.org>
Wed, 27 May 2009 03:13:02 +0000 (03:13 +0000)
LICENSE IPL10

make mkvers do a xml version file for unix also

(cherry picked from commit 29223f5a52beac5b40853863733c70028fc7c52c)

src/config/Makefile.version-CML
src/config/Makefile.version-NOCML.in

index 0b6cef8..7df4aaf 100644 (file)
@@ -22,4 +22,7 @@ $(VERSFILE).h:
 $(VERSFILE).txt:
        $(TOP_SRCDIR)/config/mkvers -o $(VERSFILE).txt -t
 
+$(VERSFILE).xml:
+       $(TOP_SRCDIR)/config/mkvers -o $(VERSFILE).xml -x
+
 noversion: install
index cd2dec1..e42cee2 100644 (file)
@@ -7,10 +7,16 @@
 
 PACKAGE=@PACKAGE@
 VERSION=@VERSION@
+VERSFILE=AFS_component_version_number
 
-AFS_component_version_number.o: AFS_component_version_number.c
+$(VERSFILE).o: $(VERSFILE).c
 
-AFS_component_version_number.c: @TOP_OBJDIR@/src/config/Makefile.version
-       echo 'char cml_version_number[]="@(#) OpenAFS ${VERSION} built ' `date +"%Y-%m-%d"` '";' >AFS_component_version_number.c
-       echo 'char* AFSVersion = "${PACKAGE} ${VERSION}"; ' >>AFS_component_version_number.c
+$(VERSFILE).c: @TOP_OBJDIR@/src/config/Makefile.version
+       echo 'char cml_version_number[]="@(#) OpenAFS ${VERSION} built ' `date +"%Y-%m-%d"` '";' >$(VERSFILE).c
+       echo 'char* AFSVersion = "${PACKAGE} ${VERSION}"; ' >>$(VERSFILE).c
 
+$(VERSFILE).xml:
+       echo '<?xml version="1.0" encoding="UTF-8"?>' >$(VERSFILE).xml
+       echo '<revision>' >>$(VERSFILE).xml
+       echo '<revnumber>${VERSION}</revnumber>' >>$(VERSFILE).xml
+       echo '</revision>' >>$(VERSFILE).xml