blob: 42c742fca6d9c78c09d96de91d26b92078ddd46f [file] [log] [blame]
Patrick Williamsc124f4f2015-09-15 14:41:29 -05001SUMMARY = "Custom Matchbox session files for the Sato environment"
2HOMEPAGE = "http://www.matchbox-project.org/"
3BUGTRACKER = "http://bugzilla.yoctoproject.org/"
4
5LICENSE = "GPLv2.0+"
6LIC_FILES_CHKSUM = "file://session;endline=3;md5=f8a5c5b9c279e52dc094d10e11c2be63"
7
8SECTION = "x11"
9DEPENDS = "gconf-native"
Patrick Williamsc0f7c042017-02-23 20:41:17 -060010RDEPENDS_${PN} = "formfactor matchbox-theme-sato matchbox-panel-2 matchbox-desktop matchbox-session gconf"
Patrick Williamsc124f4f2015-09-15 14:41:29 -050011PR = "r30"
12
13# This package is architecture specific because the session script is modified
14# based on the machine architecture.
15PACKAGE_ARCH = "${MACHINE_ARCH}"
16
17inherit distro_features_check
18
19# The matchbox-theme-sato requires x11 in DISTRO_FEATURES
20REQUIRED_DISTRO_FEATURES = "x11"
21
Patrick Williamsc0f7c042017-02-23 20:41:17 -060022SRC_URI = "file://session \
23 file://index.theme"
Patrick Williamsc124f4f2015-09-15 14:41:29 -050024S = "${WORKDIR}"
25
Patrick Williamsc0f7c042017-02-23 20:41:17 -060026FILES_${PN} += "${datadir}/themes/Sato/index.theme"
27
Patrick Williamsc124f4f2015-09-15 14:41:29 -050028do_install() {
29 # This is the set of machine features that the script has markers for
30 FEATURES="phone"
31 SCRIPT="${S}/sedder"
32 rm -f $SCRIPT
33 touch $SCRIPT
34 for FEAT in $FEATURES; do
35 if echo ${MACHINE_FEATURES} | awk "/$FEAT/ {exit 1}"; then
36 echo "/feature-$FEAT/d" >> $SCRIPT
37 fi
38 done
39
Patrick Williamsc0f7c042017-02-23 20:41:17 -060040 install -D ${S}/index.theme ${D}/${datadir}/themes/Sato/index.theme
Patrick Williamsc124f4f2015-09-15 14:41:29 -050041 install -d ${D}/${sysconfdir}/matchbox
42 sed -f "$SCRIPT" ${S}/session > ${D}/${sysconfdir}/matchbox/session
43 chmod +x ${D}/${sysconfdir}/matchbox/session
44}
45
46pkg_postinst_${PN} () {
47 set_value() {
48 #type, name, value
49 gconftool-2 --config-source=xml::$D${sysconfdir}/gconf/gconf.xml.defaults --direct --type $1 --set /desktop/poky/interface/$2 "$3"
50 }
Patrick Williamsc0f7c042017-02-23 20:41:17 -060051 set_value string theme Adwaita
52 set_value string matchbox_theme Sato
Patrick Williamsc124f4f2015-09-15 14:41:29 -050053 set_value string icon_theme Sato
54 set_value bool touchscreen true
55 set_value string font_name "Sans 9"
56}