You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

214 lines
4.9 KiB

  1. #
  2. # This is free software, licensed under the GNU General Public License v2.
  3. # See /LICENSE for more information.
  4. #
  5. include $(TOPDIR)/rules.mk
  6. PKG_NAME:=mpd
  7. PKG_VERSION:=0.20.9
  8. PKG_RELEASE:=1
  9. PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz
  10. PKG_SOURCE_URL:=http://www.musicpd.org/download/mpd/0.20/
  11. PKG_HASH:=cd77a2869e32354b004cc6b34fcb0bee56114caa2d9ed862aaa8071441e34eb7
  12. PKG_MAINTAINER:=Ted Hess <thess@kitschensync.net>
  13. PKG_LICENSE:=GPL-2.0
  14. PKG_LICENSE_FILES:=COPYING
  15. PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(BUILD_VARIANT)/$(PKG_NAME)-$(PKG_VERSION)
  16. PKG_BUILD_PARALLEL:=1
  17. PKG_CONFIG_DEPENDS:= \
  18. CONFIG_IPV6 \
  19. PKG_INSTALL:=1
  20. PKG_USE_MIPS16:=0
  21. include $(INCLUDE_DIR)/package.mk
  22. include $(INCLUDE_DIR)/nls.mk
  23. define Package/mpd/Default
  24. SECTION:=sound
  25. CATEGORY:=Sound
  26. TITLE:=Music Player Daemon
  27. URL:=http://www.musicpd.org/
  28. DEPENDS:= +glib2 +libcurl +libpthread +libmpdclient +libstdcpp $(ICONV_DEPENDS) \
  29. +AUDIO_SUPPORT:alsa-lib +boost +boost-container +libexpat
  30. endef
  31. define Package/mpd/Default/description
  32. Music Player Daemon (MPD) is a flexible, powerful, server-side
  33. application for playing music. It is typically controlled over a
  34. network using one of it's many clients including mpc (console),
  35. gmpc (gnome), phpmp (php), etc...
  36. endef
  37. define Package/mpd-full
  38. $(call Package/mpd/Default)
  39. TITLE+= (full)
  40. DEPENDS+= +libffmpeg +libid3tag +libmms +libupnp +libshout
  41. PROVIDES:=mpd
  42. VARIANT:=full
  43. endef
  44. define Package/mpd-full/description
  45. $(call Package/mpd/Default/description)
  46. .
  47. This package contains a full-blown Music Player Daemon.
  48. endef
  49. define Package/mpd-full/conffiles
  50. /etc/mpd.conf
  51. endef
  52. define Package/mpd-mini
  53. $(call Package/mpd/Default)
  54. TITLE+= (mini)
  55. DEPENDS+= +libflac +libmpg123 +libvorbisidec
  56. PROVIDES:=mpd
  57. VARIANT:=mini
  58. endef
  59. define Package/mpd-mini/description
  60. $(call Package/mpd/Default/description)
  61. .
  62. This package contains a minimal Music Player Daemon, with support for
  63. only Flac, MP3 & OGG media types & only file: & http: protocols.
  64. endef
  65. define Package/mpd-mini/conffiles
  66. /etc/mpd.conf
  67. endef
  68. define Package/mpd-avahi-service
  69. $(call Package/mpd/Default)
  70. TITLE+= (Avahi service)
  71. DEPENDS+=+avahi-daemon
  72. endef
  73. define Package/mpd-avahi-service/description
  74. $(call Package/mpd/Default/description)
  75. .
  76. This package contains the service definition for announcing the
  77. Music Player Daemon service via mDNS/DNS-SD.
  78. endef
  79. define Package/mpd-avahi-service/conffiles
  80. /etc/avahi/services/mpd.service
  81. endef
  82. EXTRA_LDFLAGS += $(if $(ICONV_FULL),-liconv,-Wl,--whole-archive -liconv -Wl,--no-whole-archive)
  83. EXTRA_CXXFLAGS += $(if $(CONFIG_GCC_VERSION_4_8),-std=gnu++11,-std=gnu++14)
  84. CONFIGURE_ARGS += \
  85. $(call autoconf_bool,CONFIG_IPV6,ipv6) \
  86. --disable-debug \
  87. --disable-documentation \
  88. --disable-test \
  89. --disable-aac \
  90. --disable-adplug \
  91. --disable-ao \
  92. --disable-audiofile \
  93. --disable-bzip2 \
  94. --disable-cdio-paranoia \
  95. --disable-fluidsynth \
  96. --disable-wildmidi \
  97. --disable-gme \
  98. --enable-inotify \
  99. --disable-icu \
  100. --enable-iconv \
  101. --disable-iso9660 \
  102. --disable-jack \
  103. --disable-roar \
  104. --disable-libwrap \
  105. --disable-lsr \
  106. --disable-mad \
  107. --disable-mikmod \
  108. --disable-modplug \
  109. --disable-mpc \
  110. --disable-nfs \
  111. --disable-openal \
  112. --disable-opus \
  113. --disable-pulse \
  114. --disable-sidplay \
  115. --disable-smbclient \
  116. --disable-sndfile \
  117. --disable-solaris-output \
  118. --disable-sqlite \
  119. --disable-systemd-daemon \
  120. --disable-lame-encoder \
  121. --disable-twolame-encoder \
  122. --disable-shine-encoder \
  123. --disable-vorbis-encoder \
  124. --enable-wave-encoder \
  125. --disable-wavpack \
  126. --disable-webdav \
  127. --disable-wildmidi \
  128. --disable-zzip \
  129. --with-zeroconf=no \
  130. --disable-soxr \
  131. --enable-curl \
  132. --enable-httpd-output \
  133. $(call autoconf_bool,CONFIG_AUDIO_SUPPORT,alsa) \
  134. --enable-tcp \
  135. --disable-sndio \
  136. --disable-haiku
  137. ifeq ($(BUILD_VARIANT),full)
  138. CONFIGURE_ARGS += \
  139. --enable-upnp \
  140. --enable-ffmpeg \
  141. --disable-flac \
  142. --enable-id3 \
  143. --enable-mms \
  144. --disable-mpg123 \
  145. --enable-pipe-output \
  146. --enable-recorder-output \
  147. --enable-shout \
  148. --disable-vorbis
  149. endif
  150. ifeq ($(BUILD_VARIANT),mini)
  151. # oggflac is not compatible with tremor
  152. CONFIGURE_ARGS += \
  153. --disable-upnp \
  154. --disable-fifo \
  155. --disable-ffmpeg \
  156. --disable-id3 \
  157. --disable-mms \
  158. --disable-shout \
  159. --enable-vorbis \
  160. --with-tremor=yes \
  161. --disable-recorder-output
  162. endif
  163. define Package/mpd/install
  164. $(INSTALL_DIR) $(1)/usr/bin
  165. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/mpd $(1)/usr/bin/
  166. $(INSTALL_DIR) $(1)/etc
  167. $(INSTALL_CONF) $(PKG_BUILD_DIR)/doc/mpdconf.example $(1)/etc/mpd.conf
  168. $(INSTALL_DIR) $(1)/etc/init.d
  169. $(INSTALL_BIN) ./files/mpd.init $(1)/etc/init.d/mpd
  170. endef
  171. define Package/mpd-full/install
  172. $(call Package/mpd/install,$1)
  173. endef
  174. define Package/mpd-mini/install
  175. $(call Package/mpd/install,$1)
  176. endef
  177. define Package/mpd-avahi-service/install
  178. $(INSTALL_DIR) $(1)/etc/avahi/services
  179. $(INSTALL_DATA) ./files/mpd.service $(1)/etc/avahi/services/
  180. endef
  181. $(eval $(call BuildPackage,mpd-full))
  182. $(eval $(call BuildPackage,mpd-mini))
  183. $(eval $(call BuildPackage,mpd-avahi-service))