[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: Building subversion runs svnversion, which fails

From: Daniel Shahaf <d.s_at_daniel.shahaf.name>
Date: Tue, 19 Nov 2019 17:04:21 +0000

Nathan Hartman wrote on Tue, 19 Nov 2019 04:53 +00:00:
> Moving this from users@ to dev@...

[Aside: when doing this, it's a good to post a short response on users@
saying the conversation continues on dev@, for anyone who wants to
follow along but isn't subscribed to both lists.]

> On a somewhat related note (and at risk of blasphemy), if we want to
> provide a way for users to know what revision their svn install was
> built from, which would work for those who build from tarballs also,
> would it make sense to create a header file for this purpose, turn on
> svn:keywords for it, and put "$Revision: $" into a string

If we do this, we'll run into this issue:


tl;dr: Putting $Revision$ in a header file will expand to the last
changed revision of _that_ header file, not to the last changed revision
of anything in cwd.

The concept of having the binary know the `svnversion` info of the
working copy it was built from does make sense, however. We could make
gen-make.py add «-DFOO=`svnversion`» to CFLAGS. (There's already
something like that, «fakedefines», in the Windows-specific part of the
build generator.)


Received on 2019-11-19 18:04:48 CET

This is an archived mail posted to the Subversion Dev mailing list.