| diff --git tools/cef_version.py tools/cef_version.py |
| index 132438ba..6972680a 100644 |
| --- tools/cef_version.py |
| +++ tools/cef_version.py |
| @@ -92,6 +92,10 @@ class VersionFormatter: |
| self._branch_version = {'MINOR': minor, 'PATCH': bugfix} |
| return self._branch_version |
| |
| + def get_piper_cl(self): |
| + """ Returns the Piper CL. """ |
| + return os.getenv('CEF_PIPER_CL', '0') |
| + |
| def get_chromium_version_string(self): |
| """ Returns the Chromium version number string. """ |
| chrome_version = self.get_chrome_version_components() |
| @@ -170,6 +174,7 @@ class VersionFormatter: |
| chrome_version = self.get_chrome_version_components() |
| chrome_major = chrome_version['MAJOR'] |
| chrome_version_part = 'chromium-' + self.get_chromium_version_string() |
| + piper_cl_part = 'piper-' + self.get_piper_cl() |
| |
| cef_commit = self.get_cef_commit_components() |
| cef_commit_hash = self._format_commit_hash(cef_commit['HASH']) |
| @@ -187,9 +192,9 @@ class VersionFormatter: |
| cef_branch_name = git.get_branch_name(self.cef_path).split('/')[-1] |
| |
| self._version_parts = {'MAJOR': int(chrome_major), 'MINOR': 0, 'PATCH': 0} |
| - self._version_string = '%s.0.0-%s.%s+%s+%s' % \ |
| + self._version_string = '%s.0.0-%s.%s+%s+%s+%s' % \ |
| (chrome_major, cef_branch_name, cef_commit['NUMBER'], |
| - cef_commit_hash, chrome_version_part) |
| + cef_commit_hash, chrome_version_part, piper_cl_part) |
| else: |
| cef_branch = self.get_cef_branch_version_components() |
| |
| @@ -198,9 +203,9 @@ class VersionFormatter: |
| 'MINOR': cef_branch['MINOR'], |
| 'PATCH': cef_branch['PATCH'] |
| } |
| - self._version_string = '%s.%d.%d+%s+%s' % \ |
| + self._version_string = '%s.%d.%d+%s+%s+%s' % \ |
| (chrome_major, cef_branch['MINOR'], cef_branch['PATCH'], |
| - cef_commit_hash, chrome_version_part) |
| + cef_commit_hash, chrome_version_part, piper_cl_part) |
| |
| def _get_version_string(self): |
| self._compute_version() |
| diff --git tools/make_version_header.py tools/make_version_header.py |
| index fa2325aa..a7ee5a43 100644 |
| --- tools/make_version_header.py |
| +++ tools/make_version_header.py |
| @@ -31,6 +31,7 @@ def make_version_header(header): |
| #define CEF_VERSION_PATCH $VERSION_PATCH$ |
| #define CEF_COMMIT_NUMBER $COMMIT_NUMBER$ |
| #define CEF_COMMIT_HASH "$COMMIT_HASH$" |
| +#define CEF_PIPER_CL $PIPER_CL$ |
| #define COPYRIGHT_YEAR $YEAR$ |
| |
| #define CHROME_VERSION_MAJOR $CHROME_MAJOR$ |
| @@ -76,6 +77,7 @@ CEF_EXPORT int cef_version_info(int entry); |
| # Substitute hash values for placeholders. |
| result = result.replace('$YEAR$', get_year()) |
| result = result.replace('$VERSION$', formatter.get_version_string()) |
| + result = result.replace('$PIPER_CL$', formatter.get_piper_cl()) |
| |
| commit_components = formatter.get_cef_commit_components() |
| for key in ('HASH', 'NUMBER'): |