Re: [PATCH] scripts/dtc: only append to HOST_EXTRACFLAGS instead of overwriting

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Sat, Sep 19, 2020 at 11:39 PM Uwe Kleine-König
<u.kleine-koenig@xxxxxxxxxxxxxx> wrote:
>
> When building with
>
>         $ HOST_EXTRACFLAGS=-g make


I do not think this is the intended usage
of HOST_EXTRACFLAGS.




Documentation/kbuild/kbuild.rst lists the user-interface,
and it clearly says HOSTCFLAGS is the one.


    HOSTCFLAGS
    ----------
    Additional flags to be passed to $(HOSTCC) when building host programs.








> the expectation is that host tools are built with debug informations.
> This however doesn't happen if the Makefile assigns a new value to the
> HOST_EXTRACFLAGS instead of appending to it. So use += instead of := for
> the first assignment.
>
> Fixes: e3fd9b5384f3 ("scripts/dtc: consolidate include path options in Makefile")
> Signed-off-by: Uwe Kleine-König <u.kleine-koenig@xxxxxxxxxxxxxx>
> ---
> Hello,
>
> this is a resend as I failed to add the devicetree mailing list to Cc
> for the first mail :-\ Thanks to Rob for reminding me. Those who got
> this mail twice and want to reply please make sure you reply to the
> right (i.e. this) mail.
>
> The patch is the same as my earlier patch "scripts/dtc: Don't overwrite
> HOST_EXTRACFLAGS passed on command line" but here the commit log is not
> wrong.
>
> Thanks and sorry,
> Uwe
>
>  scripts/dtc/Makefile | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/scripts/dtc/Makefile b/scripts/dtc/Makefile
> index a698ece43fff..4852bf44e913 100644
> --- a/scripts/dtc/Makefile
> +++ b/scripts/dtc/Makefile
> @@ -9,7 +9,7 @@ dtc-objs        := dtc.o flattree.o fstree.o data.o livetree.o treesource.o \
>  dtc-objs       += dtc-lexer.lex.o dtc-parser.tab.o
>
>  # Source files need to get at the userspace version of libfdt_env.h to compile
> -HOST_EXTRACFLAGS := -I $(srctree)/$(src)/libfdt
> +HOST_EXTRACFLAGS += -I $(srctree)/$(src)/libfdt
>
>  ifeq ($(shell pkg-config --exists yaml-0.1 2>/dev/null && echo yes),)
>  ifneq ($(CHECK_DT_BINDING)$(CHECK_DTBS),)
> --
> 2.28.0
>


-- 
Best Regards
Masahiro Yamada




[Index of Archives]     [Device Tree Compilter]     [Device Tree Spec]     [Linux Driver Backports]     [Video for Linux]     [Linux USB Devel]     [Linux PCI Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Yosemite Backpacking]


  Powered by Linux