Gentoo Archives: gentoo-dev

From: Mike Gilbert <floppym@g.o>
To: Gentoo Dev <gentoo-dev@l.g.o>
Subject: Re: [gentoo-dev] RFC: Proposal for addition of distribution variables
Date: Thu, 15 Dec 2016 23:15:53
Message-Id: CAJ0EP43RTFXNJeRsrAYY+E0AFnjwyOLwSUr8KAFgZt1L6txG-A@mail.gmail.com
In Reply to: Re: [gentoo-dev] RFC: Proposal for addition of distribution variables by "Robin H. Johnson"
1 On Thu, Dec 15, 2016 at 4:49 PM, Robin H. Johnson <robbat2@g.o> wrote:
2 > 3. The distro branding package (v1) (providers of virtual/os-branding):
3 > - MUST have NO build dependencies that require execution (this could
4 > be the very first package in a bootstrap).
5 > - MUST install /etc/os-release
6 > - /etc/os-release MUST provide the following values
7 > - NAME, ID, PRETTY_NAME, HOME_URL,
8 > - /etc/os-release MAY provide other values.
9 > - MAY provide hardcoded values for /etc/os-release
10 > - MAY read values from profiles for /etc/os-release
11 > - MAY install any other branding files (logos, artwork, trademark,
12 > notices, etc)
13
14 A technical note here: we should probably install /usr/lib/os-release
15 instead of /etc/os-release.
16
17 https://www.freedesktop.org/software/systemd/man/os-release.html
18
19 Quoting the above:
20
21 The file /etc/os-release takes precedence over /usr/lib/os-release.
22 Applications should check for the former, and exclusively use its data
23 if it exists, and only fall back to /usr/lib/os-release if it is
24 missing. Applications should not read data from both files at the same
25 time. /usr/lib/os-release is the recommended place to store OS release
26 information as part of vendor trees. /etc/os-release should be a
27 relative symlink to /usr/lib/os-release, to provide compatibility with
28 applications only looking at /etc. A relative symlink instead of an
29 absolute symlink is necessary to avoid breaking the link in a chroot
30 or initrd environment such as dracut.