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.

238 lines
5.7 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:=gstreamer1
  9. PKG_VERSION:=1.14.4
  10. PKG_RELEASE:=1
  11. PKG_MAINTAINER:=W. Michael Petullo <mike@flyn.org> \
  12. Ted Hess <thess@kitschensync.net>
  13. PKG_LICENSE:=LGPLv2
  14. PKG_LICENSE_FILES:=COPYING
  15. PKG_BUILD_DIR:=$(BUILD_DIR)/gstreamer-$(PKG_VERSION)
  16. PKG_SOURCE:=gstreamer-$(PKG_VERSION).tar.xz
  17. PKG_SOURCE_URL:=https://gstreamer.freedesktop.org/src/gstreamer
  18. PKG_HASH:=f94f6696c5f05a3b3a9183e39c5f5c0b779f75a04c0efa497e7920afa985ffc7
  19. PKG_FIXUP:=autoreconf
  20. PKG_REMOVE_FILES:=autogen.sh aclocal.m4
  21. PKG_INSTALL:=1
  22. include $(INCLUDE_DIR)/package.mk
  23. include $(INCLUDE_DIR)/nls.mk
  24. define Package/gstreamer1/Default
  25. CATEGORY:=Multimedia
  26. SECTION:=multimedia
  27. TITLE:=GStreamer
  28. URL:=http://gstreamer.freedesktop.org/
  29. DEPENDS:= $(ICONV_DEPENDS) $(INTL_DEPENDS)
  30. endef
  31. define Package/gstreamer1/description/Default
  32. GStreamer open source multimedia framework
  33. endef
  34. GSTREAMER_CORE_LIBS:= \
  35. libgstreamer1 \
  36. libgst1check \
  37. libgst1controller \
  38. libgst1net
  39. define Package/gstreamer1
  40. $(call Package/gstreamer1/Default)
  41. TITLE+= (All libraries)
  42. DEPENDS:= $(foreach lib,$(GSTREAMER_CORE_LIBS),+$(lib))
  43. HIDDEN:=1
  44. endef
  45. define Package/gstreamer1-libs/description
  46. $(call Package/gstreamer1/description/Default)
  47. .
  48. This meta package contains only dependencies on the other GStreamer
  49. componenents.
  50. endef
  51. define Package/gstreamer1-libs
  52. $(call Package/gstreamer1/Default)
  53. TITLE+= core libraries
  54. DEPENDS+=+ALL:gstreamer1
  55. endef
  56. define Package/gstreamer1-libs/config
  57. menu "Select GStreamer libraries"
  58. depends on PACKAGE_gstreamer1-libs
  59. config gstreamer1-all
  60. bool "Include all GStreamer1 core libraries"
  61. select PACKAGE_gstreamer1
  62. comment "Libraries"
  63. $(foreach lib,$(GSTREAMER_CORE_LIBS), \
  64. config PACKAGE_$(lib)
  65. prompt "GStreamer core library $(lib)"
  66. )
  67. endmenu
  68. endef
  69. define Package/gstreamer1-utils
  70. $(call Package/gstreamer1/Default)
  71. TITLE+= utilities
  72. DEPENDS+= +libgstreamer1 +gstreamer1-libs
  73. endef
  74. define Package/gstreamer1-utils/description
  75. $(call Package/gstreamer1/description/Default)
  76. .
  77. This package contains the GStreamer utilities.
  78. endef
  79. define Package/libgstreamer1
  80. $(call Package/gstreamer1/Default)
  81. TITLE+= library (core)
  82. DEPENDS+= +glib2 +libpthread +libxml2
  83. HIDDEN:=1
  84. endef
  85. define Package/libgstreamer1/description
  86. $(call Package/gstreamer1/description/Default)
  87. .
  88. This package contains the GStreamer core library.
  89. endef
  90. GST_VERSION:=1.0
  91. CONFIGURE_ARGS += \
  92. --enable-static \
  93. --disable-benchmarks \
  94. --disable-examples \
  95. --disable-failing-tests \
  96. --disable-fatal-warnings \
  97. --disable-introspection \
  98. --disable-gst-tracer-hooks \
  99. --disable-gtk-doc-html \
  100. --disable-tests \
  101. --disable-valgrind \
  102. --without-libiconv-prefix \
  103. --without-libintl-prefix \
  104. --without-unwind
  105. EXTRA_LDFLAGS+= \
  106. -Wl,-rpath-link=$(STAGING_DIR)/usr/lib \
  107. $(if $(ICONV_FULL),-liconv)
  108. define Build/InstallDev
  109. $(INSTALL_DIR) $(1)/usr/include/gstreamer-$(GST_VERSION)
  110. ( cd $(PKG_INSTALL_DIR); $(CP) \
  111. ./usr/include/gstreamer-$(GST_VERSION)/* \
  112. $(1)/usr/include/gstreamer-$(GST_VERSION)/ \
  113. )
  114. $(INSTALL_DIR) $(1)/usr/lib
  115. ( cd $(PKG_INSTALL_DIR); $(CP) \
  116. ./usr/lib/libgst*-$(GST_VERSION).{a,la,so*} \
  117. $(1)/usr/lib/ \
  118. )
  119. $(INSTALL_DIR) $(1)/usr/lib/gstreamer-$(GST_VERSION)
  120. ( cd $(PKG_INSTALL_DIR); $(CP) \
  121. ./usr/lib/gstreamer-$(GST_VERSION)/libgst*.{la,so} \
  122. $(1)/usr/lib/gstreamer-$(GST_VERSION)/ \
  123. )
  124. $(INSTALL_DIR) $(1)/usr/lib/pkgconfig
  125. ( cd $(PKG_INSTALL_DIR); $(CP) \
  126. ./usr/lib/pkgconfig/gstreamer*-$(GST_VERSION).pc \
  127. $(1)/usr/lib/pkgconfig/ \
  128. )
  129. $(INSTALL_DIR) $(2)/share/aclocal
  130. ( cd $(PKG_INSTALL_DIR); $(CP) \
  131. ./usr/share/aclocal/* \
  132. $(2)/share/aclocal/ \
  133. )
  134. endef
  135. define Package/gstreamer1/install
  136. true
  137. endef
  138. define Package/gstreamer1-libs/install
  139. true
  140. endef
  141. define Package/gstreamer1-utils/install
  142. $(INSTALL_DIR) $(1)/usr/bin
  143. ( cd $(PKG_INSTALL_DIR); $(CP) \
  144. ./usr/bin/gst-launch* \
  145. ./usr/bin/gst-inspect* \
  146. ./usr/bin/gst-typefind* \
  147. $(1)/usr/bin/ \
  148. )
  149. endef
  150. define Package/libgstreamer1/install
  151. $(INSTALL_DIR) $(1)/usr/lib
  152. ( cd $(PKG_INSTALL_DIR); $(CP) \
  153. ./usr/lib/libgstbase-$(GST_VERSION).so.* \
  154. ./usr/lib/libgstreamer-$(GST_VERSION).so.* \
  155. $(1)/usr/lib/ \
  156. )
  157. $(INSTALL_DIR) $(1)/usr/lib/gstreamer-$(GST_VERSION)
  158. ( cd $(PKG_INSTALL_DIR); $(CP) \
  159. ./usr/lib/gstreamer-$(GST_VERSION)/libgst*.so \
  160. $(1)/usr/lib/gstreamer-$(GST_VERSION)/ \
  161. )
  162. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/lib/gstreamer-$(GST_VERSION)/gst-plugin-scanner \
  163. $(1)/usr/lib/gstreamer-$(GST_VERSION)
  164. endef
  165. # 1: short name
  166. # 2: description
  167. # 3: dependencies on other gstreamer libraries (short name)
  168. # 4: dependencies on other packages
  169. define GstBuildLibrary
  170. define Package/libgst1$(1)
  171. $(call Package/gstreamer1/Default)
  172. TITLE+= $(2) library (core)
  173. DEPENDS+= +libgstreamer1 $$(foreach p,$(3),+libgst1$$(p)) $(4)
  174. HIDDEN:=1
  175. endef
  176. define Package/libgst1$(1)/description
  177. $(call Package/gstreamer1/description/Default)
  178. .
  179. This package contains the GStreamer $(2) library.
  180. endef
  181. define Package/libgst1$(1)/install
  182. $(INSTALL_DIR) $$(1)/usr/lib
  183. ( cd $(PKG_INSTALL_DIR); $(CP) \
  184. ./usr/lib/libgst$(1)-$(GST_VERSION).so.* \
  185. $$(1)/usr/lib/ \
  186. )
  187. endef
  188. $$(eval $$(call BuildPackage,libgst1$(1)))
  189. endef
  190. $(eval $(call GstBuildLibrary,check,check unit testing))
  191. $(eval $(call GstBuildLibrary,controller,dynamic parameter control))
  192. $(eval $(call GstBuildLibrary,net,network classes))
  193. $(eval $(call BuildPackage,libgstreamer1))
  194. $(eval $(call BuildPackage,gstreamer1-libs))
  195. $(eval $(call BuildPackage,gstreamer1-utils))
  196. $(eval $(call BuildPackage,gstreamer1))