mirror of
https://github.com/t-crest/rtems.git
synced 2025-12-05 15:15:48 +00:00
Add option to select BSP for running tests.
This commit is contained in:
@@ -12,6 +12,7 @@ cdlevel=0
|
|||||||
partest=
|
partest=
|
||||||
sim=
|
sim=
|
||||||
simargs=()
|
simargs=()
|
||||||
|
bsp=
|
||||||
sourcedir=$(pwd)/testsuites
|
sourcedir=$(pwd)/testsuites
|
||||||
builddir=$(pwd)/../rtems-build
|
builddir=$(pwd)/../rtems-build
|
||||||
|
|
||||||
@@ -32,7 +33,7 @@ genflag=0
|
|||||||
|
|
||||||
function usage() {
|
function usage() {
|
||||||
cat <<EOT
|
cat <<EOT
|
||||||
Usage: $0 [-h] [-c] [-r] [-g] [-p <sim args>] [-t <tests>] [-s <source dir>] [-b <build dir>] [-o <report dir>] [-l <log file>] [-m <simulator>]
|
Usage: $0 [-h] [-c] [-r] [-g] [-p <sim args>] [-t <tests>] [-s <source dir>] [-b <build dir>] [-o <report dir>] [-l <log file>] [-m <simulator>] [-x <bsp>]
|
||||||
|
|
||||||
-h Display help contents
|
-h Display help contents
|
||||||
-c Clean files created during testsuite runs
|
-c Clean files created during testsuite runs
|
||||||
@@ -45,6 +46,7 @@ function usage() {
|
|||||||
-o <report dir> Report output directory
|
-o <report dir> Report output directory
|
||||||
-l <log file> Override the default log file
|
-l <log file> Override the default log file
|
||||||
-m <simulator> Override the default simulator (pasim)
|
-m <simulator> Override the default simulator (pasim)
|
||||||
|
-x <bsp> Override the default BSP (pasim)
|
||||||
|
|
||||||
EOT
|
EOT
|
||||||
}
|
}
|
||||||
@@ -87,6 +89,9 @@ function checkDefaults() {
|
|||||||
addSimArg "--interrupt=1"
|
addSimArg "--interrupt=1"
|
||||||
addSimArg "--freq=5"
|
addSimArg "--freq=5"
|
||||||
fi
|
fi
|
||||||
|
if [[ "$bsp" == "" ]];then
|
||||||
|
bsp="pasim"
|
||||||
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
function testsOnResume() {
|
function testsOnResume() {
|
||||||
@@ -200,7 +205,7 @@ function recurseDirs
|
|||||||
done
|
done
|
||||||
}
|
}
|
||||||
|
|
||||||
while getopts ":hHp:P:t:T:l:L:cCrRb:B:s:S:o:O:m:M:gG" opt; do
|
while getopts ":hHp:P:t:T:l:L:cCrRb:B:s:S:o:O:m:M:x:X:gG" opt; do
|
||||||
case "$opt" in
|
case "$opt" in
|
||||||
h|H)
|
h|H)
|
||||||
usage
|
usage
|
||||||
@@ -246,6 +251,9 @@ while getopts ":hHp:P:t:T:l:L:cCrRb:B:s:S:o:O:m:M:gG" opt; do
|
|||||||
sim="$OPTARG"
|
sim="$OPTARG"
|
||||||
simargs=()
|
simargs=()
|
||||||
;;
|
;;
|
||||||
|
x|X)
|
||||||
|
bsp="$OPTARG"
|
||||||
|
;;
|
||||||
g|G)
|
g|G)
|
||||||
genflag=1
|
genflag=1
|
||||||
;;
|
;;
|
||||||
@@ -262,7 +270,7 @@ while getopts ":hHp:P:t:T:l:L:cCrRb:B:s:S:o:O:m:M:gG" opt; do
|
|||||||
esac
|
esac
|
||||||
done
|
done
|
||||||
|
|
||||||
testsuitedir=$builddir/patmos-unknown-rtems/c/pasim/testsuites
|
testsuitedir=$builddir/patmos-unknown-rtems/c/$bsp/testsuites
|
||||||
checkDefaults
|
checkDefaults
|
||||||
if [[ ! -d $sourcedir ]]; then
|
if [[ ! -d $sourcedir ]]; then
|
||||||
echo "Invalid source dir. Go to RTEMS source dir or specify the testsuites source dir with -s."
|
echo "Invalid source dir. Go to RTEMS source dir or specify the testsuites source dir with -s."
|
||||||
|
|||||||
Reference in New Issue
Block a user