[FFmpeg-cvslog] configure: Disable networking if winsock2.h is available but winsock functions aren' t

Martin Storsjö git at videolan.org
Mon Jan 6 22:32:11 CET 2014


ffmpeg | branch: master | Martin Storsjö <martin at martin.st> | Tue Dec 31 10:11:24 2013 +0200| [9409c9bdbfd829353473ee6cc3e91c726481c069] | committer: Martin Storsjö

configure: Disable networking if winsock2.h is available but winsock functions aren't

Previously, if neither of the checks for the closesocket function
succeeded, we still kept winsock2.h and networking in general
enabled.

When targeting the WinRT API subset, the winsock2.h header is
available (making the check for it succeed, giving the impression
that winsock is available), but tests that actually try to use
such a function will fail. In this case, disable the winsock2.h
feature and networking in general, as if the winsock2.h header
test would have failed in the first place.

Signed-off-by: Martin Storsjö <martin at martin.st>

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=9409c9bdbfd829353473ee6cc3e91c726481c069
---

 configure |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/configure b/configure
index 7c3a9f8..e9fc08c 100755
--- a/configure
+++ b/configure
@@ -3776,7 +3776,7 @@ if ! disabled network; then
         check_func_headers winsock2.h closesocket -lws2 &&
             network_extralibs="-lws2" ||
         { check_func_headers winsock2.h closesocket -lws2_32 &&
-            network_extralibs="-lws2_32"; }
+            network_extralibs="-lws2_32"; } || disable winsock2_h network
         check_func_headers ws2tcpip.h getaddrinfo $network_extralibs
         check_type ws2tcpip.h socklen_t
         check_type ws2tcpip.h "struct addrinfo"



More information about the ffmpeg-cvslog mailing list