On Jun 30, 2011, at 3:53 AM, Felix wrote:

>> That ensures these items are always updated in the banner even after a minor 
>> change or branch switch, whereas currently you have to recompile library.scm 
>> to update the version and `make spotless` to update the build tag or branch.

>> This works fine, *except* that in the case you are linking the Chicken 
>> runtime .c files together by hand with gcc runtime.c library.c ..., you also 
>> have to add version.c because Unit library depends on it.
> 
> Is this necessary? library.c already has a dependency on version.scm.

However, version.scm is currently included, not linked in.  As I stated, if you 
include the version, build tag and branch in library.scm via an include (as 
now) you have to recompile it every time you bump any of them.  That's quite 
slow.  I don't like this delay and I assumed it would be a showstopper.  With 
this change bumping a version is almost instant.

> The commit hash is only available when building from a git checkout.
> Rebuilding everything from a tarball will have no way recover that
> information.

The git hash is irrelevant in a tarball, because it is built from a known tag, 
so I'm not sure why this matters.  You can't get the current git branch from a 
tarball, either, but we still display it when available.

Anyway, this patch would not include the git hash stuff; it's mostly to fix the 
perpetually outdated build tags and branch tags when you are compiling from a 
git checkout.   However, git hash is where I'm going with this in the end.

Jim
_______________________________________________
Chicken-hackers mailing list
[email protected]
https://lists.nongnu.org/mailman/listinfo/chicken-hackers

Reply via email to