[folks] Automatically version the generated documentation



commit cc5e8d6da1935a7c7c731318c782e1a3eb1974b2
Author: Philip Withnall <philip withnall collabora co uk>
Date:   Mon Sep 13 15:40:10 2010 +0100

    Automatically version the generated documentation

 configure.ac     |    4 ++++
 docs/Makefile.am |   28 ++++++++++++++--------------
 2 files changed, 18 insertions(+), 14 deletions(-)
---
diff --git a/configure.ac b/configure.ac
index 74a43d9..abd3cde 100644
--- a/configure.ac
+++ b/configure.ac
@@ -27,6 +27,7 @@ m4_define([folks_maybe_datestamp],
                 [], [m4_esyscmd([date +.%Y%m%d | tr -d '\n\r'])]))
 
 m4_define([folks_version], folks_full_version[]folks_maybe_datestamp)
+m4_define([folks_major_minor_version], folks_major_version.folks_minor_version)
 m4_define([folks_module_version], folks_lt_current)
 
 AC_INIT([folks], folks_version,
@@ -62,6 +63,9 @@ AC_SUBST([LT_CURRENT])
 AC_SUBST([LT_REVISION])
 AC_SUBST([LT_AGE])
 
+FOLKS_MAJOR_MINOR_VERSION=folks_major_minor_version
+AC_SUBST([FOLKS_MAJOR_MINOR_VERSION])
+
 # -----------------------------------------------------------
 # Dependencies
 # -----------------------------------------------------------
diff --git a/docs/Makefile.am b/docs/Makefile.am
index cd46aba..03782cf 100644
--- a/docs/Makefile.am
+++ b/docs/Makefile.am
@@ -1,27 +1,27 @@
-docdir=$(datadir)/devhelp/references/folks-0.1
-innerdocdir=$(datadir)/devhelp/references/folks-0.1/folks-0.1
-imgdir=$(datadir)/devhelp/references/folks-0.1/folks-0.1/img
+docdir=$(datadir)/devhelp/references/folks- FOLKS_MAJOR_MINOR_VERSION@
+innerdocdir=$(datadir)/devhelp/references/folks- FOLKS_MAJOR_MINOR_VERSION@/folks- FOLKS_MAJOR_MINOR_VERSION@
+imgdir=$(datadir)/devhelp/references/folks- FOLKS_MAJOR_MINOR_VERSION@/folks- FOLKS_MAJOR_MINOR_VERSION@/img
 
 doc_data = \
-	folks-0.1/*.css \
-	folks-0.1/*.png \
+	folks- FOLKS_MAJOR_MINOR_VERSION@/*.css \
+	folks- FOLKS_MAJOR_MINOR_VERSION@/*.png \
 	$(NULL)
 
 doc_DATA = \
-	folks-0.1/index.html \
+	folks- FOLKS_MAJOR_MINOR_VERSION@/index.html \
 	$(doc_data) \
 	$(NULL)
 
 innerdoc_DATA = \
-	folks-0.1/folks-0.1/index.htm \
-	folks-0.1/folks-0.1/*.html \
+	folks- FOLKS_MAJOR_MINOR_VERSION@/folks- FOLKS_MAJOR_MINOR_VERSION@/index.htm \
+	folks- FOLKS_MAJOR_MINOR_VERSION@/folks- FOLKS_MAJOR_MINOR_VERSION@/*.html \
 	$(NULL)
 
 img_DATA = \
-	folks-0.1/folks-0.1/img/*.png \
+	folks- FOLKS_MAJOR_MINOR_VERSION@/folks- FOLKS_MAJOR_MINOR_VERSION@/img/*.png \
 	$(NULL)
 
-$(doc_data) $(innerdoc_DATA) $(img_DATA): folks-0.1/index.html
+$(doc_data) $(innerdoc_DATA) $(img_DATA): folks- FOLKS_MAJOR_MINOR_VERSION@/index.html
 
 VALAFLAGS = \
 	--vapidir=$(top_srcdir)/folks \
@@ -36,16 +36,16 @@ _doc_files = \
 	$(top_srcdir)/backends/key-file/*.vala
 doc_files = $(filter-out %-backend-factory.vala,$(wildcard $(_doc_files)))
 
-folks-0.1/index.html: $(doc_files)
-	$(AM_V_GEN)$(VALADOC) -o folks-0.1/ --force -b $(top_srcdir) \
+folks- FOLKS_MAJOR_MINOR_VERSION@/index.html: $(doc_files)
+	$(AM_V_GEN)$(VALADOC) -o folks- FOLKS_MAJOR_MINOR_VERSION@/ --force -b $(top_srcdir) \
 		--pkg=gee-1.0 --pkg=gio-2.0 --pkg=gmodule-2.0 --pkg=build-conf \
 		--pkg=dbus-glib-1 --pkg=telepathy-glib --pkg=tp-lowlevel \
 		$(VALAFLAGS) $(doc_files)
 
 distclean-local: distclean-docs
 distclean-docs:
-	rm -rf folks-0.1
+	rm -rf folks- FOLKS_MAJOR_MINOR_VERSION@
 
-GITIGNOREFILES = folks-0.1/
+GITIGNOREFILES = folks- FOLKS_MAJOR_MINOR_VERSION@/
 
 -include $(top_srcdir)/git.mk



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]