Provide an environment where cross-compiled tests can run in an emulator
authorJohn Darrington <john@darrington.wattle.id.au>
Sun, 20 Mar 2016 19:41:14 +0000 (20:41 +0100)
committerJohn Darrington <john@darrington.wattle.id.au>
Sun, 20 Mar 2016 20:42:59 +0000 (21:42 +0100)
This change allows some of the tests to run successfully under wine when
cross-compiled with mingw

tests/atlocal.in

index 29886a0cd22508023c75f272951961e945241787..b9b6239a55083bc57228e8d0fde990354bff097c 100644 (file)
@@ -36,8 +36,32 @@ export CHARSETALIASDIR
 GZIP=
 export GZIP
 
+WINEPREFIX=$HOME/.wine    # Work around the following kludge to keep wine happy
+export WINEPREFIX
+
+
 HOME=/nonexistent              # Kluge to make PSPP ignore $HOME/.pspprc.
 export HOME
 
+PSPP=$abs_top_builddir/src/ui/terminal/pspp$EXEEXT
+export PSPP
+
+PSPPCONVERT=$abs_top_builddir/utilities/pspp-convert$EXEEXT
+export PSPPCONVERT
+
+
 # Avoids error messages during tests if $TERM is set to an unknown terminal.
 TERM=; unset TERM
+
+if test X"$RUNNER" != X; then
+    pspp () {
+        $RUNNER $PSPP "$@"
+    }
+fi
+
+pspp_diff=`which diff`
+if test X"$RUNNER" = Xwine; then
+    diff () {
+        $pspp_diff -w  "$@"
+    }
+fi