[Scummvm-cvs-logs] SF.net SVN: scummvm: [22217] scummvm/trunk/base/version.cpp

fingolfin at users.sourceforge.net fingolfin at users.sourceforge.net
Sat Apr 29 05:39:04 CEST 2006


Revision: 22217
Author:   fingolfin
Date:     2006-04-29 05:38:28 -0700 (Sat, 29 Apr 2006)
ViewCVS:  http://svn.sourceforge.net/scummvm/?rev=22217&view=rev

Log Message:
-----------
Updated the common on why we would like to display the SVN rev as part of the ScummVM version string, and why this is non-trivial

Modified Paths:
--------------
    scummvm/trunk/base/version.cpp
Modified: scummvm/trunk/base/version.cpp
===================================================================
--- scummvm/trunk/base/version.cpp	2006-04-29 12:35:46 UTC (rev 22216)
+++ scummvm/trunk/base/version.cpp	2006-04-29 12:38:28 UTC (rev 22217)
@@ -33,7 +33,7 @@
  * Note: it would be very nice if we could instead of (or in addition to) the
  * build date present a date which corresponds to the date our source files
  * were last changed. To understand the difference, imagine that a user
- * makes a checkout of CVS on January 1, then after a week compiles it
+ * makes a checkout on January 1, then after a week compiles it
  * (e.g. after doing a 'make clean'). The build date then will say January 8
  * even though the files were last changed on January 1.
  *
@@ -42,28 +42,18 @@
  * It's clear that such a "last changed" date would be much more useful to us
  * for feedback purposes. After all, when somebody files a bug report, we
  * don't care about the build date, we want to know which date their checkout
- * was made. This is even more important now since anon CVS lags a few
- * days behind developer CVS.
+ * was made.
  *
  * So, how could we implement this? At least on unix systems, a special script
- * could do it. Basically, that script would run over all .cpp/.h files and
- * parse the CVS 'Header' keyword we have in our file headers.
- * That line contains a date/time in GMT. Now, the script just has to collect
- * all these times and find the latest. This time then would be inserted into
- * a header file or so (common/date.h ?) which engine.cpp then could
- * include and put into a global variable analog to gScummVMBuildDate.
+ * could do it. Basically, that script could parse the output of "svn info" to
+ * determine the revision of the checkout, and insert that information somehow
+ * into the build process (e.g. by generating a tiny header file, analog to
+ * internal_version.h, maybe called svn_rev.h or so.
  *
- * Drawback: scanning all source/header files will be rather slow. Also, this
- * only works on systems which can run powerful enough scripts (so I guess
- * Visual C++ would be out of the game here? don't know VC enough to be sure).
- *
- * Another approach would be to somehow get CVS to update a global file
- * (e.g. LAST_CHANGED) whenever any checkins are made. That would be
- * faster and work w/o much "logic" on the client side, in particular no
- * scripts have to be run. The problem with this is that I am not even
- * sure it's actually possible! Modifying files during commit time is trivial
- * to setup, but I have no idea if/how one can also change files which are not
- * currently being commit'ed.
+ * Drawback: This only works on systems which can run suitable scripts as part
+ * of the build proces (so I guess Visual C++ would be out of the game here?
+ * I don't know VC enough to be sure). And of course it must be robust enough
+ * to properly work in exports (i.e. release tar balls etc.).
  */
 const char *gScummVMVersion = SCUMMVM_VERSION;
 const char *gScummVMBuildDate = __DATE__ " " __TIME__;


This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.





More information about the Scummvm-git-logs mailing list