From fce95404aefb8779f90ce4c0e670339cdf8470ff Mon Sep 17 00:00:00 2001 From: Flatcar Buildbot Date: Mon, 9 Mar 2026 07:27:31 +0000 Subject: [PATCH] eclass/alternatives: Sync with Gentoo It's from Gentoo commit eccf647e5ed9dc7d3337f893cc46f0183528ff1f. Signed-off-by: Flatcar Buildbot --- .../third_party/portage-stable/eclass/alternatives.eclass | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/sdk_container/src/third_party/portage-stable/eclass/alternatives.eclass b/sdk_container/src/third_party/portage-stable/eclass/alternatives.eclass index 7871e7f42b..8002c5cc20 100644 --- a/sdk_container/src/third_party/portage-stable/eclass/alternatives.eclass +++ b/sdk_container/src/third_party/portage-stable/eclass/alternatives.eclass @@ -1,4 +1,4 @@ -# Copyright 1999-2024 Gentoo Authors +# Copyright 1999-2026 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 # @ECLASS: alternatives.eclass @@ -92,7 +92,7 @@ alternatives_makesym() { # usage: alternatives_makesym [alternative targets..] # make sure it is in the prefix, allow it already to be in the prefix - SYMLINK=${EPREFIX}/${1#${EPREFIX}} + SYMLINK=${EPREFIX}/${1#"${EPREFIX}"} pref=${ROOT} shift ALTERNATIVES=$@ @@ -101,7 +101,7 @@ alternatives_makesym() { # and if one exists, link it and finish. for alt in ${ALTERNATIVES}; do - alt=${EPREFIX}/${alt#${EPREFIX}} + alt=${EPREFIX}/${alt#"${EPREFIX}"} if [ -f "${pref}${alt}" ]; then #are files in same directory? if [ "${alt%/*}" = "${SYMLINK%/*}" ]