Skip to content

Commit

Permalink
scripts/bootstrap-prefix: prefer ID over NAME when guessing platform
Browse files Browse the repository at this point in the history
ID is typically something like "debian", NAME "Debian GNU/Linux".  We
want the former.

Signed-off-by: Fabian Groffen <grobian@gentoo.org>
  • Loading branch information
grobian committed Sep 16, 2023
1 parent d2ade9a commit 3fedade
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion scripts/bootstrap-prefix.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3138,8 +3138,8 @@ if [[ ${CHOST} == *-linux-* ]] ; then
rel=$(lsb_release -sr)
if [[ -z ${dist} ]] || [[ -z ${rel} ]] ; then
source /etc/os-release # this may fail if the file isn't there
[[ -z ${dist} ]] && dist=${NAME}
[[ -z ${dist} ]] && dist=${ID}
[[ -z ${dist} ]] && dist=${NAME}
[[ -z ${rel} ]] && rel=${VERSION_ID}

fi
Expand Down

0 comments on commit 3fedade

Please sign in to comment.