2006-06-27 00:35:46 +00:00
|
|
|
#
|
|
|
|
# Copyright (C) 2006 OpenWrt.org
|
|
|
|
#
|
|
|
|
# This is free software, licensed under the GNU General Public License v2.
|
|
|
|
# See /LICENSE for more information.
|
|
|
|
#
|
2006-06-21 03:13:25 +00:00
|
|
|
include $(TOPDIR)/rules.mk
|
2006-06-21 02:32:39 +00:00
|
|
|
include $(INCLUDE_DIR)/image.mk
|
2006-05-30 19:38:38 +00:00
|
|
|
|
2006-08-06 10:42:12 +00:00
|
|
|
define Build/Clean
|
|
|
|
endef
|
|
|
|
|
|
|
|
define Image/Prepare
|
|
|
|
endef
|
|
|
|
|
|
|
|
define Image/BuildKernel
|
|
|
|
cp $(LINUX_DIR)/arch/arm/boot/zImage $(BIN_DIR)/openwrt-$(BOARD)-$(KERNEL)-zImage
|
2006-12-19 13:14:06 +00:00
|
|
|
# $(shell BIN_DIR=$(BIN_DIR) $(TOPDIR)/scripts/arm-magic.sh)
|
|
|
|
BIN_DIR=$(BIN_DIR) $(TOPDIR)/scripts/arm-magic.sh
|
2006-08-06 10:42:12 +00:00
|
|
|
endef
|
|
|
|
|
2006-06-04 21:57:59 +00:00
|
|
|
define Image/Build
|
2006-08-06 10:42:12 +00:00
|
|
|
$(call Image/Build/$(1),$(1))
|
|
|
|
endef
|
|
|
|
|
|
|
|
define Image/Build/jffs2-64k
|
|
|
|
dd if=$(KDIR)/root.$(1) of=$(BIN_DIR)/openwrt-$(BOARD)-$(KERNEL)-$(1).img bs=65536 conv=sync
|
|
|
|
endef
|
|
|
|
|
|
|
|
define Image/Build/jffs2-128k
|
|
|
|
dd if=$(KDIR)/root.$(1) of=$(BIN_DIR)/openwrt-$(BOARD)-$(KERNEL)-$(1).img bs=131072 conv=sync
|
2006-12-23 08:10:35 +00:00
|
|
|
BIN_DIR=$(BIN_DIR) $(TOPDIR)/scripts/slugimage.pl \
|
|
|
|
-k $(BIN_DIR)/openwrt-nslu2-$(KERNEL)-zImage \
|
|
|
|
-r Ramdisk:1,Flashdisk:$(BIN_DIR)/openwrt-$(BOARD)-$(KERNEL)-$(1).img \
|
|
|
|
-p -o $(BIN_DIR)/openwrt-nslu2-$(KERNEL)-$(1).bin
|
|
|
|
# -L $(BIN_DIR)/apex-nslu2-armeb.bin
|
|
|
|
# -m $(BIN_DIR)/NPE-B
|
2006-06-04 21:57:59 +00:00
|
|
|
endef
|
2006-05-30 19:38:38 +00:00
|
|
|
|
2006-06-04 21:57:59 +00:00
|
|
|
$(eval $(call BuildImage))
|