diff options
author | Juergen Kahrs <Juergen.Kahrs@googlemail.com> | 2013-04-29 18:14:06 +0200 |
---|---|---|
committer | Juergen Kahrs <Juergen.Kahrs@googlemail.com> | 2013-04-29 18:14:06 +0200 |
commit | b6dbba36f373166e14cad2767b89d0331b8ac77c (patch) | |
tree | 7396f47f6a02285463507cea399d1a155b6bb30d /cmake/basictest | |
parent | 291ff169ddc21abd09e1b46c69eddd56edd31899 (diff) | |
download | egawk-b6dbba36f373166e14cad2767b89d0331b8ac77c.tar.gz egawk-b6dbba36f373166e14cad2767b89d0331b8ac77c.tar.bz2 egawk-b6dbba36f373166e14cad2767b89d0331b8ac77c.zip |
When building with a native MinGW for Win32 it is now possible to run a 'make test'; only 90% of the basic test cases pass.
Diffstat (limited to 'cmake/basictest')
-rwxr-xr-x | cmake/basictest | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/cmake/basictest b/cmake/basictest index 42cb2864..95b98a12 100755 --- a/cmake/basictest +++ b/cmake/basictest @@ -1,5 +1,6 @@ #!/bin/sh +export PATH=$PATH:/c/MinGW/msys/1.0/bin TESTHOME=$(dirname ${0})/../test export AWKPATH=${TESTHOME} export AWKLIBPATH=${TESTHOME}/../build/extension/ @@ -10,5 +11,13 @@ then else $1 $3 -f ${2}.awk > ${TESTHOME}/_${2} 2>&1 || echo EXIT CODE: $? >> ${TESTHOME}/_${2} fi -cmp ${TESTHOME}/${2}.ok ${TESTHOME}/_${2} && rm -f ${TESTHOME}/_${2} +# Is this shell running in a native MinGW shell (MSYS) ? +if test -n "$COMSPEC"; then + # Ignore all differences in white space. + COMPARE="diff -w" +else + # This is a shell running in Unix environment. + COMPARE="cmp" +fi +${COMPARE} ${TESTHOME}/${2}.ok ${TESTHOME}/_${2} && rm -f ${TESTHOME}/_${2} |