decklink: Fix building with MSYS2's MinGW
authorNirbheek Chauhan <nirbheek@centricular.com>
Thu, 20 Jul 2017 12:39:15 +0000 (18:09 +0530)
committerNirbheek Chauhan <nirbheek@centricular.com>
Thu, 20 Jul 2017 13:48:28 +0000 (19:18 +0530)
Reported and tested by Philippe Renon.

https://bugzilla.gnome.org/show_bug.cgi?id=784943

configure.ac
sys/decklink/gstdecklink.h

index 0107501..5bd76a0 100644 (file)
@@ -2256,7 +2256,7 @@ AG_GST_CHECK_FEATURE(DECKLINK, [decklink], decklink, [
      *-mingw*)
        HAVE_DECKLINK=yes
        DECKLINK_CXXFLAGS=
-       DECKLINK_LIBS="-loleaut32"
+       DECKLINK_LIBS="-lole32 -loleaut32"
        HAVE_DECKLINK_WIN=yes
        ;;
      *)
index a630f2b..80ec1b9 100644 (file)
 #ifdef G_OS_WIN32
 #include "win/DeckLinkAPI.h"
 
+#include <stdio.h>
 #include <comutil.h>
 
 #define bool BOOL
-
 #define COMSTR_T BSTR
 /* MinGW does not have comsuppw.lib, so no _com_util::ConvertBSTRToString */
 # ifdef __MINGW32__