dotsplash: rrecommend configured theme
[meta-kc-bsp.git] / recipes-bsp / dotsplash / dotsplash_git.bb
1 SUMMARY = "./dotsplash - a tiny and customizable splash screen"
2 LICENSE = "GPLv2"
3 PV = "1.0+git${SRCPV}"
4 SRCREV = "ff34b85bfed5401910b2bc28a150a347f26ce97f"
5
6
7 LIC_FILES_CHKSUM = "file://COPYING;md5=39bba7d2cf0ba1036f2a6e2be52fe3f0"
8
9 SRC_URI = "git://git@gitlab.kernelconcepts.de:2224/danb/dotsplash.git;protocol=ssh \
10           file://dotsplash-default \
11           file://dotsplash-init \
12           file://splashfuncs"
13
14 inherit pkgconfig update-rc.d meson
15
16 PACKAGE_ARCH = "${MACHINE_ARCH}"
17
18 DOTSPLASH_THEME ?= "kc-800"
19 DOTSPLASH_THEME_lamobo-r1 ?= "kc-fullhd"
20 DOTSPLASH_THEME_topasa900 ?= "kc-320"
21
22 DOTSPLASH_PARAMS ?= "-s 15 --theme ${DOTSPLASH_THEME}"
23
24 S = "${WORKDIR}/git"
25
26 FILES_${PN} += "/mnt/.psplash/"
27
28 do_install_append() {
29     install -d ${D}/mnt/.psplash/
30     install -d ${D}${sysconfdir}/init.d/
31     install -m 0755 ${WORKDIR}/dotsplash-init ${D}${sysconfdir}/init.d/dotsplash.sh
32     install -d ${D}${sysconfdir}/default/
33     sed -i 's/@PARAMS@/${DOTSPLASH_PARAMS}/g' ${WORKDIR}/dotsplash-default
34     install -m 0644 ${WORKDIR}/dotsplash-default ${D}${sysconfdir}/default/dotsplash
35     install -m 0755 ${WORKDIR}/splashfuncs ${D}${sysconfdir}/default/splashfuncs
36     cd ${D}/${bindir}
37     ln -s dotsplash-write psplash-write
38 }
39
40 INITSCRIPT_NAME = "dotsplash.sh"
41 INITSCRIPT_PARAMS = "start 0 S . stop 20 0 1 6 ."
42
43 RRECOMMENDS_${PN} = "${PN}-theme-${DOTSPLASH_THEME}"
44
45 python populate_packages_prepend () {
46     themedir = d.expand('${datadir}/dotsplash/themes')
47     do_split_packages(d, themedir, '^(.*)$',
48                      'dotsplash-theme-%s', './dotsplash theme %s',
49                       extra_depends='', allow_dirs=True, prepend=True)
50 }
51
52 PACKAGES_DYNAMIC += "^dotsplash-theme-.*"