git_sha1 = os.environ.get('MESA_GIT_SHA1_OVERRIDE', get_git_sha1())[:10]
if git_sha1:
- write_if_different('#define MESA_GIT_SHA1 "git-' + git_sha1 + '"')
+ write_if_different('#define MESA_GIT_SHA1 " (git-' + git_sha1 + ')"')
else:
- write_if_different('')
+ write_if_different('#define MESA_GIT_SHA1 ""')
svga_host_log(host_log);
util_snprintf(host_log, sizeof(host_log) - strlen(log_prefix),
- "%s%s"
-#ifdef MESA_GIT_SHA1
- " (" MESA_GIT_SHA1 ")"
-#endif
- , log_prefix, PACKAGE_VERSION);
+ "%s%s" MESA_GIT_SHA1, log_prefix, PACKAGE_VERSION);
svga_host_log(host_log);
/* If the SVGA_EXTRA_LOGGING env var is set, log the process's command
break;
case CL_DEVICE_VERSION:
- buf.as_string() = "OpenCL " + dev.device_version() + " Mesa " PACKAGE_VERSION
-#ifdef MESA_GIT_SHA1
- " (" MESA_GIT_SHA1 ")"
-#endif
- ;
+ buf.as_string() = "OpenCL " + dev.device_version() + " Mesa " PACKAGE_VERSION MESA_GIT_SHA1;
break;
case CL_DEVICE_EXTENSIONS:
static const std::string version_string =
debug_get_option("CLOVER_PLATFORM_VERSION_OVERRIDE", "1.1");
- buf.as_string() = "OpenCL " + version_string + " Mesa " PACKAGE_VERSION
-#ifdef MESA_GIT_SHA1
- " (" MESA_GIT_SHA1 ")"
-#endif
- ;
+ buf.as_string() = "OpenCL " + version_string + " Mesa " PACKAGE_VERSION MESA_GIT_SHA1;
break;
}
case CL_PLATFORM_NAME:
#if defined(DEBUG)
if (MESA_VERBOSE != 0) {
- _mesa_debug(ctx, "Mesa " PACKAGE_VERSION " DEBUG build"
-#ifdef MESA_GIT_SHA1
- " (" MESA_GIT_SHA1 ")"
-#endif
- "\n");
+ _mesa_debug(ctx, "Mesa " PACKAGE_VERSION " DEBUG build" MESA_GIT_SHA1 "\n");
}
#endif
}
ctx->VersionString = malloc(max);
if (ctx->VersionString) {
_mesa_snprintf(ctx->VersionString, max,
- "%s%u.%u%s Mesa " PACKAGE_VERSION
-#ifdef MESA_GIT_SHA1
- " (" MESA_GIT_SHA1 ")"
-#endif
- ,
+ "%s%u.%u%s Mesa " PACKAGE_VERSION MESA_GIT_SHA1,
prefix,
ctx->Version / 10, ctx->Version % 10,
(ctx->API == API_OPENGL_CORE) ? " (Core Profile)" :