From: "Yang Shi" <yang.s@alibaba-inc.com>
To: Masahiro Yamada <yamada.masahiro@socionext.com>
Cc: Douglas Anderson <dianders@chromium.org>,
Arnd Bergmann <arnd@arndb.de>, Ingo Molnar <mingo@kernel.org>,
Guenter Roeck <linux@roeck-us.net>,
linux-kernel <linux-kernel@vger.kernel.org>
Subject: Re: [BUG] Build error for 4.15-rc3 kernel caused by patch "kbuild: Add a cache for generated variables"
Date: Tue, 19 Dec 2017 01:19:13 +0800 [thread overview]
Message-ID: <a2da02b1-8930-e75c-f0cc-7d0cd1fa923b@alibaba-inc.com> (raw)
In-Reply-To: <CAK7LNAQnLkNpBWnAUwBO-Gyq41g+pdQjBw1WR5Xy8BRMn3He6Q@mail.gmail.com>
On 12/18/17 7:50 AM, Masahiro Yamada wrote:
> 2017-12-18 23:56 GMT+09:00 Masahiro Yamada <yamada.masahiro@socionext.com>:
>> 2017-12-17 7:35 GMT+09:00 Yang Shi <yang.s@alibaba-inc.com>:
>>> Hi folks,
>>>
>>> I just upgraded gcc to 6.4 on my centos 7 machine by Arnd's suggestion. But,
>>> I ran into the below compile error with 4.15-rc3 kernel:
>>>
>>> In file included from ./include/uapi/linux/uuid.h:21:0,
>>> from ./include/linux/uuid.h:19,
>>> from ./include/linux/mod_devicetable.h:12,
>>> from scripts/mod/devicetable-offsets.c:2:
>>> ./include/linux/string.h:8:20: fatal error: stdarg.h: No such file or
>>> directory
>>> #include <stdarg.h>
>>>
>>> I bisected to commit 3298b690b21cdbe6b2ae8076d9147027f396f2b1 ("kbuild: Add
>>> a cache for generated variables"). Once I revert this commit, kernel build
>>> is fine.
>>>
>>> gcc 4.8.5 is fine to build kernel with this commit.
>>>
>>> I'm not quite sure if this is a bug or my gcc install is skewed although it
>>> can build kernel without that commit since that commit might exacerbate the
>>> case.
>>>
>>> Any hint is appreciated
>>
>>
>> Today, I was also hit with the same error
>> when I was compiling linux-next.
>> I am not so sure why this error happens, but
>> "make clean" will probably fix the problem.
>>
>> You need to do "make clean" to blow .cache.mk
>> when you upgrade your compiler.
>> This is nasty, though...
>>
>
>
> I got it.
>
> The following line in the top-level Makefile.
>
> NOSTDINC_FLAGS += -nostdinc -isystem $(call shell-cached,$(CC)
> -print-file-name=include)
>
>
> If the stale result of -print-file-name is stored in the cache file,
> the compiler fails to find <stdarg.h>
Thanks for figuring it out.
"make clean" does help. I'm supposed it is an interim approach, right?
Regards,
Yang
>
>
prev parent reply other threads:[~2017-12-18 17:19 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-12-16 22:35 Yang Shi
2017-12-18 14:56 ` Masahiro Yamada
2017-12-18 15:50 ` Masahiro Yamada
2017-12-18 17:17 ` Doug Anderson
2017-12-18 17:22 ` Yang Shi
2017-12-20 16:55 ` Doug Anderson
2017-12-21 3:47 ` Masahiro Yamada
2017-12-20 2:29 ` Masahiro Yamada
2017-12-20 17:07 ` Doug Anderson
2017-12-21 4:01 ` Masahiro Yamada
2017-12-22 2:18 ` Doug Anderson
2017-12-18 17:19 ` Yang Shi [this message]
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=a2da02b1-8930-e75c-f0cc-7d0cd1fa923b@alibaba-inc.com \
--to=yang.s@alibaba-inc.com \
--cc=arnd@arndb.de \
--cc=dianders@chromium.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux@roeck-us.net \
--cc=mingo@kernel.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
all inboxes | Powered by JetHome®