#
PWD = $(shell pwd)
+WORK = $(PWD)/work
MKIMAGE = $(PWD)/../../work/mkimage
+ZIMAGE = $(PWD)/../../../kernel/efikamx/work/zImage
INITRDGZ = $(PWD)/../../../initrd/work/initrd.gz
.PHONY: all clean distclean uImage boot.scr uInitrd
distclean: clean
-uImage: # TODO
-uImage-clean: # TODO
+$(WORK)/zImage: $(ZIMAGE)
+ cp $(ZIMAGE) $(WORK)
+
+uImage: $(MKIMAGE) $(WORK)/zImage
+ $(MKIMAGE) -A arm -O linux -a 0x90008000 -e 0x90008000 \
+ -T kernel -C none -n "Linux-2.6.31.14.22-efikamx" \
+ -d $(WORK)/zImage $(WORK)/uImage
+
+uImage-clean:
+ rm -f $(WORK)/uImage $(WORK)/zImage
boot.scr: $(MKIMAGE) boot.script
- $(MKIMAGE) -A arm -O linux -a 0 -e 0 -T script -C none \
- -n "EfikaMX Boot Script" -d boot.script boot.scr
+ $(MKIMAGE) -A arm -O linux -a 0 -e 0 \
+ -T script -C none -n "EfikaMX Boot Script" \
+ -d boot.script $(WORK)/boot.scr
boot.scr-clean:
- rm -f boot.scr
+ rm -f $(WORK)/boot.scr
-initrd.gz: $(INITRDGZ)
- cp $(INITRDGZ) .
+$(WORK)/initrd.gz: $(INITRDGZ)
+ cp $(INITRDGZ) $(WORK)
-uInitrd: $(MKIMAGE) initrd.gz
- $(MKIMAGE) -A arm -O linux -a 0 -e 0 -T ramdisk -C none \
- -n "initrd" -d initrd.gz uInitrd
+uInitrd: $(MKIMAGE) $(WORK)/initrd.gz
+ $(MKIMAGE) -A arm -O linux -a 0 -e 0 \
+ -T ramdisk -C none -n "EfikaMX Initrd Image" \
+ -d $(WORK)/initrd.gz $(WORK)/uInitrd
uInitrd-clean:
- rm -f uInitrd initrd.gz
+ rm -f $(WORK)/uInitrd $(WORK)/initrd.gz
# End of file