| Make --version display git version information
This commit contains dune rules to generate version_stubs.c by running
the shell script gen-versions.sh and linking the resulting file into
the executable.
Signed-off-by: Guanzhong Chen <me@guanzhong.ca>
| 4 年前 |
| Add shell script to generate git version as an OCaml stub
This shell script generates an OCaml C stub file containing a strong
generated_hg_version function which returns the output of:
git describe --always --dirty --abbrev=7 --tags
core_kernel will call this function when displaying the version.
Note that core_kernel provides its own version of this function as a
weak symbol, which our version overrides.
Example output: v0.0.3-56-gfbf5462
Signed-off-by: Guanzhong Chen <me@guanzhong.ca>
| 4 年前 |
| v0.15~preview.126.09+236
| 4 年前 |
| v0.15~preview.126.09+236
| 4 年前 |