tests: avoid a spurious failure on MSYS
[platform/upstream/automake.git] / t / ccnoco3.sh
old mode 100755 (executable)
new mode 100644 (file)
index b47ed48..8e3547b
@@ -1,5 +1,5 @@
 #! /bin/sh
-# Copyright (C) 2001-2012 Free Software Foundation, Inc.
+# Copyright (C) 2001-2013 Free Software Foundation, Inc.
 #
 # This program is free software; you can redistribute it and/or modify
 # it under the terms of the GNU General Public License as published by
@@ -17,7 +17,7 @@
 # Test to make sure 'compile' doesn't call 'mv SRC SRC'.
 
 required=gcc
-. ./defs || Exit 1
+. test-init.sh
 
 cat >> configure.ac << 'END'
 AC_PROG_CC
@@ -52,7 +52,8 @@ case " \$* " in
     ;;
 esac
 
-# Use '$CC', not 'gcc', to honour the compiler chosen by 't/defs'.
+# Use '$CC', not 'gcc', to honour the compiler chosen
+# by the testsuite setup.
 exec $CC "\$@"
 END
 
@@ -70,8 +71,7 @@ mkdir build
 cd build
 
 ../configure
-$MAKE 2>stderr || { cat stderr >&2; Exit 1; }
-cat stderr >&2
-grep 'mv.*the same file' stderr && Exit 1
+run_make -E
+grep 'mv.*the same file' stderr && exit 1
 
 :