CRUX-ARM : Home

Home :: Documentation :: Download :: Development :: Community :: Ports :: Packages :: Bugs :: Links :: About :: Donors
U-Boot updated to 2011.12 (which fixes issues when building mkimage)
[bootloader.git] / Makefile
1 #
2 # uboot/Makefile
3 #
4
5 PWD = $(shell pwd)
6 WORK = $(PWD)/work
7
8 UBOOT_VERSION = 2011.12
9
10 .PHONY: all help mkimage clean dist-clean efikamx efikamx-clean efikamx-distclean
11
12 all: help
13
14 help:
15 @echo "Usage: make <target>"
16 @echo "Where targets available are:"
17 @echo " mkimage Build mkimage binary for your host"
18 @echo " <device> Where device specified should appear under"
19 @echo " devices's dir as for example efikamx, wm8505, ..."
20 @echo " clean Remove generated files"
21 @echo " distclean Remove generated files and temporary sources"
22
23 clean: mkimage-clean efikamx-clean
24
25 distclean: mkimage-distclean efikamx-distclean
26
27
28 $(WORK)/u-boot-$(UBOOT_VERSION).tar.bz2:
29 wget -P $(WORK) ftp://ftp.denx.de/pub/u-boot/u-boot-$(UBOOT_VERSION).tar.bz2
30
31 $(WORK)/u-boot-$(UBOOT_VERSION): $(WORK)/u-boot-$(UBOOT_VERSION).tar.bz2
32 tar -C $(WORK) -xjf $(WORK)/u-boot-$(UBOOT_VERSION).tar.bz2
33 touch $(WORK)/u-boot-$(UBOOT_VERSION)
34
35 $(WORK)/mkimage: $(WORK)/u-boot-$(UBOOT_VERSION)
36 cd $(WORK)/u-boot-$(UBOOT_VERSION) && \
37 make tools && \
38 install -m 0755 $(WORK)/u-boot-$(UBOOT_VERSION)/tools/mkimage $(WORK)/mkimage
39
40 mkimage: $(WORK)/mkimage
41
42 mkimage-clean:
43 rm -f $(WORK)/mkimage mkimage
44
45 mkimage-distclean: mkimage-clean
46 rm -rf $(WORK)/u-boot-$(UBOOT_VERSION) $(WORK)/u-boot-$(UBOOT_VERSION).tar.bz2
47
48 efikamx: mkimage
49 make -C devices/efikamx
50
51 efikamx-clean:
52 make -C devices/efikamx clean
53
54 efikamx-distclean:
55 make -C devices/efikamx distclean
56
57 # End of file