[PATCH 7/8] Check for Wine when cross-compiling to Windows

Dan Nicholson dbn.lists at gmail.com
Sat Apr 6 09:17:43 PDT 2013


If Wine is available when cross-compiling to Windows, it can be used to
run the test suite from the build machine.
---
 configure.ac | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/configure.ac b/configure.ac
index 73f2cf4..94666a4 100644
--- a/configure.ac
+++ b/configure.ac
@@ -154,6 +154,13 @@ AC_MSG_RESULT([$native_win32])
 AC_SUBST([native_win32])
 AM_CONDITIONAL(NATIVE_WIN32, [test "x$native_win32" = xyes])
 
+dnl When cross compiling to Windows, Wine might be available to help
+dnl for testing.
+if test "$cross_compiling" = yes && test "$native_win32" = yes; then
+   AC_CHECK_PROG([WINE], [wine], [wine])
+   test "x$WINE" != x && TESTS_PKG_CONFIG='${WINE} '"$TESTS_PKG_CONFIG"
+fi
+
 dnl
 dnl Find glib or use internal copy. Required version is 2.16 for
 dnl g_win32_get_package_installation_directory_of_module().
-- 
1.8.1.4



More information about the pkg-config mailing list