dns323.mk 1.0 KB

123456789101112131415161718192021222324252627282930313233343536
  1. #
  2. # Copyright (C) 2010 OpenWrt.org
  3. #
  4. # This is free software, licensed under the GNU General Public License v2.
  5. # See /LICENSE for more information.
  6. #
  7. define Image/Prepare
  8. cp $(LINUX_DIR)/arch/arm/boot/uImage $(KDIR)/uImage
  9. endef
  10. define Image/BuildKernel
  11. # Orion Kernel uImages
  12. # DNS-323: mach id 1542 (0x606)
  13. echo -en "\x06\x1c\xa0\xe3\x06\x10\x81\xe3" > $(KDIR)/dns323-zImage
  14. cat $(LINUX_DIR)/arch/arm/boot/zImage >> $(KDIR)/dns323-zImage
  15. $(STAGING_DIR_HOST)/bin/mkimage -A arm -O linux -T kernel \
  16. -C none -a 0x00008000 -e 0x00008000 -n 'Linux-$(LINUX_VERSION)' \
  17. -d $(KDIR)/dns323-zImage $(KDIR)/dns323-uImage
  18. cp $(KDIR)/dns323-uImage $(BIN_DIR)/openwrt-dns323-uImage
  19. endef
  20. define Image/Build/D-Link
  21. # Orion DNS-323 Images
  22. # mtd image
  23. dd if=$(KDIR)/root.$(1) of=$(BIN_DIR)/openwrt-dns323-rootfs bs=128k
  24. endef
  25. define Image/Build
  26. $(call Image/Build/$(1),$(1))
  27. $(call Image/Build/D-Link,$(1),dns323,DNS-323,$(1))
  28. endef
  29. define Image/Build/squashfs
  30. $(call prepare_generic_squashfs,$(KDIR)/root.squashfs)
  31. endef