Commit 98725620 authored by Sam Hocevar's avatar Sam Hocevar

  * vlc core compiles under QNX RTOS. Now if anyone feels like tidying
  it and writing output and interface plugins...
parent 0d5aa512
......@@ -58,7 +58,7 @@ PROGRAM_BUILD = `date` $(USER)
# DEFINE will contain some of the constants definitions decided in Makefile,
# including SYS_xx. It will be passed to C compiler.
DEFINE += -DSYS_$(shell echo $(SYS) | sed 's/-.*//' | tr a-z. A-Z_)
DEFINE += -DSYS_$(shell echo $(SYS) | sed 's/-.*//' | tr '[a-z].' '[A-Z]_')
# On Linux activate 64-bit off_t (by default under BSD)
ifneq (,$(findstring linux,$(SYS)))
......@@ -615,10 +615,8 @@ $(PLUGIN_QT:%.o=%.moc): %.moc: %.cpp
$(PLUGIN_KDE): %.o: Makefile.dep
$(PLUGIN_KDE): %.o: .dep/%.dpp
$(PLUGIN_KDE): %.o: %.moc
$(CC) $(CFLAGS) $(PCFLAGS) -I/usr/include/kde -I/usr/include/qt -fno-rtti -c -o $@ $(<:%.moc=%.cpp)
$(PLUGIN_KDE:%.o=%.moc): %.moc: %.cpp
moc -i $< -o $@
$(PLUGIN_KDE): %.o: %.cpp
$(CC) $(CFLAGS) $(PCFLAGS) -I/usr/include/kde -I/usr/include/qt -fno-rtti -c -o $@ $<
$(PLUGIN_BEOS): %.o: Makefile.dep
$(PLUGIN_BEOS): %.o: .dep/%.dpp
......@@ -634,9 +632,13 @@ ifeq ($(SYS),beos)
$(CC) $(CFLAGS) $(LCFLAGS) -Xlinker -soname=_APP_ -o $@ $(C_OBJ) $(CPP_OBJ) $(ASM_OBJ)
rm -f ./plugins/_APP_
ln -s ../vlc ./plugins/_APP_
else
ifeq ($(SYS),nto-qnx)
$(CC) $(CFLAGS) $(LCFLAGS) -Xlinker -export-dynamic -o $@ $(C_OBJ) $(CPP_OBJ) $(ASM_OBJ)
else
$(CC) $(CFLAGS) $(LCFLAGS) --export-dynamic @DYNAMIC_FLAG@ -o $@ $(C_OBJ) $(CPP_OBJ) $(ASM_OBJ)
endif
endif
#
# Plugin targets
......@@ -673,8 +675,13 @@ lib/alsa.so: $(PLUGIN_ALSA)
lib/fb.so: $(PLUGIN_FB)
$(CC) $(PCFLAGS) $(PLCFLAGS) -o $@ $^
ifeq ($(SYS),nto-qnx)
lib/x11.so: $(PLUGIN_X11)
$(CC) $(PCFLAGS) $(PLCFLAGS) -o $@ $^ -L/usr/X11R6/lib -lX11 -lXext -lsocket
else
lib/x11.so: $(PLUGIN_X11)
$(CC) $(PCFLAGS) $(PLCFLAGS) -o $@ $^ -L/usr/X11R6/lib -lX11 -lXext
endif
lib/mga.so: $(PLUGIN_MGA)
$(CC) $(PCFLAGS) $(PLCFLAGS) -o $@ $^ -L/usr/X11R6/lib -lX11 -lXext
......
......@@ -3415,7 +3415,7 @@ if test "${enable_mmx+set}" = set; then
enableval="$enable_mmx"
if test x$enableval = xyes; then ARCH=${ARCH}" mmx"; PLUGINS=${PLUGINS}${ACCEL_PLUGINS}; fi
else
if test x${host_cpu} = xi686 -o x${host_cpu} = xi586; then ARCH=${ARCH}" mmx"; PLUGINS=${PLUGINS}${ACCEL_PLUGINS}; fi
if test x${host_cpu} = xi686 -o x${host_cpu} = xi586 -o x${host_cpu} = xx86; then ARCH=${ARCH}" mmx"; PLUGINS=${PLUGINS}${ACCEL_PLUGINS}; fi
fi
# Check whether --enable-css or --disable-css was given.
......
......@@ -128,7 +128,7 @@ AC_ARG_ENABLE(ppro,
AC_ARG_ENABLE(mmx,
[ --disable-mmx Disable MMX optimizations (default enabled for x86)],
[ if test x$enableval = xyes; then ARCH=${ARCH}" mmx"; PLUGINS=${PLUGINS}${ACCEL_PLUGINS}; fi ],
[ if test x${host_cpu} = xi686 -o x${host_cpu} = xi586; then ARCH=${ARCH}" mmx"; PLUGINS=${PLUGINS}${ACCEL_PLUGINS}; fi ])
[ if test x${host_cpu} = xi686 -o x${host_cpu} = xi586 -o x${host_cpu} = xx86; then ARCH=${ARCH}" mmx"; PLUGINS=${PLUGINS}${ACCEL_PLUGINS}; fi ])
AC_ARG_ENABLE(css,
[ --disable-css Disable DVD CSS decryption (default enabled)],
[ if test x$enableval = xyes; then CSS=1; else CSS=0; fi ], [ CSS=1; ])
......
......@@ -2,7 +2,7 @@
* input.h: structures of the input not exported to other modules
*****************************************************************************
* Copyright (C) 1999, 2000 VideoLAN
* $Id: input.h,v 1.34 2001/03/07 00:18:46 henri Exp $
* $Id: input.h,v 1.35 2001/03/19 13:26:59 sam Exp $
*
* Authors: Christophe Massiot <massiot@via.ecp.fr>
*
......@@ -51,8 +51,10 @@ void input_FileClose( struct input_thread_s * );
/*****************************************************************************
* Prototypes from input.c to open a network socket
*****************************************************************************/
#if !defined( SYS_BEOS ) && !defined( SYS_NTO )
void input_NetworkOpen ( struct input_thread_s * );
void input_NetworkClose( struct input_thread_s * );
#endif
/*****************************************************************************
......
......@@ -2,7 +2,7 @@
* input_ts.c: TS demux and netlist management
*****************************************************************************
* Copyright (C) 1998, 1999, 2000 VideoLAN
* $Id: input_ts.c,v 1.11 2001/03/18 20:46:16 henri Exp $
* $Id: input_ts.c,v 1.12 2001/03/19 13:26:59 sam Exp $
*
* Authors: Henri Fallon <henri@videolan.org>
*
......@@ -34,6 +34,9 @@
#include <errno.h>
#include <sys/types.h>
#ifdef SYS_NTO
#include <sys/select.h>
#endif
#include <sys/uio.h>
#include <sys/stat.h>
#include <unistd.h>
......@@ -76,12 +79,12 @@ void _M( input_getfunctions )( function_list_t * p_function_list )
#define input p_function_list->functions.input
p_function_list->pf_probe = TSProbe;
input.pf_init = TSInit;
#ifdef SYS_BEOS
input.pf_open = input_FileOpen;
input.pf_close = input_FileClose;
#else
#if !defined( SYS_BEOS ) && !defined( SYS_NTO )
input.pf_open = input_NetworkOpen;
input.pf_close = input_NetworkClose;
#else
input.pf_open = input_FileOpen;
input.pf_close = input_FileClose;
#endif
input.pf_end = TSEnd;
input.pf_set_area = NULL;
......
......@@ -139,6 +139,15 @@ aout_thread_t *aout_CreateThread( int *pi_status )
return( NULL );
}
if( p_aout->l_rate == 0 )
{
intf_ErrMsg( "aout error: null sample rate" );
p_aout->pf_close( p_aout );
module_Unneed( p_main->p_bank, p_aout->p_module );
free( p_aout );
return( NULL );
}
p_aout->b_stereo = ( p_aout->i_channels == 2 ) ? 1 : 0; /* FIXME: only works
for i_channels == 1 or 2 ??*/
......
......@@ -4,7 +4,7 @@
* decoders.
*****************************************************************************
* Copyright (C) 1998, 1999, 2000 VideoLAN
* $Id: input.c,v 1.93 2001/03/15 01:42:20 sam Exp $
* $Id: input.c,v 1.94 2001/03/19 13:26:59 sam Exp $
*
* Authors: Christophe Massiot <massiot@via.ecp.fr>
*
......@@ -38,7 +38,7 @@
/* Network functions */
#ifndef SYS_BEOS
#if !defined( SYS_BEOS ) && !defined( SYS_NTO )
#include <netdb.h> /* hostent ... */
#include <sys/socket.h>
#include <netinet/in.h>
......@@ -514,7 +514,7 @@ void input_FileClose( input_thread_t * p_input )
}
#ifndef SYS_BEOS
#if !defined( SYS_BEOS ) && !defined( SYS_NTO )
/*****************************************************************************
* input_NetworkOpen : open a network socket
*****************************************************************************/
......
......@@ -29,12 +29,12 @@
#include <signal.h> /* SIGHUP, SIGINT, SIGKILL */
#include <stdio.h> /* sprintf() */
#include <unistd.h> /* getopt() under QNX */
#ifdef HAVE_GETOPT_H
#include <getopt.h> /* getopt() */
#endif
#include <unistd.h>
#include <errno.h> /* ENOMEM */
#include <stdlib.h> /* getenv(), strtol(), */
#include <string.h> /* strerror() */
......
......@@ -54,7 +54,7 @@
#include "intf_msg.h"
#ifndef SYS_BEOS /* I need help for the BeOS portage */
#if !defined( SYS_BEOS ) && !defined( SYS_NTO )
#include "netutils.h"
......
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