Message ID | 20230829221457.101469-2-afd@ti.com |
---|---|
State | RFC |
Delegated to: | Tom Rini |
Headers | show |
Series | Allow defconfigs defined from fragments | expand |
Hi Andrew, On Tue, 29 Aug 2023 at 16:15, Andrew Davis <afd@ti.com> wrote: > > This allows us to use some of the normal preprocessor directives inside > defconfig files. Such as #define and #include. > > Signed-off-by: Andrew Davis <afd@ti.com> > --- > scripts/kconfig/Makefile | 3 ++- > 1 file changed, 2 insertions(+), 1 deletion(-) > > diff --git a/scripts/kconfig/Makefile b/scripts/kconfig/Makefile > index 12e525ee31f..16db9b7cf60 100644 > --- a/scripts/kconfig/Makefile > +++ b/scripts/kconfig/Makefile > @@ -93,7 +93,8 @@ endif > endif > > %_defconfig: $(obj)/conf > - $(Q)$< $(silent) --defconfig=arch/$(SRCARCH)/configs/$@ $(Kconfig) > + $(Q)$(CPP) -nostdinc -I $(srctree) -undef -x assembler-with-cpp $(srctree)/arch/$(SRCARCH)/configs/$@ -o generated_defconfig > + $(Q)$< $(silent) --defconfig=generated_defconfig $(Kconfig) > > # Added for U-Boot (backward compatibility) > %_config: %_defconfig > -- > 2.39.2 > Reviewed-by: Simon Glass <sjg@chromium.org> Can you please check what happens if the file has an error flagged by CPP? Is it obvious what is wrong? Regards, Simon
diff --git a/scripts/kconfig/Makefile b/scripts/kconfig/Makefile index 12e525ee31f..16db9b7cf60 100644 --- a/scripts/kconfig/Makefile +++ b/scripts/kconfig/Makefile @@ -93,7 +93,8 @@ endif endif %_defconfig: $(obj)/conf - $(Q)$< $(silent) --defconfig=arch/$(SRCARCH)/configs/$@ $(Kconfig) + $(Q)$(CPP) -nostdinc -I $(srctree) -undef -x assembler-with-cpp $(srctree)/arch/$(SRCARCH)/configs/$@ -o generated_defconfig + $(Q)$< $(silent) --defconfig=generated_defconfig $(Kconfig) # Added for U-Boot (backward compatibility) %_config: %_defconfig
This allows us to use some of the normal preprocessor directives inside defconfig files. Such as #define and #include. Signed-off-by: Andrew Davis <afd@ti.com> --- scripts/kconfig/Makefile | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)