source: branches/backfire/target/linux/ifxmips/image/Makefile @ 21208

Last change on this file since 21208 was 21208, checked in by nico, 7 years ago

[backfire] merge r20834, r20840, r20854 & r20855

File size: 1.1 KB
Line 
1#
2# Copyright (C) 2006-2010 OpenWrt.org
3#
4# This is free software, licensed under the GNU General Public License v2.
5# See /LICENSE for more information.
6#
7include $(TOPDIR)/rules.mk
8include $(INCLUDE_DIR)/image.mk
9
10define Image/BuildKernel
11        $(STAGING_DIR_HOST)/bin/lzma e $(KDIR)/vmlinux $(KDIR)/vmlinux.lzma
12        mkimage -A mips -O linux -T kernel -a 0x80002000 -C lzma -e \
13                0x80002000 \
14                -n 'MIPS OpenWrt Linux-$(LINUX_VERSION)' \
15                -d $(KDIR)/vmlinux.lzma $(KDIR)/uImage
16
17        cp $(KDIR)/uImage $(BIN_DIR)/$(IMG_PREFIX)-uImage
18endef
19
20define Image/Build/squashfs
21        cat $(KDIR)/uImage $(KDIR)/root.$(1) > $(BIN_DIR)/$(IMG_PREFIX)-$(1).image
22        $(call prepare_generic_squashfs,$(BIN_DIR)/$(IMG_PREFIX)-$(1).image)
23endef
24
25define Image/Build/jffs2-64k
26        dd if=$(KDIR)/uImage of=$(KDIR)/uImage.$(1) bs=64k conv=sync
27        cat $(KDIR)/uImage.$(1) $(KDIR)/root.$(1) > $(BIN_DIR)/$(IMG_PREFIX)-$(1).image
28endef
29
30define Image/Build/jffs2-128k
31        dd if=$(KDIR)/uImage of=$(KDIR)/uImage.$(1) bs=128k conv=sync
32        cat $(KDIR)/uImage.$(1) $(KDIR)/root.$(1) > $(BIN_DIR)/$(IMG_PREFIX)-$(1).image
33endef
34
35define Image/Build
36        $(call Image/Build/$(1),$(1))
37endef
38
39$(eval $(call BuildImage))
Note: See TracBrowser for help on using the repository browser.