From: Douglas Anderson <dianders@chromium.org>
To: yamada.masahiro@socionext.com, mmarek@suse.com
Cc: groeck@chromium.org, sjg@chromium.org, briannorris@chromium.org,
Douglas Anderson <dianders@chromium.org>,
linux-kernel@vger.kernel.org, linux-kbuild@vger.kernel.org
Subject: [PATCH v2 2/2] kbuild: Cache a few more calls to the compiler
Date: Wed, 4 Oct 2017 15:37:17 -0700 [thread overview]
Message-ID: <20171004223717.3010-3-dianders@chromium.org> (raw)
In-Reply-To: <20171004223717.3010-1-dianders@chromium.org>
These are a few stragglers that I left out of the original patch to
cache calls to the C compiler ("kbuild: Add a cache for generated
variables") because they bleed out into the main Makefile and thus
uglify things a little bit. The idea is the same here, though.
Signed-off-by: Douglas Anderson <dianders@chromium.org>
---
Changes in v2:
- Abstract at a different level (like shell-cached) per Masahiro Yamada
Makefile | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/Makefile b/Makefile
index d1119941261c..d366bdc3da04 100644
--- a/Makefile
+++ b/Makefile
@@ -652,7 +652,7 @@ KBUILD_CFLAGS += $(call cc-ifversion, -lt, 0409, \
KBUILD_CFLAGS += $(call cc-option,--param=allow-store-data-races=0)
# check for 'asm goto'
-ifeq ($(shell $(CONFIG_SHELL) $(srctree)/scripts/gcc-goto.sh $(CC) $(KBUILD_CFLAGS)), y)
+ifeq ($(call shell-cached,$(CONFIG_SHELL) $(srctree)/scripts/gcc-goto.sh $(CC) $(KBUILD_CFLAGS)), y)
KBUILD_CFLAGS += -DCC_HAVE_ASM_GOTO
KBUILD_AFLAGS += -DCC_HAVE_ASM_GOTO
endif
@@ -788,7 +788,7 @@ KBUILD_CFLAGS += $(call cc-option,-fdata-sections,)
endif
# arch Makefile may override CC so keep this after arch Makefile is included
-NOSTDINC_FLAGS += -nostdinc -isystem $(shell $(CC) -print-file-name=include)
+NOSTDINC_FLAGS += -nostdinc -isystem $(call shell-cached,$(CC) -print-file-name=include)
CHECKFLAGS += $(NOSTDINC_FLAGS)
# warn about C99 declaration after statement
--
2.14.2.920.gcf0c67979c-goog
next prev parent reply other threads:[~2017-10-04 22:38 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-10-04 22:37 [PATCH v2 0/2] kbuild: Cache exploratory calls to the compiler Douglas Anderson
2017-10-04 22:37 ` [PATCH v2 1/2] kbuild: Add a cache for generated variables Douglas Anderson
2017-10-11 3:59 ` Masahiro Yamada
2017-10-11 16:20 ` Doug Anderson
2017-10-04 22:37 ` Douglas Anderson [this message]
2017-10-05 1:46 ` [PATCH v2 0/2] kbuild: Cache exploratory calls to the compiler Guenter Roeck
2017-10-05 7:52 ` Ingo Molnar
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=20171004223717.3010-3-dianders@chromium.org \
--to=dianders@chromium.org \
--cc=briannorris@chromium.org \
--cc=groeck@chromium.org \
--cc=linux-kbuild@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mmarek@suse.com \
--cc=sjg@chromium.org \
--cc=yamada.masahiro@socionext.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