summaryrefslogtreecommitdiff
path: root/linux/linux-mtx-1_2.4.27.oe
blob: 52ba6eea971f581da71d2dc6b88357b3ef9da0c3 (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
45
46
47
48
49
50
51
DESCRIPTION = "Linux kernel for MTX-1 (MeshCube)"
MAINTAINER = "Bruno Randolf <bruno.randolf@4g-systems.biz>"
LICENSE = "GPL"
KV = "${PV}"
PACKAGE_ARCH = "mtx-1"
RDEPENDS = "mtd"

SRC_URI = "cvs://cvs@ftp.linux-mips.org/home/cvs;module=linux;tag=linux_2_4 \
	ftp://ftp.linux-mips.org/pub/linux/mips/people/ppopov/2.4/zboot-2.4.26.patch;patch=1 \
	ftp://ftp.linux-mips.org/pub/linux/mips/people/ppopov/2.4/usb-nonpci-2.4.24.patch;patch=1 \
	file://mtx-1-board-reset.diff;patch=1 \
	file://zimage-flash-bin.patch;patch=1 \
	file://defconfig-mtx-1"

S = "${WORKDIR}/linux"

BROKEN = "1"
inherit kernel

ARCH = "mips"
KERNEL_OUTPUT = "arch/mips/zboot/images/mtx-1.flash.bin"
KERNEL_IMAGETYPE = "zImage.flash"
KERNEL_IMAGEDEST = "tmp"

do_configure_prepend() {
	install -m 0644 ${WORKDIR}/defconfig-mtx-1 ${S}/.config
}

pkg_postinst_kernel() {
if test "x$D" != "x"; then
	exit 1
else
	if test -e /tmp/zImage.flash.bin-${KV}; then
		echo "*** flashing kernel ***"
		flashcp -v /tmp/zImage.flash.bin-${KV} /dev/mtd/2
		echo "*** done. please reboot ***"
	fi
fi
}

FILES_kernel += " /tmp"

do_deploy() {
        install -d ${DEPLOY_DIR}/images
        install -m 0644 arch/mips/zboot/images/mtx-1.flash.bin ${DEPLOY_DIR}/images/${MACHINE}-${KV}-${DATETIME}.bin
	install -m 0644 arch/mips/zboot/images/mtx-1.flash.srec ${DEPLOY_DIR}/images/${MACHINE}-${KV}-${DATETIME}.srec
}

do_deploy[dirs] = "${S}"

addtask deploy before do_build after do_compile