-
Notifications
You must be signed in to change notification settings - Fork 180
/
beyonwiz-partitions-beyonwizv2.bb
65 lines (51 loc) · 2.16 KB
/
beyonwiz-partitions-beyonwizv2.bb
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
52
53
54
55
56
57
58
59
60
61
62
63
64
65
SUMMARY = "beyonwizv2 partitions files"
SECTION = "base"
PRIORITY = "required"
LICENSE = "CLOSED"
require conf/license/license-close.inc
PACKAGE_ARCH = "${MACHINE_ARCH}"
inherit deploy
SRCDATE = "20201218"
PR = "${SRCDATE}"
S = "${WORKDIR}/patitions"
SRC_URI = "http://source.mynonpublic.com/beyonwiz/${MACHINE}-partitions-${SRCDATE}.zip \
file://flash-apploader \
"
inherit update-rc.d
INITSCRIPT_NAME = "flash-apploader"
INITSCRIPT_PARAMS = "start 90 S ."
ALLOW_EMPTY_${PN} = "1"
do_configure[nostamp] = "1"
do_install() {
install -d ${D}/usr/share
install -m 0644 ${S}/bootargs.bin ${D}/usr/share/bootargs.bin
install -m 0644 ${S}/fastboot.bin ${D}/usr/share/fastboot.bin
install -m 0644 ${S}/apploader.bin ${D}/usr/share/apploader.bin
install -m 0755 -d ${D}${sysconfdir}/init.d
install -m 0755 ${WORKDIR}/flash-apploader ${D}${sysconfdir}/init.d/flash-apploader
}
FILES_${PN} = "/usr/share ${sysconfdir}"
do_deploy() {
install -d ${DEPLOY_DIR_IMAGE}/${MACHINE}-partitions
install -m 0755 ${S}/bootargs.bin ${DEPLOY_DIR_IMAGE}/${MACHINE}-partitions
install -m 0755 ${S}/boot.img ${DEPLOY_DIR_IMAGE}/${MACHINE}-partitions
install -m 0755 ${S}/fastboot.bin ${DEPLOY_DIR_IMAGE}/${MACHINE}-partitions
install -m 0755 ${S}/apploader.bin ${DEPLOY_DIR_IMAGE}/${MACHINE}-partitions
install -m 0755 ${S}/pq_param.bin ${DEPLOY_DIR_IMAGE}/${MACHINE}-partitions
install -m 0755 ${S}/emmc_partitions.xml ${DEPLOY_DIR_IMAGE}/${MACHINE}-partitions
install -m 0755 ${S}/baseparam.img ${DEPLOY_DIR_IMAGE}/${MACHINE}-partitions
install -m 0755 ${S}/logo.img ${DEPLOY_DIR_IMAGE}/${MACHINE}-partitions
install -m 0755 ${S}/deviceinfo.bin ${DEPLOY_DIR_IMAGE}/${MACHINE}-partitions
}
addtask deploy before do_build after do_install
SRC_URI[md5sum] = "a843de0d42cbb237119df2f30a7a6dd1"
SRC_URI[sha256sum] = "609430fdb06ac63f005a5544db52adfa9cad1bf6fe454b01069ff35f0a899417"
INSANE_SKIP_${PN} += "already-stripped"
pkg_postinst_${PN}() {
if [ "x$D" == "x" ]; then
if [ -f /usr/share/apploader.bin -a -b /dev/block/by-name/loader ] ; then
dd if=/usr/share/apploader.bin of=/dev/block/by-name/loader
fi
fi
true
}