android-xfstests: create /dev/fd on the Android device
Eric Biggers
maintainerPATCH 1/1 android-xfstests: create /dev/fd on the Android device
From: Eric Biggers <[email protected]>
In order for bash process substitution (the syntax like "<(list)" or ">(list)") to work, /dev/fd has to be a symlink to /proc/self/fd. /dev/fd doesn't exist on Android, so create it if it's missing.
This fixes xfstest generic/576.
Signed-off-by Eric Biggers <[email protected]>
--- kvm-xfstests/android-xfstests | 5 +++++ 1 file changed, 5 insertions(+)
kvm-xfstests/android-xfstests +5 -0
@@ -244,6 +244,11 @@ if ! cut -d' ' -f2 /proc/mounts 2>/dev/null | grep -q '^$CHROOT_DIR/results$'; t mount --bind $RESULTS_DIR $CHROOT_DIR/results fi +# /dev/fd needs to exist in order for bash process substitution to work. +if [ ! -e /dev/fd ]; then + ln -s /proc/self/fd /dev/fd +fi + # Android puts loopback device nodes in /dev/block/ instead of /dev/. # But losetup can only find them in /dev/, so create them there too. for i in \`seq 0 7\`; do
Signature · 1 line
2.29.2
Quoted 9 lines · Eric Biggers
From: Eric Biggers <[email protected]>
In order for bash process substitution (the syntax like "<(list)" or ">(list)") to work,
/dev/fdhas to be a symlink to/proc/self/fd./dev/fddoesn't exist on Android, so create it if it's missing.This fixes xfstest generic/576.
Signed-off-by Eric Biggers <[email protected]>
Thanks, applied.
- Ted