xref: /openbmc/linux/scripts/min-tool-version.sh (revision 8218827b)
1e24b3ffcSMasahiro Yamada#!/bin/sh
2e24b3ffcSMasahiro Yamada# SPDX-License-Identifier: GPL-2.0-only
3e24b3ffcSMasahiro Yamada#
4e24b3ffcSMasahiro Yamada# Print the minimum supported version of the given tool.
5e24b3ffcSMasahiro Yamada# When you raise the minimum version, please update
6e24b3ffcSMasahiro Yamada# Documentation/process/changes.rst as well.
7e24b3ffcSMasahiro Yamada
8e24b3ffcSMasahiro Yamadaset -e
9e24b3ffcSMasahiro Yamada
10e24b3ffcSMasahiro Yamadaif [ $# != 1 ]; then
11e24b3ffcSMasahiro Yamada	echo "Usage: $0 toolname" >&2
12e24b3ffcSMasahiro Yamada	exit 1
13e24b3ffcSMasahiro Yamadafi
14e24b3ffcSMasahiro Yamada
15e24b3ffcSMasahiro Yamadacase "$1" in
16e24b3ffcSMasahiro Yamadabinutils)
17e24b3ffcSMasahiro Yamada	echo 2.23.0
18e24b3ffcSMasahiro Yamada	;;
19e24b3ffcSMasahiro Yamadagcc)
20e24b3ffcSMasahiro Yamada	echo 5.1.0
21e24b3ffcSMasahiro Yamada	;;
22e24b3ffcSMasahiro Yamadaicc)
23e24b3ffcSMasahiro Yamada	# temporary
24e24b3ffcSMasahiro Yamada	echo 16.0.3
25e24b3ffcSMasahiro Yamada	;;
26e24b3ffcSMasahiro Yamadallvm)
27e2bc3e91SNathan Chancellor	if [ "$SRCARCH" = s390 ]; then
28*8218827bSHeiko Carstens		echo 14.0.0
29e2bc3e91SNathan Chancellor	else
30df05c0e9SNathan Chancellor		echo 11.0.0
31e2bc3e91SNathan Chancellor	fi
32e24b3ffcSMasahiro Yamada	;;
33e24b3ffcSMasahiro Yamada*)
34e24b3ffcSMasahiro Yamada	echo "$1: unknown tool" >&2
35e24b3ffcSMasahiro Yamada	exit 1
36e24b3ffcSMasahiro Yamada	;;
37e24b3ffcSMasahiro Yamadaesac
38