diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/audio_out/audio_sun_out.c | 12 | ||||
-rw-r--r-- | src/input/input_dvb.c | 7 | ||||
-rw-r--r-- | src/input/input_dvd.c | 12 | ||||
-rw-r--r-- | src/libmusepack/diff_against_svn.patch | 20 | ||||
-rw-r--r-- | src/libmusepack/musepack/internal.h | 2 |
5 files changed, 38 insertions, 15 deletions
diff --git a/src/audio_out/audio_sun_out.c b/src/audio_out/audio_sun_out.c index 93361d2f3..5923eb658 100644 --- a/src/audio_out/audio_sun_out.c +++ b/src/audio_out/audio_sun_out.c @@ -126,10 +126,10 @@ typedef struct sun_driver_s { #ifdef __svr4__ #if SW_SAMPLE_COUNT struct timeval tv0; - uint_t sample0; + size_t sample0; #endif - uint_t last_samplecnt; + size_t last_samplecnt; #endif } sun_driver_t; @@ -604,8 +604,8 @@ static int ao_sun_delay(ao_driver_t *this_gen) /* compute "current sample" based on real time */ { struct timeval tv1; - uint_t cur_sample; - uint_t msec; + size_t cur_sample; + size_t msec; gettimeofday(&tv1, NULL); @@ -807,7 +807,7 @@ static int ao_sun_get_property (ao_driver_t *this_gen, int property) { this->mixer_volume = info.play.gain * 100 / AUDIO_MAX_GAIN; } return this->mixer_volume; -#if !defined(__NetBSD__) /* audio_info.output_muted is missing on NetBSD */ +#ifdef HAVE_AUDIO_INFO_T_OUTPUT_MUTED case AO_PROP_MUTE_VOL: if (ioctl(this->audio_fd, AUDIO_GETINFO, &info) < 0) return 0; @@ -836,7 +836,7 @@ static int ao_sun_set_property (ao_driver_t *this_gen, int property, int value) if (ioctl(this->audio_fd, AUDIO_SETINFO, &info) < 0) return ~value; return value; -#if !defined(__NetBSD__) /* audio_info.output_muted is missing on NetBSD */ +#ifdef HAVE_AUDIO_INFO_T_OUTPUT_MUTED case AO_PROP_MUTE_VOL: info.output_muted = value != 0; if (ioctl(this->audio_fd, AUDIO_SETINFO, &info) < 0) diff --git a/src/input/input_dvb.c b/src/input/input_dvb.c index 39507ac15..10d6eca55 100644 --- a/src/input/input_dvb.c +++ b/src/input/input_dvb.c @@ -986,8 +986,13 @@ static int tuner_tune_it (tuner_t *this, struct dvb_frontend_parameters if (poll(pfd,1,3000)){ if (pfd[0].revents & POLLIN){ - if (ioctl(this->fd_frontend, FE_GET_EVENT, &event) == -EOVERFLOW){ +#ifdef EOVERFLOW + if (ioctl(this->fd_frontend, FE_GET_EVENT, &event) == -EOVERFLOW) { print_error("EOVERFLOW"); +#else + if (ioctl(this->fd_frontend, FE_GET_EVENT, &event) == -EINVAL) { + print_error("EINVAL"); +#endif return 0; } if (event.parameters.frequency <= 0) diff --git a/src/input/input_dvd.c b/src/input/input_dvd.c index 944ae88bd..de47de0d5 100644 --- a/src/input/input_dvd.c +++ b/src/input/input_dvd.c @@ -64,21 +64,17 @@ #endif /* WIN32 */ -#if defined(__NetBSD__) || defined(__OpenBSD__) || defined(__FreeBSD__) +#if defined(HAVE_LINUX_CDROM_H) +#include <linux/cdrom.h> +#elif defined(HAVE_SYS_DVDIO_H) #include <sys/dvdio.h> #include <sys/cdio.h> /* CDIOCALLOW etc... */ -#elif defined(HAVE_LINUX_CDROM_H) -#include <linux/cdrom.h> #elif defined(HAVE_SYS_CDIO_H) #include <sys/cdio.h> -#else - -#ifdef WIN32 +#elif defined(WIN32) #include <io.h> /* read() */ #else #warning "This might not compile due to missing cdrom ioctls" -#endif /* WIN32 */ - #endif /* DVDNAV includes */ diff --git a/src/libmusepack/diff_against_svn.patch b/src/libmusepack/diff_against_svn.patch index aca00556c..1d44efb95 100644 --- a/src/libmusepack/diff_against_svn.patch +++ b/src/libmusepack/diff_against_svn.patch @@ -1,5 +1,6 @@ Use xine's inttypes. The file config_types.h is generated from config_types.h.in in musepack SVN. +Check for previous swap32 definition before writing a new swap32 function. Index: src/libmusepack/musepack/config_types.h =================================================================== @@ -33,3 +34,22 @@ diff -u -r1.1 synth_filter.c /* C O N S T A N T S */ #undef _ +diff -r d25b274e6e6a src/libmusepack/musepack/internal.h +--- a/src/libmusepack/musepack/internal.h Wed Apr 04 13:41:11 2007 +0200 ++++ b/src/libmusepack/musepack/internal.h Wed Apr 04 13:42:45 2007 +0200 +@@ -8,6 +8,7 @@ enum { + MPC_DECODER_SYNTH_DELAY = 481 + }; + ++#ifndef swap32 + /// Big/little endian 32 bit byte swapping routine. + static inline + mpc_uint32_t swap32(mpc_uint32_t val) { +@@ -16,6 +17,7 @@ mpc_uint32_t swap32(mpc_uint32_t val) { + (mpc_uint32_t)src[0] | + ((mpc_uint32_t)src[1] << 8) | ((mpc_uint32_t)src[2] << 16) | ((mpc_uint32_t)src[3] << 24); + } ++#endif + + /// Searches for a ID3v2-tag and reads the length (in bytes) of it. + /// \param reader supplying raw stream data diff --git a/src/libmusepack/musepack/internal.h b/src/libmusepack/musepack/internal.h index 42a0e7156..f86b45bb3 100644 --- a/src/libmusepack/musepack/internal.h +++ b/src/libmusepack/musepack/internal.h @@ -8,6 +8,7 @@ enum { MPC_DECODER_SYNTH_DELAY = 481 }; +#ifndef swap32 /// Big/little endian 32 bit byte swapping routine. static inline mpc_uint32_t swap32(mpc_uint32_t val) { @@ -16,6 +17,7 @@ mpc_uint32_t swap32(mpc_uint32_t val) { (mpc_uint32_t)src[0] | ((mpc_uint32_t)src[1] << 8) | ((mpc_uint32_t)src[2] << 16) | ((mpc_uint32_t)src[3] << 24); } +#endif /// Searches for a ID3v2-tag and reads the length (in bytes) of it. /// \param reader supplying raw stream data |