generate orion images differently
[openwrt.git] / target / linux / orion / image / Makefile
1 #
2 # Copyright (C) 2008 OpenWrt.org
3 #
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
6 #
7 include $(TOPDIR)/rules.mk
8 include $(INCLUDE_DIR)/image.mk
9
10 define Image/Prepare
11 cp $(LINUX_DIR)/arch/arm/boot/uImage $(KDIR)/uImage
12 endef
13
14 define Image/BuildKernel
15 # WRT350N v2: mach id 1633 (0x661)
16 echo -en "\x06\x1c\xa0\xe3\x61\x10\x81\xe3" > $(KDIR)/wrt350nv2-zImage
17 cat $(LINUX_DIR)/arch/arm/boot/zImage >> $(KDIR)/wrt350nv2-zImage
18 $(STAGING_DIR_HOST)/bin/mkimage -A arm -O linux -T kernel \
19 -C none -a 0x00008000 -e 0x00008000 -n 'Linux-$(LINUX_VERSION)' \
20 -d $(KDIR)/wrt350nv2-zImage $(KDIR)/wrt350nv2-uImage
21 cp $(KDIR)/wrt350nv2-uImage $(BIN_DIR)/openwrt-wrt350nv2-uImage
22 endef
23
24 define Image/Build
25 $(call Image/Build/$(1),$(1))
26 endef
27
28 define Image/Build/squashfs
29 $(call prepare_generic_squashfs,$(KDIR)/root.squashfs)
30 ( \
31 dd if=$(KDIR)/uImage bs=1024k conv=sync; \
32 dd if=$(KDIR)/root.$(1) bs=128k conv=sync; \
33 ) > $(BIN_DIR)/openwrt-$(BOARD)-$(1).img
34 endef
35
36 $(eval $(call BuildImage))
This page took 0.054515 seconds and 5 git commands to generate.