aboutsummaryrefslogtreecommitdiffstats
path: root/target/powerpc/yaboot/yaboot.mk
blob: cbeae50861ce0305e82e75451a50644a057971eb (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
ifeq ($(ARCH),powerpc)

#############################################################
#
# yaboot
#
#############################################################

YABOOT_SOURCE:=yaboot-1.3.13.tar.gz
YABOOT_SITE:=http://penguinppc.org/bootloaders/yaboot
YABOOT_DIR:=$(BUILD_DIR)/yaboot-1.3.13

$(DL_DIR)/$(YABOOT_SOURCE):
	 $(call DOWNLOAD,$(YABOOT_SITE),$(YABOOT_SOURCE))

yaboot-source: $(DL_DIR)/$(YABOOT_SOURCE)

$(YABOOT_DIR)/Makefile: $(DL_DIR)/$(YABOOT_SOURCE)
	$(ZCAT) $(DL_DIR)/$(YABOOT_SOURCE) | tar -C $(BUILD_DIR) -xvf -
	touch -c $(YABOOT_DIR)/Makefile

$(YABOOT_DIR)/second/yaboot: $(YABOOT_DIR)/Makefile
	$(MAKE) -C $(YABOOT_DIR) CROSS=$(TARGET_CROSS)
	touch -c $(YABOOT_DIR)/second/yaboot

yaboot: $(YABOOT_DIR)/second/yaboot

yaboot-clean:
	$(MAKE) -C $(YABOOT_DIR) clean

yaboot-dirclean:
	rm -rf $(YABOOT_DIR)

endif

#############################################################
#
# Toplevel Makefile options
#
#############################################################
ifeq ($(BR2_TARGET_YABOOT),y)
TARGETS+=yaboot
endif