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.

295 lines
8.3 KiB

  1. #
  2. # Copyright (C) 2008-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:=gst1-plugins-base
  9. PKG_VERSION:=1.16.1
  10. PKG_RELEASE:=1
  11. PKG_MAINTAINER:=W. Michael Petullo <mike@flyn.org> \
  12. Ted Hess <thess@kitschensync.net>
  13. PKG_LICENSE:=LGPLv2 GPLv2
  14. PKG_LICENSE_FILES:=COPYING.LIB COPYING
  15. PKG_CPE_ID:=cpe:/a:gstreamer:gst-plugins-base
  16. PKG_BUILD_DIR:=$(BUILD_DIR)/gst-plugins-base-$(PKG_VERSION)
  17. PKG_SOURCE:=gst-plugins-base-$(PKG_VERSION).tar.xz
  18. PKG_SOURCE_URL:=https://gstreamer.freedesktop.org/src/gst-plugins-base
  19. PKG_HASH:=5c3cc489933d0597087c9bc6ba251c93693d64554bcc563539a084fa2d5fcb2b
  20. PKG_CONFIG_DEPENDS:= \
  21. CONFIG_PACKAGE_gst1-mod-alsa \
  22. CONFIG_PACKAGE_gst1-mod-app \
  23. CONFIG_PACKAGE_gst1-mod-audioconvert \
  24. CONFIG_PACKAGE_gst1-mod-audiorate \
  25. CONFIG_PACKAGE_gst1-mod-audioresample \
  26. CONFIG_PACKAGE_gst1-mod-audiotestsrc \
  27. CONFIG_PACKAGE_gst1-mod-gio \
  28. CONFIG_PACKAGE_gst1-mod-ogg \
  29. CONFIG_PACKAGE_gst1-mod-tcp \
  30. CONFIG_PACKAGE_gst1-mod-theora \
  31. CONFIG_PACKAGE_gst1-mod-videoconvert \
  32. CONFIG_PACKAGE_gst1-mod-videotestsrc \
  33. CONFIG_PACKAGE_gst1-mod-volume \
  34. CONFIG_PACKAGE_gst1-mod-vorbis \
  35. CONFIG_PACKAGE_libgst1app \
  36. PKG_FIXUP:=autoreconf
  37. PKG_BUILD_PARALLEL:=1
  38. PKG_INSTALL:=1
  39. include $(INCLUDE_DIR)/package.mk
  40. include $(INCLUDE_DIR)/nls.mk
  41. GST_BASE_LIBS:=
  42. GST_BASE_MODULES:=
  43. define Package/gstreamer1-base/Default
  44. CATEGORY:=Multimedia
  45. SECTION:=multimedia
  46. TITLE:=GStreamer
  47. URL:=https://gstreamer.freedesktop.org/
  48. DEPENDS:= +libgstreamer1 $(ICONV_DEPENDS)
  49. endef
  50. define Package/gstreamer1-base/description/Default
  51. GStreamer open source multimedia framework
  52. endef
  53. define Package/gst1-plugins-base
  54. $(call Package/gstreamer1-base/Default)
  55. TITLE+= plugins collection (base)
  56. DEPENDS+= $(GST_DEPENDS)
  57. HIDDEN:=1
  58. endef
  59. define Package/gts1-plugins-base/description
  60. $(call Package/gstreamer1-base/description/Default)
  61. .
  62. This meta package contains only dependencies to the other libraries and
  63. plugins from the base plugins collection.
  64. endef
  65. define Package/gstreamer1-plugins-base
  66. $(call Package/gstreamer1-base/Default)
  67. TITLE+= plugins collection (base)
  68. DEPENDS:=+ALL:gst1-plugins-base +gstreamer1-libs
  69. endef
  70. define Package/gstreamer1-plugins-base/config
  71. menu "Select GStreamer base modules and libraries"
  72. depends on PACKAGE_gstreamer1-plugins-base
  73. config gst1-plugins-base-all
  74. bool "Include all GStreamer base plugins"
  75. select PACKAGE_gst1-plugins-base
  76. comment "Modules"
  77. $(foreach mod,$(GST_BASE_MODULES), \
  78. config PACKAGE_gst1-mod-$(mod)
  79. prompt "GStreamer $(mod) module"
  80. )
  81. comment "Libraries"
  82. $(foreach lib,$(GST_BASE_LIBS), \
  83. config PACKAGE_libgst1$(lib)
  84. prompt "GStreamer $(lib) library"
  85. )
  86. endmenu
  87. endef
  88. GST_COND_SELECT = $(patsubst %,$(if $(CONFIG_PACKAGE_gst1-mod-$(1)),--enable,--disable)-%,$(1))
  89. GST_VERSION:=1.0
  90. CONFIGURE_ARGS += \
  91. --disable-debug \
  92. --disable-examples \
  93. --disable-fatal-warnings \
  94. --disable-glib-asserts \
  95. --disable-gobject-cast-checks \
  96. --disable-gtk-doc-html \
  97. --disable-introspection \
  98. --disable-rpath \
  99. --disable-valgrind \
  100. --without-html-dir \
  101. --with-pic \
  102. \
  103. $(call GST_COND_SELECT,alsa) \
  104. $(call GST_COND_SELECT,app) \
  105. $(call GST_COND_SELECT,audioconvert) \
  106. $(call GST_COND_SELECT,audiorate) \
  107. $(call GST_COND_SELECT,audioresample) \
  108. $(call GST_COND_SELECT,audiotestsrc) \
  109. --disable-cdparanoia \
  110. $(call GST_COND_SELECT,gio) \
  111. --disable-libvisual \
  112. $(call GST_COND_SELECT,ogg) \
  113. --disable-pango \
  114. --disable-subparse \
  115. $(call GST_COND_SELECT,tcp) \
  116. $(call GST_COND_SELECT,theora) \
  117. $(call GST_COND_SELECT,videorate) \
  118. $(call GST_COND_SELECT,videoscale) \
  119. $(call GST_COND_SELECT,videoconvert) \
  120. $(call GST_COND_SELECT,videotestsrc) \
  121. $(call GST_COND_SELECT,volume) \
  122. $(call GST_COND_SELECT,vorbis) \
  123. --disable-x \
  124. --disable-xshm \
  125. --disable-xvideo \
  126. \
  127. --without-libiconv-prefix \
  128. --without-libintl-prefix \
  129. \
  130. --with-audioresample-format=int \
  131. define Build/InstallDev
  132. $(INSTALL_DIR) $(1)/usr/include/gstreamer-$(GST_VERSION)
  133. ( cd $(PKG_INSTALL_DIR); $(CP) \
  134. ./usr/include/gstreamer-$(GST_VERSION)/* \
  135. $(1)/usr/include/gstreamer-$(GST_VERSION)/ \
  136. )
  137. $(INSTALL_DIR) $(1)/usr/lib
  138. ( cd $(PKG_INSTALL_DIR); $(CP) \
  139. ./usr/lib/libgst*-$(GST_VERSION).{la,so*} \
  140. $(1)/usr/lib/ \
  141. )
  142. $(INSTALL_DIR) $(1)/usr/lib/gstreamer-$(GST_VERSION)
  143. ( cd $(PKG_INSTALL_DIR); $(CP) \
  144. ./usr/lib/gstreamer-$(GST_VERSION)/libgst*.{la,so} \
  145. $(1)/usr/lib/gstreamer-$(GST_VERSION)/ \
  146. )
  147. $(INSTALL_DIR) $(1)/usr/lib/pkgconfig
  148. ( cd $(PKG_INSTALL_DIR); $(CP) \
  149. ./usr/lib/pkgconfig/gstreamer*-$(GST_VERSION).pc \
  150. $(1)/usr/lib/pkgconfig/ \
  151. )
  152. endef
  153. define Package/gst1-plugins-base/install
  154. true
  155. endef
  156. define Package/gstreamer1-plugins-base/install
  157. true
  158. endef
  159. # 1: short name
  160. # 2: description
  161. # 3: dependencies on other gstreamer libraries (short name)
  162. # 4: dependencies on other packages
  163. define GstBuildLibrary
  164. GST_DEPENDS += +libgst1$(1)
  165. GST_BASE_LIBS+= $(1)
  166. define Package/libgst1$(1)
  167. $(call Package/gstreamer1-base/Default)
  168. TITLE+= $(2) library (base)
  169. DEPENDS+= $$(foreach p,$(3),+libgst1$$(p)) $(4)
  170. HIDDEN:=1
  171. endef
  172. define Package/libgst1$(1)/description
  173. $(call Package/gstreamer1-base/description/Default)
  174. .
  175. This package contains the GStreamer $(2) library.
  176. endef
  177. define Package/libgst1$(1)/install
  178. $(INSTALL_DIR) $$(1)/usr/lib
  179. ( cd $(PKG_INSTALL_DIR); $(CP) \
  180. ./usr/lib/libgst$(1)-$(GST_VERSION).so.* \
  181. $$(1)/usr/lib/ \
  182. )
  183. endef
  184. $$(eval $$(call BuildPackage,libgst1$(1)))
  185. endef
  186. $(eval $(call GstBuildLibrary,allocators,allocators,,))
  187. $(eval $(call GstBuildLibrary,app,app,,))
  188. $(eval $(call GstBuildLibrary,audio,audio,tag,))
  189. $(eval $(call GstBuildLibrary,fft,FFT,,))
  190. $(eval $(call GstBuildLibrary,pbutils,utils,audio tag video,))
  191. $(eval $(call GstBuildLibrary,riff,RIFF media,audio tag,,))
  192. $(eval $(call GstBuildLibrary,rtp,RTP,,))
  193. $(eval $(call GstBuildLibrary,rtsp,RTSP,,))
  194. $(eval $(call GstBuildLibrary,sdp,SDP,rtp,))
  195. $(eval $(call GstBuildLibrary,tag,tag support,,))
  196. $(eval $(call GstBuildLibrary,video,video,,))
  197. # 1: short name
  198. # 2: description
  199. # 3: dependencies on other gstreamer libraries (short name)
  200. # 4: dependencies on other gstreamer plugins (short name)
  201. # 5: dependencies on other packages
  202. define GstBuildPlugin
  203. GST_DEPENDS += +gst1-mod-$(1)
  204. GST_BASE_MODULES+= $(1)
  205. define Package/gst1-mod-$(1)
  206. $(call Package/gstreamer1-base/Default)
  207. TITLE+= $(2) plugin (base)
  208. DEPENDS+= $$(foreach p,$(3),+libgst1$$(p)) $$(foreach p,$(4),+gst1-mod-$$(p)) $(5)
  209. HIDDEN:=1
  210. endef
  211. define Package/gst1-mod-$(1)/description
  212. $(call Package/gstreamer1-base/description/Default)
  213. .
  214. This package contains the GStreamer $(2) plugin.
  215. endef
  216. define Package/gst1-mod-$(1)/install
  217. $(INSTALL_DIR) $$(1)/usr/lib/gstreamer-$(GST_VERSION)
  218. ( cd $(PKG_INSTALL_DIR); $(CP) \
  219. ./usr/lib/gstreamer-$(GST_VERSION)/libgst$(1).so* \
  220. $$(1)/usr/lib/gstreamer-$(GST_VERSION)/ \
  221. )
  222. endef
  223. $$(eval $$(call BuildPackage,gst1-mod-$(1)))
  224. endef
  225. $(eval $(call GstBuildPlugin,alsa,ALSA,audio tag,,+alsa-lib))
  226. $(eval $(call GstBuildPlugin,app,app,app,,))
  227. $(eval $(call GstBuildPlugin,audioconvert,audio format conversion,audio,,))
  228. $(eval $(call GstBuildPlugin,audiorate,audio rate adjusting,audio tag,,))
  229. $(eval $(call GstBuildPlugin,audioresample,audio resampling,audio tag,,))
  230. $(eval $(call GstBuildPlugin,audiotestsrc,audio test,audio tag controller,,))
  231. $(eval $(call GstBuildPlugin,playback,media decoder (v2),pbutils,,))
  232. $(eval $(call GstBuildPlugin,gio,GIO,,,))
  233. $(eval $(call GstBuildPlugin,ogg,Ogg,riff tag pbutils video,,+libogg))
  234. $(eval $(call GstBuildPlugin,opus,OPUS plugin library,pbutils video,,+libopus))
  235. $(eval $(call GstBuildPlugin,tcp,TCP,net,,))
  236. $(eval $(call GstBuildPlugin,theora,Theora,tag video,,+libogg +libtheora))
  237. $(eval $(call GstBuildPlugin,typefindfunctions,'typefind' functions,audio pbutils tag video,,))
  238. $(eval $(call GstBuildPlugin,videoconvert,video format conversion,video,,))
  239. $(eval $(call GstBuildPlugin,videorate,Adjusts video frames,video,,))
  240. $(eval $(call GstBuildPlugin,videoscale,Resizes video,video,,))
  241. $(eval $(call GstBuildPlugin,videotestsrc,video test,video,,+liboil))
  242. $(eval $(call GstBuildPlugin,volume,volume,audio controller,,+liboil))
  243. $(eval $(call GstBuildPlugin,vorbis,Vorbis,audio tag,ogg,+libvorbis))
  244. $(eval $(call BuildPackage,gstreamer1-plugins-base))
  245. $(eval $(call BuildPackage,gst1-plugins-base))