Opened 13 years ago

Closed 13 years ago

Last modified 12 years ago

#631 closed enhancement (fixed)

Enhance banner to include git hash, ensure build info is current

Reported by: Jim Ursetto Owned by: felix winkelmann
Priority: not urgent at all Milestone: 4.9.0
Component: unknown Version: 4.7.x
Keywords: Cc:
Estimated difficulty:


The attached patches make the build tag, build branch, and build version available as ##sys#build-* variables in unit build-version, as well as the current build revision (git hash of HEAD). Furthermore, unit build-version is rebuilt with every make, ensuring that the versions are always current, even if you simply switch branches or make a small commit. Finally, unit library uses these new variables to generate the banner, and version.scm is removed.

I could rewrite this patch without unit build-version if desired, instead forcing library.scm to be rebuilt with every make. However, note there is a significant build time impact. For example, ckeen found that it takes almost 1 minute to build library.scm versus 2 seconds to build build-version.scm, which would happen in every single rebuild -- regardless of whether library.scm was actually modified.

This patch has been tested on OS X, Mingw (no msys), and OpenBSD.

I have also ensured that make buildhead and continue to work correctly. Furthermore, if you do not have git installed, or if you are not building from a git checkout, the information is simply omitted from the banner.

Comments on the implementation are appreciated.

(These commits are also available from in branch zb/ver3.)

Change History (6)

comment:1 Changed 13 years ago by felix winkelmann

Owner: set to felix winkelmann
Status: newassigned

comment:2 Changed 13 years ago by felix winkelmann

Resolution: fixed
Status: assignedclosed

It's hard to believe, but I finally managed to apply this patch. Thank you.

comment:3 Changed 12 years ago by felix winkelmann


Milestone 4.8.0 deleted

Note: See TracTickets for help on using tickets.