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
5.0 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.23
  8. PKG_RELEASE:=3
  9. PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz
  10. PKG_SOURCE_URL:=http://www.musicpd.org/download/mpd/0.20/
  11. PKG_HASH:=503e5f9f237290f568ff7956ab2f9aed563594bf749f19b8fe994fb21434afea
  12. PKG_MAINTAINER:=Ted Hess <thess@kitschensync.net>
  13. PKG_LICENSE:=GPL-2.0-or-later
  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:= +zlib +libcurl +libpthread +libmpdclient +libstdcpp $(ICONV_DEPENDS) \
  29. +AUDIO_SUPPORT:alsa-lib +boost +boost-container +libexpat +libflac
  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 +pulseaudio-daemon +yajl
  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+= +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) -Wl,-rpath-link=$(STAGING_DIR)/usr/lib/pulseaudio
  83. CONFIGURE_ARGS += \
  84. $(call autoconf_bool,CONFIG_IPV6,ipv6) \
  85. --disable-debug \
  86. --disable-documentation \
  87. --disable-test \
  88. --disable-aac \
  89. --disable-adplug \
  90. --disable-ao \
  91. --disable-audiofile \
  92. --disable-bzip2 \
  93. --disable-cdio-paranoia \
  94. --disable-fluidsynth \
  95. --disable-wildmidi \
  96. --disable-gme \
  97. --enable-inotify \
  98. --disable-icu \
  99. --enable-iconv \
  100. --disable-iso9660 \
  101. --disable-jack \
  102. --disable-roar \
  103. --disable-libwrap \
  104. --disable-lsr \
  105. --disable-mad \
  106. --disable-mikmod \
  107. --disable-modplug \
  108. --disable-mpc \
  109. --disable-nfs \
  110. --disable-openal \
  111. --disable-opus \
  112. --disable-sidplay \
  113. --disable-smbclient \
  114. --disable-sndfile \
  115. --disable-solaris-output \
  116. --disable-sqlite \
  117. --disable-systemd-daemon \
  118. --disable-lame-encoder \
  119. --disable-twolame-encoder \
  120. --disable-shine-encoder \
  121. --disable-vorbis-encoder \
  122. --enable-wave-encoder \
  123. --disable-wavpack \
  124. --enable-webdav \
  125. --disable-zzip \
  126. --with-zeroconf=no \
  127. --disable-soxr \
  128. --enable-curl \
  129. --enable-httpd-output \
  130. $(call autoconf_bool,CONFIG_AUDIO_SUPPORT,alsa) \
  131. --enable-tcp \
  132. --disable-sndio \
  133. --disable-haiku
  134. ifeq ($(BUILD_VARIANT),full)
  135. CONFIGURE_ARGS += \
  136. --enable-upnp \
  137. --enable-ffmpeg \
  138. --enable-id3 \
  139. --enable-mms \
  140. --disable-mpg123 \
  141. --enable-pipe-output \
  142. --enable-recorder-output \
  143. --enable-shout \
  144. --enable-pulse \
  145. --disable-vorbis \
  146. --enable-soundcloud
  147. endif
  148. ifeq ($(BUILD_VARIANT),mini)
  149. # oggflac is not compatible with tremor
  150. CONFIGURE_ARGS += \
  151. --disable-upnp \
  152. --disable-fifo \
  153. --disable-ffmpeg \
  154. --disable-id3 \
  155. --disable-mms \
  156. --disable-shout \
  157. --disable-soundcloud \
  158. --disable-pulse \
  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))