Skip to content

Commit 0521d54

Browse files
committed
etc: adb_run_wrapper argument change
1 parent fe1dc32 commit 0521d54

File tree

2 files changed

+22
-15
lines changed

2 files changed

+22
-15
lines changed

src/compiletest/runtest.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -768,6 +768,7 @@ fn _arm_exec_compiled_test(config: &config, props: &TestProps,
768768

769769
runargs.push(~"shell");
770770
runargs.push(fmt!("%s/adb_run_wrapper.sh", config.adb_test_dir));
771+
runargs.push(fmt!("%s", config.adb_test_dir));
771772
runargs.push(fmt!("%s", prog_short));
772773

773774
for args.args.each |tv| {
@@ -795,7 +796,7 @@ fn _arm_exec_compiled_test(config: &config, props: &TestProps,
795796
_ => 0,
796797
}
797798
}
798-
maxtry = maxtry - 1;
799+
// maxtry = maxtry - 1;
799800
// unsafe { libc::sleep(1); }
800801
// }
801802

src/etc/adb_run_wrapper.sh

Lines changed: 20 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,23 @@
1-
2-
PATH=$(echo $0 | sed 's#/[^/]*$##')
3-
RUN=$1
4-
5-
if [ ! -z "$RUN" ]
1+
#
2+
# usage : adb_run_wrapper [test dir - where test executables exist] [test executable]
3+
#
4+
PATH=$1
5+
if [ -d "$PATH" ]
66
then
77
shift
8-
while [ -f $PATH/lock ]
9-
do
10-
sleep 1
11-
done
12-
touch $PATH/lock
13-
LD_LIBRARY_PATH=$PATH $PATH/$RUN $@ 1>$PATH/$RUN.stdout 2>$PATH/$RUN.stderr
14-
echo $? > $PATH/$RUN.exitcode
15-
/system/bin/rm $PATH/lock
16-
fi
8+
RUN=$1
179

10+
if [ ! -z "$RUN" ]
11+
then
12+
shift
13+
while [ -f $PATH/lock ]
14+
do
15+
/system/bin/sleep 1
16+
done
17+
/system/bin/touch $PATH/lock
18+
LD_LIBRARY_PATH=$PATH $PATH/$RUN $@ 1>$PATH/$RUN.stdout 2>$PATH/$RUN.stderr
19+
echo $? > $PATH/$RUN.exitcode
20+
/system/bin/rm $PATH/lock
21+
/system/bin/sync
22+
fi
23+
fi

0 commit comments

Comments
 (0)