summaryrefslogtreecommitdiff
path: root/yocto-poky/meta/recipes-connectivity/bluez5/bluez5.inc
diff options
context:
space:
mode:
Diffstat (limited to 'yocto-poky/meta/recipes-connectivity/bluez5/bluez5.inc')
-rw-r--r--yocto-poky/meta/recipes-connectivity/bluez5/bluez5.inc30
1 files changed, 19 insertions, 11 deletions
diff --git a/yocto-poky/meta/recipes-connectivity/bluez5/bluez5.inc b/yocto-poky/meta/recipes-connectivity/bluez5/bluez5.inc
index df42c88b9..a508229a3 100644
--- a/yocto-poky/meta/recipes-connectivity/bluez5/bluez5.inc
+++ b/yocto-poky/meta/recipes-connectivity/bluez5/bluez5.inc
@@ -18,10 +18,14 @@ PACKAGECONFIG[experimental] = "--enable-experimental,--disable-experimental,"
SRC_URI = "\
${KERNELORG_MIRROR}/linux/bluetooth/bluez-${PV}.tar.xz \
+ file://init \
+ file://run-ptest \
+ ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', '', 'file://0001-Allow-using-obexd-without-systemd-in-the-user-sessio.patch', d)} \
+ file://0001-tests-add-a-target-for-building-tests-without-runnin.patch \
"
S = "${WORKDIR}/bluez-${PV}"
-inherit autotools-brokensep pkgconfig systemd
+inherit autotools-brokensep pkgconfig systemd update-rc.d distro_features_check ptest
EXTRA_OECONF = "\
--enable-tools \
@@ -42,6 +46,9 @@ NOINST_TOOLS = " \
"
do_install_append() {
+ install -d ${D}${INIT_D_DIR}
+ install -m 0755 ${WORKDIR}/init ${D}${INIT_D_DIR}/bluetooth
+
install -d ${D}${sysconfdir}/bluetooth/
if [ -f ${S}/profiles/audio/audio.conf ]; then
install -m 0644 ${S}/profiles/audio/audio.conf ${D}/${sysconfdir}/bluetooth/
@@ -53,8 +60,6 @@ do_install_append() {
install -m 0644 ${S}/profiles/input/input.conf ${D}/${sysconfdir}/bluetooth/
fi
- install -m 0644 ${S}/src/bluetooth.conf ${D}/${sysconfdir}/dbus-1/system.d/
-
# Install desired tools that upstream leaves in build area
for f in ${NOINST_TOOLS} ; do
install -m 755 ${B}/$f ${D}/${bindir}
@@ -89,16 +94,19 @@ def get_noinst_tools_paths (d, bb, tools):
FILES_${PN}-noinst-tools = "${@get_noinst_tools_paths(d, bb, d.getVar('NOINST_TOOLS', True))}"
-FILES_${PN}-dbg += "\
- ${libexecdir}/bluetooth/.debug \
- ${libdir}/bluetooth/plugins/.debug \
- ${libdir}/*/.debug \
- */udev/.debug \
- */*/udev/.debug \
- "
-
RDEPENDS_${PN}-testtools += "python python-dbus python-pygobject"
SYSTEMD_SERVICE_${PN} = "bluetooth.service"
+INITSCRIPT_PACKAGES = "${PN}"
+INITSCRIPT_NAME_${PN} = "bluetooth"
EXCLUDE_FROM_WORLD = "1"
+
+do_compile_ptest() {
+ oe_runmake buildtests
+}
+
+do_install_ptest() {
+ cp -r ${B}/unit/ ${D}${PTEST_PATH}
+ rm ${D}${PTEST_PATH}/unit/*.c ${D}${PTEST_PATH}/unit/*.o
+}