mirror of
https://github.com/openembedded/meta-openembedded.git
synced 2026-07-15 16:07:26 +00:00
android-tools: move android-tools v29.x from dynamic-layers/selinux to meta-oe
Relocate the recipe from dynamic-layers/selinux/ to the main meta-oe/recipes-devtools/ directory. The android-tools recipe (version 29.0.6.r14) was previously restricted to the selinux dynamic-layer. Investigation shows that version 29.0.6.r14 does not have a hard dependency on libselinux for core tool functionality. (adb, fastboot, and sparse image tools). - Basic runable test was done for binaries in android-tools-native - Checked for selinux absense by looking for selinx using $ ldd binary-name Changes: - Relocate recipe from dynamic-layers/selinux/ to recipes-devtools/ Signed-off-by: AshishKumar Mishra <ashishkumar.mishra@bmwtechworks.in> Signed-off-by: Khem Raj <khem.raj@oss.qualcomm.com>
This commit is contained in:
committed by
Khem Raj
parent
33c1e33d23
commit
66f56dda5e
@@ -0,0 +1,37 @@
|
||||
#!/bin/sh
|
||||
|
||||
[ ! -e /dev/pts ] && mkdir -p /dev/pts
|
||||
[ ! -e /dev/pts/0 ] && mount devpts /dev/pts -t devpts
|
||||
|
||||
# TODO enable the lines below once we have support for getprop
|
||||
# retrieve the product info from Android
|
||||
# manufacturer=$(getprop ro.product.manufacturer Android)
|
||||
# model=$(getprop ro.product.model Android)
|
||||
# serial=$(getprop ro.serialno 0123456789ABCDEF)
|
||||
|
||||
#below are now needed in order to use FunctionFS for ADB, tested to work with 3.4+ kernels
|
||||
if grep -q functionfs /proc/filesystems; then
|
||||
mkdir -p /dev/usb-ffs/adb
|
||||
mount -t functionfs adb /dev/usb-ffs/adb
|
||||
#android-gadget-setup doesn't provide below 2 and without them it won't work, so we provide them here.
|
||||
echo adb > /sys/class/android_usb/android0/f_ffs/aliases
|
||||
echo ffs > /sys/class/android_usb/android0/functions
|
||||
fi
|
||||
|
||||
manufacturer="$(cat /system/build.prop | grep -o 'ro.product.manufacturer=.*' | cut -d'=' -f 2)"
|
||||
model="$(cat /system/build.prop | grep -o 'ro.product.model=.*' | cut -d'=' -f 2)"
|
||||
# get the device serial number from /proc/cmdline directly(since we have no getprop on
|
||||
# GNU/Linux)
|
||||
serial="$(cat /proc/cmdline | sed 's/.*androidboot.serialno=//' | sed 's/ .*//')"
|
||||
|
||||
echo $serial > /sys/class/android_usb/android0/iSerial
|
||||
echo $manufacturer > /sys/class/android_usb/android0/iManufacturer
|
||||
echo $model > /sys/class/android_usb/android0/iProduct
|
||||
|
||||
echo "0" > /sys/class/android_usb/android0/enable
|
||||
echo "18d1" > /sys/class/android_usb/android0/idVendor
|
||||
echo "D002" > /sys/class/android_usb/android0/idProduct
|
||||
echo "adb" > /sys/class/android_usb/android0/functions
|
||||
echo "1" > /sys/class/android_usb/android0/enable
|
||||
|
||||
sleep 4
|
||||
Reference in New Issue
Block a user