From: Masahiro Yamada <masahiroy@kernel.org>
To: linux-kbuild@vger.kernel.org
Cc: Jiri Slaby <jslaby@suse.cz>,
Masahiro Yamada <masahiroy@kernel.org>,
Jiri Slaby <jirislaby@kernel.org>,
Miguel Ojeda <ojeda@kernel.org>,
Nathan Chancellor <nathan@kernel.org>,
Nick Desaulniers <ndesaulniers@google.com>,
Philipp Rudo <prudo@linux.ibm.com>,
linux-kernel@vger.kernel.org
Subject: [PATCH] kbuild: dummy-tools: adjust to scripts/cc-version.sh
Date: Wed, 10 Mar 2021 01:25:45 +0900 [thread overview]
Message-ID: <20210309162545.637647-1-masahiroy@kernel.org> (raw)
Commit aec6c60a01d3 ("kbuild: check the minimum compiler version in
Kconfig") changed how the script detects the compiler version.
Get 'make CROSS_COMPILE=scripts/dummy-tools/' back working again.
Fixes: aec6c60a01d3 ("kbuild: check the minimum compiler version in Kconfig")
Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>
---
Perhaps, Jiri may have already noticed this issue, and have a similar patch.
I just checked ML, but I did not find a patch to fix this.
scripts/dummy-tools/gcc | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/scripts/dummy-tools/gcc b/scripts/dummy-tools/gcc
index 7b10332b23ba..39e65fee59bd 100755
--- a/scripts/dummy-tools/gcc
+++ b/scripts/dummy-tools/gcc
@@ -57,9 +57,9 @@ if arg_contain --version "$@"; then
fi
if arg_contain -E "$@"; then
- # For scripts/gcc-version.sh; This emulates GCC 20.0.0
+ # For scripts/cc-version.sh; This emulates GCC 20.0.0
if arg_contain - "$@"; then
- sed 's/^__GNUC__$/20/; s/^__GNUC_MINOR__$/0/; s/^__GNUC_PATCHLEVEL__$/0/'
+ sed -n '/^GCC/{s/__GNUC__/20/; s/__GNUC_MINOR__/0/; s/__GNUC_PATCHLEVEL__/0/; p;}'
exit 0
else
echo "no input files" >&2
--
2.27.0
next reply other threads:[~2021-03-09 16:27 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-03-09 16:25 Masahiro Yamada [this message]
2021-03-09 17:37 ` Nathan Chancellor
2021-03-09 18:16 ` Miguel Ojeda
2021-03-10 4:54 ` Jiri Slaby
2021-03-10 12:17 ` Masahiro Yamada
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20210309162545.637647-1-masahiroy@kernel.org \
--to=masahiroy@kernel.org \
--cc=jirislaby@kernel.org \
--cc=jslaby@suse.cz \
--cc=linux-kbuild@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=nathan@kernel.org \
--cc=ndesaulniers@google.com \
--cc=ojeda@kernel.org \
--cc=prudo@linux.ibm.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®