Skip to content
Snippets Groups Projects
Commit 5002a257 authored by chrfranke's avatar chrfranke
Browse files

utility.cpp: Add git commit hash to '-V' output if available.

git-svn-id: https://svn.code.sf.net/p/smartmontools/code/trunk@5592 4ea69e1a-61f1-4043-bf83-b5c94c648137
parent 9f157758
No related branches found
No related tags found
No related merge requests found
...@@ -2,6 +2,8 @@ $Id$ ...@@ -2,6 +2,8 @@ $Id$
2024-01-17 Christian Franke <franke@computer.org> 2024-01-17 Christian Franke <franke@computer.org>
utility.cpp: Add git commit hash to '-V' output if available.
Set version information also for builds from GH R/O mirror. Set version information also for builds from GH R/O mirror.
Makefile.am: Move creation of svnversion.sh to ... Makefile.am: Move creation of svnversion.sh to ...
......
...@@ -123,6 +123,9 @@ std::string format_version_info(const char * prog_name, int lines /* = 2 */) ...@@ -123,6 +123,9 @@ std::string format_version_info(const char * prog_name, int lines /* = 2 */)
#endif #endif
#ifdef SMARTMONTOOLS_SVN_REV #ifdef SMARTMONTOOLS_SVN_REV
"smartmontools SVN rev " SMARTMONTOOLS_SVN_REV "smartmontools SVN rev " SMARTMONTOOLS_SVN_REV
#ifdef SMARTMONTOOLS_GIT_HASH
" (git " SMARTMONTOOLS_GIT_HASH ")"
#endif
" dated " SMARTMONTOOLS_SVN_DATE " at " SMARTMONTOOLS_SVN_TIME "\n" " dated " SMARTMONTOOLS_SVN_DATE " at " SMARTMONTOOLS_SVN_TIME "\n"
#else #else
"smartmontools SVN rev is unknown\n" "smartmontools SVN rev is unknown\n"
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment