Author: nbd
Date: 2015-12-10 13:39:32 +0100 (Thu, 10 Dec 2015)
New Revision: 47823

Modified:
   trunk/include/image.mk
   trunk/target/linux/ramips/image/Makefile
Log:
build: fix arch used during dts compilation

Use kernel arch for dts compilation.
Also use Image/BuildDTB to build dts for ramips.

Signed-off-by: Nikolay Martynov <[email protected]>

Modified: trunk/include/image.mk
===================================================================
--- trunk/include/image.mk      2015-12-10 12:17:24 UTC (rev 47822)
+++ trunk/include/image.mk      2015-12-10 12:39:32 UTC (rev 47823)
@@ -16,7 +16,7 @@
 
 KDIR=$(KERNEL_BUILD_DIR)
 KDIR_TMP=$(KDIR)/tmp
-DTS_DIR:=$(LINUX_DIR)/arch/$(ARCH)/boot/dts/
+DTS_DIR:=$(LINUX_DIR)/arch/$(LINUX_KARCH)/boot/dts
 
 IMG_PREFIX:=openwrt-$(if 
$(CONFIG_VERSION_FILENAMES),$(VERSION_NUMBER)-)$(BOARD)$(if 
$(SUBTARGET),-$(SUBTARGET))
 
@@ -143,8 +143,8 @@
 # $(4) extra DTC flags
 define Image/BuildDTB
        $(CPP) -nostdinc -x assembler-with-cpp \
-               -I$(LINUX_DIR)/arch/$(ARCH)/boot/dts \
-               -I$(LINUX_DIR)/arch/$(ARCH)/boot/dts/include \
+               -I$(DTS_DIR) \
+               -I$(DTS_DIR)/include \
                -undef -D__DTS__ $(3) \
                -o $(2).tmp $(1)
        $(LINUX_DIR)/scripts/dtc/dtc -O dtb \

Modified: trunk/target/linux/ramips/image/Makefile
===================================================================
--- trunk/target/linux/ramips/image/Makefile    2015-12-10 12:17:24 UTC (rev 
47822)
+++ trunk/target/linux/ramips/image/Makefile    2015-12-10 12:39:32 UTC (rev 
47823)
@@ -39,7 +39,7 @@
 endef
 
 define Build/patch-dtb
-       $(LINUX_DIR)/scripts/dtc/dtc -O dtb -o [email protected] ../dts/$(DTS).dts
+       $(call Image/BuildDTB,../dts/$(DTS).dts,[email protected])
        $(STAGING_DIR_HOST)/bin/patch-dtb $@ [email protected]
 endef
 
_______________________________________________
openwrt-commits mailing list
[email protected]
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-commits

Reply via email to