[vlc-devel] [PATCH] configure: workaround mingw32 missing crypto header testing if_nametoindex

Francois Cartegnie fcvlcdev at free.fr
Wed Jun 17 20:04:18 CEST 2020


false negative due to test not compiling creating double decl conflict

In file included from /opt/gcc-x86_64-w64-mingw32/x86_64-w64-mingw32/include/iprtrmib.h:9:0,
                 from /opt/gcc-x86_64-w64-mingw32/x86_64-w64-mingw32/include/iphlpapi.h:17,
                 from conftest.c:90:

/opt/gcc-x86_64-w64-mingw32/x86_64-w64-mingw32/include/mprapi.h:865:3: error: unknown type name 'CERT_NAME_BLOB'

   CERT_NAME_BLOB *certificateNames;

   ^~~~~~~~~~~~~~

packages from docker image:

binutils-mingw-w64-i686/oldstable,now 2.28-5+7.4+b4 amd64 [installed,automatic]
g++-mingw-w64-i686/oldstable,now 6.3.0-18+19.3+b3 amd64 [installed]
gcc-mingw-w64-base/oldstable,now 6.3.0-18+19.3+b3 amd64 [installed,automatic]
gcc-mingw-w64-i686/oldstable,now 6.3.0-18+19.3+b3 amd64 [installed,automatic]
mingw-w64-common/oldstable,oldstable,now 5.0.1-1 all [installed,automatic]
mingw-w64-i686-dev/oldstable,oldstable,now 5.0.1-1 all [installed,automatic]

---
 configure.ac | 1 +
 1 file changed, 1 insertion(+)

diff --git a/configure.ac b/configure.ac
index 89fc36cdf4..8cbc3054d6 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1069,6 +1069,7 @@ AS_IF([test "${SYS}" = "mingw32"], [
   AC_MSG_CHECKING(for if_nametoindex availability)
   AC_COMPILE_IFELSE([AC_LANG_PROGRAM(
       [[#include <windows.h>
+        #include <wincrypt.h>
         #include <iphlpapi.h>
         static void test (void) {
           if_nametoindex("");
-- 
2.25.4



More information about the vlc-devel mailing list