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.

321 lines
9.9 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.17.2
  10. PKG_RELEASE:=1
  11. PKG_SOURCE:=gst-plugins-base-$(PKG_VERSION).tar.xz
  12. PKG_SOURCE_URL:=https://gstreamer.freedesktop.org/src/gst-plugins-base
  13. PKG_HASH:=30bfdaad8faa380fd74c3e74261748e218649786939ad10edfe067a39d4c4996
  14. PKG_BUILD_DIR:=$(BUILD_DIR)/gst-plugins-base-$(PKG_VERSION)
  15. PKG_MAINTAINER:=W. Michael Petullo <mike@flyn.org> \
  16. Ted Hess <thess@kitschensync.net>
  17. PKG_LICENSE:=LGPL-2.1-or-later GPL-2.0-or-later
  18. PKG_LICENSE_FILES:=COPYING.LIB COPYING
  19. PKG_CPE_ID:=cpe:/a:gstreamer:gst-plugins-base
  20. PKG_INSTALL:=1
  21. include $(INCLUDE_DIR)/package.mk
  22. include $(INCLUDE_DIR)/nls.mk
  23. include ../../devel/meson/meson.mk
  24. PKG_CONFIG_DEPENDS:= \
  25. CONFIG_PACKAGE_gst1-mod-alsa \
  26. CONFIG_PACKAGE_gst1-mod-app \
  27. CONFIG_PACKAGE_gst1-mod-audioconvert \
  28. CONFIG_PACKAGE_gst1-mod-audiorate \
  29. CONFIG_PACKAGE_gst1-mod-audioresample \
  30. CONFIG_PACKAGE_gst1-mod-audiotestsrc \
  31. CONFIG_PACKAGE_gst1-mod-playback \
  32. CONFIG_PACKAGE_gst1-mod-gio \
  33. CONFIG_PACKAGE_gst1-mod-ogg \
  34. CONFIG_PACKAGE_gst1-mod-opus \
  35. CONFIG_PACKAGE_gst1-mod-tcp \
  36. CONFIG_PACKAGE_gst1-mod-theora \
  37. CONFIG_PACKAGE_gst1-mod-typefind \
  38. CONFIG_PACKAGE_gst1-mod-videoconvert \
  39. CONFIG_PACKAGE_gst1-mod-videorate \
  40. CONFIG_PACKAGE_gst1-mod-videoscale \
  41. CONFIG_PACKAGE_gst1-mod-videotestsrc \
  42. CONFIG_PACKAGE_gst1-mod-volume \
  43. CONFIG_PACKAGE_gst1-mod-vorbis \
  44. CONFIG_PACKAGE_libgst1app
  45. GST_BASE_LIBS:=
  46. GST_BASE_MODULES:=
  47. define Package/gstreamer1-base/Default
  48. CATEGORY:=Multimedia
  49. SECTION:=multimedia
  50. TITLE:=GStreamer
  51. URL:=https://gstreamer.freedesktop.org/
  52. DEPENDS:= +libgstreamer1 $(ICONV_DEPENDS)
  53. endef
  54. define Package/gstreamer1-base/description/Default
  55. GStreamer open source multimedia framework
  56. endef
  57. define Package/gst1-plugins-base
  58. $(call Package/gstreamer1-base/Default)
  59. TITLE+= plugins collection (base)
  60. DEPENDS+= $(GST_DEPENDS)
  61. HIDDEN:=1
  62. endef
  63. define Package/gts1-plugins-base/description
  64. $(call Package/gstreamer1-base/description/Default)
  65. .
  66. This meta package contains only dependencies to the other libraries and
  67. plugins from the base plugins collection.
  68. endef
  69. define Package/gstreamer1-plugins-base
  70. $(call Package/gstreamer1-base/Default)
  71. TITLE+= plugins collection (base)
  72. DEPENDS:=+ALL:gst1-plugins-base +gstreamer1-libs
  73. endef
  74. define Package/gstreamer1-plugins-base/config
  75. menu "Select GStreamer base modules and libraries"
  76. depends on PACKAGE_gstreamer1-plugins-base
  77. config gst1-plugins-base-all
  78. bool "Include all GStreamer base plugins"
  79. select PACKAGE_gst1-plugins-base
  80. comment "Modules"
  81. $(foreach mod,$(GST_BASE_MODULES), \
  82. config PACKAGE_gst1-mod-$(mod)
  83. prompt "GStreamer $(mod) module"
  84. )
  85. comment "Libraries"
  86. $(foreach lib,$(GST_BASE_LIBS), \
  87. config PACKAGE_libgst1$(lib)
  88. prompt "GStreamer $(lib) library"
  89. )
  90. endmenu
  91. endef
  92. GST_COND_SELECT = -D$(1)=$(if $(CONFIG_PACKAGE_gst1-mod-$(1)),en,dis)abled
  93. GST_VERSION:=1.0
  94. MESON_ARGS += \
  95. -Daudioresample_format=int \
  96. -Dgl=disabled \
  97. \
  98. $(call GST_COND_SELECT,adder) \
  99. $(call GST_COND_SELECT,app) \
  100. $(call GST_COND_SELECT,audioconvert) \
  101. $(call GST_COND_SELECT,audiomixer) \
  102. $(call GST_COND_SELECT,audiorate) \
  103. $(call GST_COND_SELECT,audioresample) \
  104. $(call GST_COND_SELECT,audiotestsrc) \
  105. $(call GST_COND_SELECT,compositor) \
  106. $(call GST_COND_SELECT,encoding) \
  107. $(call GST_COND_SELECT,gio) \
  108. $(call GST_COND_SELECT,overlaycomposition) \
  109. $(call GST_COND_SELECT,pbtypes) \
  110. $(call GST_COND_SELECT,playback) \
  111. $(call GST_COND_SELECT,rawparse) \
  112. $(call GST_COND_SELECT,subparse) \
  113. $(call GST_COND_SELECT,tcp) \
  114. -Dtypefind=$(if $(CONFIG_PACKAGE_gst1-mod-typefindfunctions),en,dis)abled \
  115. $(call GST_COND_SELECT,videoconvert) \
  116. $(call GST_COND_SELECT,videorate) \
  117. $(call GST_COND_SELECT,videoscale) \
  118. $(call GST_COND_SELECT,videotestsrc) \
  119. $(call GST_COND_SELECT,volume) \
  120. \
  121. $(call GST_COND_SELECT,alsa) \
  122. $(call GST_COND_SELECT,cdparanoia) \
  123. $(call GST_COND_SELECT,libvisual) \
  124. $(call GST_COND_SELECT,ogg) \
  125. $(call GST_COND_SELECT,opus) \
  126. $(call GST_COND_SELECT,pango) \
  127. $(call GST_COND_SELECT,theora) \
  128. $(call GST_COND_SELECT,tremor) \
  129. -Dtremor=$(if $(CONFIG_PACKAGE_gst1-mod-ivorbisdec),en,dis)abled \
  130. $(call GST_COND_SELECT,vorbis) \
  131. -Dx11=disabled \
  132. -Dxshm=disabled \
  133. -Dxvideo=disabled \
  134. \
  135. -Dexamples=disabled \
  136. -Dtests=disabled \
  137. -Dtools=disabled \
  138. -Dintrospection=disabled \
  139. -Dnls=enabled \
  140. -Dorc=disabled \
  141. -Dgobject-cast-checks=disabled \
  142. -Dglib-asserts=disabled \
  143. -Dglib-checks=disabled \
  144. -Ddoc=disabled
  145. define Build/InstallDev
  146. $(INSTALL_DIR) $(1)/usr/include/gstreamer-$(GST_VERSION)
  147. ( cd $(PKG_INSTALL_DIR); $(CP) \
  148. ./usr/include/gstreamer-$(GST_VERSION)/* \
  149. $(1)/usr/include/gstreamer-$(GST_VERSION)/ \
  150. )
  151. $(INSTALL_DIR) $(1)/usr/lib
  152. ( cd $(PKG_INSTALL_DIR); $(CP) \
  153. ./usr/lib/libgst*-$(GST_VERSION).so* \
  154. $(1)/usr/lib/ \
  155. )
  156. $(INSTALL_DIR) $(1)/usr/lib/gstreamer-$(GST_VERSION)
  157. ( cd $(PKG_INSTALL_DIR); $(CP) \
  158. ./usr/lib/gstreamer-$(GST_VERSION)/libgst*.so \
  159. $(1)/usr/lib/gstreamer-$(GST_VERSION)/ \
  160. )
  161. $(INSTALL_DIR) $(1)/usr/lib/pkgconfig
  162. ( cd $(PKG_INSTALL_DIR); $(CP) \
  163. ./usr/lib/pkgconfig/gstreamer*-$(GST_VERSION).pc \
  164. $(1)/usr/lib/pkgconfig/ \
  165. )
  166. endef
  167. define Package/gst1-plugins-base/install
  168. true
  169. endef
  170. define Package/gstreamer1-plugins-base/install
  171. true
  172. endef
  173. # 1: short name
  174. # 2: description
  175. # 3: dependencies on other gstreamer libraries (short name)
  176. # 4: dependencies on other packages
  177. define GstBuildLibrary
  178. GST_DEPENDS += +libgst1$(1)
  179. GST_BASE_LIBS+= $(1)
  180. define Package/libgst1$(1)
  181. $(call Package/gstreamer1-base/Default)
  182. TITLE+= $(2) library (base)
  183. DEPENDS+= $$(foreach p,$(3),+libgst1$$(p)) $(4)
  184. HIDDEN:=1
  185. endef
  186. define Package/libgst1$(1)/description
  187. $(call Package/gstreamer1-base/description/Default)
  188. .
  189. This package contains the GStreamer $(2) library.
  190. endef
  191. define Package/libgst1$(1)/install
  192. $(INSTALL_DIR) $$(1)/usr/lib
  193. ( cd $(PKG_INSTALL_DIR); $(CP) \
  194. ./usr/lib/libgst$(1)-$(GST_VERSION).so.* \
  195. $$(1)/usr/lib/ \
  196. )
  197. endef
  198. $$(eval $$(call BuildPackage,libgst1$(1)))
  199. endef
  200. $(eval $(call GstBuildLibrary,allocators,allocators,,))
  201. $(eval $(call GstBuildLibrary,app,app,,))
  202. $(eval $(call GstBuildLibrary,audio,audio,tag,))
  203. $(eval $(call GstBuildLibrary,fft,FFT,,))
  204. $(eval $(call GstBuildLibrary,pbutils,utils,audio tag video,))
  205. $(eval $(call GstBuildLibrary,riff,RIFF media,audio tag,,))
  206. $(eval $(call GstBuildLibrary,rtp,RTP,,))
  207. $(eval $(call GstBuildLibrary,rtsp,RTSP,,))
  208. $(eval $(call GstBuildLibrary,sdp,SDP,rtp,))
  209. $(eval $(call GstBuildLibrary,tag,tag support,,))
  210. $(eval $(call GstBuildLibrary,video,video,,))
  211. # 1: short name
  212. # 2: description
  213. # 3: dependencies on other gstreamer libraries (short name)
  214. # 4: dependencies on other gstreamer plugins (short name)
  215. # 5: dependencies on other packages
  216. define GstBuildPlugin
  217. GST_DEPENDS += +gst1-mod-$(1)
  218. GST_BASE_MODULES+= $(1)
  219. define Package/gst1-mod-$(1)
  220. $(call Package/gstreamer1-base/Default)
  221. TITLE+= $(2) plugin (base)
  222. DEPENDS+= $$(foreach p,$(3),+libgst1$$(p)) $$(foreach p,$(4),+gst1-mod-$$(p)) $(5)
  223. HIDDEN:=1
  224. endef
  225. define Package/gst1-mod-$(1)/description
  226. $(call Package/gstreamer1-base/description/Default)
  227. .
  228. This package contains the GStreamer $(2) plugin.
  229. endef
  230. define Package/gst1-mod-$(1)/install
  231. $(INSTALL_DIR) $$(1)/usr/lib/gstreamer-$(GST_VERSION)
  232. ( cd $(PKG_INSTALL_DIR); $(CP) \
  233. ./usr/lib/gstreamer-$(GST_VERSION)/libgst$(1).so* \
  234. $$(1)/usr/lib/gstreamer-$(GST_VERSION)/ \
  235. )
  236. endef
  237. $$(eval $$(call BuildPackage,gst1-mod-$(1)))
  238. endef
  239. $(eval $(call GstBuildPlugin,adder,adder,audio,,))
  240. $(eval $(call GstBuildPlugin,app,app,app,,))
  241. $(eval $(call GstBuildPlugin,audioconvert,audio format conversion,audio,,))
  242. $(eval $(call GstBuildPlugin,audiomixer,audio mixing,audio,,))
  243. $(eval $(call GstBuildPlugin,audiorate,audio rate adjusting,audio tag,,))
  244. $(eval $(call GstBuildPlugin,audioresample,audio resampling,audio tag,,))
  245. $(eval $(call GstBuildPlugin,audiotestsrc,audio test,audio tag controller,,))
  246. $(eval $(call GstBuildPlugin,compositor,video compositor,video,,))
  247. $(eval $(call GstBuildPlugin,encoding,encoding plugin,pbutils video,,))
  248. $(eval $(call GstBuildPlugin,gio,GIO,,,))
  249. $(eval $(call GstBuildPlugin,overlaycomposition,overlay composition,video,,))
  250. $(eval $(call GstBuildPlugin,pbtypes,pbtypes,video,,))
  251. $(eval $(call GstBuildPlugin,playback,playback,pbutils,,))
  252. $(eval $(call GstBuildPlugin,subparse,subparse,video,,))
  253. $(eval $(call GstBuildPlugin,rawparse,parse raw media,audio video,,))
  254. $(eval $(call GstBuildPlugin,tcp,TCP,net,,))
  255. $(eval $(call GstBuildPlugin,typefindfunctions,'typefind' functions,audio pbutils tag video,,))
  256. $(eval $(call GstBuildPlugin,videoconvert,video format conversion,video,,))
  257. $(eval $(call GstBuildPlugin,videorate,Adjusts video frames,video,,))
  258. $(eval $(call GstBuildPlugin,videoscale,Resizes video,video,,))
  259. $(eval $(call GstBuildPlugin,videotestsrc,video test,video,,+liboil))
  260. $(eval $(call GstBuildPlugin,volume,volume,audio controller,,+liboil))
  261. $(eval $(call GstBuildPlugin,alsa,ALSA audio source/sink,audio tag,,+alsa-lib))
  262. $(eval $(call GstBuildPlugin,ivorbisdec,Integer Vorbis decoder plugin for devices without floating point,audio tag,,+libvorbisidec))
  263. #$(eval $(call GstBuildPlugin,cdparanoia,cdparanoia,,+libcdparanoia))
  264. #$(eval $(call GstBuildPlugin,libvisual,libvisual audio visualization,,+libvisual))
  265. $(eval $(call GstBuildPlugin,ogg,ogg parser muxer demuxer,riff tag pbutils video,,+libogg))
  266. $(eval $(call GstBuildPlugin,opus,OPUS audio codec,pbutils video,,+libopus))
  267. #$(eval $(call GstBuildPlugin,pango,Pango text rendering and overlay plugin,,+pango))
  268. $(eval $(call GstBuildPlugin,theora,Theora,tag video,,+libogg +libtheora))
  269. $(eval $(call GstBuildPlugin,vorbis,Vorbis,audio tag,ogg,+libvorbis))
  270. $(eval $(call BuildPackage,gstreamer1-plugins-base))
  271. $(eval $(call BuildPackage,gst1-plugins-base))