File indexing completed on 2025-01-18 09:28:01
0001
0002
0003
0004
0005
0006
0007
0008
0009 #pragma once
0010
0011
0012
0013
0014
0015
0016 #include <iosfwd>
0017
0018 namespace Acts {
0019
0020
0021
0022 constexpr unsigned int VersionMajor = 35u;
0023 constexpr unsigned int VersionMinor = 2u;
0024 constexpr unsigned int VersionPatch = 0u;
0025
0026 constexpr unsigned int Version =
0027 10000u * VersionMajor + 100u * VersionMinor + VersionPatch;
0028 constexpr const char* const CommitHash = "GITDIR-NOTFOUND-dirty";
0029 constexpr const char* const CommitHashShort = "GITDIR-NO-dirty";
0030
0031 struct VersionInfo {
0032 unsigned int versionMajor;
0033 unsigned int versionMinor;
0034 unsigned int versionPatch;
0035 const char* const commitHash;
0036
0037 VersionInfo() = delete;
0038
0039 static VersionInfo fromHeader() {
0040 return VersionInfo(VersionMajor, VersionMinor, VersionPatch, CommitHash);
0041 }
0042
0043 static VersionInfo fromLibrary();
0044
0045 bool operator==(const VersionInfo& other) const;
0046 bool operator!=(const VersionInfo& other) const { return !(*this == other); }
0047
0048 friend std::ostream& operator<<(std::ostream& os, const VersionInfo& vi);
0049
0050 private:
0051 VersionInfo(unsigned int majorIn, unsigned int minorIn, unsigned int patchIn,
0052 const char* const commitHashIn);
0053 };
0054
0055 }