mirror of
https://github.com/isc-projects/bind9.git
synced 2026-02-25 10:59:35 -05:00
Fix "srcid" on Windows
Windows BIND releases produced by GitLab CI are built from Git
repositories, not from release tarballs, which means the "srcid" file is
not present in the top source directory when MSBuild is invoked. This
causes the Git commit hash for such builds to be set to "unset_id".
Enable win32utils/Configure to try determining the commit hash for a
build by invoking Git on the build host if the "srcid" file is not
present (which is what its Unix counterpart does).
(cherry picked from commit 05e13e7caf)
This commit is contained in:
parent
b0ca52f211
commit
021b83059e
1 changed files with 7 additions and 0 deletions
|
|
@ -2638,6 +2638,13 @@ sub makesrcid {
|
|||
close SIN;
|
||||
}
|
||||
|
||||
if ($srcid eq "unset_id" and -d "..\\.git") {
|
||||
$data = `git rev-list --max-count=1 HEAD`;
|
||||
if (length($data) > 0) {
|
||||
$srcid = substr($data, 0, 7);
|
||||
}
|
||||
}
|
||||
|
||||
# Now set up the output version file
|
||||
|
||||
my $ThisDate = scalar localtime();
|
||||
|
|
|
|||
Loading…
Reference in a new issue