[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]
[or-cvs] r9988: Make svn revision number visible in version even if building (in tor/trunk: . src/or)
- To: or-cvs@xxxxxxxxxxxxx
- Subject: [or-cvs] r9988: Make svn revision number visible in version even if building (in tor/trunk: . src/or)
- From: nickm@xxxxxxxx
- Date: Wed, 18 Apr 2007 15:28:48 -0400 (EDT)
- Delivered-to: archiver@seul.org
- Delivered-to: or-cvs-outgoing@seul.org
- Delivered-to: or-cvs@seul.org
- Delivery-date: Wed, 18 Apr 2007 15:28:58 -0400
- Reply-to: or-talk@xxxxxxxxxxxxx
- Sender: owner-or-cvs@xxxxxxxxxxxxx
Author: nickm
Date: 2007-04-18 15:28:47 -0400 (Wed, 18 Apr 2007)
New Revision: 9988
Modified:
tor/trunk/
tor/trunk/ChangeLog
tor/trunk/src/or/Makefile.am
Log:
r12429@catbus: nickm | 2007-04-18 15:28:41 -0400
Make svn revision number visible in version even if building from a .tar.gz. This was remarkably painless.
Property changes on: tor/trunk
___________________________________________________________________
svk:merge ticket from /tor/trunk [r12429] on 8246c3cf-6607-4228-993b-4d95d33730f1
Modified: tor/trunk/ChangeLog
===================================================================
--- tor/trunk/ChangeLog 2007-04-18 17:55:47 UTC (rev 9987)
+++ tor/trunk/ChangeLog 2007-04-18 19:28:47 UTC (rev 9988)
@@ -23,8 +23,10 @@
- When warning about missing headers, tell the user to let us
know if the compile succeeds anyway, so we can downgrade the
warning.
- - If we're building from a subversion checkout or an SVK mirror, include
- the current SVN revision as part of the version string.
+ - Include the current subversion revision as part of the version
+ string: either fetch it directly if we're in an SVN checkout, do
+ some magic to guess it if we're in an SVK checkout, or use
+ the last-detected version if we're building from a .tar.gz.
o Minor features (logging):
- Always prepend "Bug: " to any log message about a bug.
Modified: tor/trunk/src/or/Makefile.am
===================================================================
--- tor/trunk/src/or/Makefile.am 2007-04-18 17:55:47 UTC (rev 9987)
+++ tor/trunk/src/or/Makefile.am 2007-04-18 19:28:47 UTC (rev 9988)
@@ -26,38 +26,38 @@
test_LDADD = ../common/libor.a ../common/libor-crypto.a
-noinst_HEADERS = or.h eventdns.h eventdns_tor.h
+noinst_HEADERS = or.h eventdns.h eventdns_tor.h micro-revision.i
tor_main.o: micro-revision.i
micro-revision.i: FORCE
- rm -f micro-revision.i; \
if test -d ../../.svn ; then \
svn info ../.. | \
sed -n 's/^Revision: \([0-9][0-9]*\).*/"\1"/p' > micro-revision.i \
- || true; \
+ || true; \
fi; \
if test ! -f micro-revision.i -a x`which svk` != x; then\
location=../..; \
rev=x; \
- while test x$$rev = xx; do \
- x=`svk info $$location | \
+ while test x$$rev = xx; do \
+ x=`svk info $$location | \
sed -n 's/^Mirrored From:.*, Rev\. \([0-9][0-9]*\)/\1/p'`; \
- if test x$$x != x; then \
- rev=$$x; \
+ if test x$$x != x; then \
+ rev=$$x; \
break; \
else \
- loc=`svk info $$location | \
+ loc=`svk info $$location | \
sed -n 's/^Copied From: \(.*\), Rev\. [0-9][0-9]*/\1/p'`; \
- if test x$$loc == x; then \
- rev=""; \
+ if test x$$loc = x; then \
break; \
else \
- location=/$$loc; \
+ location=/$$loc; \
fi; \
fi; \
done; \
- echo \"$$rev\" > micro-revision.i; \
+ if test x$$rev != x; then \
+ echo \"$$rev\" > micro-revision.i; \
+ fi; \
fi; \
if test ! -f micro-revision.i; then \
echo '""' > micro-revision.i; \