change handling of target/linux/generic-2.x/files to match other targets (#1648)
[openwrt.git] / target / linux / adm5120eb-2.6 / image / Makefile
1 #
2 # Copyright (C) 2006 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 Build/Compile
11 rm -f $(KDIR)/loader-zynos.gz $(KDIR)/loader-zynos.bin
12 $(MAKE) -C lzma-loader \
13 BUILD_DIR="$(KDIR)" \
14 TARGET="$(KDIR)" \
15 LOADER=loader-zynos \
16 install
17 endef
18
19 define Build/Clean
20 $(MAKE) -C lzma-loader clean
21 endef
22
23 define Image/Prepare
24 cat $(KDIR)/vmlinux | $(STAGING_DIR)/bin/lzma e -si -so -eos -lc1 -lp2 -pb2 > $(KDIR)/vmlinux.lzma
25 endef
26
27 define trxalign/jffs2-128k
28 -a 0x20000
29 endef
30 define trxalign/jffs2-64k
31 -a 0x10000
32 endef
33 define trxalign/squashfs
34 -a 1024
35 endef
36
37 define Image/Build/ZyXEL
38 $(CP) $(BIN_DIR)/openwrt-$(BOARD)-$(KERNEL)-$(1)-noloader.trx $(BIN_DIR)/openwrt-$(BOARD)-$(KERNEL)-$(3)-$(2).trx
39 endef
40
41 define Image/Build
42 $(STAGING_DIR)/bin/trx -o $(BIN_DIR)/openwrt-$(BOARD)-$(KERNEL)-$(1)-noloader.trx -f $(KDIR)/vmlinux.lzma $(call trxalign/$(1)) -f $(KDIR)/root.$(1)
43 ifneq ($(1),jffs2-128K)
44 #FIXME: no supported boards yet
45 endif
46 endef
47
48 $(eval $(call BuildImage))
This page took 0.046708 seconds and 5 git commands to generate.