opendreambox 2.0
[opendreambox.git] / meta-bsp / common / recipes / dreambox / dreambox-bootlogo.inc
1 DESCRIPTION = "Bootlogo support"
2 SECTION = "base"
3 LICENSE = "CLOSED"
4 PRIORITY = "required"
5 INC_PR = "r10"
6
7 inherit opendreambox-precompiled-binary opendreambox-sysvinit
8
9 do_install() {
10         install -d ${D}/boot ${D}${datadir}/${PN}
11         install -m 0755 bootlogo-${MACHINE}.elf.gz ${D}/boot
12         install -m 0644 bootlogo-${MACHINE}.jpg ${D}/boot
13         for file in *.mvi; do
14                 install -m 0644 $file ${D}${datadir}/${PN}
15                 ln -s ${PN}/$file ${D}${datadir}
16         done
17 }
18
19 PACKAGES += "${PN}-data"
20
21 PACKAGE_ARCH := "${MACHINE_ARCH}"
22
23 RDEPENDS_${PN} = "${PN}-data"
24
25 FILES_${PN} = "/boot/bootlogo-${MACHINE}.elf.gz"
26 FILES_${PN}-data = "/boot/bootlogo-${MACHINE}.jpg ${datadir} ${sysconfdir}"
27
28 pkg_preinst() {
29         if [ -z "$D" ] && mountpoint -q /boot; then mount -o remount,rw /boot; fi
30 }
31 pkg_prerm() {
32         if [ -z "$D" ] && mountpoint -q /boot; then mount -o remount,rw /boot; fi
33 }
34 pkg_postinst() {
35         if [ -z "$D" ] && mountpoint -q /boot; then mount -o remount,ro /boot; fi
36 }
37 pkg_postrm() {
38         if [ -z "$D" ] && mountpoint -q /boot; then mount -o remount,ro /boot; fi
39 }
40
41 INITSCRIPT_PARAMS = "start 3 S . stop 89 0 ."