From 2539ab9c12fde0155822fe9e6393edb265240dae Mon Sep 17 00:00:00 2001 Message-Id: <2539ab9c12fde0155822fe9e6393edb265240dae.1714899642.git.mdw@distorted.org.uk> From: Mark Wooding Date: Sat, 24 May 2014 14:00:03 +0100 Subject: [PATCH] server/tests.at: Don't run strace(1) unconditionally. Organization: Straylight/Edgeware From: Mark Wooding It slows things down, might not be available, and doesn't work in Scratchbox (because QEmu doesn't implement ptrace(2)). --- server/tests.at | 17 ++++++++++++----- 1 file changed, 12 insertions(+), 5 deletions(-) diff --git a/server/tests.at b/server/tests.at index 7a64cb44..e3813d76 100644 --- a/server/tests.at +++ b/server/tests.at @@ -91,12 +91,19 @@ $3 ## have the child process run in another. ) && :; } | { cd $1 - mkdir -p strace-hack/ echo TRIPE $2 >&2 - (cd strace-hack/ - ulimit -c hard >/dev/null 2>&1 - strace -f -o ../tripe.trace \ - TRIPE -d.. $2 >../server-output.full 2>../server-errors) + case "${TRIPE_TEST_STRACE-nil}" in + nil) + TRIPE -d. $2 >server-output.full 2>server-errors + ;; + *) + mkdir -p strace-hack/ + (cd strace-hack/ + ulimit -c hard >/dev/null 2>&1 + strace -f -o ../tripe.trace \ + TRIPE -d.. $2 >../server-output.full 2>../server-errors) + ;; + esac stat=$? echo $stat >server-status if test $stat -ne 0; then -- [mdw]