vermaseren / form

The FORM project for symbolic manipulation of very big expressions
GNU General Public License v3.0
1.14k stars 136 forks source link

Preprocessor variable for commit number #194

Open jodavies opened 7 years ago

jodavies commented 7 years ago

If I understand correctly, the 347 in

TFORM 4.1 (Jun  6 2017, v4.1-20131025-347-g76561be) 64-bits

is an index that increments with commits?

Since there are regular bugfixes and feature additions in this repository it could be useful to have a way to check the form build is sufficiently up-to-date to run a script. Making such an index available as a preprocessor variable would be sufficient.

Or, is there already a way to do this?

Thanks, Josh.

tueda commented 7 years ago

Basically it is just what git describe --tags prints for the sources directory and embedded by automake on Unix-like systems, introduced after the discussion of #89 (but see also #119). It could be possible to add a preprocessor variable for that number, but this will not be available in builds without automake. And, Jos never uses automake, which means binaries sitting in the official FORM site will not get such a feature...

jodavies commented 7 years ago

This could also be implemented in a more coarse-grained way by incrementing the minor version number regularly. At the moment there is not even a minor version of form that will run forcer.

tueda commented 7 years ago

I agree with you that a more coarse-grained versioning is useful. Historically, I failed to persuade the developers to do that, which led to our versioning with the release date v4.0-20120330, v4.0-20120410, v4.1-20131025.