blob: d5aeceeb422b3baacfc2b8ed9a99806945295141 [file] [log] [blame]
Andrew Geissler9aee5002022-03-30 16:27:02 +00001DESCRIPTION = "Blueman is a GTK+ Bluetooth Manager"
2LICENSE = "GPL-3.0-only"
3LIC_FILES_CHKSUM = "file://COPYING;md5=d32239bcb673463ab874e80d47fae504"
4
5DEPENDS = "gtk+3 glib-2.0 bluez5 python3-pygobject python3-cython-native"
6
7inherit meson gettext systemd gsettings pkgconfig python3native gtk-icon-cache
8
9SRC_URI = " \
10 https://github.com/blueman-project/blueman/releases/download/${PV}/blueman-${PV}.tar.xz \
11 file://0001-Search-for-cython3.patch \
12 file://0002-fix-fail-to-enable-bluetooth.patch \
Patrick Williamsde0582f2022-04-08 10:23:27 -050013 file://0001-meson-add-pythoninstalldir-option.patch \
Andrew Geissler9aee5002022-03-30 16:27:02 +000014"
15SRC_URI[sha256sum] = "55d639feeda0b43b18a659e65985213a54b47dcb1348f3b4effb5238db242602"
16
Patrick Williamsde0582f2022-04-08 10:23:27 -050017EXTRA_OEMESON = "-Druntime_deps_check=false -Dappindicator=false -Dpythoninstalldir=${@noprefix('PYTHON_SITEPACKAGES_DIR', d)}"
Andrew Geissler9aee5002022-03-30 16:27:02 +000018
19SYSTEMD_SERVICE:${PN} = "${BPN}-mechanism.service"
20SYSTEMD_AUTO_ENABLE:${PN} = "disable"
21
22RRECOMENDS_${PN} += "adwaita-icon-theme"
23RDEPENDS:${PN} += " \
24 python3-core \
25 python3-dbus \
26 python3-pygobject \
27 python3-terminal \
28 packagegroup-tools-bluetooth \
29"
30
31PACKAGECONFIG ??= " \
32 ${@bb.utils.filter('DISTRO_FEATURES', 'polkit pulseaudio ', d)} \
33 thunar \
34"
35PACKAGECONFIG[thunar] = "-Dthunar-sendto=true,-Dthunar-sendto=false"
36PACKAGECONFIG[pulseaudio] = "-Dpulseaudio=true,-Dpulseaudio=false"
37PACKAGECONFIG[polkit] = "-Dpolicykit=true,-Dpolicykit=false"
38
39FILES:${PN} += " \
40 ${datadir} \
41 ${systemd_user_unitdir} \
42 ${PYTHON_SITEPACKAGES_DIR} \
43"
44
45# In code, path to python is a variable that is replaced with path to native version of it
46# during the configure stage, e.g ../recipe-sysroot-native/usr/bin/python3-native/python3.
47# Replace it with #!/usr/bin/env python3
48do_install:append() {
49 sed -i "1s/.*/#!\/usr\/bin\/env python3/" ${D}${prefix}/libexec/blueman-rfcomm-watcher \
50 ${D}${prefix}/libexec/blueman-mechanism \
51 ${D}${bindir}/blueman-adapters \
52 ${D}${bindir}/blueman-applet \
53 ${D}${bindir}/blueman-manager \
54 ${D}${bindir}/blueman-sendto \
55 ${D}${bindir}/blueman-services \
56 ${D}${bindir}/blueman-tray
57}
58