This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: Add revision number to gcc version?
- From: Volker Reichelt <reichelt at igpm dot rwth-aachen dot de>
- To: hjl at lucon dot org, gcc at gcc dot gnu dot org
- Date: Fri, 16 Dec 2005 12:07:54 +0100 (CET)
- Subject: Re: Add revision number to gcc version?
> 1. contrib/gcc_update creates gcc/REVISION with branch name and
> revision number.
> 2. If gcc/REVISION exists, it will be used in gcc/version.c.
>
> With those 2 patches, I got
>
> [hjl@gnu-13 gcc]$ ./xgcc --version
> xgcc (GCC) 4.1.0 (gcc-4_1-branch revision 108596) 20051215 (prerelease)
[snip]
> xgcc (GCC) 4.2.0 (trunk revision 108596) 20051215 (experimental)
IMHO we should change the current naming system as little as possible
for those who run scripts to extract the information from the compiler
automatically. (Maybe I'm the only one, but I do.)
Therefore I'd like to suggest to add the new stuff at the end and
with brackets instead of parentheses to make that information easily
extractable as well.
xgcc (GCC) 4.1.0 20051215 (prerelease) [gcc-4_1-branch revision 108596]
xgcc (GCC) 4.2.0 20051215 (experimental) [trunk revision 108596]
Somebody on this thread also suggested to skip the date and only use
the revision number. I don't think that this is a good idea, because
1.) there are scripts out there that rely on the date
(OK, maybe I'm the only one)
2.) if we ever change the revision control system again,
these numbers are probably obsolete
3.) the date carries a lot of information for humans (oh, this snapshot
is already two month old, I should get a new one) without having
to consult a database (for those who only download snapshots).
And this info is available offline, too.
Regards,
Volker