]> git.ipfire.org Git - thirdparty/openembedded/openembedded-core.git/commit
os-release: Fix VERSION_CODENAME in case it is empty
authorDaniel Semkowicz <dse@thaumatec.com>
Thu, 20 Jun 2024 13:03:31 +0000 (15:03 +0200)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Tue, 25 Jun 2024 10:49:54 +0000 (11:49 +0100)
commit70a0b8bc1d846c857be90ce2e97e60c5ee32558e
treefea289bb47aa40dede5f267210a46944d31f0101
parent4995e222ebdc9b5508c2f03a11868f184e4629a0
os-release: Fix VERSION_CODENAME in case it is empty

If DISTRO_CODENAME was not set, VERSION_CODENAME field was populated
with unparsed string. This resulted in the following line in os-release
file:

  VERSION_CODENAME="${DISTRO_CODENAME}"

According to systemd documentation, this field is optional.
Fix the problem by setting VERSION_CODENAME conditionally, only if
DISTRO_CODENAME was set.

Signed-off-by: Daniel Semkowicz <dse@thaumatec.com>
Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
meta/recipes-core/os-release/os-release.bb