Browse Source

Merge pull request #10052 from dhewg/pull/mpc

libmpdclient/mpc/mpd: update and build with meson
lilik-openwrt-22.03
Rosen Penev 5 years ago
committed by GitHub
parent
commit
d2c7a1193c
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
20 changed files with 114 additions and 1353 deletions
  1. +4
    -10
      libs/libmpdclient/Makefile
  2. +0
    -118
      libs/libmpdclient/autotools-files/Makefile.am
  3. +0
    -79
      libs/libmpdclient/autotools-files/config.h.in
  4. +0
    -162
      libs/libmpdclient/autotools-files/configure.ac
  5. +0
    -10
      libs/libmpdclient/autotools-files/libmpdclient.pc.in
  6. +0
    -74
      libs/libmpdclient/autotools-files/m4/ax_check_compiler_flags.m4
  7. +7
    -13
      sound/mpc/Makefile
  8. +0
    -33
      sound/mpc/autotools-files/Makefile.am
  9. +0
    -61
      sound/mpc/autotools-files/config.h.in
  10. +0
    -177
      sound/mpc/autotools-files/configure.ac
  11. +0
    -65
      sound/mpc/autotools-files/m4/ax_append_compile_flags.m4
  12. +0
    -71
      sound/mpc/autotools-files/m4/ax_append_flag.m4
  13. +0
    -63
      sound/mpc/autotools-files/m4/ax_append_link_flags.m4
  14. +0
    -74
      sound/mpc/autotools-files/m4/ax_check_compile_flag.m4
  15. +0
    -74
      sound/mpc/autotools-files/m4/ax_check_link_flag.m4
  16. +0
    -37
      sound/mpc/autotools-files/m4/ax_require_defined.m4
  17. +0
    -132
      sound/mpc/autotools-files/m4/check.m4
  18. +102
    -83
      sound/mpd/Makefile
  19. +1
    -1
      sound/mpd/patches/210-support_raw_pcm_streams.patch
  20. +0
    -16
      sound/mpd/patches/220-handle_slow_server_stream_startup.patch

+ 4
- 10
libs/libmpdclient/Makefile View File

@ -7,7 +7,7 @@ include $(TOPDIR)/rules.mk
PKG_NAME:=libmpdclient
PKG_VERSION:=2.16
PKG_RELEASE:=1
PKG_RELEASE:=2
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz
PKG_HASH:=fa6bdab67c0e0490302b38f00c27b4959735c3ec8aef7a88327adb1407654464
@ -17,10 +17,11 @@ PKG_MAINTAINER:=Ted Hess <thess@kitschensync.net>
PKG_LICENSE:=BSD-3-Clause
PKG_LICENSE_FILES:=COPYING
PKG_FIXUP:=autoreconf
PKG_BUILD_DEPENDS:=meson/host
PKG_INSTALL:=1
include $(INCLUDE_DIR)/package.mk
include ../../devel/meson/meson.mk
define Package/libmpdclient
TITLE:=libmpdclient
@ -33,14 +34,7 @@ define Package/libmpdclient/description
A stable, documented, asynchronous API library for interfacing MPD in the C, C++ & Objective C languages.
endef
CONFIGURE_ARGS+= --disable-documentation
# Newer sources require meson/ninja to build so...
# Use our hacked-up version of the libmpdclient v2.11 autotools.
define Build/Prepare
$(call Build/Prepare/Default)
$(CP) ./autotools-files/* $(PKG_BUILD_DIR)/
endef
MESON_ARGS+=-Ddocumentation=false
define Build/InstallDev
$(INSTALL_DIR) \


+ 0
- 118
libs/libmpdclient/autotools-files/Makefile.am View File

@ -1,118 +0,0 @@
ACLOCAL_AMFLAGS = -I m4
AUTOMAKE_OPTIONS = foreign 1.11 dist-xz subdir-objects
mpdincludedir = $(includedir)/mpd
mpdinclude_HEADERS = \
include/mpd/async.h \
include/mpd/audio_format.h \
include/mpd/client.h \
include/mpd/capabilities.h \
include/mpd/compiler.h \
include/mpd/connection.h \
include/mpd/database.h \
include/mpd/directory.h \
include/mpd/entity.h \
include/mpd/error.h \
include/mpd/idle.h \
include/mpd/list.h \
include/mpd/mixer.h \
include/mpd/mount.h \
include/mpd/parser.h \
include/mpd/password.h \
include/mpd/player.h \
include/mpd/playlist.h \
include/mpd/protocol.h \
include/mpd/queue.h \
include/mpd/recv.h \
include/mpd/response.h \
include/mpd/send.h \
include/mpd/status.h \
include/mpd/stats.h \
include/mpd/tag.h \
include/mpd/output.h \
include/mpd/pair.h \
include/mpd/search.h \
include/mpd/socket.h \
include/mpd/song.h \
include/mpd/sticker.h \
include/mpd/settings.h \
include/mpd/message.h \
include/mpd/version.h
AM_CPPFLAGS += -I$(srcdir)/include -Iinclude
lib_LTLIBRARIES = src/libmpdclient.la
src_libmpdclient_la_SOURCES = \
src/async.c src/iasync.h \
src/audio_format.c \
src/buffer.h \
src/internal.h \
src/ierror.c src/ierror.h \
src/resolver.c src/resolver.h \
src/capabilities.c \
src/connection.c \
src/database.c \
src/directory.c \
src/rdirectory.c \
src/error.c \
src/fd_util.c src/fd_util.h \
src/output.c \
src/coutput.c \
src/entity.c \
src/idle.c \
src/iso8601.h \
src/iso8601.c \
src/kvlist.c \
src/list.c \
src/mixer.c \
src/mount.c \
src/cmount.c \
src/parser.c \
src/password.c \
src/player.c \
src/playlist.c \
src/rplaylist.c \
src/cplaylist.c \
src/queue.c \
src/quote.c src/quote.h \
src/recv.c \
src/response.c \
src/run.c src/run.h \
src/search.c \
src/send.c src/isend.h \
src/socket.c src/socket.h \
src/song.c \
src/status.c \
src/cstatus.c \
src/stats.c \
src/cstats.c \
src/sync.c src/sync.h \
src/tag.c \
src/sticker.c \
src/settings.c \
src/message.c \
src/cmessage.c \
src/uri.h
src_libmpdclient_la_LDFLAGS = -version-info @LIBMPDCLIENT_LIBTOOL_VERSION@ \
-no-undefined
if HAVE_GNU_LD
src_libmpdclient_la_LDFLAGS += -Wl,--version-script=$(srcdir)/libmpdclient.ld
endif
#
# Installation
#
pkgconfigdir = $(libdir)/pkgconfig
pkgconfig_DATA = libmpdclient.pc
#
# Distribution
#
EXTRA_DIST = \
libmpdclient.ld \
libmpdclient.pc.in

+ 0
- 79
libs/libmpdclient/autotools-files/config.h.in View File

@ -1,79 +0,0 @@
/* config.h.in. Generated from configure.ac by autoheader. */
/* Default MPD host */
#undef DEFAULT_HOST
/* Default MPD port */
#undef DEFAULT_PORT
/* Default UNIX socket path */
#undef DEFAULT_SOCKET
/* Define to enable TCP support */
#undef ENABLE_TCP
/* Define to 1 if you have the <dlfcn.h> header file. */
#undef HAVE_DLFCN_H
/* Define to 1 if you have the `getaddrinfo' function. */
#undef HAVE_GETADDRINFO
/* Define to 1 if you have the <inttypes.h> header file. */
#undef HAVE_INTTYPES_H
/* Define to 1 if you have the <memory.h> header file. */
#undef HAVE_MEMORY_H
/* Define to 1 if you have the <stdint.h> header file. */
#undef HAVE_STDINT_H
/* Define to 1 if you have the <stdlib.h> header file. */
#undef HAVE_STDLIB_H
/* Define to 1 if you have the <strings.h> header file. */
#undef HAVE_STRINGS_H
/* Define to 1 if you have the <string.h> header file. */
#undef HAVE_STRING_H
/* Define to 1 if you have the `strndup' function. */
#undef HAVE_STRNDUP
/* Define to 1 if you have the <sys/stat.h> header file. */
#undef HAVE_SYS_STAT_H
/* Define to 1 if you have the <sys/types.h> header file. */
#undef HAVE_SYS_TYPES_H
/* Define to 1 if you have the <unistd.h> header file. */
#undef HAVE_UNISTD_H
/* Define to the sub-directory where libtool stores uninstalled libraries. */
#undef LT_OBJDIR
/* Name of package */
#undef PACKAGE
/* Define to the address where bug reports for this package should be sent. */
#undef PACKAGE_BUGREPORT
/* Define to the full name of this package. */
#undef PACKAGE_NAME
/* Define to the full name and version of this package. */
#undef PACKAGE_STRING
/* Define to the one symbol short name of this package. */
#undef PACKAGE_TARNAME
/* Define to the home page for this package. */
#undef PACKAGE_URL
/* Define to the version of this package. */
#undef PACKAGE_VERSION
/* Define to 1 if you have the ANSI C header files. */
#undef STDC_HEADERS
/* Version number of package */
#undef VERSION

+ 0
- 162
libs/libmpdclient/autotools-files/configure.ac View File

@ -1,162 +0,0 @@
AC_PREREQ(2.60)
AC_INIT(libmpdclient, 2.16, musicpd-dev-team@lists.sourceforge.net)
AC_CONFIG_SRCDIR([src/connection.c])
AC_CONFIG_AUX_DIR(build)
AM_INIT_AUTOMAKE([foreign 1.11 dist-xz subdir-objects silent-rules])
AC_CONFIG_HEADERS([config.h])
AC_CONFIG_MACRO_DIR([m4])
AC_SUBST(MAJOR_VERSION,2)
AC_SUBST(MINOR_VERSION,16)
AC_SUBST(PATCH_VERSION,0)
LIBMPDCLIENT_LIBTOOL_VERSION=2:16:0
AC_SUBST(LIBMPDCLIENT_LIBTOOL_VERSION)
# Remove the check for c++ and fortran compiler
m4_defun([_LT_AC_LANG_CXX_CONFIG], [:])
m4_defun([_LT_AC_LANG_F77_CONFIG], [:])
dnl Check for programs
AC_PROG_CC_C99
AC_PROG_INSTALL
AC_PROG_LD
AM_CONDITIONAL(HAVE_GNU_LD, test x$with_gnu_ld = xyes)
AC_LIBTOOL_WIN32_DLL
AC_PROG_LIBTOOL
dnl
dnl initialize variables
dnl
set -- $CFLAGS
dnl
dnl OS specific defaults
dnl
AC_CANONICAL_HOST
case "$host_os" in
mingw32* | windows*)
LIBS="$LIBS -lws2_32"
;;
esac
dnl
dnl Check for libraries
dnl
AC_SEARCH_LIBS([socket], [network socket])
dnl
dnl build options
dnl
AC_ARG_ENABLE(documentation,
AS_HELP_STRING([--disable-documentation],
[Disable API doc generation @<:@default=enabled@:>@]),,
[enable_documentation=yes])
if test "x$enable_documentation" = xyes; then
AC_PATH_PROG(DOXYGEN, doxygen)
if test x$DOXYGEN = x; then
AC_MSG_ERROR([doxygen not found])
fi
AC_SUBST(DOXYGEN)
fi
AM_CONDITIONAL(DOXYGEN, test x$enable_documentation = xyes)
AC_ARG_ENABLE(tcp,
AS_HELP_STRING([--disable-tcp],
[Disable TCP support @<:@default=enabled@:>@]),,
[enable_tcp=yes])
if test "x$enable_tcp" = xyes; then
AC_DEFINE([ENABLE_TCP], 1, [Define to enable TCP support])
AC_SEARCH_LIBS([gethostbyname], [nsl])
AC_CHECK_FUNCS([getaddrinfo])
AC_CHECK_FUNCS([strndup])
fi
AC_ARG_ENABLE(werror,
AS_HELP_STRING([--enable-werror],
[Treat warnings as errors @<:@default=disabled@:>@]),
enable_werror=no)
if test "x$enable_werror" = xyes; then
AM_CFLAGS="$AM_CFLAGS -Werror -pedantic-errors"
fi
AC_ARG_ENABLE(debug,
AS_HELP_STRING([--enable-debug],
[Enable debugging @<:@default=disabled@:>@]),
enable_debug=no)
if test "x$enable_debug" = xno; then
AM_CFLAGS="$AM_CFLAGS -DNDEBUG"
fi
dnl
dnl CFLAGS
dnl
AC_SUBST(AM_CFLAGS)
AC_SUBST(AM_CPPFLAGS)
WANTED_CFLAGS="-Wall -W -Wextra -Wno-deprecated-declarations -Wmissing-prototypes -Wshadow -Wpointer-arith -Wstrict-prototypes -Wcast-qual -Wwrite-strings"
for flag in $WANTED_CFLAGS ; do
AX_CHECK_COMPILER_FLAGS([$flag], [CFLAGS="$CFLAGS $flag"],)
done
dnl
dnl Compile-time options
dnl
AC_ARG_WITH([default-socket],
AC_HELP_STRING([--with-default-socket=PATH],
[default path of the socket file @<:@/var/run/mpd/socket@:>@]),,
[with_default_socket=auto])
if test x$with_default_socket = xauto; then
case "$host_os" in
mingw32* | windows*)
# no UNIX domain sockets on WIN32
with_default_socket=no
;;
*)
with_default_socket=/var/run/mpd/socket
;;
esac
fi
if test x$with_default_socket != xno; then
AC_DEFINE_UNQUOTED([DEFAULT_SOCKET], ["$with_default_socket"],
[Default UNIX socket path])
fi
AC_ARG_WITH([default-host],
AC_HELP_STRING([--with-default-host=ARG],
[default MPD host @<:@localhost@:>@]),,
[with_default_host=localhost])
AC_DEFINE_UNQUOTED([DEFAULT_HOST], ["$with_default_host"], [Default MPD host])
AC_ARG_WITH([default-port],
AC_HELP_STRING([--with-default-port=ARG],
[default MPD port @<:@6600@:>@]),,
[with_default_port=6600])
AC_DEFINE_UNQUOTED([DEFAULT_PORT], [$with_default_port], [Default MPD port])
dnl
dnl Done
dnl
AC_OUTPUT([Makefile include/mpd/version.h libmpdclient.pc doc/doxygen.conf])

+ 0
- 10
libs/libmpdclient/autotools-files/libmpdclient.pc.in View File

@ -1,10 +0,0 @@
prefix=@prefix@
exec_prefix=@exec_prefix@
libdir=@libdir@
includedir=@includedir@
Name: libmpdclient
Description: Music Player Daemon client library
Version: @VERSION@
Libs: -L${libdir} -lmpdclient
Cflags: -I${includedir}

+ 0
- 74
libs/libmpdclient/autotools-files/m4/ax_check_compiler_flags.m4 View File

@ -1,74 +0,0 @@
# ===========================================================================
# http://www.nongnu.org/autoconf-archive/ax_check_compiler_flags.html
# ===========================================================================
#
# SYNOPSIS
#
# AX_CHECK_COMPILER_FLAGS(FLAGS, [ACTION-SUCCESS], [ACTION-FAILURE])
#
# DESCRIPTION
#
# Check whether the given compiler FLAGS work with the current language's
# compiler, or whether they give an error. (Warnings, however, are
# ignored.)
#
# ACTION-SUCCESS/ACTION-FAILURE are shell commands to execute on
# success/failure.
#
# LICENSE
#
# Copyright (c) 2009 Steven G. Johnson <stevenj@alum.mit.edu>
# Copyright (c) 2009 Matteo Frigo
#
# This program is free software: you can redistribute it and/or modify it
# under the terms of the GNU General Public License as published by the
# Free Software Foundation, either version 3 of the License, or (at your
# option) any later version.
#
# This program is distributed in the hope that it will be useful, but
# WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General
# Public License for more details.
#
# You should have received a copy of the GNU General Public License along
# with this program. If not, see <http://www.gnu.org/licenses/>.
#
# As a special exception, the respective Autoconf Macro's copyright owner
# gives unlimited permission to copy, distribute and modify the configure
# scripts that are the output of Autoconf when processing the Macro. You
# need not follow the terms of the GNU General Public License when using
# or distributing such scripts, even though portions of the text of the
# Macro appear in them. The GNU General Public License (GPL) does govern
# all other use of the material that constitutes the Autoconf Macro.
#
# This special exception to the GPL applies to versions of the Autoconf
# Macro released by the Autoconf Archive. When you make and distribute a
# modified version of the Autoconf Macro, you may extend this special
# exception to the GPL to apply to your modified version as well.
AC_DEFUN([AX_CHECK_COMPILER_FLAGS],
[AC_PREREQ(2.59) dnl for _AC_LANG_PREFIX
AC_MSG_CHECKING([whether _AC_LANG compiler accepts $1])
dnl Some hackery here since AC_CACHE_VAL can't handle a non-literal varname:
AS_LITERAL_IF([$1],
[AC_CACHE_VAL(AS_TR_SH(ax_cv_[]_AC_LANG_ABBREV[]_flags_[$1]), [
ax_save_FLAGS=$[]_AC_LANG_PREFIX[]FLAGS
_AC_LANG_PREFIX[]FLAGS="$1"
AC_COMPILE_IFELSE([AC_LANG_PROGRAM()],
AS_TR_SH(ax_cv_[]_AC_LANG_ABBREV[]_flags_[$1])=yes,
AS_TR_SH(ax_cv_[]_AC_LANG_ABBREV[]_flags_[$1])=no)
_AC_LANG_PREFIX[]FLAGS=$ax_save_FLAGS])],
[ax_save_FLAGS=$[]_AC_LANG_PREFIX[]FLAGS
_AC_LANG_PREFIX[]FLAGS="$1"
AC_COMPILE_IFELSE([AC_LANG_PROGRAM()],
eval AS_TR_SH(ax_cv_[]_AC_LANG_ABBREV[]_flags_[$1])=yes,
eval AS_TR_SH(ax_cv_[]_AC_LANG_ABBREV[]_flags_[$1])=no)
_AC_LANG_PREFIX[]FLAGS=$ax_save_FLAGS])
eval ax_check_compiler_flags=$AS_TR_SH(ax_cv_[]_AC_LANG_ABBREV[]_flags_[$1])
AC_MSG_RESULT($ax_check_compiler_flags)
if test "x$ax_check_compiler_flags" = xyes; then
m4_default([$2], :)
else
m4_default([$3], :)
fi
])dnl AX_CHECK_COMPILER_FLAGS

+ 7
- 13
sound/mpc/Makefile View File

@ -6,21 +6,24 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=mpc
PKG_VERSION:=0.30
PKG_RELEASE:=3
PKG_VERSION:=0.32
PKG_RELEASE:=1
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz
PKG_SOURCE_URL:=https://www.musicpd.org/download/mpc/0
PKG_HASH:=65fc5b0a8430efe9acbe6e261127960682764b20ab994676371bdc797d867fce
PKG_HASH:=7961d95b7ce019996beab281cf957e905667c989c53fffd13ade5e62fea331c7
PKG_LICENSE:=GPL-2.0-or-later
PKG_LICENSE_FILES:=COPYING
PKG_MAINTAINER:=Ted Hess <thess@kitschensync.net>
PKG_FIXUP:=autoreconf
PKG_BUILD_DEPENDS:=meson/host
PKG_INSTALL:=1
include $(INCLUDE_DIR)/package.mk
include ../../devel/meson/meson.mk
MESON_ARGS+=-Diconv=disabled -Ddocumentation=disabled
define Package/mpc
SECTION:=sound
@ -37,15 +40,6 @@ define Package/mpc/description
this is MPC
endef
CONFIGURE_ARGS+= --disable-iconv
# Newer sources require meson/ninja to build so...
# Use our hacked-up version of the mpc v0.28 autotools.
define Build/Prepare
$(call Build/Prepare/Default)
$(CP) ./autotools-files/* $(PKG_BUILD_DIR)/
endef
define Package/mpc/install
$(INSTALL_DIR) $(1)/usr/bin
$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/mpc $(1)/usr/bin/


+ 0
- 33
sound/mpc/autotools-files/Makefile.am View File

@ -1,33 +0,0 @@
ACLOCAL_AMFLAGS = -I m4
AUTOMAKE_OPTIONS = foreign 1.11 dist-xz subdir-objects
bin_PROGRAMS = src/mpc
src_mpc_SOURCES = \
src/main.c src/mpc.h \
src/list.c src/list.h \
src/password.c src/password.h \
src/status.c src/status.h \
src/args.c src/args.h \
src/format.c src/format.h \
src/song_format.c src/song_format.h \
src/util.c src/util.h \
src/command.c src/command.h \
src/queue.c src/queue.h \
src/sticker.c src/sticker.h \
src/tab.c src/tab.h \
src/idle.c src/idle.h \
src/message.c src/message.h \
src/search.c src/search.h \
src/output.c src/output.h \
src/options.c src/options.h \
src/path.c src/path.h \
src/Compiler.h
if HAVE_ICONV
src_mpc_SOURCES += src/charset.c src/charset.h
endif
src_mpc_CPPFLAGS = $(AM_CPPFLAGS) $(ICONV_CFLAGS) $(LIBMPDCLIENT_CFLAGS)
src_mpc_LDADD = $(ICONV_LIBS) $(LIBMPDCLIENT_LIBS)

+ 0
- 61
sound/mpc/autotools-files/config.h.in View File

@ -1,61 +0,0 @@
/* config.h.in. Generated from configure.ac by autoheader. */
/* Define if iconv() support is enabled */
#undef HAVE_ICONV
/* Define to 1 if you have the <inttypes.h> header file. */
#undef HAVE_INTTYPES_H
/* Define if you have <langinfo.h> and nl_langinfo(CODESET). */
#undef HAVE_LANGINFO_CODESET
/* Define to 1 if you have the <memory.h> header file. */
#undef HAVE_MEMORY_H
/* Define to 1 if you have the <stdint.h> header file. */
#undef HAVE_STDINT_H
/* Define to 1 if you have the <stdlib.h> header file. */
#undef HAVE_STDLIB_H
/* Define to 1 if you have the <strings.h> header file. */
#undef HAVE_STRINGS_H
/* Define to 1 if you have the <string.h> header file. */
#undef HAVE_STRING_H
/* Define to 1 if you have the <sys/stat.h> header file. */
#undef HAVE_SYS_STAT_H
/* Define to 1 if you have the <sys/types.h> header file. */
#undef HAVE_SYS_TYPES_H
/* Define to 1 if you have the <unistd.h> header file. */
#undef HAVE_UNISTD_H
/* Name of package */
#undef PACKAGE
/* Define to the address where bug reports for this package should be sent. */
#undef PACKAGE_BUGREPORT
/* Define to the full name of this package. */
#undef PACKAGE_NAME
/* Define to the full name and version of this package. */
#undef PACKAGE_STRING
/* Define to the one symbol short name of this package. */
#undef PACKAGE_TARNAME
/* Define to the home page for this package. */
#undef PACKAGE_URL
/* Define to the version of this package. */
#undef PACKAGE_VERSION
/* Define to 1 if you have the ANSI C header files. */
#undef STDC_HEADERS
/* Version number of package */
#undef VERSION

+ 0
- 177
sound/mpc/autotools-files/configure.ac View File

@ -1,177 +0,0 @@
AC_PREREQ(2.60)
AC_INIT(mpc, 0.30, musicpd-dev-team@lists.sourceforge.net)
AC_CONFIG_MACRO_DIR([m4])
AC_CONFIG_SRCDIR(src/main.c)
AM_INIT_AUTOMAKE([foreign 1.11 dist-xz subdir-objects])
AM_SILENT_RULES
AC_CONFIG_HEADERS(config.h)
dnl
dnl programs
dnl
AC_PROG_CC_C99
AC_PROG_INSTALL
AC_PROG_MAKE_SET
PKG_PROG_PKG_CONFIG
dnl
dnl declare variables
dnl
AC_SUBST(AM_CFLAGS)
AC_SUBST(AM_CPPFLAGS)
dnl
dnl OS specific defaults
dnl
case "$host" in
*-mingw32* | *-windows* | *-cygwin*)
AM_CFLAGS="$AM_CFLAGS -mms-bitfields -fno-strict-aliasing"
;;
esac
if test -z "$prefix" || test "x$prefix" = xNONE; then
local_lib=
local_include=
# aren't autotools supposed to be smart enough to figure this out?
# oh well, the git-core Makefile managed to do some of the work for us :)
case "`uname -s | tr A-Z a-z`" in
darwin*)
local_lib='/sw/lib /opt/local/lib'
local_include='/sw/include /opt/local/include'
;;
freebsd* | openbsd*)
local_lib=/usr/local/lib
local_include=/usr/local/include
;;
netbsd*)
local_lib=/usr/pkg/lib
local_include=/usr/pkg/include
LDFLAGS="$LDFLAGS -Wl,-rpath,/usr/pkg/lib"
;;
esac
for d in $local_lib; do
if test -d "$d"; then
LDFLAGS="$LDFLAGS -L$d"
break
fi
done
for d in $local_include; do
if test -d "$d"; then
CFLAGS="$CFLAGS -I$d"
break
fi
done
fi
dnl
dnl libc features
dnl
PKG_CHECK_MODULES([LIBMPDCLIENT], [libmpdclient >= 2.9],,
[AC_MSG_ERROR([libmpdclient 2.9 is required])])
dnl
dnl i18n / l10n (iconv)
dnl
AC_ARG_ENABLE(iconv,
AS_HELP_STRING([--disable-iconv],
[disable iconv support (default: enable)]),,
[enable_iconv=yes])
if test x$enable_iconv = xyes; then
AC_CHECK_FUNC(iconv,
[ICONV_CFLAGS="" ICONV_LIBS=""],
[AC_CHECK_LIB(intl, iconv,
[ICONV_CFLAGS="" ICONV_LIBS="-lintl"],
[enable_iconv=no])])
fi
if test x$enable_iconv = xyes; then
AC_CHECK_HEADER([locale.h],, [enable_iconv=no])
if test x$enable_iconv != xyes; then
AC_MSG_WARN(locale.h not available - disabling iconv)
fi
fi
if test x$enable_iconv = xyes; then
AC_DEFINE(HAVE_ICONV, 1, [Define if iconv() support is enabled])
else
ICONV_CPPFLAGS=""
ICONV_LIBS=""
fi
AC_SUBST(ICONV_CPPFLAGS)
AC_SUBST(ICONV_LIBS)
AM_CONDITIONAL(HAVE_ICONV, test x$enable_iconv = xyes)
dnl
dnl CFLAGS
dnl
AX_APPEND_COMPILE_FLAGS([-Wall])
AX_APPEND_COMPILE_FLAGS([-Wextra])
AX_APPEND_COMPILE_FLAGS([-Wno-deprecated-declarations])
AX_APPEND_COMPILE_FLAGS([-Wmissing-prototypes])
AX_APPEND_COMPILE_FLAGS([-Wshadow])
AX_APPEND_COMPILE_FLAGS([-Wpointer-arith])
AX_APPEND_COMPILE_FLAGS([-Wstrict-prototypes])
AX_APPEND_COMPILE_FLAGS([-Wcast-qual])
AX_APPEND_COMPILE_FLAGS([-Wwrite-strings])
dnl
dnl build options
dnl
AC_ARG_ENABLE(werror,
AS_HELP_STRING([--enable-werror],
[Treat warnings as errors @<:@default=disabled@:>@]),,
enable_werror=no)
if test "x$enable_werror" = xyes; then
AM_CFLAGS="$AM_CFLAGS -Werror -pedantic-errors"
fi
AC_ARG_ENABLE(debug,
AS_HELP_STRING([--enable-debug],
[Enable debugging @<:@default=disabled@:>@]),,
enable_debug=no)
if test "x$enable_debug" = xno; then
AM_CPPFLAGS="$AM_CPPFLAGS -DNDEBUG"
AX_APPEND_COMPILE_FLAGS([-ffunction-sections])
AX_APPEND_COMPILE_FLAGS([-fdata-sections])
AX_APPEND_COMPILE_FLAGS([-fvisibility=hidden])
AX_APPEND_LINK_FLAGS([-Wl,--gc-sections])
fi
AC_ARG_ENABLE(test,
AS_HELP_STRING([--enable-test],
[build the test programs (default: disabled)]),,
enable_test=no)
if test "x$enable_test" = xyes; then
AM_PATH_CHECK(,, [AC_MSG_ERROR([check not found])])
fi
AM_CONDITIONAL(ENABLE_TEST, test "x$enable_test" = xyes)
dnl
AC_OUTPUT(Makefile)

+ 0
- 65
sound/mpc/autotools-files/m4/ax_append_compile_flags.m4 View File

@ -1,65 +0,0 @@
# ===========================================================================
# http://www.gnu.org/software/autoconf-archive/ax_append_compile_flags.html
# ===========================================================================
#
# SYNOPSIS
#
# AX_APPEND_COMPILE_FLAGS([FLAG1 FLAG2 ...], [FLAGS-VARIABLE], [EXTRA-FLAGS])
#
# DESCRIPTION
#
# For every FLAG1, FLAG2 it is checked whether the compiler works with the
# flag. If it does, the flag is added FLAGS-VARIABLE
#
# If FLAGS-VARIABLE is not specified, the current language's flags (e.g.
# CFLAGS) is used. During the check the flag is always added to the
# current language's flags.
#
# If EXTRA-FLAGS is defined, it is added to the current language's default
# flags (e.g. CFLAGS) when the check is done. The check is thus made with
# the flags: "CFLAGS EXTRA-FLAGS FLAG". This can for example be used to
# force the compiler to issue an error when a bad flag is given.
#
# NOTE: This macro depends on the AX_APPEND_FLAG and
# AX_CHECK_COMPILE_FLAG. Please keep this macro in sync with
# AX_APPEND_LINK_FLAGS.
#
# LICENSE
#
# Copyright (c) 2011 Maarten Bosmans <mkbosmans@gmail.com>
#
# This program is free software: you can redistribute it and/or modify it
# under the terms of the GNU General Public License as published by the
# Free Software Foundation, either version 3 of the License, or (at your
# option) any later version.
#
# This program is distributed in the hope that it will be useful, but
# WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General
# Public License for more details.
#
# You should have received a copy of the GNU General Public License along
# with this program. If not, see <http://www.gnu.org/licenses/>.
#
# As a special exception, the respective Autoconf Macro's copyright owner
# gives unlimited permission to copy, distribute and modify the configure
# scripts that are the output of Autoconf when processing the Macro. You
# need not follow the terms of the GNU General Public License when using
# or distributing such scripts, even though portions of the text of the
# Macro appear in them. The GNU General Public License (GPL) does govern
# all other use of the material that constitutes the Autoconf Macro.
#
# This special exception to the GPL applies to versions of the Autoconf
# Macro released by the Autoconf Archive. When you make and distribute a
# modified version of the Autoconf Macro, you may extend this special
# exception to the GPL to apply to your modified version as well.
#serial 4
AC_DEFUN([AX_APPEND_COMPILE_FLAGS],
[AX_REQUIRE_DEFINED([AX_CHECK_COMPILE_FLAG])
AX_REQUIRE_DEFINED([AX_APPEND_FLAG])
for flag in $1; do
AX_CHECK_COMPILE_FLAG([$flag], [AX_APPEND_FLAG([$flag], [$2])], [], [$3])
done
])dnl AX_APPEND_COMPILE_FLAGS

+ 0
- 71
sound/mpc/autotools-files/m4/ax_append_flag.m4 View File

@ -1,71 +0,0 @@
# ===========================================================================
# http://www.gnu.org/software/autoconf-archive/ax_append_flag.html
# ===========================================================================
#
# SYNOPSIS
#
# AX_APPEND_FLAG(FLAG, [FLAGS-VARIABLE])
#
# DESCRIPTION
#
# FLAG is appended to the FLAGS-VARIABLE shell variable, with a space
# added in between.
#
# If FLAGS-VARIABLE is not specified, the current language's flags (e.g.
# CFLAGS) is used. FLAGS-VARIABLE is not changed if it already contains
# FLAG. If FLAGS-VARIABLE is unset in the shell, it is set to exactly
# FLAG.
#
# NOTE: Implementation based on AX_CFLAGS_GCC_OPTION.
#
# LICENSE
#
# Copyright (c) 2008 Guido U. Draheim <guidod@gmx.de>
# Copyright (c) 2011 Maarten Bosmans <mkbosmans@gmail.com>
#
# This program is free software: you can redistribute it and/or modify it
# under the terms of the GNU General Public License as published by the
# Free Software Foundation, either version 3 of the License, or (at your
# option) any later version.
#
# This program is distributed in the hope that it will be useful, but
# WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General
# Public License for more details.
#
# You should have received a copy of the GNU General Public License along
# with this program. If not, see <http://www.gnu.org/licenses/>.
#
# As a special exception, the respective Autoconf Macro's copyright owner
# gives unlimited permission to copy, distribute and modify the configure
# scripts that are the output of Autoconf when processing the Macro. You
# need not follow the terms of the GNU General Public License when using
# or distributing such scripts, even though portions of the text of the
# Macro appear in them. The GNU General Public License (GPL) does govern
# all other use of the material that constitutes the Autoconf Macro.
#
# This special exception to the GPL applies to versions of the Autoconf
# Macro released by the Autoconf Archive. When you make and distribute a
# modified version of the Autoconf Macro, you may extend this special
# exception to the GPL to apply to your modified version as well.
#serial 6
AC_DEFUN([AX_APPEND_FLAG],
[dnl
AC_PREREQ(2.64)dnl for _AC_LANG_PREFIX and AS_VAR_SET_IF
AS_VAR_PUSHDEF([FLAGS], [m4_default($2,_AC_LANG_PREFIX[FLAGS])])
AS_VAR_SET_IF(FLAGS,[
AS_CASE([" AS_VAR_GET(FLAGS) "],
[*" $1 "*], [AC_RUN_LOG([: FLAGS already contains $1])],
[
AS_VAR_APPEND(FLAGS,[" $1"])
AC_RUN_LOG([: FLAGS="$FLAGS"])
])
],
[
AS_VAR_SET(FLAGS,[$1])
AC_RUN_LOG([: FLAGS="$FLAGS"])
])
AS_VAR_POPDEF([FLAGS])dnl
])dnl AX_APPEND_FLAG

+ 0
- 63
sound/mpc/autotools-files/m4/ax_append_link_flags.m4 View File

@ -1,63 +0,0 @@
# ===========================================================================
# http://www.gnu.org/software/autoconf-archive/ax_append_link_flags.html
# ===========================================================================
#
# SYNOPSIS
#
# AX_APPEND_LINK_FLAGS([FLAG1 FLAG2 ...], [FLAGS-VARIABLE], [EXTRA-FLAGS])
#
# DESCRIPTION
#
# For every FLAG1, FLAG2 it is checked whether the linker works with the
# flag. If it does, the flag is added FLAGS-VARIABLE
#
# If FLAGS-VARIABLE is not specified, the linker's flags (LDFLAGS) is
# used. During the check the flag is always added to the linker's flags.
#
# If EXTRA-FLAGS is defined, it is added to the linker's default flags
# when the check is done. The check is thus made with the flags: "LDFLAGS
# EXTRA-FLAGS FLAG". This can for example be used to force the linker to
# issue an error when a bad flag is given.
#
# NOTE: This macro depends on the AX_APPEND_FLAG and AX_CHECK_LINK_FLAG.
# Please keep this macro in sync with AX_APPEND_COMPILE_FLAGS.
#
# LICENSE
#
# Copyright (c) 2011 Maarten Bosmans <mkbosmans@gmail.com>
#
# This program is free software: you can redistribute it and/or modify it
# under the terms of the GNU General Public License as published by the
# Free Software Foundation, either version 3 of the License, or (at your
# option) any later version.
#
# This program is distributed in the hope that it will be useful, but
# WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General
# Public License for more details.
#
# You should have received a copy of the GNU General Public License along
# with this program. If not, see <http://www.gnu.org/licenses/>.
#
# As a special exception, the respective Autoconf Macro's copyright owner
# gives unlimited permission to copy, distribute and modify the configure
# scripts that are the output of Autoconf when processing the Macro. You
# need not follow the terms of the GNU General Public License when using
# or distributing such scripts, even though portions of the text of the
# Macro appear in them. The GNU General Public License (GPL) does govern
# all other use of the material that constitutes the Autoconf Macro.
#
# This special exception to the GPL applies to versions of the Autoconf
# Macro released by the Autoconf Archive. When you make and distribute a
# modified version of the Autoconf Macro, you may extend this special
# exception to the GPL to apply to your modified version as well.
#serial 4
AC_DEFUN([AX_APPEND_LINK_FLAGS],
[AX_REQUIRE_DEFINED([AX_CHECK_LINK_FLAG])
AX_REQUIRE_DEFINED([AX_APPEND_FLAG])
for flag in $1; do
AX_CHECK_LINK_FLAG([$flag], [AX_APPEND_FLAG([$flag], [m4_default([$2], [LDFLAGS])])], [], [$3])
done
])dnl AX_APPEND_LINK_FLAGS

+ 0
- 74
sound/mpc/autotools-files/m4/ax_check_compile_flag.m4 View File

@ -1,74 +0,0 @@
# ===========================================================================
# http://www.gnu.org/software/autoconf-archive/ax_check_compile_flag.html
# ===========================================================================
#
# SYNOPSIS
#
# AX_CHECK_COMPILE_FLAG(FLAG, [ACTION-SUCCESS], [ACTION-FAILURE], [EXTRA-FLAGS], [INPUT])
#
# DESCRIPTION
#
# Check whether the given FLAG works with the current language's compiler
# or gives an error. (Warnings, however, are ignored)
#
# ACTION-SUCCESS/ACTION-FAILURE are shell commands to execute on
# success/failure.
#
# If EXTRA-FLAGS is defined, it is added to the current language's default
# flags (e.g. CFLAGS) when the check is done. The check is thus made with
# the flags: "CFLAGS EXTRA-FLAGS FLAG". This can for example be used to
# force the compiler to issue an error when a bad flag is given.
#
# INPUT gives an alternative input source to AC_COMPILE_IFELSE.
#
# NOTE: Implementation based on AX_CFLAGS_GCC_OPTION. Please keep this
# macro in sync with AX_CHECK_{PREPROC,LINK}_FLAG.
#
# LICENSE
#
# Copyright (c) 2008 Guido U. Draheim <guidod@gmx.de>
# Copyright (c) 2011 Maarten Bosmans <mkbosmans@gmail.com>
#
# This program is free software: you can redistribute it and/or modify it
# under the terms of the GNU General Public License as published by the
# Free Software Foundation, either version 3 of the License, or (at your
# option) any later version.
#
# This program is distributed in the hope that it will be useful, but
# WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General
# Public License for more details.
#
# You should have received a copy of the GNU General Public License along
# with this program. If not, see <http://www.gnu.org/licenses/>.
#
# As a special exception, the respective Autoconf Macro's copyright owner
# gives unlimited permission to copy, distribute and modify the configure
# scripts that are the output of Autoconf when processing the Macro. You
# need not follow the terms of the GNU General Public License when using
# or distributing such scripts, even though portions of the text of the
# Macro appear in them. The GNU General Public License (GPL) does govern
# all other use of the material that constitutes the Autoconf Macro.
#
# This special exception to the GPL applies to versions of the Autoconf
# Macro released by the Autoconf Archive. When you make and distribute a
# modified version of the Autoconf Macro, you may extend this special
# exception to the GPL to apply to your modified version as well.
#serial 4
AC_DEFUN([AX_CHECK_COMPILE_FLAG],
[AC_PREREQ(2.64)dnl for _AC_LANG_PREFIX and AS_VAR_IF
AS_VAR_PUSHDEF([CACHEVAR],[ax_cv_check_[]_AC_LANG_ABBREV[]flags_$4_$1])dnl
AC_CACHE_CHECK([whether _AC_LANG compiler accepts $1], CACHEVAR, [
ax_check_save_flags=$[]_AC_LANG_PREFIX[]FLAGS
_AC_LANG_PREFIX[]FLAGS="$[]_AC_LANG_PREFIX[]FLAGS $4 $1"
AC_COMPILE_IFELSE([m4_default([$5],[AC_LANG_PROGRAM()])],
[AS_VAR_SET(CACHEVAR,[yes])],
[AS_VAR_SET(CACHEVAR,[no])])
_AC_LANG_PREFIX[]FLAGS=$ax_check_save_flags])
AS_VAR_IF(CACHEVAR,yes,
[m4_default([$2], :)],
[m4_default([$3], :)])
AS_VAR_POPDEF([CACHEVAR])dnl
])dnl AX_CHECK_COMPILE_FLAGS

+ 0
- 74
sound/mpc/autotools-files/m4/ax_check_link_flag.m4 View File

@ -1,74 +0,0 @@
# ===========================================================================
# http://www.gnu.org/software/autoconf-archive/ax_check_link_flag.html
# ===========================================================================
#
# SYNOPSIS
#
# AX_CHECK_LINK_FLAG(FLAG, [ACTION-SUCCESS], [ACTION-FAILURE], [EXTRA-FLAGS], [INPUT])
#
# DESCRIPTION
#
# Check whether the given FLAG works with the linker or gives an error.
# (Warnings, however, are ignored)
#
# ACTION-SUCCESS/ACTION-FAILURE are shell commands to execute on
# success/failure.
#
# If EXTRA-FLAGS is defined, it is added to the linker's default flags
# when the check is done. The check is thus made with the flags: "LDFLAGS
# EXTRA-FLAGS FLAG". This can for example be used to force the linker to
# issue an error when a bad flag is given.
#
# INPUT gives an alternative input source to AC_LINK_IFELSE.
#
# NOTE: Implementation based on AX_CFLAGS_GCC_OPTION. Please keep this
# macro in sync with AX_CHECK_{PREPROC,COMPILE}_FLAG.
#
# LICENSE
#
# Copyright (c) 2008 Guido U. Draheim <guidod@gmx.de>
# Copyright (c) 2011 Maarten Bosmans <mkbosmans@gmail.com>
#
# This program is free software: you can redistribute it and/or modify it
# under the terms of the GNU General Public License as published by the
# Free Software Foundation, either version 3 of the License, or (at your
# option) any later version.
#
# This program is distributed in the hope that it will be useful, but
# WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General
# Public License for more details.
#
# You should have received a copy of the GNU General Public License along
# with this program. If not, see <http://www.gnu.org/licenses/>.
#
# As a special exception, the respective Autoconf Macro's copyright owner
# gives unlimited permission to copy, distribute and modify the configure
# scripts that are the output of Autoconf when processing the Macro. You
# need not follow the terms of the GNU General Public License when using
# or distributing such scripts, even though portions of the text of the
# Macro appear in them. The GNU General Public License (GPL) does govern
# all other use of the material that constitutes the Autoconf Macro.
#
# This special exception to the GPL applies to versions of the Autoconf
# Macro released by the Autoconf Archive. When you make and distribute a
# modified version of the Autoconf Macro, you may extend this special
# exception to the GPL to apply to your modified version as well.
#serial 4
AC_DEFUN([AX_CHECK_LINK_FLAG],
[AC_PREREQ(2.64)dnl for _AC_LANG_PREFIX and AS_VAR_IF
AS_VAR_PUSHDEF([CACHEVAR],[ax_cv_check_ldflags_$4_$1])dnl
AC_CACHE_CHECK([whether the linker accepts $1], CACHEVAR, [
ax_check_save_flags=$LDFLAGS
LDFLAGS="$LDFLAGS $4 $1"
AC_LINK_IFELSE([m4_default([$5],[AC_LANG_PROGRAM()])],
[AS_VAR_SET(CACHEVAR,[yes])],
[AS_VAR_SET(CACHEVAR,[no])])
LDFLAGS=$ax_check_save_flags])
AS_VAR_IF(CACHEVAR,yes,
[m4_default([$2], :)],
[m4_default([$3], :)])
AS_VAR_POPDEF([CACHEVAR])dnl
])dnl AX_CHECK_LINK_FLAGS

+ 0
- 37
sound/mpc/autotools-files/m4/ax_require_defined.m4 View File

@ -1,37 +0,0 @@
# ===========================================================================
# http://www.gnu.org/software/autoconf-archive/ax_require_defined.html
# ===========================================================================
#
# SYNOPSIS
#
# AX_REQUIRE_DEFINED(MACRO)
#
# DESCRIPTION
#
# AX_REQUIRE_DEFINED is a simple helper for making sure other macros have
# been defined and thus are available for use. This avoids random issues
# where a macro isn't expanded. Instead the configure script emits a
# non-fatal:
#
# ./configure: line 1673: AX_CFLAGS_WARN_ALL: command not found
#
# It's like AC_REQUIRE except it doesn't expand the required macro.
#
# Here's an example:
#
# AX_REQUIRE_DEFINED([AX_CHECK_LINK_FLAG])
#
# LICENSE
#
# Copyright (c) 2014 Mike Frysinger <vapier@gentoo.org>
#
# Copying and distribution of this file, with or without modification, are
# permitted in any medium without royalty provided the copyright notice
# and this notice are preserved. This file is offered as-is, without any
# warranty.
#serial 1
AC_DEFUN([AX_REQUIRE_DEFINED], [dnl
m4_ifndef([$1], [m4_fatal([macro ]$1[ is not defined; is a m4 file missing?])])
])dnl AX_REQUIRE_DEFINED

+ 0
- 132
sound/mpc/autotools-files/m4/check.m4 View File

@ -1,132 +0,0 @@
dnl AM_PATH_CHECK([MINIMUM-VERSION, [ACTION-IF-FOUND [, ACTION-IF-NOT-FOUND]]])
dnl Test for check, and define CHECK_CFLAGS and CHECK_LIBS
dnl
AC_DEFUN([AM_PATH_CHECK],
[
AC_MSG_WARN([A@&t@M_PATH_CHECK() is deprecated])
AC_MSG_WARN([[use P@&t@KG_CHECK_MODULES([CHECK], [check >= 0.9.4]) instead]])
AC_ARG_WITH([check],
[ --with-check=PATH prefix where check is installed [default=auto]])
min_check_version=ifelse([$1], ,0.8.2,$1)
AC_MSG_CHECKING(for check - version >= $min_check_version)
if test x$with_check = xno; then
AC_MSG_RESULT(disabled)
ifelse([$3], , AC_MSG_ERROR([disabling check is not supported]), [$3])
else
if test "x$with_check" != x; then
CHECK_CFLAGS="-I$with_check/include"
CHECK_LIBS="-L$with_check/lib -lcheck"
else
CHECK_CFLAGS=""
CHECK_LIBS="-lcheck"
fi
ac_save_CFLAGS="$CFLAGS"
ac_save_LIBS="$LIBS"
CFLAGS="$CFLAGS $CHECK_CFLAGS"
LIBS="$CHECK_LIBS $LIBS"
rm -f conf.check-test
AC_COMPILE_IFELSE([AC_LANG_SOURCE([AC_INCLUDES_DEFAULT([])
#include <check.h>
int main ()
{
int major, minor, micro;
char *tmp_version;
system ("touch conf.check-test");
/* HP/UX 9 (%@#!) writes to sscanf strings */
tmp_version = strdup("$min_check_version");
if (sscanf(tmp_version, "%d.%d.%d", &major, &minor, &micro) != 3) {
printf("%s, bad version string\n", "$min_check_version");
return 1;
}
if ((CHECK_MAJOR_VERSION != check_major_version) ||
(CHECK_MINOR_VERSION != check_minor_version) ||
(CHECK_MICRO_VERSION != check_micro_version))
{
printf("\n*** The check header file (version %d.%d.%d) does not match\n",
CHECK_MAJOR_VERSION, CHECK_MINOR_VERSION, CHECK_MICRO_VERSION);
printf("*** the check library (version %d.%d.%d).\n",
check_major_version, check_minor_version, check_micro_version);
return 1;
}
if ((check_major_version > major) ||
((check_major_version == major) && (check_minor_version > minor)) ||
((check_major_version == major) && (check_minor_version == minor) && (check_micro_version >= micro)))
{
return 0;
}
else
{
printf("\n*** An old version of check (%d.%d.%d) was found.\n",
check_major_version, check_minor_version, check_micro_version);
printf("*** You need a version of check being at least %d.%d.%d.\n", major, minor, micro);
printf("***\n");
printf("*** If you have already installed a sufficiently new version, this error\n");
printf("*** probably means that the wrong copy of the check library and header\n");
printf("*** file is being found. Rerun configure with the --with-check=PATH option\n");
printf("*** to specify the prefix where the correct version was installed.\n");
}
return 1;
}
])],, no_check=yes, [echo $ac_n "cross compiling; assumed OK... $ac_c"])
CFLAGS="$ac_save_CFLAGS"
LIBS="$ac_save_LIBS"
if test "x$no_check" = x ; then
AC_MSG_RESULT(yes)
ifelse([$2], , :, [$2])
else
AC_MSG_RESULT(no)
if test -f conf.check-test ; then
:
else
echo "*** Could not run check test program, checking why..."
CFLAGS="$CFLAGS $CHECK_CFLAGS"
LIBS="$CHECK_LIBS $LIBS"
AC_TRY_LINK([
#include <stdio.h>
#include <stdlib.h>
#include <check.h>
], , [ echo "*** The test program compiled, but did not run. This usually means"
echo "*** that the run-time linker is not finding check. You'll need to set your"
echo "*** LD_LIBRARY_PATH environment variable, or edit /etc/ld.so.conf to point"
echo "*** to the installed location Also, make sure you have run ldconfig if that"
echo "*** is required on your system"
echo "***"
echo "*** If you have an old version installed, it is best to remove it, although"
echo "*** you may also be able to get things to work by modifying LD_LIBRARY_PATH"],
[ echo "*** The test program failed to compile or link. See the file config.log for"
echo "*** the exact error that occured." ])
CFLAGS="$ac_save_CFLAGS"
LIBS="$ac_save_LIBS"
fi
CHECK_CFLAGS=""
CHECK_LIBS=""
rm -f conf.check-test
ifelse([$3], , AC_MSG_ERROR([check not found]), [$3])
fi
AC_SUBST(CHECK_CFLAGS)
AC_SUBST(CHECK_LIBS)
rm -f conf.check-test
fi
])

+ 102
- 83
sound/mpd/Makefile View File

@ -6,19 +6,17 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=mpd
PKG_VERSION:=0.20.23
PKG_RELEASE:=3
PKG_VERSION:=0.21.16
PKG_RELEASE:=1
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz
PKG_SOURCE_URL:=http://www.musicpd.org/download/mpd/0.20/
PKG_HASH:=503e5f9f237290f568ff7956ab2f9aed563594bf749f19b8fe994fb21434afea
PKG_SOURCE_URL:=http://www.musicpd.org/download/mpd/0.21/
PKG_HASH:=30cf1bddf7d7388487276745ad3515f134e07f0c57f9f97cb2b5d3befd4a4d92
PKG_MAINTAINER:=Ted Hess <thess@kitschensync.net>
PKG_LICENSE:=GPL-2.0-or-later
PKG_LICENSE_FILES:=COPYING
PKG_BUILD_PARALLEL:=1
PKG_CONFIG_DEPENDS:= \
CONFIG_IPV6 \
@ -27,6 +25,7 @@ PKG_USE_MIPS16:=0
include $(INCLUDE_DIR)/package.mk
include $(INCLUDE_DIR)/nls.mk
include ../../devel/meson/meson.mk
define Package/mpd/Default
SECTION:=sound
@ -34,7 +33,7 @@ define Package/mpd/Default
TITLE:=Music Player Daemon
URL:=http://www.musicpd.org/
DEPENDS:= +zlib +libcurl +libpthread +libmpdclient +libstdcpp $(ICONV_DEPENDS) \
+AUDIO_SUPPORT:alsa-lib +boost +boost-container +libexpat +libflac
+AUDIO_SUPPORT:alsa-lib +boost +libexpat +libflac
endef
define Package/mpd/Default/description
@ -47,7 +46,7 @@ endef
define Package/mpd-full
$(call Package/mpd/Default)
TITLE+= (full)
DEPENDS+= +libffmpeg +libid3tag +libmms +libupnp +libshout +pulseaudio-daemon +yajl
DEPENDS+= +libffmpeg +libid3tag +libvorbis +libmms +libupnp +libshout +pulseaudio-daemon +yajl
PROVIDES:=mpd
VARIANT:=full
endef
@ -100,90 +99,110 @@ endef
EXTRA_LDFLAGS += $(if $(ICONV_FULL),-liconv,-Wl,--whole-archive -liconv -Wl,--no-whole-archive) -Wl,-rpath-link=$(STAGING_DIR)/usr/lib/pulseaudio
CONFIGURE_ARGS += \
$(call autoconf_bool,CONFIG_IPV6,ipv6) \
--disable-debug \
--disable-documentation \
--disable-test \
--disable-aac \
--disable-adplug \
--disable-ao \
--disable-audiofile \
--disable-bzip2 \
--disable-cdio-paranoia \
--disable-fluidsynth \
--disable-wildmidi \
--disable-gme \
--enable-inotify \
--disable-icu \
--enable-iconv \
--disable-iso9660 \
--disable-jack \
--disable-roar \
--disable-libwrap \
--disable-lsr \
--disable-mad \
--disable-mikmod \
--disable-modplug \
--disable-mpc \
--disable-nfs \
--disable-openal \
--disable-opus \
--disable-sidplay \
--disable-smbclient \
--disable-sndfile \
--disable-solaris-output \
--disable-sqlite \
--disable-systemd-daemon \
--disable-lame-encoder \
--disable-twolame-encoder \
--disable-shine-encoder \
--disable-vorbis-encoder \
--enable-wave-encoder \
--disable-wavpack \
--enable-webdav \
--disable-zzip \
--with-zeroconf=no \
--disable-soxr \
--enable-curl \
--enable-httpd-output \
$(call autoconf_bool,CONFIG_AUDIO_SUPPORT,alsa) \
--enable-tcp \
--disable-sndio \
--disable-haiku
MESON_ARGS += \
-Ddocumentation=false \
-Dtest=false \
-Dsyslog=enabled \
-Dinotify=true \
-Ddaemon=false \
-Dsystemd=disabled \
-Dtcp=true \
-Dipv6=$(if $(CONFIG_IPV6),enabled,disabled) \
-Dlocal_socket=true \
-Ddsd=false \
-Ddatabase=true \
-Dlibmpdclient=enabled \
-Dneighbor=false \
-Dudisks=disabled \
-Dwebdav=enabled \
-Dcue=true \
-Dcdio_paranoia=disabled \
-Dcurl=enabled \
-Dnfs=disabled \
-Dsmbclient=disabled \
-Dqobuz=disabled \
-Dtidal=disabled \
-Dbzip2=disabled \
-Diso9660=disabled \
-Dzzip=disabled \
-Dchromaprint=disabled \
-Dadplug=disabled \
-Daudiofile=disabled \
-Dfaad=disabled \
-Dflac=enabled \
-Dfluidsynth=disabled \
-Dgme=disabled \
-Dmad=disabled \
-Dmikmod=disabled \
-Dmodplug=disabled \
-Dmpcdec=disabled \
-Dopus=disabled \
-Dsidplay=disabled \
-Dsndfile=disabled \
-Dwavpack=disabled \
-Dwildmidi=disabled \
-Dvorbisenc=disabled \
-Dlame=disabled \
-Dtwolame=disabled \
-Dshine=disabled \
-Dwave_encoder=true \
-Dlibsamplerate=disabled \
-Dsoxr=disabled \
-Dalsa=$(if CONFIG_AUDIO_SUPPORT,enabled,disabled) \
-Dao=disabled \
-Dhttpd=true \
-Djack=disabled \
-Dopenal=disabled \
-Doss=disabled \
-Dsndio=disabled \
-Dsolaris_output=disabled \
-Ddbus=disabled \
-Dexpat=enabled \
-Dicu=disabled \
-Diconv=enabled \
-Dpcre=disabled \
-Dsqlite=disabled \
-Dzlib=enabled \
-Dzeroconf=disabled
ifeq ($(BUILD_VARIANT),full)
CONFIGURE_ARGS += \
--enable-upnp \
--enable-ffmpeg \
--enable-id3 \
--enable-mms \
--disable-mpg123 \
--enable-pipe-output \
--enable-recorder-output \
--enable-shout \
--enable-pulse \
--disable-vorbis \
--enable-soundcloud
MESON_ARGS += \
-Dupnp=enabled \
-Dmms=enabled \
-Dsoundcloud=enabled \
-Did3tag=enabled \
-Dffmpeg=enabled \
-Dmpg123=disabled \
-Dtremor=disabled \
-Dvorbis=enabled \
-Dfifo=true \
-Dpipe=true \
-Dpulse=enabled \
-Drecorder=true \
-Dshout=enabled \
-Dyajl=enabled
endif
ifeq ($(BUILD_VARIANT),mini)
# oggflac is not compatible with tremor
CONFIGURE_ARGS += \
--disable-upnp \
--disable-fifo \
--disable-ffmpeg \
--disable-id3 \
--disable-mms \
--disable-shout \
--disable-soundcloud \
--disable-pulse \
--enable-vorbis \
--with-tremor=yes \
--disable-recorder-output
MESON_ARGS += \
-Dupnp=disabled \
-Dmms=disabled \
-Dsoundcloud=disabled \
-Did3tag=disabled \
-Dffmpeg=disabled \
-Dmpg123=enabled \
-Dtremor=enabled \
-Dvorbis=disabled \
-Dfifo=false \
-Dpipe=false \
-Dpulse=disabled \
-Drecorder=false \
-Dshout=disabled \
-Dyajl=disabled
endif
define Package/mpd/install


+ 1
- 1
sound/mpd/patches/210-support_raw_pcm_streams.patch View File

@ -1,6 +1,6 @@
--- a/src/decoder/plugins/FfmpegDecoderPlugin.cxx
+++ b/src/decoder/plugins/FfmpegDecoderPlugin.cxx
@@ -937,6 +937,7 @@ static const char *const ffmpeg_mime_typ
@@ -775,6 +775,7 @@ static const char *const ffmpeg_mime_typ
"audio/qcelp",
"audio/vorbis",
"audio/vorbis+ogg",


+ 0
- 16
sound/mpd/patches/220-handle_slow_server_stream_startup.patch View File

@ -1,16 +0,0 @@
--- a/src/decoder/plugins/FfmpegDecoderPlugin.cxx
+++ b/src/decoder/plugins/FfmpegDecoderPlugin.cxx
@@ -478,6 +478,13 @@ ffmpeg_probe(DecoderClient *client, Inpu
unsigned char buffer[BUFFER_SIZE];
size_t nbytes = decoder_read(client, is, buffer, BUFFER_SIZE);
+
+ if ((nbytes > 0) && (nbytes < 1024))
+ {
+ // Gobble some more data if header is small
+ nbytes += decoder_read(client, is, buffer + nbytes, BUFFER_SIZE - nbytes);
+ }
+
if (nbytes <= PADDING)
return nullptr;

Loading…
Cancel
Save