diff options
| author | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2021-03-15 08:36:41 +0100 |
|---|---|---|
| committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2021-03-15 08:36:41 +0100 |
| commit | 83be46e944f630fde26ce03cb93f61a3066448e3 (patch) | |
| tree | d94a48051f9311d99b615fa06adda2511f9cff2d /scripts/ld-version.sh | |
| parent | f8096ff38d5f62d8a2c473e1bec0163a1b2b86d8 (diff) | |
| parent | 1e28eed17697bcf343c6743f0028cc3b5dd88bf0 (diff) | |
Merge v5.12-rc3 into char-misc-next
We need the char/misc fixes in here as well.
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'scripts/ld-version.sh')
| -rwxr-xr-x | scripts/ld-version.sh | 22 |
1 files changed, 14 insertions, 8 deletions
diff --git a/scripts/ld-version.sh b/scripts/ld-version.sh index a463273509b5..1bf3aadde9de 100755 --- a/scripts/ld-version.sh +++ b/scripts/ld-version.sh @@ -29,7 +29,7 @@ orig_args="$@" # Get the first line of the --version output. IFS=' ' -set -- $("$@" --version) +set -- $(LC_ALL=C "$@" --version) # Split the line on spaces. IFS=' ' @@ -44,14 +44,20 @@ if [ "$1" = GNU -a "$2" = ld ]; then elif [ "$1" = GNU -a "$2" = gold ]; then echo "gold linker is not supported as it is not capable of linking the kernel proper." >&2 exit 1 -elif [ "$1" = LLD ]; then - version=$2 - min_version=$lld_min_version - name=LLD - disp_name=LLD else - echo "$orig_args: unknown linker" >&2 - exit 1 + while [ $# -gt 1 -a "$1" != "LLD" ]; do + shift + done + + if [ "$1" = LLD ]; then + version=$2 + min_version=$lld_min_version + name=LLD + disp_name=LLD + else + echo "$orig_args: unknown linker" >&2 + exit 1 + fi fi # Some distributions append a package release number, as in 2.34-4.fc32 |
