sunxi: tidy up and sort alphabetically in image Makefiles
[openwrt/openwrt.git] / target / linux / sunxi / image / Makefile
index 20ecf66a9ce0e67259cc080e90dd670b39c4b2cc..705d409ac5e5e8e81c8b39055554e6b19be4acb6 100644 (file)
@@ -32,14 +32,26 @@ endef
 # why \x00\x00\x00\x00 for zImage-initramfs
 define Device/Default
   PROFILES := Default
-  DEVICE_VARS := SUNXI_DTS SUNXI_UBOOT
+  DEVICE_VARS := SUNXI_DTS SUNXI_DTS_DIR SUNXI_UBOOT
   KERNEL_NAME := zImage
   KERNEL := kernel-bin | uImage none
   IMAGES := sdcard.img.gz
   IMAGE/sdcard.img.gz := sunxi-sdcard | append-metadata | gzip
+  SUPPORTED_DEVICES := $(subst _,$(comma),$(1))
+  SUNXI_DTS_DIR :=
+  SUNXI_DTS = $$(SUNXI_DTS_DIR)$$(SOC)-$(lastword $(subst _, ,$(1)))
 endef
 
+ifeq ($(SUBTARGET),cortexa7)
 include cortex-a7.mk
+endif
+
+ifeq ($(SUBTARGET),cortexa8)
 include cortex-a8.mk
+endif
+
+ifeq ($(SUBTARGET),cortexa53)
+include cortex-a53.mk
+endif
 
 $(eval $(call BuildImage))