diff options
-rw-r--r-- | cmake/scripts/buildinfo.cmake | 2 | ||||
-rw-r--r-- | cmake/templates/BuildInfo.h.in | 2 | ||||
-rw-r--r-- | libsolidity/interface/Version.cpp | 3 |
3 files changed, 6 insertions, 1 deletions
diff --git a/cmake/scripts/buildinfo.cmake b/cmake/scripts/buildinfo.cmake index 8e1615f6..efbfb8fb 100644 --- a/cmake/scripts/buildinfo.cmake +++ b/cmake/scripts/buildinfo.cmake @@ -60,6 +60,8 @@ if (SOL_COMMIT_HASH AND SOL_LOCAL_CHANGES) set(SOL_COMMIT_HASH "${SOL_COMMIT_HASH}.mod") endif() +set(SOL_VERSION_COMMIT "commit.${SOL_COMMIT_HASH}") +set(SOl_VERSION_PLATFORM ETH_BUILD_PLATFORM) set(SOL_VERSION_BUILDINFO "commit.${SOL_COMMIT_HASH}.${ETH_BUILD_PLATFORM}") set(TMPFILE "${ETH_DST_DIR}/BuildInfo.h.tmp") diff --git a/cmake/templates/BuildInfo.h.in b/cmake/templates/BuildInfo.h.in index 6c16e4ac..4b35df98 100644 --- a/cmake/templates/BuildInfo.h.in +++ b/cmake/templates/BuildInfo.h.in @@ -8,3 +8,5 @@ #define ETH_BUILD_PLATFORM "@ETH_BUILD_PLATFORM@" #define SOL_VERSION_PRERELEASE "@SOL_VERSION_PRERELEASE@" #define SOL_VERSION_BUILDINFO "@SOL_VERSION_BUILDINFO@" +#define SOL_VERSION_COMMIT "@SOL_VERSION_COMMIT@" +#define SOL_VERSION_PLATFORM "@SOL_VERSION_PLATFORM@" diff --git a/libsolidity/interface/Version.cpp b/libsolidity/interface/Version.cpp index 30923fc2..0d23f9c3 100644 --- a/libsolidity/interface/Version.cpp +++ b/libsolidity/interface/Version.cpp @@ -40,7 +40,8 @@ string const dev::solidity::VersionString = string const dev::solidity::VersionStringStrict = string(dev::solidity::VersionNumber) + - (string(SOL_VERSION_PRERELEASE).empty() ? "" : "-" + string(SOL_VERSION_PRERELEASE)); + (string(SOL_VERSION_PRERELEASE).empty() ? "" : "-" + string(SOL_VERSION_PRERELEASE)) + + (string(SOL_VERSION_COMMIT).empty() ? "" : "+" + string(SOL_VERSION_COMMIT)); bytes dev::solidity::binaryVersion() { |