[U-Boot] [PATCH V2 9/9] dts/Makefile: pass -undef -D__DTS__ to cpp

Stephen Warren swarren at wwwdotorg.org
Mon Jun 24 17:43:49 CEST 2013


From: Stephen Warren <swarren at nvidia.com>

This brings U-Boot's cpp invocation into line with the way the Linux
kernel invokes cpp on device trees. Consistency will be useful to ensure
*.dts is portable between the two.

-undef also has the added advantage of not defining "linux", so DT
property names such as "linux,keymap" don't get mangled.

Signed-off-by: Stephen Warren <swarren at nvidia.com>
Acked-by: Simon Glass <sjg at chromium.org>
---
 dts/Makefile | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/dts/Makefile b/dts/Makefile
index 805d2cc..b125bd3 100644
--- a/dts/Makefile
+++ b/dts/Makefile
@@ -37,7 +37,7 @@ DTS_INCDIRS =  $(SRCTREE)/board/$(VENDOR)/$(BOARD)/dts
 DTS_INCDIRS += $(SRCTREE)/board/$(VENDOR)/dts
 DTS_INCDIRS += $(SRCTREE)/arch/$(ARCH)/dts
 
-DTS_CPPFLAGS := -x assembler-with-cpp \
+DTS_CPPFLAGS := -x assembler-with-cpp -undef -D__DTS__ \
 		-nostdinc $(addprefix -I,$(DTS_INCDIRS))
 
 DTC_FLAGS := -R 4 -p 0x1000 \
-- 
1.8.1.5



More information about the U-Boot mailing list