Commit 3266cd72 authored by Jon Lech Johansen's avatar Jon Lech Johansen

* darwin_specific.[ch]: added strndup needed by video_output.c.

  * configure.in: added -lintl to plugins_LDFLAGS.
parent 7682a00c
......@@ -4023,6 +4023,7 @@ fi
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
echo "$ac_t""yes" 1>&6
vlc_LDFLAGS="${vlc_LDFLAGS} -lintl"
plugins_LDFLAGS="${plugins_LDFLAGS} -lintl"
else
echo "$ac_t""no" 1>&6
fi
......
......@@ -154,7 +154,10 @@ AC_CHECK_FUNC(inet_aton,,[
AC_CHECK_LIB(resolv,inet_aton,ipv4_LDFLAGS="${ipv4_LDFLAGS} -lresolv")
])
AC_CHECK_FUNC(textdomain,,[
AC_CHECK_LIB(intl,textdomain,vlc_LDFLAGS="${vlc_LDFLAGS} -lintl")
AC_CHECK_LIB(intl,textdomain,
vlc_LDFLAGS="${vlc_LDFLAGS} -lintl"
plugins_LDFLAGS="${plugins_LDFLAGS} -lintl"
)
])
dnl Check for getopt
......
......@@ -2,7 +2,7 @@
* darwin_specific.h: Darwin specific features
*****************************************************************************
* Copyright (C) 2001 VideoLAN
* $Id: darwin_specific.h,v 1.3 2002/04/02 23:43:57 gbazin Exp $
* $Id: darwin_specific.h,v 1.4 2002/07/02 22:07:02 jlj Exp $
*
* Authors: Samuel Hocevar <sam@zoy.org>
*
......@@ -25,3 +25,4 @@
* Prototypes
*****************************************************************************/
char * system_GetProgramPath( void );
extern char *strndup( const char *string, size_t n );
......@@ -2,7 +2,7 @@
* darwin_specific.c: Darwin specific features
*****************************************************************************
* Copyright (C) 2001 VideoLAN
* $Id: darwin_specific.c,v 1.12 2002/06/02 14:26:16 gbazin Exp $
* $Id: darwin_specific.c,v 1.13 2002/07/02 22:07:02 jlj Exp $
*
* Authors: Samuel Hocevar <sam@zoy.org>
*
......@@ -60,7 +60,7 @@ void system_Init( vlc_t *p_this, int *pi_argc, char *ppsz_argv[] )
param.sched_priority = 10;
if (pthread_setschedparam(pthread_self(), SCHED_RR, &param))
{
intf_ErrMsg("pthread_setschedparam failed");
msg_Err( p_this, "pthread_setschedparam failed" );
}
}
}
......@@ -89,3 +89,23 @@ char * system_GetProgramPath( void )
return( psz_program_path );
}
/*****************************************************************************
* strndup: returns a malloc'd copy of at most n bytes of string
* Does anyone know whether or not it will be present in Jaguar?
*****************************************************************************/
char *strndup( const char *string, size_t n )
{
char *psz;
size_t len;
len = __MIN( strlen( string ), n );
psz = (char*)malloc( len + 1 );
if( psz != NULL )
{
memcpy( (void*)psz, (const void*)string, len );
psz[ len ] = 0;
}
return( psz );
}
......@@ -5,7 +5,7 @@
* thread, and destroy a previously oppened video output thread.
*****************************************************************************
* Copyright (C) 2000-2001 VideoLAN
* $Id: video_output.c,v 1.185 2002/06/11 09:44:22 gbazin Exp $
* $Id: video_output.c,v 1.186 2002/07/02 22:07:02 jlj Exp $
*
* Authors: Vincent Seguin <seguin@via.ecp.fr>
*
......@@ -41,6 +41,10 @@
#include "video.h"
#include "video_output.h"
#if defined( SYS_DARWIN )
#include "darwin_specific.h"
#endif
/*****************************************************************************
* Local prototypes
*****************************************************************************/
......
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