HomePhabricator

[CMAKE] Add the -commit suffix to version number through obj/build.h

Description

[CMAKE] Add the -commit suffix to version number through obj/build.h

Summary:
The obj/build.h header is built by calling the share/genbuild.sh
script and contains the commit description generated by git (the short
commit hash, eventually suffixed by -dirty).

This will allow to compare version numbers entirely between autotools
and CMake, avoiding confusion.

This should definitely by moved to the version.h file, but it is kept
as is for now so it remains compatible with the current codebase and
autotools.

Test Plan:

ninja
./src/bitcoind -version

Check the suffix is the commit hash rather than -unk.

Reviewers: #bitcoin_abc, deadalnix, jasonbcox

Reviewed By: #bitcoin_abc, jasonbcox

Differential Revision: https://reviews.bitcoinabc.org/D3916

Details

Provenance
FabienAuthored on Aug 20 2019, 11:54
jasonbcoxPushed on Aug 20 2019, 21:03
Reviewer
Restricted Project
Differential Revision
D3916: [CMAKE] Add the -commit suffix to version number through obj/build.h
Parents
rSTAGING5c5a7fe37a30: Merge #12779: Qt: Remove unused method setupAmountWidget(...)
Branches
Unknown
Tags
Unknown