# HG changeset patch # User Markus Mützel # Date 1517672881 -3600 # Node ID 9af783c01c7f61881327d9cdb58e7972f470a911 # Parent ea1c88bd44306b5104cab2c6168ee795f685bf04 Fix cross-building for win32 target (bug #50463). * configure.ac: Check for existence of header file instead of exported function in library because the autoconf macro can't check for functions with __stdcall calling convention (win32). diff -r ea1c88bd4430 -r 9af783c01c7f configure.ac --- a/configure.ac Fri Feb 09 16:14:26 2018 -0500 +++ b/configure.ac Sat Feb 03 16:48:01 2018 +0100 @@ -1530,7 +1530,10 @@ ## Windows-specific module used for winqueryreg function case $host_os in msdosmsvc | mingw*) - AC_CHECK_LIB([psapi], [EnumProcessModules]) + AC_CHECK_HEADERS([psapi.h], + [LIBS="-lpsapi $LIBS"], + [AC_MSG_ERROR([Missing PSAPI required to build for Windows target.])], + [#include ]) ;; esac