diff options
author | František Dvořák <valtri@users.sourceforge.net> | 2005-11-28 12:24:56 +0000 |
---|---|---|
committer | František Dvořák <valtri@users.sourceforge.net> | 2005-11-28 12:24:56 +0000 |
commit | 29889061262a94aeb8871b185b29a1699f55af63 (patch) | |
tree | 5ce0740455e3e6051dbf726abb090165f8abfcec | |
parent | e9ad6a71dbf9f5f0b1e249ad7969afa1fd8665ba (diff) | |
download | xine-lib-29889061262a94aeb8871b185b29a1699f55af63.tar.gz xine-lib-29889061262a94aeb8871b185b29a1699f55af63.tar.bz2 |
*BUGFIX*
Improved cross-compiling: detect and precedence of the host-specific libs
W32dll: enabled by platforms as originaly, user can override it
Fixed shell errors in the Makefile of the hackersguide
Detect the place of SDL header independently on platform
Fixed spelling in CDDA, include the header sys/param.h if available
Fixed format strings (fix warnings (or even bugs) on Gentoo/FreeBSD)
CVS patchset: 7815
CVS date: 2005/11/28 12:24:56
36 files changed, 178 insertions, 147 deletions
@@ -39,6 +39,7 @@ xine-lib (1.1.0) xine-lib (1.0.3) * tiny doc update + * build fixes and cross build improvements xine-lib (1.0.2) * fixed playback of single-session Real RTSP streams, such as diff --git a/configure.ac b/configure.ac index 3f538d8a1..264fad845 100644 --- a/configure.ac +++ b/configure.ac @@ -871,7 +871,7 @@ dnl --------------------------------------------- dnl Find pkg-config dnl --------------------------------------------- -AC_PATH_PROG(PKG_CONFIG, pkg-config, no) +AC_PATH_TOOL(PKG_CONFIG, pkg-config, no) if test x$PKG_CONFIG = xno ; then echo "*** pkg-config not found. See http://pkgconfig.sourceforge.net" echo "*** All of DIRECTFB dependent parts will be disabled" @@ -1240,7 +1240,7 @@ AC_ARG_ENABLE([imagemagick], [with_imagemagick=$enableval], [with_imagemagick=yes]) if test "x$with_imagemagick" = "xyes"; then - AC_PATH_PROG(WAND_CONFIG, Wand-config, no) + AC_PATH_TOOL(WAND_CONFIG, Wand-config, no) if test "$WAND_CONFIG" = "no" ; then AC_MSG_RESULT([*** All Imagemagick dependent parts will be disabled, Wand-config not found. ***]) have_imagemagick="no" @@ -1788,6 +1788,33 @@ dnl AM_CONDITIONAL(HAVE_MODPLUG, [test x"$have_modplug" = x"yes"]) dnl --------------------------------------------- +dnl Win32 DLL codecs +dnl --------------------------------------------- +AC_ARG_ENABLE([w32dll], + AC_HELP_STRING([--disable-w32dll], [Disable Win32 DLL support]), + enable_w32dll=$enableval, [ + AC_MSG_CHECKING([whether to enable Win32 DLL support]) + case "$host_or_hostalias" in + *-mingw* | *-cygwin) + enable_w32dll="no" + ;; + i?86-* | k?-* | athlon-* | pentium*-) + enable_w32dll="yes" + ;; + *) + enable_w32dll="no" + esac + AC_MSG_RESULT([$enable_w32dll])]) +AM_CONDITIONAL(HAVE_W32DLL, test x"$enable_w32dll" = "xyes") +if test x"$enable_w32dll" = "xyes"; then + W32DLL_DEP="" +else + W32DLL_DEP="#" +fi +AC_SUBST(W32DLL_DEP) + + +dnl --------------------------------------------- dnl ip_mreqn dnl --------------------------------------------- @@ -1865,7 +1892,6 @@ DEBUG_CFLAGS="-D_REENTRANT -D_FILE_OFFSET_BITS=64 -DXINE_COMPILE $DEBUG_CFLAGS" AC_OPTIMIZATIONS -enable_w32dll="no" enable_ffmmx="no" enable_armv4l="no" @@ -1880,14 +1906,9 @@ case "$host_or_hostalias" in AC_DEFINE_UNQUOTED(ARCH_X86,,[Define this if you're running x86 architecture]) AC_DEFINE(FPM_INTEL,1,[Define to select libmad fixed point arithmetic implementation]) enable_ffmmx="yes" - enable_w32dll="yes" case "$host_or_hostalias" in - *-*-mingw*) - enable_w32dll="no" - ;; *-*-cygwin) - enable_w32dll="no" LIBS="$LIBS @INTLLIBS@ -lkernel32" ;; esac @@ -1974,14 +1995,6 @@ esac AM_CONDITIONAL(HOST_OS_DARWIN, test x"$HOST_OS_DARWIN" = "x1") -AM_CONDITIONAL(HAVE_W32DLL, test x"$enable_w32dll" = "xyes") -if test x"$enable_w32dll" = "xyes"; then - W32DLL_DEP="" -else - W32DLL_DEP="#" -fi -AC_SUBST(W32DLL_DEP) - AM_CONDITIONAL(HAVE_FFMMX, test x"$enable_ffmmx" = "xyes") dnl --------------------------------------------- diff --git a/doc/hackersguide/Makefile.am b/doc/hackersguide/Makefile.am index 7fdc77706..e6812c19e 100644 --- a/doc/hackersguide/Makefile.am +++ b/doc/hackersguide/Makefile.am @@ -7,12 +7,16 @@ hackersguide_sgml = hackersguide.sgml \ internals.sgml \ stream.sgml \ output.sgml +hackersguide_fig = architecture.fig \ + library.fig \ + overlays.fig \ + post_frame.fig docs_DATA = hackersguide.html \ architecture.png library.png overlays.png post_frame.png -EXTRA_DIST = README $(hackersguide_sgml) \ - architecture.fig library.fig overlays.fig post_frame.fig $(docs_DATA) +EXTRA_DIST = README $(hackersguide_sgml) $(hackersguide_fig) \ + $(docs_DATA) docsdir = $(prefix)/share/doc/xine/hackersguide @@ -20,9 +24,9 @@ docs: $(docs_DATA) distclean-local: clean-docs -docs-prepare: $(addprefix $(srcdir)/, $(hackersguide_sgml) $(wildcard *.fig)) +docs-prepare: $(addprefix $(srcdir)/, $(hackersguide_sgml)) if test "$(srcdir)" != "." ; then \ - for file in $(hackersguide_sgml) *.fig ; do \ + for file in $(hackersguide_sgml) ; do \ test -f ./$$file -a ./$$file -nt $(srcdir)/$$file || cp $(srcdir)/$$file .; \ done ; \ fi @@ -58,11 +62,9 @@ endif if HAVE_FIG2DEV %.png: %.fig - @$(MAKE) docs-prepare $(FIG2DEV) -L png -S 4 $< $@; else %.png: %.fig - @$(MAKE) docs-prepare if test x"$(fail_if_missing)" = x"yes"; then \ echo "Please install fig2dev."; \ exit 1; \ @@ -69,7 +69,7 @@ AC_ARG_ENABLE(aalibtest, if test ! -x "$AALIB_CONFIG"; then AALIB_CONFIG="" fi - AC_PATH_PROG(AALIB_CONFIG, aalib-config, no) + AC_PATH_TOOL(AALIB_CONFIG, aalib-config, no) if test "$AALIB_CONFIG" = "no" ; then @@ -93,7 +93,7 @@ dnl aalib-config is missing, check for old aainfo fi if test x"$aalib_config_prefix" = "x"; then - AC_PATH_PROG(AAINFO, aainfo, no) + AC_PATH_TOOL(AAINFO, aainfo, no) else AC_MSG_CHECKING(for $AAINFO) if test -x $AAINFO; then diff --git a/m4/arts.m4 b/m4/arts.m4 index f1c2963d0..b44d26a21 100644 --- a/m4/arts.m4 +++ b/m4/arts.m4 @@ -21,7 +21,7 @@ AC_ARG_ENABLE(artstest, AC_HELP_STRING([--disable-artstest], [do not try to comp fi fi - AC_PATH_PROG(ARTS_CONFIG, artsc-config, no) + AC_PATH_TOOL(ARTS_CONFIG, artsc-config, no) min_arts_version=ifelse([$1], ,0.9.5,$1) AC_MSG_CHECKING(for ARTS artsc - version >= $min_arts_version) diff --git a/m4/caca.m4 b/m4/caca.m4 index 884256fbe..7e59dedf4 100644 --- a/m4/caca.m4 +++ b/m4/caca.m4 @@ -44,7 +44,7 @@ AC_ARG_ENABLE(cacatest, if test ! -x "$CACA_CONFIG"; then CACA_CONFIG="" fi - AC_PATH_PROG(CACA_CONFIG, caca-config, no) + AC_PATH_TOOL(CACA_CONFIG, caca-config, no) if test "$CACA_CONFIG" = "no" ; then dnl diff --git a/m4/dvdnav.m4 b/m4/dvdnav.m4 index 505050676..9254ca533 100644 --- a/m4/dvdnav.m4 +++ b/m4/dvdnav.m4 @@ -57,7 +57,7 @@ AC_ARG_ENABLE(dvdnavtest, if test "x$enable_dvdnavtest" != "xyes" ; then AC_MSG_CHECKING([for DVDNAV-LIB version >= $min_dvdnav_version]) else - AC_PATH_PROG(DVDNAV_CONFIG, dvdnav-config, no) + AC_PATH_TOOL(DVDNAV_CONFIG, dvdnav-config, no) AC_MSG_CHECKING([for DVDNAV-LIB version >= $min_dvdnav_version]) no_dvdnav="" if test "$DVDNAV_CONFIG" = "no" ; then @@ -31,7 +31,7 @@ AC_ARG_ENABLE(esdtest, AC_HELP_STRING([--disable-esdtest], [do not try to compil fi fi - AC_PATH_PROG(ESD_CONFIG, esd-config, no) + AC_PATH_TOOL(ESD_CONFIG, esd-config, no) min_esd_version=ifelse([$1], ,0.2.7,$1) AC_MSG_CHECKING([for ESD - version >= $min_esd_version]) no_esd="" diff --git a/m4/freetype2.m4 b/m4/freetype2.m4 index d894b5fb4..5fc51bda9 100644 --- a/m4/freetype2.m4 +++ b/m4/freetype2.m4 @@ -13,7 +13,7 @@ AC_DEFUN([AM_PATH_FREETYPE2], [ ) if test x"$enable_freetype" = "xyes"; then - AC_PATH_PROG(FREETYPE_CONFIG, freetype-config, no) + AC_PATH_TOOL(FREETYPE_CONFIG, freetype-config, no) if test "$FREETYPE_CONFIG" = "no" ; then AC_MSG_RESULT([*** freetype-config not found, freetype2 support disabled ** ]) diff --git a/m4/gettext.m4 b/m4/gettext.m4 index a27be9a65..80d877ef2 100644 --- a/m4/gettext.m4 +++ b/m4/gettext.m4 @@ -122,7 +122,7 @@ return (int) gettext ("")]ifelse([$2], need-ngettext, [ + (int) ngettext ("", "" dnl Search for GNU msgfmt in the PATH. AM_PATH_PROG_WITH_TEST(MSGFMT, msgfmt, [$ac_dir/$ac_word --statistics /dev/null >/dev/null 2>&1], :) - AC_PATH_PROG(GMSGFMT, gmsgfmt, $MSGFMT) + AC_PATH_TOOL(GMSGFMT, gmsgfmt, $MSGFMT) dnl Search for GNU xgettext in the PATH. AM_PATH_PROG_WITH_TEST(XGETTEXT, xgettext, @@ -144,7 +144,7 @@ return (int) gettext ("")]ifelse([$2], need-ngettext, [ + (int) ngettext ("", "" INTLOBJS="\$(GETTOBJS)" AM_PATH_PROG_WITH_TEST(MSGFMT, msgfmt, [$ac_dir/$ac_word --statistics /dev/null >/dev/null 2>&1], :) - AC_PATH_PROG(GMSGFMT, gmsgfmt, $MSGFMT) + AC_PATH_TOOL(GMSGFMT, gmsgfmt, $MSGFMT) AM_PATH_PROG_WITH_TEST(XGETTEXT, xgettext, [$ac_dir/$ac_word --omit-header /dev/null >/dev/null 2>&1], :) AC_SUBST(MSGFMT) diff --git a/m4/libfame.m4 b/m4/libfame.m4 index 74b368e9a..b6a14ed34 100644 --- a/m4/libfame.m4 +++ b/m4/libfame.m4 @@ -27,7 +27,7 @@ AC_ARG_ENABLE(libfametest, AC_HELP_STRING([--disable-libfametest], [do not try t fi fi - AC_PATH_PROG(LIBFAME_CONFIG, libfame-config, no) + AC_PATH_TOOL(LIBFAME_CONFIG, libfame-config, no) min_libfame_version=ifelse([$1], , 0.9.0, $1) AC_MSG_CHECKING(for libfame - version >= $min_libfame_version) no_libfame="" @@ -6,7 +6,7 @@ AC_DEFUN([PKG_CHECK_MODULES], [ succeeded=no if test -z "$PKG_CONFIG"; then - AC_PATH_PROG(PKG_CONFIG, pkg-config, no) + AC_PATH_TOOL(PKG_CONFIG, pkg-config, no) fi if test "$PKG_CONFIG" = "no" ; then @@ -35,11 +35,11 @@ AC_DEFUN([AM_PATH_SDL], fi fi - AC_PATH_PROG(SDL_CONFIG, sdl-config, no) + AC_PATH_TOOL(SDL_CONFIG, sdl-config, no) min_sdl_version=ifelse([$1], ,0.11.0,$1) - AC_MSG_CHECKING(for SDL - version >= $min_sdl_version) no_sdl="" if test "$SDL_CONFIG" = "no" ; then + AC_MSG_CHECKING(for SDL - version >= $min_sdl_version) no_sdl=yes else SDL_CFLAGS=`$SDL_CONFIG $sdlconf_args --cflags` @@ -61,11 +61,17 @@ dnl Now check if the installed SDL is sufficiently new. (Also sanity dnl checks the results of sdl-config to some extent dnl rm -f conf.sdltest + AC_CHECK_HEADERS([SDL11/SDL.h]) + AC_MSG_CHECKING(for SDL - version >= $min_sdl_version) AC_TRY_RUN([ #include <stdio.h> #include <stdlib.h> #include <string.h> -#include "SDL.h" +#ifdef HAVE_SDL11_SDL_H +# include <SDL11/SDL.h> +#else +# include <SDL.h> +#endif char* my_strdup (char *str) @@ -121,9 +127,13 @@ int main (int argc, char *argv[]) ],, no_sdl=yes, AC_TRY_LINK([ #include <stdio.h> -#include "SDL.h" +#ifdef HAVE_SDL11_SDL_H +# include <SDL11/SDL.h> +#else +# include <SDL.h> +#endif -int main(int argc, char *argv[]) +int main(int argc, char *argv@<:@@:>@) { return 0; } #undef main #define main K_and_R_C_main @@ -152,9 +162,13 @@ int main(int argc, char *argv[]) LIBS="$LIBS $SDL_LIBS" AC_TRY_LINK([ #include <stdio.h> -#include "SDL.h" +#ifdef HAVE_SDL11_SDL_H +# include <SDL11/SDL.h> +#else +# include <SDL.h> +#endif -int main(int argc, char *argv[]) +int main(int argc, char *argv@<:@@:>@) { return 0; } #undef main #define main K_and_R_C_main diff --git a/m4/xine.m4 b/m4/xine.m4 index 316ca4918..1b21bbbab 100644 --- a/m4/xine.m4 +++ b/m4/xine.m4 @@ -57,7 +57,7 @@ AC_ARG_ENABLE(xinetest, if test "x$enable_xinetest" != "xyes" ; then AC_MSG_CHECKING([for XINE-LIB version >= $min_xine_version]) else - AC_PATH_PROG(XINE_CONFIG, xine-config, no) + AC_PATH_TOOL(XINE_CONFIG, xine-config, no) AC_MSG_CHECKING([for XINE-LIB version >= $min_xine_version]) no_xine="" if test "$XINE_CONFIG" = "no" ; then diff --git a/src/demuxers/demux_avi.c b/src/demuxers/demux_avi.c index b2ba15293..4cf6c5b31 100644 --- a/src/demuxers/demux_avi.c +++ b/src/demuxers/demux_avi.c @@ -19,7 +19,7 @@ */ /* - * $Id: demux_avi.c,v 1.220 2005/11/01 18:36:19 tmattern Exp $ + * $Id: demux_avi.c,v 1.221 2005/11/28 12:24:57 valtri Exp $ * * demultiplexer for avi streams * @@ -347,7 +347,7 @@ static void check_newpts (demux_avi_t *this, int64_t pts, int video) { if (this->send_newpts) { - lprintf ("sending newpts %lld (video = %d)\n", pts, video); + lprintf ("sending newpts %" PRId64 " (video = %d)\n", pts, video); if (this->buf_flag_seek) { _x_demux_control_newpts(this->stream, pts, BUF_FLAG_SEEK); @@ -415,7 +415,7 @@ static int64_t get_audio_pts (demux_avi_t *this, int track, uint32_t posc, avi_audio_t *at = this->avi->audio[track]; - lprintf("get_audio_pts: track=%d, posc=%d, postot=%lld, posb=%d\n", track, posc, postot, posb); + lprintf("get_audio_pts: track=%d, posc=%d, postot=%" PRIdMAX ", posb=%d\n", track, posc, (intmax_t)postot, posb); if ((at->dwSampleSize == 0) && (at->dwScale > 1)) { /* variable bitrate */ @@ -438,8 +438,8 @@ static int64_t get_audio_pts (demux_avi_t *this, int track, uint32_t posc, } static int64_t get_video_pts (demux_avi_t *this, off_t pos) { - lprintf("get_video_pts: dwScale=%d, dwRate=%d, pos=%lld\n", - this->avi->dwScale, this->avi->dwRate, pos); + lprintf("get_video_pts: dwScale=%d, dwRate=%d, pos=%" PRIdMAX "\n", + this->avi->dwScale, this->avi->dwRate, (intmax_t)pos); return (int64_t)(90000.0 * (double)pos * (double)this->avi->dwScale / (double)this->avi->dwRate); } @@ -543,7 +543,7 @@ static int idx_grow(demux_avi_t *this, int (*stopper)(demux_avi_t *, void *), } if (this->input->read(this->input, data, AVI_HEADER_SIZE) != AVI_HEADER_SIZE) { - lprintf("read failed, chunk_pos=%lld\n", chunk_pos); + lprintf("read failed, chunk_pos=%" PRIdMAX "\n", (intmax_t)chunk_pos); break; } @@ -634,7 +634,7 @@ static int idx_grow(demux_avi_t *this, int (*stopper)(demux_avi_t *, void *), } chunk_pos = this->input->seek(this->input, this->idx_grow.nexttagoffset, SEEK_SET); if (chunk_pos != this->idx_grow.nexttagoffset) { - lprintf("seek failed: %lld != %lld\n", chunk_pos, this->idx_grow.nexttagoffset); + lprintf("seek failed: %" PRIdMAX " != %" PRIdMAX "\n", (intmax_t)chunk_pos, (intmax_t)this->idx_grow.nexttagoffset); break; } } @@ -787,7 +787,7 @@ static avi_t *AVI_init(demux_avi_t *this) { break; } - lprintf("chunk: %c%c%c%c, size: %lld\n", + lprintf("chunk: %c%c%c%c, size: %" PRId64 "\n", data[0], data[1], data[2], data[3], (int64_t)n); if(strncasecmp(data,"LIST",4) == 0) { @@ -1390,7 +1390,7 @@ static avi_t *AVI_init(demux_avi_t *this) { AVI->video_posf = 0; AVI->video_posb = 0; - lprintf("done, pos=%lld, AVI->movi_start=%lld\n", this->input->get_current_pos(this->input), AVI->movi_start); + lprintf("done, pos=%lld, AVI->movi_start=%" PRIdMAX "\n", this->input->get_current_pos(this->input), (intmax_t)AVI->movi_start); return AVI; } @@ -1548,7 +1548,7 @@ static int demux_avi_next (demux_avi_t *this, int decoder_flags) { audio_pts = get_audio_pts (this, i, aie->block_no, aie->tot, audio->audio_posb); - lprintf ("video_pts %lld audio_pts %lld\n", video_pts, audio_pts); + lprintf ("video_pts %" PRId64 " audio_pts %" PRId64 "\n", video_pts, audio_pts); if (!this->no_audio && (audio_pts < video_pts)) { @@ -1648,9 +1648,9 @@ static int get_chunk_header(demux_avi_t *this, uint32_t *len, int *audio_stream) break; *len = LE_32(data + 4); - lprintf("header: %c%c%c%c, pos=%lld, len=%u\n", + lprintf("header: %c%c%c%c, pos=%" PRIdMAX ", len=%u\n", data[0], data[1], data[2], data[3], - this->input->get_current_pos(this->input), *len); + (intmax_t)this->input->get_current_pos(this->input), *len); /* Dive into RIFF and LIST entries */ if(strncasecmp(data, "LIST", 4) == 0 || @@ -1699,13 +1699,13 @@ static int demux_avi_next_streaming (demux_avi_t *this, int decoder_flags) { buf_element_t *buf = NULL; int64_t audio_pts, video_pts; - int64_t current_pos; + off_t current_pos; int left; int header, chunk_len, audio_stream; avi_audio_t *audio; current_pos = this->input->get_current_pos(this->input); - lprintf("input_pos=%lld\n", current_pos); + lprintf("input_pos=%" PRIdMAX "\n", (intmax_t)current_pos); header = get_chunk_header(this, &chunk_len, &audio_stream); @@ -1725,7 +1725,7 @@ static int demux_avi_next_streaming (demux_avi_t *this, int decoder_flags) { /* read audio */ buf->pts = audio_pts; - lprintf("audio pts: %lld\n", audio_pts); + lprintf("audio pts: %" PRId64 "\n", audio_pts); if (left > this->audio_fifo->buffer_pool_buf_size) { buf->size = this->audio_fifo->buffer_pool_buf_size; @@ -1771,7 +1771,7 @@ static int demux_avi_next_streaming (demux_avi_t *this, int decoder_flags) { /* read video */ buf->pts = video_pts; - lprintf("video pts: %lld\n", video_pts); + lprintf("video pts: %" PRId64 "\n", video_pts); if (left > this->video_fifo->buffer_pool_buf_size) { buf->size = this->video_fifo->buffer_pool_buf_size; @@ -2145,7 +2145,7 @@ static int demux_avi_seek_internal (demux_avi_t *this) { * position we've already found, so we won't be seeking though the * file much at this point. */ - xprintf(this->stream->xine, XINE_VERBOSITY_DEBUG, "video_pts = %lld\n", video_pts); + xprintf(this->stream->xine, XINE_VERBOSITY_DEBUG, "video_pts = %" PRId64 "\n", video_pts); /* FIXME ? */ audio_pts = 77777777; @@ -2157,7 +2157,7 @@ static int demux_avi_seek_internal (demux_avi_t *this) { for(i = 0; i < this->avi->n_audio; i++) { max_pos = this->avi->audio[i]->audio_idx.audio_chunks - 1; min_pos = 0; - lprintf("audio_chunks=%d, min=%lld, max=%lld\n", this->avi->audio[i]->audio_idx.audio_chunks, min_pos, max_pos); + lprintf("audio_chunks=%d, min=%" PRId64 ", max=%" PRId64 "\n", this->avi->audio[i]->audio_idx.audio_chunks, min_pos, max_pos); while (min_pos < max_pos) { cur_pos = this->avi->audio[i]->audio_posc = (max_pos + min_pos) / 2; if (cur_pos == min_pos) break; @@ -2168,7 +2168,7 @@ static int demux_avi_seek_internal (demux_avi_t *this) { } else { min_pos = cur_pos; } - lprintf ("audio_pts = %lld %lld < %lld < %lld\n", + lprintf ("audio_pts = %" PRId64 " %" PRId64 " < %" PRId64 " < %" PRId64 "\n", audio_pts, min_pos, cur_pos, max_pos); } else { if (cur_pos > min_pos) { @@ -2180,7 +2180,7 @@ static int demux_avi_seek_internal (demux_avi_t *this) { } } } - lprintf ("audio_pts = %lld\n", audio_pts); + lprintf ("audio_pts = %" PRId64 "\n", audio_pts); /* * try to make audio pos more accurate for long index entries diff --git a/src/demuxers/demux_film.c b/src/demuxers/demux_film.c index 428604c71..9d3ed3f0e 100644 --- a/src/demuxers/demux_film.c +++ b/src/demuxers/demux_film.c @@ -21,7 +21,7 @@ * For more information on the FILM file format, visit: * http://www.pcisys.net/~melanson/codecs/ * - * $Id: demux_film.c,v 1.78 2005/02/03 07:19:05 valtri Exp $ + * $Id: demux_film.c,v 1.79 2005/11/28 12:24:57 valtri Exp $ */ #ifdef HAVE_CONFIG_H @@ -311,7 +311,7 @@ static int open_film_file(demux_film_t *film) { if (film->sample_table[j].pts > largest_pts) largest_pts = film->sample_table[j].pts; - llprintf(DEBUG_FILM_LOAD, "sample %4d @ %8" PRIxMAX ", %8X bytes, %s, pts %lld, duration %lld%s\n", + llprintf(DEBUG_FILM_LOAD, "sample %4d @ %8" PRIxMAX ", %8X bytes, %s, pts %lld, duration %" PRId64 "%s\n", j, (intmax_t)film->sample_table[j].sample_offset, film->sample_table[j].sample_size, @@ -473,7 +473,7 @@ static int demux_film_send_chunk(demux_plugin_t *this_gen) { if (!remaining_sample_bytes) buf->decoder_flags |= BUF_FLAG_FRAME_END; - llprintf(DEBUG_FILM_DEMUX, "sending video buf with %d bytes, %lld pts, %d duration\n", + llprintf(DEBUG_FILM_DEMUX, "sending video buf with %" PRId32 " bytes, %" PRId64 " pts, %" PRId32 " duration\n", buf->size, buf->pts, buf->decoder_info[0]); this->video_fifo->put(this->video_fifo, buf); } @@ -517,7 +517,7 @@ static int demux_film_send_chunk(demux_plugin_t *this_gen) { if (!remaining_sample_bytes) buf->decoder_flags |= BUF_FLAG_FRAME_END; - llprintf(DEBUG_FILM_DEMUX, "sending video buf with %d bytes, %lld pts, %d duration\n", + llprintf(DEBUG_FILM_DEMUX, "sending video buf with %" PRId32 " bytes, %" PRId64 " pts, %" PRId32 " duration\n", buf->size, buf->pts, buf->decoder_info[0]); this->video_fifo->put(this->video_fifo, buf); } @@ -577,7 +577,7 @@ static int demux_film_send_chunk(demux_plugin_t *this_gen) { if (!remaining_sample_bytes) buf->decoder_flags |= BUF_FLAG_FRAME_END; - llprintf(DEBUG_FILM_DEMUX, "sending mono audio buf with %d bytes, %lld pts, %d duration\n", + llprintf(DEBUG_FILM_DEMUX, "sending mono audio buf with %" PRId32 " bytes, %" PRId64 " pts, %" PRId32 " duration\n", buf->size, buf->pts, buf->decoder_info[0]); this->audio_fifo->put(this->audio_fifo, buf); @@ -648,7 +648,7 @@ static int demux_film_send_chunk(demux_plugin_t *this_gen) { if (!remaining_sample_bytes) buf->decoder_flags |= BUF_FLAG_FRAME_END; - llprintf(DEBUG_FILM_DEMUX, "sending stereo audio buf with %d bytes, %lld pts, %d duration\n", + llprintf(DEBUG_FILM_DEMUX, "sending stereo audio buf with %" PRId32 " bytes, %" PRId64 " pts, %" PRId32 " duration\n", buf->size, buf->pts, buf->decoder_info[0]); this->audio_fifo->put(this->audio_fifo, buf); } diff --git a/src/demuxers/demux_iff.c b/src/demuxers/demux_iff.c index 493595ef8..0dec90169 100644 --- a/src/demuxers/demux_iff.c +++ b/src/demuxers/demux_iff.c @@ -36,7 +36,7 @@ * * ANIM (Animations) * - Animation works fine, without seeking. * - * $Id: demux_iff.c,v 1.13 2005/02/06 15:26:16 tmattern Exp $ + * $Id: demux_iff.c,v 1.14 2005/11/28 12:24:57 valtri Exp $ */ #ifdef HAVE_CONFIG_H @@ -927,7 +927,7 @@ static int demux_iff_send_chunk(demux_plugin_t *this_gen) { buf->decoder_flags |= BUF_FLAG_FRAME_END; xprintf (this->stream->xine, XINE_VERBOSITY_LOG, - "sending audio buf with %d bytes, %lld pts, %d duration\n", + "sending audio buf with %" PRId32 " bytes, %" PRId64 " pts, %" PRId32 " duration\n", buf->size, buf->pts, buf->decoder_info[0]); this->audio_fifo->put(this->audio_fifo, buf); } diff --git a/src/demuxers/demux_matroska.c b/src/demuxers/demux_matroska.c index bdee3b9b9..ad2ca7729 100644 --- a/src/demuxers/demux_matroska.c +++ b/src/demuxers/demux_matroska.c @@ -17,7 +17,7 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA * - * $Id: demux_matroska.c,v 1.40 2005/10/03 18:22:29 tmattern Exp $ + * $Id: demux_matroska.c,v 1.41 2005/11/28 12:24:57 valtri Exp $ * * demultiplexer for matroska streams * @@ -163,7 +163,7 @@ static void check_newpts (demux_matroska_t *this, int64_t pts, if (pts && (this->send_newpts || (track->last_pts && abs(diff)>WRAP_THRESHOLD)) ) { int i; - lprintf ("sending newpts %lld, diff %lld, track %d\n", pts, diff, track->track_num); + lprintf ("sending newpts %" PRId64 ", diff %" PRId64 ", track %d\n", pts, diff, track->track_num); if (this->buf_flag_seek) { _x_demux_control_newpts(this->stream, pts, BUF_FLAG_SEEK); @@ -179,7 +179,7 @@ static void check_newpts (demux_matroska_t *this, int64_t pts, } else { #ifdef LOG if (pts) - lprintf ("diff %lld, track %d\n", diff, track->track_num); + lprintf ("diff %" PRId64 ", track %d\n", diff, track->track_num); #endif } @@ -255,7 +255,7 @@ static int parse_info(demux_matroska_t *this) { this->timecode_scale = 1000000; } this->duration = (int)(duration * (double)this->timecode_scale / 1000000.0); - lprintf("timecode_scale: %lld\n", this->timecode_scale); + lprintf("timecode_scale: %" PRId64 "\n", this->timecode_scale); lprintf("duration: %d\n", this->duration); return 1; } @@ -369,7 +369,7 @@ static void init_codec_video(demux_matroska_t *this, matroska_track_t *track) { if (track->codec_private_len > buf->max_size) { xprintf(this->stream->xine, XINE_VERBOSITY_LOG, - "demux_matroska: private decoder data length (%d) is greater than fifo buffer length (%d)\n", + "demux_matroska: private decoder data length (%d) is greater than fifo buffer length (%" PRId32 ")\n", track->codec_private_len, buf->max_size); buf->free_buffer(buf); return; @@ -408,7 +408,7 @@ static void init_codec_audio(demux_matroska_t *this, matroska_track_t *track) { if (track->codec_private_len > buf->max_size) { xprintf(this->stream->xine, XINE_VERBOSITY_LOG, - "demux_matroska: private decoder data length (%d) is greater than fifo buffer length (%d)\n", + "demux_matroska: private decoder data length (%d) is greater than fifo buffer length (%" PRId32 ")\n", track->codec_private_len, buf->max_size); buf->free_buffer(buf); return; @@ -451,7 +451,7 @@ static void init_codec_real(demux_matroska_t *this, matroska_track_t * track) { if (track->codec_private_len > buf->max_size) { xprintf(this->stream->xine, XINE_VERBOSITY_LOG, - "demux_matroska: private decoder data length (%d) is greater than fifo buffer length (%d)\n", + "demux_matroska: private decoder data length (%d) is greater than fifo buffer length (%" PRId32 ")\n", track->codec_private_len, buf->max_size); buf->free_buffer(buf); return; @@ -505,7 +505,7 @@ static void init_codec_vorbis(demux_matroska_t *this, matroska_track_t *track) { if (frame[i] > buf->max_size) { xprintf(this->stream->xine, XINE_VERBOSITY_LOG, - "demux_matroska: private decoder data length (%d) is greater than fifo buffer length (%d)\n", + "demux_matroska: private decoder data length (%d) is greater than fifo buffer length (%" PRId32 ")\n", frame[i], buf->max_size); buf->free_buffer(buf); return; @@ -788,7 +788,7 @@ static void handle_realvideo (demux_plugin_t *this_gen, matroska_track_t *track, if (chunk_tab_size > buf->max_size) { xprintf(this->stream->xine, XINE_VERBOSITY_LOG, - "demux_matroska: Real Chunk Table length (%d) is greater than fifo buffer length (%d)\n", + "demux_matroska: Real Chunk Table length (%d) is greater than fifo buffer length (%" PRId32 ")\n", chunk_tab_size, buf->max_size); buf->free_buffer(buf); return; @@ -822,7 +822,7 @@ static void handle_sub_ssa (demux_plugin_t *this_gen, matroska_track_t *track, int dest_len; int skip = 0; - lprintf ("pts: %lld, duration: %d\n", data_pts, data_duration); + lprintf ("pts: %" PRId64 ", duration: %d\n", data_pts, data_duration); /* skip ',' */ while (data_len && (commas < 8)) { if (*data == ',') commas++; @@ -1665,14 +1665,14 @@ static int parse_block (demux_matroska_t *this, uint64_t block_size, flags = *data; data += 1; - lprintf("track_num: %lld, timecode_diff: %d, flags: 0x%x\n", track_num, timecode_diff, flags); + lprintf("track_num: %" PRId64 ", timecode_diff: %d, flags: 0x%x\n", track_num, timecode_diff, flags); gap = flags & 1; lacing = (flags >> 1) & 0x3; if (!find_track_by_id(this, (int)track_num, &track)) { xprintf(this->stream->xine, XINE_VERBOSITY_LOG, - "demux_matroska: invalid track id: %lld\n", track_num); + "demux_matroska: invalid track id: %" PRId64 "\n", track_num); return 0; } @@ -1696,7 +1696,7 @@ static int parse_block (demux_matroska_t *this, uint64_t block_size, block_duration = track->default_duration; xduration = (int64_t)block_duration * (int64_t)90 / (int64_t)1000000; } - lprintf("pts: %lld, duration: %lld\n", pts, xduration); + lprintf("pts: %" PRId64 ", duration: %" PRId64 "\n", pts, xduration); check_newpts(this, pts, track); @@ -1710,7 +1710,7 @@ static int parse_block (demux_matroska_t *this, uint64_t block_size, lprintf("no lacing\n"); block_size_left = (this->block_data + block_size) - data; - lprintf("size: %d, block_size: %lld\n", block_size_left, block_size); + lprintf("size: %d, block_size: %" PRIu64 "\n", block_size_left, block_size); if (track->handle_content != NULL) { track->handle_content((demux_plugin_t *)this, track, @@ -1863,7 +1863,7 @@ static int parse_block_group(demux_matroska_t *this, /* should override track duration */ if (!ebml_read_uint(ebml, &elem, &block_duration)) return 0; - lprintf("duration: %lld\n", block_duration); + lprintf("duration: %" PRIu64 "\n", block_duration); break; case MATROSKA_ID_CL_REFERENCEBLOCK: is_key = 0; @@ -2078,7 +2078,7 @@ static int parse_top_level_head(demux_matroska_t *this, int *next_level) { off_t current_pos; current_pos = this->input->get_current_pos(this->input); - lprintf("current_pos: %lld\n", current_pos); + lprintf("current_pos: %" PRIdMAX "\n", (intmax_t)current_pos); if (!ebml_read_elem_head(ebml, &elem)) return 0; @@ -2447,16 +2447,16 @@ static int demux_matroska_seek (demux_plugin_t *this_gen, entry = binary_seek(index, start_pos, start_time); if (entry == -1) { - lprintf("seeking for track %d to %s %lld - no entry found/EOS.\n", + lprintf("seeking for track %d to %s %" PRIdMAX " - no entry found/EOS.\n", index->track_num, start_pos ? "pos" : "time", - start_pos ? (int64_t)start_pos : (int64_t)start_time); + start_pos ? (intmax_t)start_pos : (intmax_t)start_time); this->status = DEMUX_FINISHED; } else { - lprintf("seeking for track %d to %s %lld. decision is #%d at %lld/%lld\n", + lprintf("seeking for track %d to %s %" PRIdMAX ". decision is #%d at %" PRIu64 "/%" PRIdMAX "\n", index->track_num, start_pos ? "pos" : "time", - start_pos ? (int64_t)start_pos : (int64_t)start_time, - index->track_num, index->timecode[entry], index->pos[entry]); + start_pos ? (intmax_t)start_pos : (intmax_t)start_time, + index->track_num, index->timecode[entry], (intmax_t)index->pos[entry]); if (this->input->seek(this->input, index->pos[entry], SEEK_SET) < 0) this->status = DEMUX_FINISHED; diff --git a/src/demuxers/demux_slave.c b/src/demuxers/demux_slave.c index aa9e806db..b37909c20 100644 --- a/src/demuxers/demux_slave.c +++ b/src/demuxers/demux_slave.c @@ -21,7 +21,7 @@ */ /* - * $Id: demux_slave.c,v 1.14 2005/02/06 15:26:19 tmattern Exp $ + * $Id: demux_slave.c,v 1.15 2005/11/28 12:24:57 valtri Exp $ * * demuxer for slave "protocol" * master xine must be started with XINE_PARAM_BROADCASTER_PORT set, that is, @@ -123,7 +123,7 @@ static int demux_slave_next (demux_slave_t *this) { int64_t disc_off; /* discontinuity offset */ uint32_t decoder_flags; /* stuff like keyframe, is_header ... see below */ - if( sscanf(s,"fifo=%10s size=%d type=%u pts=%lld disc=%lld flags=%u", + if( sscanf(s,"fifo=%10s size=%" SCNd32 " type=%" SCNu32 " pts=%" SCNd64 " disc=%" SCNd64 " flags=%" SCNu32, fifo_name, &size, &type, &pts, &disc_off, &decoder_flags) != 6 ) { lprintf("'buffer' command error\n"); this->status = DEMUX_FINISHED; diff --git a/src/demuxers/ebml.c b/src/demuxers/ebml.c index 933185400..88492dde6 100644 --- a/src/demuxers/ebml.c +++ b/src/demuxers/ebml.c @@ -20,7 +20,7 @@ * EBML parser * a lot of ideas from the gstreamer parser * - * $Id: ebml.c,v 1.3 2005/02/03 07:19:06 valtri Exp $ + * $Id: ebml.c,v 1.4 2005/11/28 12:24:57 valtri Exp $ * */ #ifdef HAVE_CONFIG_H @@ -73,14 +73,14 @@ uint32_t ebml_get_next_level(ebml_parser_t *ebml, ebml_elem_t *elem) { if (ebml->level > 0) { parent_elem = &ebml->elem_stack[ebml->level - 1]; while ((elem->start + elem->len) >= (parent_elem->start + parent_elem->len)) { - lprintf("parent: %lld, %lld; elem: %lld, %lld\n", - parent_elem->start, parent_elem->len, elem->start, elem->len); + lprintf("parent: %" PRIdMAX ", %" PRIu64 "; elem: %" PRIdMAX ", %" PRIu64 "\n", + (intmax_t)parent_elem->start, parent_elem->len, (intmax_t)elem->start, elem->len); ebml->level--; if (ebml->level == 0) break; parent_elem = &ebml->elem_stack[ebml->level - 1]; } } - lprintf("id: 0x%x, len: %lld, next_level: %d\n", elem->id, elem->len, ebml->level); + lprintf("id: 0x%x, len: %" PRIu64 ", next_level: %d\n", elem->id, elem->len, ebml->level); return ebml->level; } @@ -231,7 +231,7 @@ int ebml_read_uint(ebml_parser_t *ebml, ebml_elem_t *elem, uint64_t *num) { if ((elem->len < 1) || (elem->len > 8)) { xprintf(ebml->xine, XINE_VERBOSITY_LOG, - "ebml: Invalid integer element size %lld\n", size); + "ebml: Invalid integer element size %" PRIu64 "\n", size); return 0; } @@ -253,7 +253,7 @@ int ebml_read_sint (ebml_parser_t *ebml, ebml_elem_t *elem, int64_t *num) { if ((elem->len < 1) || (elem->len > 8)) { xprintf(ebml->xine, XINE_VERBOSITY_LOG, - "ebml: Invalid integer element size %lld\n", size); + "ebml: Invalid integer element size %" PRIu64 "\n", size); return 0; } @@ -281,7 +281,7 @@ int ebml_read_float (ebml_parser_t *ebml, ebml_elem_t *elem, double *num) { if ((size != 4) && (size != 8) && (size != 10)) { xprintf(ebml->xine, XINE_VERBOSITY_LOG, - "ebml: Invalid float element size %lld\n", size); + "ebml: Invalid float element size %" PRIu64 "\n", size); return 0; } @@ -335,7 +335,7 @@ int ebml_read_master (ebml_parser_t *ebml, ebml_elem_t *elem) { top_elem->id = elem->id; ebml->level++; - lprintf("id: 0x%x, len: %lld, level: %d\n", elem->id, elem->len, ebml->level); + lprintf("id: 0x%x, len: %" PRIu64 ", level: %d\n", elem->id, elem->len, ebml->level); if (ebml->level >= EBML_STACK_SIZE) { xprintf(ebml->xine, XINE_VERBOSITY_LOG, "ebml: max level exceeded\n"); @@ -388,7 +388,7 @@ int ebml_check_header(ebml_parser_t *ebml) { if (!ebml_read_uint (ebml, &elem, &num)) return 0; - lprintf("ebml_version: %lld\n", num); + lprintf("ebml_version: %" PRIu64 "\n", num); ebml->version = num; break; } @@ -398,7 +398,7 @@ int ebml_check_header(ebml_parser_t *ebml) { if (!ebml_read_uint (ebml, &elem, &num)) return 0; - lprintf("ebml_read_version: %lld\n", num); + lprintf("ebml_read_version: %" PRIu64 "\n", num); if (num != EBML_VERSION) return 0; ebml->read_version = num; @@ -410,7 +410,7 @@ int ebml_check_header(ebml_parser_t *ebml) { if (!ebml_read_uint (ebml, &elem, &num)) return 0; - lprintf("ebml_max_id_length: %lld\n", num); + lprintf("ebml_max_id_length: %" PRIu64 "\n", num); ebml->max_id_len = num; break; } @@ -420,7 +420,7 @@ int ebml_check_header(ebml_parser_t *ebml) { if (!ebml_read_uint (ebml, &elem, &num)) return 0; - lprintf("ebml_max_size_length: %lld\n", num); + lprintf("ebml_max_size_length: %" PRIu64 "\n", num); ebml->max_size_len = num; break; } @@ -444,7 +444,7 @@ int ebml_check_header(ebml_parser_t *ebml) { if (!ebml_read_uint (ebml, &elem, &num)) return 0; - lprintf("doctype_version: %lld\n", num); + lprintf("doctype_version: %" PRIu64 "\n", num); ebml->doctype_version = num; break; } @@ -454,7 +454,7 @@ int ebml_check_header(ebml_parser_t *ebml) { if (!ebml_read_uint (ebml, &elem, &num)) return 0; - lprintf("doctype_read_version: %lld\n", num); + lprintf("doctype_read_version: %" PRIu64 "\n", num); ebml->doctype_read_version = num; break; } diff --git a/src/dxr3/dxr3_decode_spu.c b/src/dxr3/dxr3_decode_spu.c index e6d6c85c8..c0d38f4cf 100644 --- a/src/dxr3/dxr3_decode_spu.c +++ b/src/dxr3/dxr3_decode_spu.c @@ -17,7 +17,7 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA * - * $Id: dxr3_decode_spu.c,v 1.51 2004/10/08 20:39:51 mroi Exp $ + * $Id: dxr3_decode_spu.c,v 1.52 2005/11/28 12:24:57 valtri Exp $ */ /* dxr3 spu decoder plugin. @@ -519,7 +519,7 @@ static void dxr3_spudec_decode_data(spu_decoder_t *this_gen, buf_element_t *buf) uint32_t vpts32; vpts = this->stream->metronom->got_spu_packet(this->stream->metronom, buf->pts); - llprintf(LOG_PTS, "pts = %lld vpts = %lld\n", buf->pts, vpts); + llprintf(LOG_PTS, "pts = %" PRId64 " vpts = %" PRIu64 "\n", buf->pts, vpts); vpts32 = vpts; if (ioctl(this->fd_spu, EM8300_IOCTL_SPU_SETPTS, &vpts32)) xprintf(this->stream->xine, XINE_VERBOSITY_DEBUG, diff --git a/src/dxr3/dxr3_decode_video.c b/src/dxr3/dxr3_decode_video.c index f19cf529b..f85454cfa 100644 --- a/src/dxr3/dxr3_decode_video.c +++ b/src/dxr3/dxr3_decode_video.c @@ -17,7 +17,7 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA * - * $Id: dxr3_decode_video.c,v 1.59 2004/12/16 13:59:06 mroi Exp $ + * $Id: dxr3_decode_video.c,v 1.60 2005/11/28 12:24:57 valtri Exp $ */ /* dxr3 video decoder plugin. @@ -583,7 +583,7 @@ static void dxr3_decode_data(video_decoder_t *this_gen, buf_element_t *buf) delay = vpts - this->class->clock->get_current_time( this->class->clock); - llprintf(LOG_PTS, "SETPTS got %lld\n", vpts); + llprintf(LOG_PTS, "SETPTS got %" PRId64 "\n", vpts); /* SETPTS only if less then one second in the future and * either buffer has pts or sync_every_frame is set */ if ((delay > 0) && (delay < 90000) && @@ -597,13 +597,13 @@ static void dxr3_decode_data(video_decoder_t *this_gen, buf_element_t *buf) if (delay >= 90000) /* frame more than 1 sec ahead */ xprintf(this->stream->xine, XINE_VERBOSITY_DEBUG, - "dxr3_decode_video: WARNING: vpts %lld is %.02f seconds ahead of time!\n", + "dxr3_decode_video: WARNING: vpts %" PRId64 " is %.02f seconds ahead of time!\n", vpts, delay/90000.0); if (delay < 0) xprintf(this->stream->xine, XINE_VERBOSITY_DEBUG, "dxr3_decode_video: WARNING: overdue frame.\n"); } else if (buf->pts) - llprintf(LOG_PTS, "skip buf->pts = %lld (no vpts)\n", buf->pts); + llprintf(LOG_PTS, "skip buf->pts = %" PRId64 " (no vpts)\n", buf->pts); /* now write the content to the dxr3 mpeg device and, in a dramatic * break with open source tradition, check the return value diff --git a/src/dxr3/dxr3_mpeg_encoders.c b/src/dxr3/dxr3_mpeg_encoders.c index 85089567f..6fe2ff397 100644 --- a/src/dxr3/dxr3_mpeg_encoders.c +++ b/src/dxr3/dxr3_mpeg_encoders.c @@ -17,7 +17,7 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA * - * $Id: dxr3_mpeg_encoders.c,v 1.23 2005/02/09 20:03:22 tmattern Exp $ + * $Id: dxr3_mpeg_encoders.c,v 1.24 2005/11/28 12:24:57 valtri Exp $ */ /* mpeg encoders for the dxr3 video out plugin. @@ -29,7 +29,6 @@ #endif #ifdef HAVE_LIBRTE -# define _GNU_SOURCE # include <unistd.h> # include <rte.h> #endif diff --git a/src/input/input_cdda.c b/src/input/input_cdda.c index bb766d155..b28ec201d 100644 --- a/src/input/input_cdda.c +++ b/src/input/input_cdda.c @@ -20,7 +20,7 @@ * Compact Disc Digital Audio (CDDA) Input Plugin * by Mike Melanson (melanson@pcisys.net) * - * $Id: input_cdda.c,v 1.80 2005/11/15 13:29:10 miguelfreitas Exp $ + * $Id: input_cdda.c,v 1.81 2005/11/28 12:24:57 valtri Exp $ */ #ifdef HAVE_CONFIG_H @@ -32,7 +32,7 @@ #include <unistd.h> #include <sys/types.h> -#ifdef SYS_PARAM_H +#ifdef HAVE_SYS_PARAM_H #include <sys/param.h> #endif #ifdef HAVE_DIRENT_H diff --git a/src/input/input_dvb.c b/src/input/input_dvb.c index 3b4fe73b3..842f96a49 100644 --- a/src/input/input_dvb.c +++ b/src/input/input_dvb.c @@ -1013,11 +1013,11 @@ static int tuner_tune_it (tuner_t *this, struct dvb_frontend_parameters strength=0; if(ioctl(this->fd_frontend,FE_READ_SIGNAL_STRENGTH,&strength) >= 0) - xprintf(this->xine,XINE_VERBOSITY_LOG,"input_dvb: Signal strength: %i\n",strength); + xprintf(this->xine,XINE_VERBOSITY_LOG,"input_dvb: Signal strength: %u\n",strength); strength=0; if(ioctl(this->fd_frontend,FE_READ_SNR,&strength) >= 0) - xprintf(this->xine,XINE_VERBOSITY_LOG,"input_dvb: Signal/Noise Ratio: %i\n",strength); + xprintf(this->xine,XINE_VERBOSITY_LOG,"input_dvb: Signal/Noise Ratio: %u\n",strength); if (status & FE_HAS_LOCK && !(status & FE_TIMEDOUT)) { xprintf(this->xine,XINE_VERBOSITY_LOG,"input_dvb: Lock achieved at %lu Hz\n",(unsigned long)front_param->frequency); @@ -2406,7 +2406,7 @@ static off_t dvb_plugin_read (input_plugin_t *this_gen, return 0; dvb_event_handler (this); xprintf(this->class->xine,XINE_VERBOSITY_DEBUG, - "input_dvb: reading %lld bytes...\n", len); + "input_dvb: reading %" PRIdMAX " bytes...\n", (intmax_t)len); #ifndef DVB_NO_BUFFERING nbc_check_buffers (this->nbc); @@ -2459,8 +2459,8 @@ static off_t dvb_plugin_read (input_plugin_t *this_gen, } xprintf(this->class->xine,XINE_VERBOSITY_DEBUG, - "input_dvb: got %lld bytes (%lld/%lld bytes read)\n", - n, total,len); + "input_dvb: got %" PRIdMAX " bytes (%" PRIdMAX "/%" PRIdMAX " bytes read)\n", + (intmax_t)n, (intmax_t)total, (intmax_t)len); if (n > 0){ this->curpos += n; @@ -2517,7 +2517,7 @@ static off_t dvb_plugin_seek (input_plugin_t *this_gen, off_t offset, dvb_input_plugin_t *this = (dvb_input_plugin_t *) this_gen; - xprintf(this->class->xine,XINE_VERBOSITY_DEBUG,"seek %lld bytes, origin %d\n", offset, origin); + xprintf(this->class->xine,XINE_VERBOSITY_DEBUG,"seek %" PRIdMAX " bytes, origin %d\n", (intmax_t)offset, origin); /* only relative forward-seeking is implemented */ diff --git a/src/input/input_net.c b/src/input/input_net.c index 6dd9c8be4..1dd75efc1 100644 --- a/src/input/input_net.c +++ b/src/input/input_net.c @@ -20,7 +20,7 @@ * Read from a tcp network stream over a lan (put a tweaked mp1e encoder the * other end and you can watch tv anywhere in the house ..) * - * $Id: input_net.c,v 1.64 2005/10/14 21:02:16 miguelfreitas Exp $ + * $Id: input_net.c,v 1.65 2005/11/28 12:24:57 valtri Exp $ * * how to set up mp1e for use with this plugin: * @@ -253,7 +253,7 @@ static off_t net_plugin_read (input_plugin_t *this_gen, net_input_plugin_t *this = (net_input_plugin_t *) this_gen; off_t n, total; - lprintf("reading %d bytes...\n", len); + lprintf("reading %" PRIdMAX " bytes...\n", (intmax_t)len); total=0; if (this->curpos < this->preview_size) { @@ -261,7 +261,7 @@ static off_t net_plugin_read (input_plugin_t *this_gen, if (n > (len - total)) n = len - total; - lprintf("%lld bytes from preview (which has %lld bytes)\n", n, this->preview_size); + lprintf("%" PRIdMAX " bytes from preview (which has %" PRIdMAX " bytes)\n", (intmax_t)n, (intmax_t)this->preview_size); memcpy (&buf[total], &this->preview[this->curpos], n); this->curpos += n; diff --git a/src/input/input_pvr.c b/src/input/input_pvr.c index 1445f8a6d..5fd44a0c0 100644 --- a/src/input/input_pvr.c +++ b/src/input/input_pvr.c @@ -38,7 +38,7 @@ * usage: * xine pvr:/<prefix_to_tmp_files>\!<prefix_to_saved_files>\!<max_page_age> * - * $Id: input_pvr.c,v 1.56 2005/10/14 21:02:16 miguelfreitas Exp $ + * $Id: input_pvr.c,v 1.57 2005/11/28 12:24:57 valtri Exp $ */ /************************************************************************** @@ -646,7 +646,7 @@ static int pvr_rec_file(pvr_input_plugin_t *this) { pos = (off_t)(this->rec_blk - this->page_block[this->rec_page]) * PVR_BLOCK_SIZE; if( lseek (this->rec_fd, pos, SEEK_SET) != pos ) { xprintf(this->stream->xine, XINE_VERBOSITY_DEBUG, - "input_pvr: error setting position for writing %lld\n", pos); + "input_pvr: error setting position for writing %" PRIdMAX "\n", (intmax_t)pos); return 0; } if( this->rec_fd != -1 ) { @@ -772,7 +772,7 @@ static int pvr_play_file(pvr_input_plugin_t *this, fifo_buffer_t *fifo, uint8_t pos = (off_t)(this->play_blk - this->page_block[this->play_page]) * PVR_BLOCK_SIZE; if( lseek (this->play_fd, pos, SEEK_SET) != pos ) { xprintf(this->stream->xine, XINE_VERBOSITY_DEBUG, - "input_pvr: error setting position for reading %lld\n", pos); + "input_pvr: error setting position for reading %" PRIdMAX "\n", (intmax_t)pos); return 0; } if( read(this->play_fd, buffer, PVR_BLOCK_SIZE) < PVR_BLOCK_SIZE ) { diff --git a/src/input/net_buf_ctrl.c b/src/input/net_buf_ctrl.c index f5ad8148d..75743a070 100644 --- a/src/input/net_buf_ctrl.c +++ b/src/input/net_buf_ctrl.c @@ -118,11 +118,12 @@ void nbc_check_buffers (nbc_t *this) { } static void display_stats (nbc_t *this) { - char *buffering[2] = {" ", "buf"}; - char *enabled[2] = {"off", "on "}; + const char *buffering[2] = {" ", "buf"}; + const char *enabled[2] = {"off", "on "}; - printf("net_buf_ctrl: vid %3d%% %4.1fs %4lldkbps %1d, "\ - "aud %3d%% %4.1fs %4lldkbps %1d, %s %s\r", + printf("bufing: %d, enb: %d\n", this->buffering, this->enabled); + printf("net_buf_ctrl: vid %3d%% %4.1fs %4" PRId64 "kbps %1d, "\ + "aud %3d%% %4.1fs %4" PRId64 "kbps %1d, %s %s\r", this->video_fifo_fill, (float)(this->video_fifo_length / 1000), this->video_br / 1000, diff --git a/src/libsputext/xine_decoder.c b/src/libsputext/xine_decoder.c index c4100f0e0..66ae49372 100644 --- a/src/libsputext/xine_decoder.c +++ b/src/libsputext/xine_decoder.c @@ -17,7 +17,7 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA * - * $Id: xine_decoder.c,v 1.90 2005/05/29 10:18:23 valtri Exp $ + * $Id: xine_decoder.c,v 1.91 2005/11/28 12:24:57 valtri Exp $ * */ @@ -696,7 +696,7 @@ static void spudec_decode_data (spu_decoder_t *this_gen, buf_element_t *buf) { _x_get_current_info (this->stream->master, &extra_info, sizeof(extra_info) ); - lprintf("master: %d slave: %d input_normpos: %lld vo_discard: %d\n", + lprintf("master: %d slave: %d input_normpos: %d vo_discard: %d\n", master_status, slave_status, extra_info.input_normpos, vo_discard); if( !this->started && (master_status == XINE_STATUS_PLAY && diff --git a/src/post/deinterlace/tvtime.c b/src/post/deinterlace/tvtime.c index 31cf3f7c2..0c13329ff 100644 --- a/src/post/deinterlace/tvtime.c +++ b/src/post/deinterlace/tvtime.c @@ -20,7 +20,6 @@ # include "config.h" #endif -#define _GNU_SOURCE #include <stdio.h> #include <string.h> #include <unistd.h> diff --git a/src/post/goom/Makefile.am b/src/post/goom/Makefile.am index 85d6c165e..bb6496342 100644 --- a/src/post/goom/Makefile.am +++ b/src/post/goom/Makefile.am @@ -5,7 +5,8 @@ libdir = $(XINE_PLUGINDIR)/post EXTRA_DIST = mmx.c xmmx.c ppc_drawings.s ppc_zoom_ultimate.s diff_against_release.patch ## -fomit-frame-pointer segfaults here -CFLAGS = `echo @CFLAGS@ | sed -e 's/-fomit-frame-pointer//g;s/-Os//g'` +## Use -O2 if -Os is stripped or x86 does not build +CFLAGS = `echo @CFLAGS@ | sed -e 's/-fomit-frame-pointer//g;s/-Os/-O2/g'` lib_LTLIBRARIES = xineplug_post_goom.la diff --git a/src/video_out/video_out_sdl.c b/src/video_out/video_out_sdl.c index 5d0d96f8f..870bfd6c0 100644 --- a/src/video_out/video_out_sdl.c +++ b/src/video_out/video_out_sdl.c @@ -17,7 +17,7 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA * - * $Id: video_out_sdl.c,v 1.44 2005/09/25 00:44:04 miguelfreitas Exp $ + * $Id: video_out_sdl.c,v 1.45 2005/11/28 12:25:21 valtri Exp $ * * video_out_sdl.c, Simple DirectMedia Layer * @@ -47,7 +47,8 @@ #include <string.h> #include <inttypes.h> #include <math.h> -#if defined (__FreeBSD__) + +#ifdef HAVE_SDL11_SDL_H # include <SDL11/SDL.h> #else # include <SDL.h> diff --git a/src/xine-engine/input_cache.c b/src/xine-engine/input_cache.c index deec873d8..0b61c6c44 100644 --- a/src/xine-engine/input_cache.c +++ b/src/xine-engine/input_cache.c @@ -22,7 +22,7 @@ * The goal of this input plugin is to reduce * the number of calls to the real input plugin. * - * $Id: input_cache.c,v 1.8 2005/10/14 21:02:16 miguelfreitas Exp $ + * $Id: input_cache.c,v 1.9 2005/11/28 12:25:21 valtri Exp $ */ #ifdef HAVE_CONFIG_H @@ -258,7 +258,7 @@ static off_t cache_plugin_seek_time(input_plugin_t *this_gen, int time_offset, i cache_input_plugin_t *this = (cache_input_plugin_t *)this_gen; off_t cur_pos; - lprintf("time_offset: %ld, origin: %d\n", time_offset, origin); + lprintf("time_offset: %d, origin: %d\n", time_offset, origin); this->seek_call++; cur_pos = this->main_input_plugin->seek_time(this->main_input_plugin, time_offset, origin); diff --git a/src/xine-engine/load_plugins.c b/src/xine-engine/load_plugins.c index 24f51af45..f7f243938 100644 --- a/src/xine-engine/load_plugins.c +++ b/src/xine-engine/load_plugins.c @@ -17,7 +17,7 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA * - * $Id: load_plugins.c,v 1.216 2005/09/19 16:14:02 valtri Exp $ + * $Id: load_plugins.c,v 1.217 2005/11/28 12:25:21 valtri Exp $ * * * Load input/demux/audio_out/video_out/codec plugins @@ -794,8 +794,8 @@ static void save_plugin_list(FILE *fp, xine_list_t *plugins) { file = node->file; fprintf(fp, "[%s]\n", file->filename ); - fprintf(fp, "size=%llu\n", (uint64_t) file->filesize ); - fprintf(fp, "mtime=%llu\n", (uint64_t) file->filemtime ); + fprintf(fp, "size=%" PRId64 "\n", (uint64_t) file->filesize ); + fprintf(fp, "mtime=%" PRId64 "\n", (uint64_t) file->filemtime ); fprintf(fp, "type=%d\n", node->info->type ); fprintf(fp, "api=%d\n", node->info->API ); fprintf(fp, "id=%s\n", node->info->id ); @@ -913,10 +913,10 @@ static void load_plugin_list(FILE *fp, xine_list_t *plugins) { } } else if (node) { if( !strcmp("size",line) ) { - sscanf(value," %llu",&llu); + sscanf(value," %" SCNu64,&llu); file->filesize = (off_t) llu; } else if( !strcmp("mtime",line) ) { - sscanf(value," %llu",&llu); + sscanf(value," %" SCNu64,&llu); file->filemtime = (time_t) llu; } else if( !strcmp("type",line) ) { sscanf(value," %d",&i); diff --git a/src/xine-engine/osd.c b/src/xine-engine/osd.c index e1c47d198..505401ae2 100644 --- a/src/xine-engine/osd.c +++ b/src/xine-engine/osd.c @@ -967,7 +967,7 @@ static int osd_set_encoding (osd_object_t *osd, const char *encoding) { _("osd: can't find out current locale character set\n")); return 0; } - lprintf("locale encoding='%s'\n", osd, enc); + lprintf("locale encoding='%s'\n", enc); } else enc = strdup(encoding); diff --git a/src/xine-utils/memcpy.c b/src/xine-utils/memcpy.c index d448f4902..7b5b3a245 100644 --- a/src/xine-utils/memcpy.c +++ b/src/xine-utils/memcpy.c @@ -526,7 +526,7 @@ void xine_probe_fast_memcpy(xine_t *xine) t = rdtsc(config_flags) - t; memcpy_method[i].time = t; - xprintf(xine, XINE_VERBOSITY_LOG, "\t%s : %lld\n", memcpy_method[i].name, t); + xprintf(xine, XINE_VERBOSITY_LOG, "\t%s : %" PRIu64 "\n", memcpy_method[i].name, t); if( best == 0 || t < memcpy_method[best].time ) best = i; |