Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754354AbdFNHky (ORCPT ); Wed, 14 Jun 2017 03:40:54 -0400 Received: from conssluserg-05.nifty.com ([210.131.2.90]:52049 "EHLO conssluserg-05.nifty.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751821AbdFNHkw (ORCPT ); Wed, 14 Jun 2017 03:40:52 -0400 DKIM-Filter: OpenDKIM Filter v2.10.3 conssluserg-05.nifty.com v5E7ecjD001693 X-Nifty-SrcIP: [209.85.161.181] MIME-Version: 1.0 In-Reply-To: References: <20170613230854.112282-1-mka@chromium.org> <20170613230854.112282-3-mka@chromium.org> From: Masahiro Yamada Date: Wed, 14 Jun 2017 16:40:37 +0900 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [PATCH v2 2/4] kbuild: Add hostcc-option macro To: Arnd Bergmann Cc: Matthias Kaehlcke , Thomas Gleixner , Ingo Molnar , "H . Peter Anvin" , "H . J . Lu" , David Woodhouse , Michal Marek , "the arch/x86 maintainers" , Linux Kbuild mailing list , Linux Kernel Mailing List , Michael Davidson , Greg Hackmann , Nick Desaulniers , Stephen Hines , Kees Cook , =?UTF-8?Q?Bernhard_Rosenkr=C3=A4nzer?= , Peter Foley , Behan Webster , Douglas Anderson Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1324 Lines: 43 Hi Arnd, 2017-06-14 16:26 GMT+09:00 Arnd Bergmann : > On Wed, Jun 14, 2017 at 1:08 AM, Matthias Kaehlcke wrote: >> hostcc-option is equivalent to cc-option, but uses the host compiler >> and HOSTCFLAGS. Change HOSTCFLAGS to a simple expanded variable to >> allow for HOSTCFLAGS += $(call hostcc-option, ...). >> >> Suggested-by: Arnd Bergmann >> Suggested-by: Masahiro Yamada >> Signed-off-by: Matthias Kaehlcke > > Actually, we already have a hostcc-option macro. What I meant with my suggestion > was that we could redefine the existing one using cc-option-raw. > > I checked again now and found that while this was added in 2016 by > Emese Revfy, we apparently don't have any users of the helper in the > kernel. Oops, I missed it because it is defined in scripts/Makefile.host instead of scripts/Kbuild.include $(call cc-option, ...) is generally used in the top Makefile (or arch/*/Makefile). However, scripts/Makefile.host is not included from the top Makefile, so $(call hostcc-option, ...) is available only under sub-directories. I guess that is why we had no user of it. I think the right thing to do is to remove the former implementation from Makefile.host Thanks! -- Best Regards Masahiro Yamada