Use empty string for buildtime if BUILD_TIMESTAMP is not set.

In combination with the relevant changes in opm-common this
prevent flow in binary Linux packages from having a timestamp in the
executable that changes with every rebuild.

With the changes in opm-common  one can now set the variable
OPM_BINARY_PACKAGE_VERSION to a meaningful version string (Debian
11.2: 2021.10-4). If that is done and flow is built from tarballs it
will now not have a time stamp and print the package version to the
PRT file. E.g.

Flow Version     =  2021.10 (Debian 11.2: 2021.10-1)
This commit is contained in:
Markus Blatt 2022-03-23 22:46:40 +01:00
parent 8e61733ec0
commit 08fd5da6a7

View File

@ -51,7 +51,11 @@ namespace Opm
/// the binary was compiled.
std::string compileTimestamp()
{
#ifdef BUILD_TIMESTAMP
return BUILD_TIMESTAMP;
#else
return "";
#endif
}
} // namespace Opm