aboutsummaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authorKevin O'Connor <kevin@koconnor.net>2015-10-22 11:59:47 -0400
committerKevin O'Connor <kevin@koconnor.net>2015-10-23 11:11:09 -0400
commit98a100c24febc9e8bd677d65e808ad6cf83fb1ee (patch)
treee9bafca3d24db3c58f0225257a351c233c5e2290 /scripts
parent08d39868d326c0a75a188639d86f1a248178d1c6 (diff)
downloadseabios-hppa-98a100c24febc9e8bd677d65e808ad6cf83fb1ee.zip
seabios-hppa-98a100c24febc9e8bd677d65e808ad6cf83fb1ee.tar.gz
seabios-hppa-98a100c24febc9e8bd677d65e808ad6cf83fb1ee.tar.bz2
build: Allow official tarball builds to be considered "clean"
If building from an official tarball and EXTRAVERSION info is provided, then consider the build to be "clean" (don't include hostname/build timestamp). This is done on the expectation that EXTRAVERSION will have enough information to allow developers to find the builder and build environment should a defect be reported, and therefore the hostname/timestamp is not necessary. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/buildversion.py10
1 files changed, 8 insertions, 2 deletions
diff --git a/scripts/buildversion.py b/scripts/buildversion.py
index bceae63..d61fc9e 100755
--- a/scripts/buildversion.py
+++ b/scripts/buildversion.py
@@ -23,7 +23,8 @@ def git_version():
return ""
return ver
-# Look for version in a ".version" file
+# Look for version in a ".version" file. Official release tarballs
+# have this file (see scripts/tarball.sh).
def file_version():
if not os.path.isfile('.version'):
return ""
@@ -90,9 +91,14 @@ def main():
cleanbuild, toolstr = tool_versions(options.tools)
ver = git_version()
- cleanbuild = cleanbuild and ver and 'dirty' not in ver
+ cleanbuild = cleanbuild and 'dirty' not in ver
if not ver:
ver = file_version()
+ # We expect the "extra version" to contain information on the
+ # distributor and distribution package version (if
+ # applicable). It is a "clean" build if this is a build from
+ # an official release tarball and the above info is present.
+ cleanbuild = cleanbuild and ver and options.extra != ""
if not ver:
ver = "?"
if not cleanbuild: