From d9588a3a67a44c3e9b6483210c8cdc7a6fbe629c Mon Sep 17 00:00:00 2001 From: Carsten Haitzler Date: Fri, 21 May 2010 05:42:27 +0000 Subject: [PATCH] add svn revision tracking into src. about dialog shows it now. SVN revision: 49086 --- Makefile.am | 2 +- configure.ac | 6 ++++++ enlightenment.pc.in | 1 + src/bin/Makefile.am | 3 ++- src/bin/e_about.c | 3 ++- svnrev.h.in | 1 + 6 files changed, 13 insertions(+), 3 deletions(-) create mode 100644 svnrev.h.in diff --git a/Makefile.am b/Makefile.am index 0d7416416..ebbb3aa49 100644 --- a/Makefile.am +++ b/Makefile.am @@ -7,7 +7,7 @@ MAINTAINERCLEANFILES = Makefile.in aclocal.m4 config.guess \ enlightenment.spec enlightenment.pc ABOUT-NLS* \ $(PACKAGE_TARNAME)-$(PACKAGE_VERSION)-doc.tar.bz2 -EXTRA_DIST = config.rpath README AUTHORS COPYING COPYING-PLAIN \ +EXTRA_DIST = svnrev.h.in config.rpath README AUTHORS COPYING COPYING-PLAIN \ enlightenment.spec.in enlightenment.spec enlightenment.pc filesdir = $(datadir)/enlightenment/ diff --git a/configure.ac b/configure.ac index 759875939..f4dddf8c2 100644 --- a/configure.ac +++ b/configure.ac @@ -560,7 +560,13 @@ AC_E_OPTIONAL_MODULE([everything-windows], true) AC_E_OPTIONAL_MODULE([systray], true) AC_E_OPTIONAL_MODULE([comp], true) +SVNVERSION=`which svnversion` +SVNREV="UNKNOWN" +if test -n "$SVNVERSION"; then SVNREV=`$SVNVERSION -n .`; fi +AC_SUBST(SVNREV) + AC_OUTPUT([ +svnrev.h Makefile enlightenment.spec enlightenment.pc diff --git a/enlightenment.pc.in b/enlightenment.pc.in index 069463681..f66fcb5ff 100644 --- a/enlightenment.pc.in +++ b/enlightenment.pc.in @@ -5,6 +5,7 @@ includedir=@includedir@/@PACKAGE@ modules=@libdir@/@PACKAGE@/modules config_apps=@prefix@/share/@PACKAGE@/config-apps release=@release@ +svnrev=@SVNREV@ Name: enlightenment Description: Enlightenmnt Window Manager diff --git a/src/bin/Makefile.am b/src/bin/Makefile.am index aa7f35107..a2f5c9a37 100644 --- a/src/bin/Makefile.am +++ b/src/bin/Makefile.am @@ -1,6 +1,7 @@ MAINTAINERCLEANFILES = Makefile.in -INCLUDES = -I$(top_srcdir) \ +INCLUDES = -I$(top_builddir) \ + -I$(top_srcdir) \ -I$(top_srcdir)/src/bin \ -I$(top_srcdir)/src/lib \ @e_cflags@ \ diff --git a/src/bin/e_about.c b/src/bin/e_about.c index b5dde1e64..6c811b431 100644 --- a/src/bin/e_about.c +++ b/src/bin/e_about.c @@ -2,6 +2,7 @@ * vim:ts=8:sw=3:sts=8:noexpandtab:cino=>5n-3f0^-2{2 */ #include "e.h" +#include "svnrev.h" /* local subsystem functions */ @@ -19,7 +20,7 @@ e_about_new(E_Container *con) e_obj_dialog_obj_theme_set(od, "base/theme/about", "e/widgets/about/main"); e_obj_dialog_obj_part_text_set(od, "e.text.label", _("Close")); e_obj_dialog_obj_part_text_set(od, "e.text.title", _("Enlightenment")); - e_obj_dialog_obj_part_text_set(od, "e.text.version", VERSION); + e_obj_dialog_obj_part_text_set(od, "e.text.version", VERSION"/"SVNREV); e_obj_dialog_obj_part_text_set (od, "e.textblock.about", _( diff --git a/svnrev.h.in b/svnrev.h.in new file mode 100644 index 000000000..0bb9f39b5 --- /dev/null +++ b/svnrev.h.in @@ -0,0 +1 @@ +#define SVNREV "@SVNREV@"