summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBartłomiej Kurzeja <bartlomiej@kurzeja.it>2021-06-21 14:40:22 +0200
committerBartłomiej Kurzeja <bartlomiej@kurzeja.it>2021-06-21 14:40:22 +0200
commit8837bb99d44a1b8c936ba94e1e564922631ca78f (patch)
tree2d0ff8beb86e74a5fe16c428c8d04e4d58cc5a3b
parentc6fb832e10cb6e65b2afe536489eefac483a0259 (diff)
331 Autogenerate Debian versions
Part-of: <https://gitlab.freedesktop.org/gstreamer/cerbero/-/merge_requests/709>
-rw-r--r--cerbero/enums.py1
-rw-r--r--cerbero/utils/__init__.py2
2 files changed, 3 insertions, 0 deletions
diff --git a/cerbero/enums.py b/cerbero/enums.py
index 1b0a7716..0a480bff 100644
--- a/cerbero/enums.py
+++ b/cerbero/enums.py
@@ -78,6 +78,7 @@ class DistroVersion:
DEBIAN_BUSTER = 'debian_10_buster'
DEBIAN_BULLSEYE = 'debian_11_bullseye'
DEBIAN_SID = 'debian_99_sid'
+ # further debian versions are generated automatically
UBUNTU_LUCID = 'ubuntu_10_04_lucid'
UBUNTU_MAVERICK = 'ubuntu_10_10_maverick'
UBUNTU_NATTY = 'ubuntu_11_04_natty'
diff --git a/cerbero/utils/__init__.py b/cerbero/utils/__init__.py
index f034af30..54398ac8 100644
--- a/cerbero/utils/__init__.py
+++ b/cerbero/utils/__init__.py
@@ -263,6 +263,8 @@ Terminating.''', file=sys.stderr)
distro_version = DistroVersion.DEBIAN_BULLSEYE
elif d[1] == 'unstable' and d[2] == 'sid':
distro_version = DistroVersion.DEBIAN_SID
+ elif d[0] in ['debian', 'Debian GNU/Linux']:
+ distro_version = "debian_{number:02d}_{name}".format(number=int(d[1]), name=d[2])
else:
raise FatalError("Distribution '%s' not supported" % str(d))
elif d[0] in ['RedHat', 'Fedora', 'CentOS', 'Red Hat Enterprise Linux Server', 'CentOS Linux', 'Amazon Linux']: