[MPlayer-cvslog] r31749 - in trunk: Makefile cfg-common.h configure libmpdemux/asfheader.c stream/stream.c stream/stream.h

diego subversion at mplayerhq.hu
Sat Jul 17 15:14:54 CEST 2010


Author: diego
Date: Sat Jul 17 15:14:53 2010
New Revision: 31749

Log:
Rename network build system variable and command line option to networking.
This avoids conflicts with the FFmpeg variable of the same name.

Modified:
   trunk/Makefile
   trunk/cfg-common.h
   trunk/configure
   trunk/libmpdemux/asfheader.c
   trunk/stream/stream.c
   trunk/stream/stream.h

Modified: trunk/Makefile
==============================================================================
--- trunk/Makefile	Sat Jul 17 12:28:17 2010	(r31748)
+++ trunk/Makefile	Sat Jul 17 15:14:53 2010	(r31749)
@@ -222,7 +222,7 @@ SRCS_COMMON-$(NEED_SHMEM)            += 
 SRCS_COMMON-$(NEED_STRSEP)           += osdep/strsep.c
 SRCS_COMMON-$(NEED_SWAB)             += osdep/swab.c
 SRCS_COMMON-$(NEED_VSSCANF)          += osdep/vsscanf.c
-SRCS_COMMON-$(NETWORK)               += stream/stream_netstream.c \
+SRCS_COMMON-$(NETWORKING)            += stream/stream_netstream.c \
                                         stream/asf_mmst_streaming.c \
                                         stream/asf_streaming.c \
                                         stream/cookies.c \

Modified: trunk/cfg-common.h
==============================================================================
--- trunk/cfg-common.h	Sat Jul 17 12:28:17 2010	(r31748)
+++ trunk/cfg-common.h	Sat Jul 17 15:14:53 2010	(r31749)
@@ -349,7 +349,7 @@ const m_option_t common_opts[] = {
     {"dvdkey", "libcss is obsolete. Try libdvdread instead.\n", CONF_TYPE_PRINT, CONF_NOCFG, 0, 0, NULL},
     {"csslib", "libcss is obsolete. Try libdvdread instead.\n", CONF_TYPE_PRINT, CONF_NOCFG, 0, 0, NULL},
 
-#ifdef CONFIG_NETWORK
+#ifdef CONFIG_NETWORKING
     {"user", &network_username, CONF_TYPE_STRING, 0, 0, 0, NULL},
     {"passwd", &network_password, CONF_TYPE_STRING, 0, 0, 0, NULL},
     {"bandwidth", &network_bandwidth, CONF_TYPE_INT, CONF_MIN, 0, 0, NULL},
@@ -373,7 +373,7 @@ const m_option_t common_opts[] = {
     {"passwd", "MPlayer was compiled without streaming (network) support.\n", CONF_TYPE_PRINT, CONF_NOCFG, 0, 0, NULL},
     {"bandwidth", "MPlayer was compiled without streaming (network) support.\n", CONF_TYPE_PRINT, CONF_NOCFG, 0, 0, NULL},
     {"user-agent", "MPlayer was compiled without streaming (network) support.\n", CONF_TYPE_PRINT, CONF_NOCFG, 0, 0, NULL},
-#endif /* CONFIG_NETWORK */
+#endif /* CONFIG_NETWORKING */
 
 #ifdef CONFIG_LIVE555
     {"sdp", "-sdp has been removed, use sdp://file instead.\n", CONF_TYPE_PRINT, 0, 0, 0, NULL},
@@ -392,13 +392,13 @@ const m_option_t common_opts[] = {
 #else
     {"rtsp-stream-over-sctp", "-rtsp-stream-over-sctp requires the \"libnemesi\" library\n", CONF_TYPE_PRINT, CONF_NOCFG, 0, 0, NULL},
 #endif /* CONFIG_LIBNEMESI */
-#ifdef CONFIG_NETWORK
+#ifdef CONFIG_NETWORKING
     {"rtsp-port", &rtsp_port, CONF_TYPE_INT, CONF_RANGE, -1, 65535, NULL},
     {"rtsp-destination", &rtsp_destination, CONF_TYPE_STRING, CONF_MIN, 0, 0, NULL},
 #else
-    {"rtsp-port", "MPlayer was compiled without network support.\n", CONF_TYPE_PRINT, CONF_NOCFG, 0, 0, NULL},
-    {"rtsp-destination", "MPlayer was compiled without network support.\n", CONF_TYPE_PRINT, CONF_NOCFG, 0, 0, NULL},
-#endif /* CONFIG_NETWORK */
+    {"rtsp-port", "MPlayer was compiled without networking support.\n", CONF_TYPE_PRINT, CONF_NOCFG, 0, 0, NULL},
+    {"rtsp-destination", "MPlayer was compiled without networking support.\n", CONF_TYPE_PRINT, CONF_NOCFG, 0, 0, NULL},
+#endif /* CONFIG_NETWORKING */
 
 // ------------------------- demuxer options --------------------
 

Modified: trunk/configure
==============================================================================
--- trunk/configure	Sat Jul 17 12:28:17 2010	(r31748)
+++ trunk/configure	Sat Jul 17 15:14:53 2010	(r31749)
@@ -273,7 +273,7 @@ Optional features:
   --disable-tv-bsdbt848  disable BSD BT848 interface [autodetect]
   --disable-pvr          disable Video4Linux2 MPEG PVR [autodetect]
   --disable-rtc          disable RTC (/dev/rtc) on Linux [autodetect]
-  --disable-network      disable networking [enable]
+  --disable-networking   disable networking [enable]
   --enable-winsock2_h    enable winsock2_h [autodetect]
   --enable-smb           enable Samba (SMB) input [autodetect]
   --enable-live          enable LIVE555 Streaming Media [autodetect]
@@ -713,7 +713,7 @@ _tv_v4l2=auto
 _tv_bsdbt848=auto
 _tv_dshow=auto
 _pvr=auto
-_network=yes
+networking=yes
 _winsock2_h=auto
 _struct_addrinfo=auto
 _getaddrinfo=auto
@@ -1154,8 +1154,8 @@ for ac_option do
   --disable-fastmemcpy) _fastmemcpy=no  ;;
   --enable-hardcoded-tables)  hardcoded_tables=yes ;;
   --disable-hardcoded-tables) hardcoded_tables=no  ;;
-  --enable-network)     _network=yes    ;;
-  --disable-network)    _network=no     ;;
+  --enable-networking)     networking=yes    ;;
+  --disable-networking)    networking=no     ;;
   --enable-winsock2_h)  _winsock2_h=yes ;;
   --disable-winsock2_h) _winsock2_h=no  ;;
   --enable-smb)         _smb=yes        ;;
@@ -3375,21 +3375,23 @@ fi
 echores "$_closesocket"
 
 
-echocheck "network"
+echocheck "networking"
 test $_winsock2_h = no && test $inet_pton = no &&
-  test $inet_aton = no && _network=no
-if test "$_network" = yes ; then
+  test $inet_aton = no && networking=no
+if test "$networking" = yes ; then
   def_network='#define CONFIG_NETWORK 1'
+  def_networking='#define CONFIG_NETWORKING 1'
   extra_ldflags="$extra_ldflags $_ld_sock"
-  inputmodules="network $inputmodules"
+  inputmodules="networking $inputmodules"
 else
-  noinputmodules="network $noinputmodules"
+  noinputmodules="networking $noinputmodules"
   def_network='#undef CONFIG_NETWORK'
+  def_networking='#undef CONFIG_NETWORKING'
   _ftp=no
   libavprotocols=$(echo $libavprotocols | sed -e s/GOPHER_PROTOCOL// -e s/HTTP_PROTOCOL// -e s/RTMP_PROTOCOL// -e s/RTP_PROTOCOL// -e s/TCP_PROTOCOL// -e s/UDP_PROTOCOL//)
   libavdemuxers=$(echo $libavdemuxers | sed -e s/RTSP_DEMUXER// -e s/SDP_DEMUXER//)
 fi
-echores "$_network"
+echores "$networking"
 
 
 echocheck "inet6"
@@ -6242,7 +6244,7 @@ fi
 echores "$_libcdio"
 
 if test "$_cdda" = yes ; then
-    test $_cddb = auto && test $_network = yes && _cddb=yes
+    test $_cddb = auto && test $networking = yes && _cddb=yes
     def_cdparanoia='#define CONFIG_CDDA 1'
     inputmodules="cdda $inputmodules"
 else
@@ -7142,7 +7144,7 @@ fi
 echores "$_qtx"
 
 echocheck "Nemesi Streaming Media libraries"
-if test "$_nemesi" = auto  && test "$_network" = yes ; then
+if test "$_nemesi" = auto  && test "$networking" = yes ; then
     _nemesi=no
     if $_pkg_config libnemesi --atleast-version=0.6.3 ; then
         extra_cflags="$extra_cflags $($_pkg_config --cflags libnemesi)"
@@ -7155,7 +7157,7 @@ if test "$_nemesi" = yes; then
     def_nemesi='#define CONFIG_LIBNEMESI 1'
     inputmodules="nemesi $inputmodules"
 else
-    _native_rtsp="$_network"
+    _native_rtsp="$networking"
     _nemesi=no
     def_nemesi='#undef CONFIG_LIBNEMESI'
     noinputmodules="nemesi $noinputmodules"
@@ -7163,7 +7165,7 @@ fi
 echores "$_nemesi"
 
 echocheck "LIVE555 Streaming Media libraries"
-if test "$_live" = auto  && test "$_network" = yes ; then
+if test "$_live" = auto  && test "$networking" = yes ; then
   cat > $TMPCPP << EOF
 #include <liveMedia.hh>
 #if (LIVEMEDIA_LIBRARY_VERSION_INT < 1141257600)
@@ -7194,11 +7196,11 @@ EOF
       fi
   fi
 fi
-if test "$_live" = yes && test "$_network" = yes; then
+if test "$_live" = yes && test "$networking" = yes; then
   test $_livelibdir && res_comment="using $_livelibdir"
   def_live='#define CONFIG_LIVE555 1'
  inputmodules="live555 $inputmodules"
-elif test "$_live_dist" = yes && test "$_network" = yes; then
+elif test "$_live_dist" = yes && test "$networking" = yes; then
   res_comment="using distribution version"
   _live="yes"
   def_live='#define CONFIG_LIVE555 1'
@@ -7214,7 +7216,7 @@ fi
 echores "$_live"
 
 echocheck "RTMPDump Streaming Media library"
-if test "$_librtmp" = auto  && test "$_network" = yes ; then
+if test "$_librtmp" = auto  && test "$networking" = yes ; then
   cat > $TMPC << EOF
 #include <librtmp/rtmp.h>
 int main(void) { RTMP r; RTMP_Socket(&r); return 0; }
@@ -7228,7 +7230,7 @@ EOF
 	  extra_cflags="$extra_cflags $_inc_tmp"
   fi
 fi
-if test "$_librtmp" = yes && test "$_network" = yes; then
+if test "$_librtmp" = yes && test "$networking" = yes; then
   nolibrtmp=no
   def_librtmp='#define CONFIG_LIBRTMP 1'
   inputmodules="librtmp $inputmodules"
@@ -8664,7 +8666,7 @@ MPG123 = $_mpg123
 MUSEPACK = $_musepack
 NAS = $_nas
 NATIVE_RTSP = $_native_rtsp
-NETWORK = $_network
+NETWORKING = $networking
 OPENAL = $_openal
 OSS = $_ossaudio
 PE_EXECUTABLE = $_pe_executable
@@ -9122,7 +9124,7 @@ $def_inet_aton
 $def_inet_pton
 $def_live
 $def_nemesi
-$def_network
+$def_networking
 $def_smb
 $def_socklen_t
 $def_struct_ipv6_mreq
@@ -9255,6 +9257,7 @@ $def_log2f
 $def_lrint
 $def_mlib
 $def_mkstemp
+$def_network
 $def_pic
 $def_posix_memalign
 $def_pthreads

Modified: trunk/libmpdemux/asfheader.c
==============================================================================
--- trunk/libmpdemux/asfheader.c	Sat Jul 17 12:28:17 2010	(r31748)
+++ trunk/libmpdemux/asfheader.c	Sat Jul 17 15:14:53 2010	(r31749)
@@ -662,7 +662,7 @@ if(streams) {
   // as the servers often do not care about what we requested.
 #if 0
   uint32_t vr = 0, ar = 0,i;
-#ifdef CONFIG_NETWORK
+#ifdef CONFIG_NETWORKING
   if( demuxer->stream->streaming_ctrl!=NULL ) {
 	  if( demuxer->stream->streaming_ctrl->bandwidth!=0 && demuxer->stream->streaming_ctrl->data!=NULL ) {
 		  best_audio = ((asf_http_streaming_ctrl_t*)demuxer->stream->streaming_ctrl->data)->audio_id;

Modified: trunk/stream/stream.c
==============================================================================
--- trunk/stream/stream.c	Sat Jul 17 12:28:17 2010	(r31748)
+++ trunk/stream/stream.c	Sat Jul 17 15:14:53 2010	(r31749)
@@ -89,7 +89,7 @@ static const stream_info_t* const auto_o
 #ifdef CONFIG_CDDA
   &stream_info_cdda,
 #endif
-#ifdef CONFIG_NETWORK
+#ifdef CONFIG_NETWORKING
   &stream_info_netstream,
   &stream_info_http1,
   &stream_info_asf,
@@ -181,7 +181,7 @@ static stream_t* open_stream_plugin(cons
   s->flags |= mode;
   *ret = sinfo->open(s,mode,arg,file_format);
   if((*ret) != STREAM_OK) {
-#ifdef CONFIG_NETWORK
+#ifdef CONFIG_NETWORKING
     if (*ret == STREAM_REDIRECTED && redirected_url) {
         if (s->streaming_ctrl && s->streaming_ctrl->url
             && s->streaming_ctrl->url->url)
@@ -272,7 +272,7 @@ int stream_fill_buffer(stream_t *s){
   // we will retry even if we already reached EOF previously.
   switch(s->type){
   case STREAMTYPE_STREAM:
-#ifdef CONFIG_NETWORK
+#ifdef CONFIG_NETWORKING
     if( s->streaming_ctrl!=NULL && s->streaming_ctrl->streaming_read ) {
 	    len=s->streaming_ctrl->streaming_read(s->fd,s->buffer,STREAM_BUFFER_SIZE, s->streaming_ctrl);
     } else
@@ -343,7 +343,7 @@ if(newpos==0 || newpos!=s->pos){
     // Some streaming protocol allow to seek backward and forward
     // A function call that return -1 can tell that the protocol
     // doesn't support seeking.
-#ifdef CONFIG_NETWORK
+#ifdef CONFIG_NETWORKING
     if(s->seek) { // new stream seek is much cleaner than streaming_ctrl one
       if(!s->seek(s,newpos)) {
       	mp_msg(MSGT_STREAM,MSGL_ERR, "Seek failed\n");

Modified: trunk/stream/stream.h
==============================================================================
--- trunk/stream/stream.h	Sat Jul 17 12:28:17 2010	(r31748)
+++ trunk/stream/stream.h	Sat Jul 17 15:14:53 2010	(r31749)
@@ -159,13 +159,13 @@ typedef struct stream {
   void* cache_data;
   void* priv; // used for DVD, TV, RTSP etc
   char* url;  // strdup() of filename/url
-#ifdef CONFIG_NETWORK
+#ifdef CONFIG_NETWORKING
   streaming_ctrl_t *streaming_ctrl;
 #endif
   unsigned char buffer[STREAM_BUFFER_SIZE>VCD_SECTOR_SIZE?STREAM_BUFFER_SIZE:VCD_SECTOR_SIZE];
 } stream_t;
 
-#ifdef CONFIG_NETWORK
+#ifdef CONFIG_NETWORKING
 #include "network.h"
 #endif
 


More information about the MPlayer-cvslog mailing list