android-tools: create flag flag file for adbd at a proper location

The patches by Raghuvarya changed the location of the file that systemd
uses to check whether to start the adbd or not. However those patches
completely ignored creating those two flag files, as done by the
android-tools recipes.

Make the android-tools create the /etc/usb-debugging-enabled file so
that it's possible to enable the adbd automatically.

Fixes: a29c6386d576 ("android-toold-adbd: Fix inconsistency between selinux configurations")
Fixes: 8106cfe769aa ("android-tools-adbd.service: Change /var to /etc in ConditionPathExists")
Cc: Raghuvarya S <quic_raghuvar@quicinc.com>
Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
Signed-off-by: Khem Raj <raj.khem@gmail.com>
This commit is contained in:
Dmitry Baryshkov 2024-09-05 13:56:33 +03:00 committed by Khem Raj
parent 0a37700632
commit 2a3d4be999
No known key found for this signature in database
GPG Key ID: BB053355919D3314
2 changed files with 2 additions and 2 deletions

View File

@ -190,7 +190,7 @@ FILES:${PN} += "${libdir}/android ${libdir}/android/*"
BBCLASSEXTEND = "native"
android_tools_enable_devmode() {
touch ${IMAGE_ROOTFS}/var/usb-debugging-enabled
touch ${IMAGE_ROOTFS}/etc/usb-debugging-enabled
}
ROOTFS_POSTPROCESS_COMMAND_${PN}-adbd += "${@bb.utils.contains("USB_DEBUGGING_ENABLED", "1", "android_tools_enable_devmode;", "", d)}"

View File

@ -189,7 +189,7 @@ FILES:${PN}-fstools = "\
BBCLASSEXTEND = "native"
android_tools_enable_devmode() {
touch ${IMAGE_ROOTFS}/var/usb-debugging-enabled
touch ${IMAGE_ROOTFS}/etc/usb-debugging-enabled
}
ROOTFS_POSTPROCESS_COMMAND_${PN}-adbd += "${@bb.utils.contains("USB_DEBUGGING_ENABLED", "1", "android_tools_enable_devmode;", "", d)}"