]> sjero.net Git - linphone/commitdiff
ported to mingw
authorSimon Morlat <simon.morlat@linphone.org>
Mon, 30 Jan 2012 21:21:30 +0000 (22:21 +0100)
committerSimon Morlat <simon.morlat@linphone.org>
Mon, 30 Jan 2012 21:21:30 +0000 (22:21 +0100)
Makefile.am
coreapi/Makefile.am
coreapi/TunnelManager.cc
coreapi/TunnelManager.hh
coreapi/linphone_tunnel.cc
tunnel

index 15cf2a90d6c77968778c8554de829468fe9fd50b..400e064fbd7c651f77bb99ce741be94d20e05ab1 100644 (file)
@@ -94,6 +94,10 @@ if BUILD_ZRTP
 WINBINDIST_FILES+=./bin/libzrtpcpp.dll ./bin/msys-1.0.dll ./bin/msys-crypto-1.0.0.dll
 endif
 
+if BUILD_TUNNEL
+WINBINDIST_FILES+=./bin/libtunnel-0.dll
+endif
+
 other-cherrypick:
        cd $(GTK_PREFIX) && \
        for file in $(WINBINDIST_FILES) ; do \
index fdcaefdcf6c27a5b6a25c7d72311b634360bd3b9..eab5bdc5cbecc72130ce02ae47e80bf369e4001f 100644 (file)
@@ -56,9 +56,6 @@ liblinphone_la_LIBADD= \
                $(ORTP_LIBS) $(OPENSSL_LIBS) \
                $(TUNNEL_LIBS)
 
-if BUILD_WIN32
-liblinphone_la_LIBADD+=$(top_builddir)/oRTP/src/libortp.la
-endif
 if BUILD_TESTS
 noinst_PROGRAMS=test_lsd test_ecc
 
index 2243119d47ecd903bd401b0c951f870068ea5d62..bbf9cc87d2d4a2f291d3958fa86e14373c7540a6 100644 (file)
@@ -68,23 +68,9 @@ int TunnelManager::eXosipSelect(int max_fds, fd_set *s1, fd_set *s2, fd_set *s3,
        TunnelManager* lTunnelMgr=(TunnelManager*)userdata;
        if (tv!=0 && tv->tv_sec){
                /*this is the select from udp.c, the one that is interesting to us*/
-               int i;
-               int udp_fd=eXosip_get_udp_socket();
-               int controlfd=-1;
-
-               /*
-                       Find the udp fd and the control fd
-               */
-               for(i=0;i<max_fds;++i){
-                       if (FD_ISSET(i,s1) && i!=udp_fd){
-                               controlfd=i;
-                               break;
-                       }
-               }
-               if (controlfd==-1){
-                       ms_error("Could not find control fd !");
-                       return -1;
-               }
+               NativeSocket udp_fd=(NativeSocket)eXosip_get_udp_socket();
+               NativeSocket controlfd=(NativeSocket)eXosip_get_control_fd();
+
                FD_ZERO(s1);            
                gettimeofday(&begin,NULL);
                do{
@@ -157,7 +143,7 @@ void TunnelManager::setCallback(StateCallback cb, void *userdata) {
 
 static void sCloseRtpTransport(RtpTransport *t, void *userData){
        TunnelSocket *s=(TunnelSocket*)userData;
-       TunnelManager::TunnelManager *manager=(TunnelManager::TunnelManager*)s->getUserPointer();
+       TunnelManager *manager=(TunnelManager*)s->getUserPointer();
        manager->closeRtpTransport(t, s);
 }
 void TunnelManager::closeRtpTransport(RtpTransport *t, TunnelSocket *s){
@@ -166,7 +152,7 @@ void TunnelManager::closeRtpTransport(RtpTransport *t, TunnelSocket *s){
 }
 
 static RtpTransport *sCreateRtpTransport(void* userData, int port){
-       return ((TunnelManager::TunnelManager *) userData)->createRtpTransport(port);
+       return ((TunnelManager *) userData)->createRtpTransport(port);
 }
 
 RtpTransport *TunnelManager::createRtpTransport(int port){
index 89044cce721ebfa4ae32f9443734c94a2423af34..0cc560e90119f2e4a915d38d5bfed76d2f9d9cb6 100644 (file)
@@ -12,8 +12,9 @@
 #define __TUNNEL_CLIENT_MANAGER_H__
 #include <list>
 #include <string>
-#include "linphonecore.h"
 #include "tunnel/client.hh"
+#include "linphonecore.h"
+
 extern "C" {
        #include "eXosip2/eXosip_transport_hook.h"
 }
index 5afccff3d4066c63ca7eaace3fb587683ccf6346..120b1b12b9809b9974f31c3e42f743046d70e183 100644 (file)
@@ -23,9 +23,8 @@
  *  Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
  */
 
-
-#include "linphone_tunnel.h"
 #include "TunnelManager.hh"
+#include "linphone_tunnel.h"
 #include "linphonecore.h"
 #include "private.h"
 #include "lpconfig.h"
diff --git a/tunnel b/tunnel
index 3c19ce5fd922b926c1ee16a90633986c6e585af3..7ab47085cf698660e9fe17c2c4f3255cd5d5a8a5 160000 (submodule)
--- a/tunnel
+++ b/tunnel
@@ -1 +1 @@
-Subproject commit 3c19ce5fd922b926c1ee16a90633986c6e585af3
+Subproject commit 7ab47085cf698660e9fe17c2c4f3255cd5d5a8a5