On Mon, 3 Nov 2025 22:35:36 GMT, Sergey Bylokhov <[email protected]> wrote:
>>> But still, according to that document, the correct location for storing the >>> file is /usr/lib/os-release, while /etc/xx is only a compatibility >>> workaround. Since we’ve already moved from an unspecified or non-standard >>> behavior to the standard one, why not follow the specification completely? >> >> No, according to the [/etc/os-release man >> page](https://www.freedesktop.org/software/systemd/man/latest/os-release.html): >> >> _"The file /etc/os-release takes precedence over /usr/lib/os-release. >> Applications should check for the former, and exclusively use its data if it >> exists, and only fall back to /usr/lib/os-release if that is missing."_ > >> No, according to the [/etc/os-release man >> page](https://www.freedesktop.org/software/systemd/man/latest/os-release.html): > > This is what I already posted above, same text on your link: > >> /usr/lib/os-release is the recommended place to store OS release information >> as part of vendor trees. /etc/os-release should be a relative symlink to >> /usr/lib/os-release, to provide compatibility with applications only looking >> at /etc/. That is a recommendation for Linux vendors on how to organize systemd related data - but we are not Linux vendors. We are on the side of application so we should check /etc as the documentation dictates. Because vendors can disobey the vendor side recommendation and put it... somewhere, like in /proc/systemd to be generated instead of static file. ------------- PR Review Comment: https://git.openjdk.org/jdk/pull/28073#discussion_r2488063772
