summaryrefslogtreecommitdiff
path: root/release/src/router/busybox/testsuite/umlwrapper.sh
diff options
context:
space:
mode:
Diffstat (limited to 'release/src/router/busybox/testsuite/umlwrapper.sh')
-rwxr-xr-xrelease/src/router/busybox/testsuite/umlwrapper.sh20
1 files changed, 20 insertions, 0 deletions
diff --git a/release/src/router/busybox/testsuite/umlwrapper.sh b/release/src/router/busybox/testsuite/umlwrapper.sh
new file mode 100755
index 00000000..e55e4dbd
--- /dev/null
+++ b/release/src/router/busybox/testsuite/umlwrapper.sh
@@ -0,0 +1,20 @@
+#!/bin/sh
+
+# Wrapper for User Mode Linux emulation environment
+
+RUNFILE="$(pwd)/${1}.testroot"
+if [ -z "$RUNFILE" ] || [ ! -x "$RUNFILE" ]
+then
+ echo "Can't run '$RUNFILE'"
+ exit 1
+fi
+
+shift
+
+if [ -z $(which linux) ]
+then
+ echo "No User Mode Linux."
+ exit 1;
+fi
+
+linux rootfstype=hostfs rw init="$RUNFILE" TESTDIR=`pwd` PATH="$PATH" $* quiet