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