[xiph-commits] r2868 - liboggplay/trunk/src/liboggplay
conrad at svn.annodex.net
conrad at svn.annodex.net
Thu Jun 7 05:14:12 PDT 2007
Author: conrad
Date: 2007-06-07 05:14:12 -0700 (Thu, 07 Jun 2007)
New Revision: 2868
Modified:
liboggplay/trunk/src/liboggplay/Makefile.am
liboggplay/trunk/src/liboggplay/oggplay.c
liboggplay/trunk/src/liboggplay/oggplay_tcp_reader.c
liboggplay/trunk/src/liboggplay/oggplay_yuv2rgb.c
Log:
Compilation fix for src/liboggplay: remove explicit -std=c99 restriction
because this code relies on the non-c99 library functions strdup (in
oggplay.c) and nanosleep (in oggplay_tcp_reader.c). We do also want to use
a feature that was standardized in C99: restricted pointers, in
oggplay_yuv2rgb.c, but we can do that in GCC without requesting c99 mode by
using the inbuilt __restrict__.
Modified: liboggplay/trunk/src/liboggplay/Makefile.am
===================================================================
--- liboggplay/trunk/src/liboggplay/Makefile.am 2007-06-07 04:07:13 UTC (rev 2867)
+++ liboggplay/trunk/src/liboggplay/Makefile.am 2007-06-07 12:14:12 UTC (rev 2868)
@@ -1,6 +1,6 @@
## Process this file with automake to produce Makefile.in
-AM_CFLAGS = -Wall $(SSE2_CFLAGS) -std=c99 -Werror
+AM_CFLAGS = -Wall $(SSE2_CFLAGS) -Werror
INCLUDES = $(INCLTDL) -I$(top_srcdir)/include
Modified: liboggplay/trunk/src/liboggplay/oggplay.c
===================================================================
--- liboggplay/trunk/src/liboggplay/oggplay.c 2007-06-07 04:07:13 UTC (rev 2867)
+++ liboggplay/trunk/src/liboggplay/oggplay.c 2007-06-07 12:14:12 UTC (rev 2868)
@@ -42,8 +42,6 @@
#include <string.h>
#include <stdlib.h>
-extern char *strdup(const char *in);
-
OggPlay *
oggplay_new_with_reader(OggPlayReader *reader, char *location) {
Modified: liboggplay/trunk/src/liboggplay/oggplay_tcp_reader.c
===================================================================
--- liboggplay/trunk/src/liboggplay/oggplay_tcp_reader.c 2007-06-07 04:07:13 UTC (rev 2867)
+++ liboggplay/trunk/src/liboggplay/oggplay_tcp_reader.c 2007-06-07 12:14:12 UTC (rev 2868)
@@ -52,6 +52,8 @@
#include <sys/socket.h>
#include <sys/fcntl.h>
#include <sys/errno.h>
+#include <sys/time.h>
+#include <time.h>
#include <netdb.h>
#include <unistd.h>
#endif
Modified: liboggplay/trunk/src/liboggplay/oggplay_yuv2rgb.c
===================================================================
--- liboggplay/trunk/src/liboggplay/oggplay_yuv2rgb.c 2007-06-07 04:07:13 UTC (rev 2867)
+++ liboggplay/trunk/src/liboggplay/oggplay_yuv2rgb.c 2007-06-07 12:14:12 UTC (rev 2868)
@@ -61,7 +61,10 @@
#include <emmintrin.h>
#else
#include <xmmintrin.h>
+#ifndef restrict
+#define restrict __restrict__
#endif
+#endif
/* YUV -> RGB Intel MMX implementation */
void oggplay_yuv2rgb(OggPlayYUVChannels * yuv, OggPlayRGBChannels * rgb) {
More information about the commits
mailing list