Commit 7c80c87d authored by Eric Petit's avatar Eric Petit

* configure.ac.in, mms.c, sap.c, ipv4.c: added network support for BeOS 5

   (Dano is no more needed); multicast still doesn't work.
   UDP (unicast) and HTTP have been successfully tested, mms is untested.
 * sap.c: BeOS doesn't have memccpy
 * VideoOutput.cpp: forgot to remove a printf
parent 6d142974
......@@ -154,7 +154,11 @@ case "x${target_os}" in
LDFLAGS_vlc="${LDFLAGS_vlc} -lbe"
LDFLAGS_plugins="${LDFLAGS_plugins} -nostart"
LDFLAGS_beos="${LDFLAGS_beos} -lbe -lmedia -lroot -ltracker -lstdc++.r4 -ltranslation"
LDFLAGS_ipv4="${LDFLAGS_ipv4} -lbind"
dnl BONE or not BONE ?
AC_CHECK_LIB( bind, inet_ntoa,
[ LDFLAGS_access_mms="${LDFLAGS_access_mms} -lbind"
LDFLAGS_ipv4="${LDFLAGS_ipv4} -lbind"],
[])
;;
x*)
SYS="${target_os}"
......@@ -621,11 +625,7 @@ PLUGINS="${PLUGINS} aout_file"
PLUGINS="${PLUGINS} i420_rgb i420_yuy2 i422_yuy2 i420_ymga"
PLUGINS="${PLUGINS} id3 m3u"
PLUGINS="${PLUGINS} wav araw demuxdump demuxsub adpcm"
dnl
dnl Network modules
dnl
NETWORK_MODULES="access_udp access_http access_rtp ipv4 access_mms sap"
PLUGINS="${PLUGINS} access_udp access_http access_rtp ipv4 access_mms sap"
dnl
dnl Accelerated modules
......@@ -636,11 +636,6 @@ THREEDNOW_MODULES="memcpy3dn imdct3dn downmix3dn"
SSE_MODULES="imdctsse downmixsse"
ALTIVEC_MODULES="idctaltivec motionaltivec memcpyaltivec"
if test x${SYS} != xbeos
then
PLUGINS="${PLUGINS} ${NETWORK_MODULES}"
fi
AC_CACHE_CHECK([if \$CC groks MMX inline assembly],
[ac_cv_mmx_inline],
[CFLAGS="${CFLAGS_save}"
......
......@@ -2,7 +2,7 @@
* mms.c: MMS access plug-in
*****************************************************************************
* Copyright (C) 2001, 2002 VideoLAN
* $Id: mms.c,v 1.10 2002/12/02 21:13:25 jlj Exp $
* $Id: mms.c,v 1.11 2002/12/04 06:23:08 titer Exp $
*
* Authors: Laurent Aimar <fenrir@via.ecp.fr>
*
......@@ -57,7 +57,11 @@
#else
# include <sys/socket.h>
# include <netinet/in.h>
# include <arpa/inet.h>
# if HAVE_ARPA_INET_H
# include <arpa/inet.h>
# elif defined( SYS_BEOS )
# include <net/netdb.h>
# endif
#endif
#include "network.h"
......
......@@ -2,7 +2,7 @@
* vout_beos.cpp: beos video output display method
*****************************************************************************
* Copyright (C) 2000, 2001 VideoLAN
* $Id: VideoOutput.cpp,v 1.7 2002/12/03 02:00:37 titer Exp $
* $Id: VideoOutput.cpp,v 1.8 2002/12/04 06:23:08 titer Exp $
*
* Authors: Jean-Marc Dressler <polux@via.ecp.fr>
* Samuel Hocevar <sam@zoy.org>
......@@ -900,7 +900,6 @@ VLCView::MouseDown(BPoint where)
{
VideoWindow* videoWindow = dynamic_cast<VideoWindow*>(Window());
BMessage* msg = Window()->CurrentMessage();
msg->PrintToStream();
int32 clicks;
uint32 buttons;
msg->FindInt32("clicks", &clicks);
......
......@@ -2,7 +2,7 @@
* ipv4.c: IPv4 network abstraction layer
*****************************************************************************
* Copyright (C) 2001, 2002 VideoLAN
* $Id: ipv4.c,v 1.7 2002/11/28 23:24:15 massiot Exp $
* $Id: ipv4.c,v 1.8 2002/12/04 06:23:08 titer Exp $
*
* Authors: Christophe Massiot <massiot@via.ecp.fr>
* Mathias Kretschmer <mathias@research.att.com>
......@@ -187,7 +187,11 @@ static int OpenUDP( vlc_object_t * p_this, network_socket_t * p_socket )
/* Increase the receive buffer size to 1/2MB (8Mb/s during 1/2s) to avoid
* packet loss caused by scheduling problems */
i_opt = 0x80000;
#if defined( SYS_BEOS )
if( setsockopt( i_handle, SOL_SOCKET, SO_NONBLOCK,
#else
if( setsockopt( i_handle, SOL_SOCKET, SO_RCVBUF,
#endif
(void *) &i_opt, sizeof( i_opt ) ) == -1 )
{
#ifdef HAVE_ERRNO_H
......@@ -203,7 +207,11 @@ static int OpenUDP( vlc_object_t * p_this, network_socket_t * p_socket )
* is typically only 65535 bytes */
i_opt = 0;
i_opt_size = sizeof( i_opt );
#if defined( SYS_BEOS )
if( getsockopt( i_handle, SOL_SOCKET, SO_NONBLOCK,
#else
if( getsockopt( i_handle, SOL_SOCKET, SO_RCVBUF,
#endif
(void*) &i_opt, &i_opt_size ) == -1 )
{
#ifdef HAVE_ERRNO_H
......@@ -266,7 +274,11 @@ static int OpenUDP( vlc_object_t * p_this, network_socket_t * p_socket )
if( !*psz_bind_addr )
{
i_opt = 1;
#if defined( SYS_BEOS )
if( setsockopt( i_handle, SOL_SOCKET, SO_NONBLOCK,
#else
if( setsockopt( i_handle, SOL_SOCKET, SO_BROADCAST,
#endif
(void*) &i_opt, sizeof( i_opt ) ) == -1 )
{
#ifdef HAVE_ERRNO_H
......@@ -278,7 +290,7 @@ static int OpenUDP( vlc_object_t * p_this, network_socket_t * p_socket )
}
}
#ifndef UNDER_CE
#if !defined( UNDER_CE ) && !defined( SYS_BEOS )
/* Join the multicast group if the socket is a multicast address */
#ifndef IN_MULTICAST
# define IN_MULTICAST(a) IN_CLASSD(a)
......
......@@ -2,7 +2,7 @@
* sap.c : SAP interface module
*****************************************************************************
* Copyright (C) 2001 VideoLAN
* $Id: sap.c,v 1.2 2002/12/03 23:36:41 gitan Exp $
* $Id: sap.c,v 1.3 2002/12/04 06:23:08 titer Exp $
*
* Authors: Arnaud Schauly <gitan@via.ecp.fr>
*
......@@ -55,7 +55,11 @@
#else
# include <sys/socket.h>
# include <netinet/in.h>
# include <arpa/inet.h>
# if HAVE_ARPA_INET_H
# include <arpa/inet.h>
# elif defined( SYS_BEOS )
# include <net/netdb.h>
# endif
#endif
#include "network.h"
......@@ -364,7 +368,13 @@ static sess_descr_t * parse_sdp( char * psz_pct, intf_thread_t * p_intf )
if( ppsz_fill != NULL )
{
*ppsz_fill= malloc( sizeof(char) * (k+1) );
memccpy(*ppsz_fill, &(psz_pct[j-k+1]),'\n', k );
#if defined( SYS_BEOS )
/* BeOS doesn't have memccpy. This line probably won't work
properly, but BeOS has no multicast support anyway */
memcpy(*ppsz_fill, &(psz_pct[j-k+1]), k );
#else
memccpy(*ppsz_fill, &(psz_pct[j-k+1]),'\n', k );
#endif
(*ppsz_fill)[k]='\0';
}
ppsz_fill = NULL;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment