From: Masahiro Yamada <masahiroy@kernel.org>
To: linux-kbuild@vger.kernel.org
Cc: Arnd Bergmann <arnd@arndb.de>,
Masahiro Yamada <masahiroy@kernel.org>,
Alexey Dobriyan <adobriyan@gmail.com>,
Denis Efremov <efremov@linux.com>,
Michal Marek <michal.lkml@markovi.net>,
linux-kernel@vger.kernel.org
Subject: [PATCH 4/4] kbuild: clean up ${quiet} checks in shell scripts
Date: Mon, 17 May 2021 16:03:14 +0900 [thread overview]
Message-ID: <20210517070314.1428091-4-masahiroy@kernel.org> (raw)
In-Reply-To: <20210517070314.1428091-1-masahiroy@kernel.org>
There were efforts to make 'make -s' really silent when it is a
warning-free build.
The conventional way was to let scripts check ${quiet}, and if it
is 'silent_', suppress the output by their own.
With the previous commit, the 'cmd' takes care of it now. The 'cmd' is
also invoked from if_changed, if_changed_dep, and if_changed_rule.
You can omit ${quiet} checks in shell scripts when they are invoked
from the 'cmd' macro.
Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>
---
| 4 +---
scripts/link-vmlinux.sh | 4 +---
scripts/mkcompile_h | 4 +---
3 files changed, 3 insertions(+), 9 deletions(-)
--git a/kernel/gen_kheaders.sh b/kernel/gen_kheaders.sh
index 34a1dc2abc7d..1966a749e0d9 100755
--- a/kernel/gen_kheaders.sh
+++ b/kernel/gen_kheaders.sh
@@ -56,9 +56,7 @@ if [ -f kernel/kheaders.md5 ] &&
exit
fi
-if [ "${quiet}" != "silent_" ]; then
- echo " GEN $tarfile"
-fi
+echo " GEN $tarfile"
rm -rf $cpio_dir
mkdir $cpio_dir
diff --git a/scripts/link-vmlinux.sh b/scripts/link-vmlinux.sh
index f4de4c97015b..3b342b0b0b38 100755
--- a/scripts/link-vmlinux.sh
+++ b/scripts/link-vmlinux.sh
@@ -38,9 +38,7 @@ LDFLAGS_vmlinux="$3"
# Will be supressed by "make -s"
info()
{
- if [ "${quiet}" != "silent_" ]; then
- printf " %-7s %s\n" "${1}" "${2}"
- fi
+ printf " %-7s %s\n" "${1}" "${2}"
}
# Generate a linker script to ensure correct ordering of initcalls.
diff --git a/scripts/mkcompile_h b/scripts/mkcompile_h
index 4ae735039daf..06bbf4c2c66c 100755
--- a/scripts/mkcompile_h
+++ b/scripts/mkcompile_h
@@ -9,8 +9,6 @@ PREEMPT_RT=$5
CC_VERSION="$6"
LD=$7
-vecho() { [ "${quiet}" = "silent_" ] || echo "$@" ; }
-
# Do not expand names
set -f
@@ -82,7 +80,7 @@ if [ -r $TARGET ] && \
cmp -s .tmpver.1 .tmpver.2; then
rm -f .tmpcompile
else
- vecho " UPD $TARGET"
+ echo " UPD $TARGET"
mv -f .tmpcompile $TARGET
fi
rm -f .tmpver.1 .tmpver.2
--
2.27.0
next prev parent reply other threads:[~2021-05-17 7:04 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-05-17 7:03 [PATCH 1/4] kbuild: merge scripts/mkmakefile to top Makefile Masahiro Yamada
2021-05-17 7:03 ` [PATCH 2/4] init: use $(call cmd,) for generating include/generated/compile.h Masahiro Yamada
2021-05-17 7:03 ` [PATCH 3/4] kbuild: sink stdout from cmd for silent build Masahiro Yamada
2021-05-17 7:03 ` Masahiro Yamada [this message]
2021-05-26 14:29 ` [PATCH 1/4] kbuild: merge scripts/mkmakefile to top Makefile 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=20210517070314.1428091-4-masahiroy@kernel.org \
--to=masahiroy@kernel.org \
--cc=adobriyan@gmail.com \
--cc=arnd@arndb.de \
--cc=efremov@linux.com \
--cc=linux-kbuild@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=michal.lkml@markovi.net \
/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