summaryrefslogtreecommitdiffstats
path: root/recipes/angstrom/angstrom-uboot-scripts.bb
blob: 020a7afd8d94c31a89aa2ca24e28d8c6640e5eda (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
DESCRIPTION = "Various uboot scripts"

PR = "r10"

DEPENDS = "u-boot-mkimage-native"

SRC_URI = "file://*.cmd"

do_configure() {
	cp ${WORKDIR}/*.cmd ${S}

	for i in *.cmd ; do
		mv $i uboot-$i
	done
}

do_compile() {
	for i in *.cmd ; do
		uboot-mkimage -A ${TARGET_ARCH} -O linux -T script -C none -a 0 -e 0 -n "Angstrom $i" -d $i $i.scr
	done
}

do_install() {
	install -d ${D}/boot/u-boot-scripts
	for i in *.cmd *.scr ; do
		install -m 0644 $i ${D}/boot/u-boot-scripts
	done
}

FILES_${PN} += "/boot"

addtask deploy before do_package after do_install

do_deploy() {
	install -d ${DEPLOY_DIR_IMAGE}
	for i in *.scr ; do
		cp $i ${DEPLOY_DIR_IMAGE}
		package_stagefile_shell ${DEPLOY_DIR_IMAGE}/$i
	done
}

PACKAGE_ARCH = "${MACHINE_ARCH}"