aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDevendra Tewari <devendra.tewari@gmail.com>2021-07-26 16:31:20 -0300
committerArmin Kuster <akuster808@gmail.com>2021-08-01 09:27:35 -0700
commitb97e6c971639072f3866e26218505e390fd26cae (patch)
treedecccf47b9e11725727c64c55fc6e7ee0c659fd8
parenteee9348f79b0f70fbd57db28b5def4db85d564c6 (diff)
downloadmeta-openembedded-b97e6c971639072f3866e26218505e390fd26cae.tar.gz
meta-openembedded-b97e6c971639072f3866e26218505e390fd26cae.tar.bz2
meta-openembedded-b97e6c971639072f3866e26218505e390fd26cae.zip
Suppress eol in functionfs setup scripts (#147)
Stray newline character causes errors in functionfs setup scripts used by android-tools-adbd.service, when using musl libc and/or toybox. Signed-off-by: Devendra Tewari <devendra.tewari@gmail.com> Signed-off-by: Khem Raj <raj.khem@gmail.com> (cherry picked from commit db5f48734404a52ee5323659082f1d6baa225ca7) Signed-off-by: Armin Kuster <akuster808@gmail.com>
-rw-r--r--meta-oe/recipes-devtools/android-tools/android-tools-conf-configfs/android-gadget-cleanup2
-rw-r--r--meta-oe/recipes-devtools/android-tools/android-tools-conf-configfs/android-gadget-setup4
-rw-r--r--meta-oe/recipes-devtools/android-tools/android-tools-conf-configfs/android-gadget-start2
3 files changed, 4 insertions, 4 deletions
diff --git a/meta-oe/recipes-devtools/android-tools/android-tools-conf-configfs/android-gadget-cleanup b/meta-oe/recipes-devtools/android-tools/android-tools-conf-configfs/android-gadget-cleanup
index 517227d4a..f27d77df5 100644
--- a/meta-oe/recipes-devtools/android-tools/android-tools-conf-configfs/android-gadget-cleanup
+++ b/meta-oe/recipes-devtools/android-tools/android-tools-conf-configfs/android-gadget-cleanup
@@ -6,7 +6,7 @@ cd /sys/kernel/config/usb_gadget
cd adb
-echo "" > UDC || true
+echo -n "" > UDC || true
killall adbd || true
diff --git a/meta-oe/recipes-devtools/android-tools/android-tools-conf-configfs/android-gadget-setup b/meta-oe/recipes-devtools/android-tools/android-tools-conf-configfs/android-gadget-setup
index e44d1bacb..dbd711515 100644
--- a/meta-oe/recipes-devtools/android-tools/android-tools-conf-configfs/android-gadget-setup
+++ b/meta-oe/recipes-devtools/android-tools/android-tools-conf-configfs/android-gadget-setup
@@ -23,8 +23,8 @@ mkdir configs/c.1
mkdir functions/ffs.usb0
mkdir strings/0x409
mkdir configs/c.1/strings/0x409
-echo 0x18d1 > idVendor
-echo 0xd002 > idProduct
+echo -n 0x18d1 > idVendor
+echo -n 0xd002 > idProduct
echo "$serial" > strings/0x409/serialnumber
echo "$manufacturer" > strings/0x409/manufacturer
echo "$model" > strings/0x409/product
diff --git a/meta-oe/recipes-devtools/android-tools/android-tools-conf-configfs/android-gadget-start b/meta-oe/recipes-devtools/android-tools/android-tools-conf-configfs/android-gadget-start
index ca6c3df27..d67878fef 100644
--- a/meta-oe/recipes-devtools/android-tools/android-tools-conf-configfs/android-gadget-start
+++ b/meta-oe/recipes-devtools/android-tools/android-tools-conf-configfs/android-gadget-start
@@ -4,4 +4,4 @@ set -e
sleep 3
-ls /sys/class/udc/ > /sys/kernel/config/usb_gadget/adb/UDC
+ls /sys/class/udc/ | xargs echo -n > /sys/kernel/config/usb_gadget/adb/UDC