makefiles: Disable winetest when tests are disabled.
diff --git a/configure b/configure
index bc61d07..0d59588 100755
--- a/configure
+++ b/configure
@@ -4111,6 +4111,8 @@
 
 enable_win16=${enable_win16:-no}
 
+enable_winetest=${enable_winetest:-$enable_tests}
+
 if test -n "$with_wine64"
 then
     if test "x$enable_win64" = "xyes"
diff --git a/configure.ac b/configure.ac
index b0e6a48..6276241 100644
--- a/configure.ac
+++ b/configure.ac
@@ -170,6 +170,9 @@
 dnl enable_win16 defaults to yes on x86, to no on other CPUs
 enable_win16=${enable_win16:-no}
 
+dnl Disable winetest too if tests are disabled
+enable_winetest=${enable_winetest:-$enable_tests}
+
 dnl Some special cases for the wow64 build
 if test -n "$with_wine64"
 then