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.

275 lines
6.3 KiB

  1. #
  2. # Copyright (C) 2011-2016 OpenWrt.org
  3. #
  4. # This is free software, licensed under the GNU General Public License v2.
  5. # See /LICENSE for more information.
  6. #
  7. include $(TOPDIR)/rules.mk
  8. PKG_NAME:=pulseaudio
  9. PKG_VERSION:=12.0
  10. PKG_RELEASE:=1
  11. PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz
  12. PKG_SOURCE_URL:=https://freedesktop.org/software/pulseaudio/releases/
  13. PKG_HASH:=6e422dbdc9fd11c0cb6af869e5eda73dc24a8be3c14725440edd51ce6b464444
  14. PKG_LICENSE:=LGPL-2.1+
  15. PKG_LICENSE_FILES:=GPL LICENSE
  16. PKG_BUILD_PARALLEL:=1
  17. PKG_BUILD_DEPENDS:=intltool/host
  18. PKG_FIXUP:=autoreconf
  19. PKG_USE_MIPS16:=0
  20. PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(BUILD_VARIANT)/$(PKG_NAME)-$(PKG_VERSION)
  21. PKG_INSTALL = 1
  22. include $(INCLUDE_DIR)/package.mk
  23. include $(INCLUDE_DIR)/nls.mk
  24. define Package/pulseaudio/Default
  25. SECTION:=sound
  26. CATEGORY:=Sound
  27. DEPENDS:=+libsndfile +libltdl +libpthread +librt +alsa-lib \
  28. +libopenssl +libwrap +libcap $(ICONV_DEPENDS) $(INTL_DEPENDS)
  29. TITLE:=Network sound server
  30. MAINTAINER:=Peter Wagner <tripolar@gmx.at>
  31. URL:=http://www.pulseaudio.org
  32. PROVIDES:=pulseaudio
  33. USERID:=pulse=51:pulse=51
  34. endef
  35. define Package/pulseaudio-daemon
  36. $(call Package/pulseaudio/Default)
  37. VARIANT:=noavahi
  38. endef
  39. define Package/pulseaudio-daemon-avahi
  40. $(call Package/pulseaudio/Default)
  41. DEPENDS+=+dbus +libavahi-client +sbc
  42. # DEPENDS+=+avahi-daemon
  43. TITLE+= (avahi/bluez)
  44. VARIANT:=avahi
  45. endef
  46. define Package/pulseaudio/Default/description
  47. PulseAudio (formerly Polypaudio) is a cross-platform, networked sound server.
  48. endef
  49. define Package/pulseaudio-daemon/description
  50. $(call Package/pulseaudio/Default/description)
  51. endef
  52. define Package/pulseaudio-daemon-avahi/description
  53. $(call Package/pulseaudio/Default/description)
  54. This package enables avahi,bluez and is compiled against dbus, sbc, and avahi.
  55. endef
  56. define Package/pulseaudio-daemon/conffiles
  57. /etc/pulse/client.conf
  58. /etc/pulse/daemon.conf
  59. /etc/pulse/default.pa
  60. /etc/pulse/system.pa
  61. endef
  62. define Package/pulseaudio-daemon-avahi/conffiles
  63. /etc/pulse/client.conf
  64. /etc/pulse/daemon.conf
  65. /etc/pulse/default.pa
  66. /etc/pulse/system.pa
  67. endef
  68. define Package/pulseaudio-tools
  69. SECTION:=sound
  70. CATEGORY:=Sound
  71. DEPENDS:=+libsndfile +pulseaudio
  72. TITLE:=Tools for Pulseaudio
  73. URL:=http://www.pulseaudio.org
  74. VARIANT:=noavahi
  75. endef
  76. define Package/pulseaudio-profiles
  77. SECTION:=sound
  78. CATEGORY:=Sound
  79. DEPENDS:=+pulseaudio
  80. TITLE:=Profiles for Pulseaudio
  81. URL:=http://www.pulseaudio.org
  82. endef
  83. CONFIGURE_ARGS += \
  84. $(if $(findstring neon,$(CONFIG_TARGET_OPTIMIZATION)),--enable-neon-opt,--disable-neon-opt) \
  85. --with-system-user=pulse \
  86. --with-system-group=pulse \
  87. --with-access-group=audio \
  88. --with-database=simple \
  89. --enable-alsa \
  90. --disable-hal \
  91. --disable-gconf \
  92. --disable-nls \
  93. --disable-manpages \
  94. --enable-oss-output \
  95. --disable-oss-wrapper \
  96. --disable-samplerate \
  97. --disable-per-user-esound-socket \
  98. --disable-solaris \
  99. --disable-gtk2 \
  100. --disable-glib2 \
  101. --disable-jack \
  102. --disable-asyncns \
  103. --disable-lirc \
  104. --disable-udev \
  105. --without-fftw \
  106. --without-soxr \
  107. --without-speex
  108. # --disable-bluez
  109. ifeq ($(BUILD_VARIANT),avahi)
  110. CONFIGURE_ARGS += \
  111. --enable-avahi \
  112. --enable-dbus
  113. endif
  114. ifeq ($(BUILD_VARIANT),noavahi)
  115. CONFIGURE_ARGS += \
  116. --disable-avahi \
  117. --disable-dbus
  118. endif
  119. CONFIGURE_VARS += \
  120. PKG_CONFIG_LIBDIR="$(STAGING_DIR)/usr/lib/pkgconfig"
  121. #SUPP_LIBS:=-L$(INTL_PREFIX)/lib -L$(ICONV_PREFIX)/lib
  122. TARGET_CFLAGS += -std=gnu99
  123. define Build/InstallDev
  124. $(INSTALL_DIR) \
  125. $(1)/usr/lib/pkgconfig \
  126. $(1)/usr/include/pulse \
  127. $(1)/usr/lib \
  128. $(1)/usr/lib/pulseaudio
  129. $(CP) \
  130. $(PKG_INSTALL_DIR)/usr/include/pulse/* \
  131. $(1)/usr/include/pulse
  132. $(CP) \
  133. $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/*.pc \
  134. $(1)/usr/lib/pkgconfig
  135. $(CP) \
  136. $(PKG_INSTALL_DIR)/usr/lib/*.so* \
  137. $(1)/usr/lib/
  138. $(CP) \
  139. $(PKG_INSTALL_DIR)/usr/lib/pulseaudio/* \
  140. $(1)/usr/lib/pulseaudio/
  141. endef
  142. define Package/pulseaudio-daemon/install
  143. $(INSTALL_DIR) \
  144. $(1)/etc/pulse \
  145. $(1)/etc/init.d \
  146. $(1)/usr/bin \
  147. $(1)/usr/lib \
  148. $(1)/usr/lib/pulseaudio \
  149. $(1)/usr/lib/pulse-$(PKG_VERSION)/modules
  150. $(INSTALL_BIN) \
  151. $(PKG_INSTALL_DIR)/usr/bin/pulseaudio \
  152. $(1)/usr/bin/pulseaudio
  153. $(INSTALL_BIN) \
  154. ./files/pulseaudio.init \
  155. $(1)/etc/init.d/pulseaudio
  156. $(INSTALL_DATA) \
  157. $(PKG_INSTALL_DIR)/etc/pulse/* \
  158. $(1)/etc/pulse
  159. $(CP) \
  160. $(PKG_INSTALL_DIR)/usr/lib/*.so* \
  161. $(1)/usr/lib/
  162. $(CP) \
  163. $(PKG_INSTALL_DIR)/usr/lib/pulseaudio/* \
  164. $(1)/usr/lib/pulseaudio/
  165. $(CP) \
  166. $(PKG_INSTALL_DIR)/usr/lib/pulse-$(PKG_VERSION)/modules/lib*.so \
  167. $(1)/usr/lib/
  168. $(CP) \
  169. $(PKG_INSTALL_DIR)/usr/lib/pulse-$(PKG_VERSION)/modules/module*.so \
  170. $(1)/usr/lib/pulse-$(PKG_VERSION)/modules/
  171. endef
  172. define Package/pulseaudio-daemon-avahi/install
  173. $(INSTALL_DIR) \
  174. $(1)/etc/pulse \
  175. $(1)/etc/init.d \
  176. $(1)/usr/bin \
  177. $(1)/usr/lib \
  178. $(1)/usr/lib/pulseaudio \
  179. $(1)/usr/lib/pulse-$(PKG_VERSION)/modules \
  180. $(1)/etc/dbus-1/system.d
  181. $(INSTALL_BIN) \
  182. $(PKG_INSTALL_DIR)/usr/bin/pulseaudio \
  183. $(1)/usr/bin/pulseaudio
  184. $(INSTALL_BIN) \
  185. ./files/pulseaudio.init \
  186. $(1)/etc/init.d/pulseaudio
  187. $(INSTALL_DATA) \
  188. $(PKG_INSTALL_DIR)/etc/pulse/* \
  189. $(1)/etc/pulse
  190. $(CP) \
  191. $(PKG_INSTALL_DIR)/usr/lib/*.so* \
  192. $(1)/usr/lib/
  193. $(CP) \
  194. $(PKG_INSTALL_DIR)/usr/lib/pulseaudio/* \
  195. $(1)/usr/lib/pulseaudio/
  196. $(CP) \
  197. $(PKG_INSTALL_DIR)/usr/lib/pulse-$(PKG_VERSION)/modules/lib*.so \
  198. $(1)/usr/lib/
  199. $(CP) \
  200. $(PKG_INSTALL_DIR)/usr/lib/pulse-$(PKG_VERSION)/modules/module*.so \
  201. $(1)/usr/lib/pulse-$(PKG_VERSION)/modules/
  202. $(INSTALL_DATA) \
  203. $(PKG_INSTALL_DIR)/etc/dbus-1/system.d/pulseaudio-system.conf \
  204. $(1)/etc/dbus-1/system.d/pulseaudio-system.conf
  205. endef
  206. define Package/pulseaudio-tools/install
  207. $(INSTALL_DIR) \
  208. $(1)/usr/bin
  209. $(INSTALL_BIN) \
  210. $(PKG_INSTALL_DIR)/usr/bin/pa* \
  211. $(1)/usr/bin/
  212. endef
  213. define Package/pulseaudio-profiles/install
  214. $(INSTALL_DIR) \
  215. $(1)/usr/share/pulseaudio/alsa-mixer/paths \
  216. $(1)/usr/share/pulseaudio/alsa-mixer/profile-sets
  217. $(INSTALL_DATA) \
  218. $(PKG_INSTALL_DIR)/usr/share/pulseaudio/alsa-mixer/paths/* \
  219. $(1)/usr/share/pulseaudio/alsa-mixer/paths
  220. $(INSTALL_DATA) \
  221. $(PKG_INSTALL_DIR)/usr/share/pulseaudio/alsa-mixer/profile-sets/* \
  222. $(1)/usr/share/pulseaudio/alsa-mixer/profile-sets
  223. endef
  224. $(eval $(call BuildPackage,pulseaudio-daemon))
  225. $(eval $(call BuildPackage,pulseaudio-daemon-avahi))
  226. $(eval $(call BuildPackage,pulseaudio-tools))
  227. $(eval $(call BuildPackage,pulseaudio-profiles))