From 17f255e208756f6a379ec433016a35d7c7aacfc1 Mon Sep 17 00:00:00 2001 From: Daniel Verkamp Date: Thu, 8 Oct 2015 17:22:39 -0700 Subject: [PATCH] autotest: use inherited output_dir if it's set Change-Id: I182ebe8dbbd650b6093ac34e52a2ff595811e047 Signed-off-by: Daniel Verkamp --- scripts/autotest_common.sh | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/scripts/autotest_common.sh b/scripts/autotest_common.sh index 14116ee07..964f46338 100755 --- a/scripts/autotest_common.sh +++ b/scripts/autotest_common.sh @@ -18,10 +18,13 @@ esac MAKEFLAGS=${MAKEFLAGS:--j16} -if [ -z "$rootdir" ] || [ ! -d "$rootdir/../output" ]; then - output_dir=. -else - output_dir=$rootdir/../output +if [ -z "$output_dir" ]; then + if [ -z "$rootdir" ] || [ ! -d "$rootdir/../output" ]; then + output_dir=. + else + output_dir=$rootdir/../output + fi + export output_dir fi if hash valgrind &> /dev/null; then