3 #ifndef DONT_HAVE_STDIO_H
11 #define DATE "xx/xx/xx"
19 #define TIME "xx:xx:xx"
23 /* on unix, SVNVERSION is passed on the command line.
24 * on Windows, the string is interpolated using
28 #define SVNVERSION "$WCRANGE$$WCMODS?M:$"
31 /* XXX Only unix build process has been tested */
45 static char buildinfo[50 + sizeof(HGVERSION) +
46 ((sizeof(HGTAG) > sizeof(HGBRANCH)) ?
47 sizeof(HGTAG) : sizeof(HGBRANCH))];
48 const char *revision = _Py_hgversion();
49 const char *sep = *revision ? ":" : "";
50 const char *hgid = _Py_hgidentifier();
53 PyOS_snprintf(buildinfo, sizeof(buildinfo),
54 "%s%s%s, %.20s, %.9s", hgid, sep, revision,
62 /* the following string can be modified by subwcrev.exe */
63 static const char svnversion[] = SVNVERSION;
64 if (svnversion[0] != '$')
65 return svnversion; /* it was interpolated, or passed on command line */
66 return "Unversioned directory";
76 _Py_hgidentifier(void)
78 const char *hgtag, *hgid;
80 if ((*hgtag) && strcmp(hgtag, "tip") != 0)