Skip to content

Commit

Permalink
Add flag to enable adbd service (openembedded#147)
Browse files Browse the repository at this point in the history
android-tools-adbd service can be enabled in the image using
USB_DEBUGGING_ENABLED = "1" in local.conf.

Signed-off-by: Devendra Tewari <[email protected]>
  • Loading branch information
tewarid committed Jul 26, 2021
1 parent ff93be0 commit d1b0a83
Showing 1 changed file with 5 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -141,6 +141,10 @@ do_install() {
if echo ${TOOLS} | grep -q "adbd" ; then
install -d ${D}${bindir}
install -m0755 ${B}/adbd/adbd ${D}${bindir}
if [ "${USB_DEBUGGING_ENABLED}" = "1" ] ; then
mkdir ${D}${localstatedir}
touch ${D}${localstatedir}/usb-debugging-enabled
fi
fi

# Outside the if statement to avoid errors during do_package
Expand All @@ -166,6 +170,7 @@ RDEPENDS_${PN}-fstools = "bash"
FILES_${PN}-adbd = "\
${bindir}/adbd \
${systemd_unitdir}/system/android-tools-adbd.service \
${@bb.utils.contains('USB_DEBUGGING_ENABLED', '1', '${localstatedir}/usb-debugging-enabled', '',d)} \
"

FILES_${PN}-fstools = "\
Expand Down

0 comments on commit d1b0a83

Please sign in to comment.