#
-# Copyright (C) 2007-2011 OpenWrt.org
+# Copyright (C) 2007-2014 OpenWrt.org
#
# This is free software, licensed under the GNU General Public License v2.
# See /LICENSE for more information.
include $(TOPDIR)/rules.mk
PKG_NAME:=mpd
-PKG_VERSION:=0.16.8
-PKG_RELEASE:=2
+PKG_VERSION:=0.17.6
+PKG_RELEASE:=4
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
-PKG_SOURCE_URL:=http://www.musicpd.org/download/mpd/0.16/
-PKG_MD5SUM:=b412a9d0b3457bea1bb87904a8f80c04
+PKG_SOURCE_URL:=http://www.musicpd.org/download/mpd/0.17/
+PKG_MD5SUM:=0a42ed81ff298c12e22c16be31097e4c
+PKG_MAINTAINER:=Ted Hess <thess@kitschensync.net>
PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(BUILD_VARIANT)/$(PKG_NAME)-$(PKG_VERSION)
PKG_BUILD_PARALLEL:=1
CATEGORY:=Sound
TITLE:=Music Player Daemon
URL:=http://www.musicpd.org/
- DEPENDS:= +glib2 +libcurl +libpthread \
- +libflac +BUILD_PATENTED:libmad +libvorbisidec
+ DEPENDS:= +glib2 +libcurl +libpthread $(ICONV_DEPENDS) \
+ +libflac +BUILD_PATENTED:libmad +libvorbisidec
endef
define Package/mpd/Default/description
gmpc (gnome), phpmp (php), etc...
endef
-
define Package/mpd-full
$(call Package/mpd/Default)
TITLE+= (full)
DEPENDS+= \
+AUDIO_SUPPORT:alsa-lib \
+libaudiofile +BUILD_PATENTED:libfaad2 +libffmpeg +libid3tag \
- +libmms +libogg +libshout +libsndfile +libvorbis
+ +libmms +libogg +libsndfile +libvorbis
PROVIDES:=mpd
VARIANT:=full
endef
/etc/mpd.conf
endef
-
define Package/mpd-mini
$(call Package/mpd/Default)
TITLE+= (mini)
/etc/mpd.conf
endef
-
CONFIGURE_ARGS += \
$(call autoconf_bool,CONFIG_IPV6,ipv6) \
--disable-debug \
\
--disable-ao \
--disable-bzip2 \
- --disable-cue \
+ --enable-cue \
--disable-ffado \
--disable-fluidsynth \
--disable-gme \
- --disable-inotify \
+ --enable-inotify \
--disable-iso9660 \
--disable-jack \
--disable-lame-encoder \
--disable-solaris-output \
--disable-sqlite \
--disable-twolame-encoder \
- --disable-wave-encoder \
+ --enable-wave-encoder \
--disable-wavpack \
--disable-wildmidi \
--disable-zzip \
- --with-zeroconf=no \
+ --with-zeroconf=auto \
\
--enable-curl \
--enable-flac \
$(if $(CONFIG_BUILD_PATENTED),MAD_LIBS="$(TARGET_LDFLAGS) -lmad") \
TARGET_CFLAGS += -std=gnu99
-TARGET_LDFLAGS += -Wl,-rpath-link=$(STAGING_DIR)/usr/lib
+TARGET_LDFLAGS += -Wl,-rpath-link=$(STAGING_DIR)/usr/lib $(if $(ICONV_FULL),-liconv)
# use gcc instead of g++ to avoid unnecessary linking against libstdc++
TARGET_CXX:=$(TARGET_CC)
--enable-oggflac \
--enable-pipe-output \
--enable-recorder-output \
- --enable-shout \
+ --disable-shout \
--enable-sndfile \
--enable-vorbis \
- --enable-vorbis-encoder \
+ --disable-vorbis-encoder \
--with-faad="$(STAGING_DIR)/usr" \
- --with-tremor=no \
+ --with-tremor=yes \
endif
--- a/configure
+++ b/configure
-@@ -8803,6 +8803,7 @@ fi
+@@ -9821,6 +9821,7 @@ fi
# Check whether --with-faad was given.
if test "${with_faad+set}" = set; then :
withval=$with_faad;
fi
--- a/src/input/file_input_plugin.c
+++ b/src/input/file_input_plugin.c
-@@ -79,10 +79,6 @@ input_file_open(const char *filename, GE
- return false;
+@@ -82,10 +82,6 @@ input_file_open(const char *filename,
+ return NULL;
}
-#ifdef POSIX_FADV_SEQUENTIAL
-#endif
-
fis = g_new(struct file_input_stream, 1);
- input_stream_init(&fis->base, &input_plugin_file, filename);
-
+ input_stream_init(&fis->base, &input_plugin_file, filename,
+ mutex, cond);
--- /dev/null
+--- a/src/decoder/ffmpeg_decoder_plugin.c
++++ b/src/decoder/ffmpeg_decoder_plugin.c
+@@ -370,6 +370,13 @@
+ #endif
+ return SAMPLE_FORMAT_S32;
+
++#if LIBAVCODEC_VERSION_INT >= AV_VERSION_INT(52, 94, 1)
++ case AV_SAMPLE_FMT_FLT:
++#else
++ case SAMPLE_FMT_FLOAT:
++#endif
++ return SAMPLE_FORMAT_FLOAT;
++
+ default:
+ g_warning("Unsupported libavcodec SampleFormat value: %d",
+ codec_context->sample_fmt);
--- /dev/null
+--- a/src/decoder/ffmpeg_decoder_plugin.c
++++ b/src/decoder/ffmpeg_decoder_plugin.c
+@@ -387,6 +387,13 @@ ffmpeg_probe(struct decoder *decoder, st
+
+ unsigned char *buffer = g_malloc(BUFFER_SIZE);
+ size_t nbytes = decoder_read(decoder, is, buffer, BUFFER_SIZE);
++
++ if ((nbytes > 0) && (nbytes < 1024))
++ {
++ // Gobble some more data if header is small
++ nbytes += decoder_read(decoder, is, buffer + nbytes, BUFFER_SIZE - nbytes);
++ }
++
+ if (nbytes <= PADDING ||
+ !input_stream_lock_seek(is, 0, SEEK_SET, NULL)) {
+ g_free(buffer);
+@@ -683,6 +690,7 @@ static const char *const ffmpeg_mime_typ
+ "audio/qcelp",
+ "audio/vorbis",
+ "audio/vorbis+ogg",
++ "audio/wav",
+ "audio/x-8svx",
+ "audio/x-16sv",
+ "audio/x-aac",