]>
Commit | Line | Data |
---|---|---|
2adf1e07 JB |
1 | # |
2 | # Conditional build: | |
574e0d82 | 3 | %bcond_without bcg729 # support for G279AnnexB in RTC3389 implementation of Comfort Noise Payload |
b49a5518 | 4 | %bcond_without srtp # SRTP (secure RTP) support |
d1086c6e | 5 | %bcond_without zrtp # support for RFC 6189: Media Path Key Agreement for Unicast Secure RTP |
b49a5518 | 6 | %bcond_without matroska # Matroska support via libebml2/libmatroska2 |
2adf1e07 JB |
7 | %bcond_without opengl # X11+OpenGL rendering support |
8 | %bcond_with pcap # audio playing from PCAP files | |
574e0d82 JB |
9 | # audio I/O |
10 | %bcond_without alsa # ALSA sound I/O support | |
11 | %bcond_with arts # aRts sound I/O support | |
12 | %bcond_with portaudio # PortAudio sound I/O support | |
13 | %bcond_without pulseaudio # PulseAudio sound I/O support | |
210be78d | 14 | %bcond_without static_libs # static library |
2adf1e07 | 15 | # |
bbb0ffde | 16 | Summary: Audio/Video real-time streaming |
2adf1e07 | 17 | Summary(pl.UTF-8): Przesyłanie strumieni audio/video w czasie rzeczywistym |
bbb0ffde | 18 | Name: mediastreamer |
348172d7 JB |
19 | Version: 4.4.2 |
20 | Release: 1 | |
21 | License: GPL v3+ | |
bbb0ffde | 22 | Group: Libraries |
348172d7 JB |
23 | #Source0Download: https://gitlab.linphone.org/BC/public/mediastreamer2/tags |
24 | Source0: https://gitlab.linphone.org/BC/public/mediastreamer2/-/archive/%{version}/mediastreamer2-%{version}.tar.bz2 | |
25 | # Source0-md5: f2fe330ad7a65dcab407c311f98fc829 | |
c28fe572 | 26 | Patch0: build.patch |
d8296b8a | 27 | Patch2: libupnp-1.14.patch |
b49a5518 | 28 | URL: http://www.linphone.org/technical-corner/mediastreamer2/overview |
2adf1e07 JB |
29 | %{?with_opengl:BuildRequires: OpenGL-GLX-devel} |
30 | BuildRequires: SDL-devel >= 1.2.0 | |
574e0d82 JB |
31 | %{?with_alsa:BuildRequires: alsa-lib-devel} |
32 | %{?with_arts:BuildRequires: artsc-devel} | |
bbb0ffde | 33 | BuildRequires: autoconf >= 2.53 |
aa0ebe9a | 34 | BuildRequires: automake >= 1:1.9 |
348172d7 | 35 | %{?with_bcg729:BuildRequires: bcg729-devel >= 1.0.1} |
67eb68d6 | 36 | BuildRequires: bctoolbox-devel >= 0.4.0 |
c28fe572 | 37 | %{?with_zrtp:BuildRequires: bzrtp-devel >= 1.0.6} |
bbb0ffde | 38 | BuildRequires: doxygen |
2adf1e07 | 39 | # libavcodec >= 51.0.0, libswscale >= 0.7.0 |
bbb0ffde | 40 | BuildRequires: ffmpeg-devel |
c07fcbab | 41 | BuildRequires: gettext-tools |
2adf1e07 | 42 | %{?with_opengl:BuildRequires: glew-devel >= 1.5} |
2adf1e07 | 43 | BuildRequires: intltool >= 0.40 |
bbb0ffde | 44 | BuildRequires: libgsm-devel |
2adf1e07 | 45 | %{?with_pcap:BuildRequires: libpcap-devel} |
348172d7 | 46 | BuildRequires: libstdc++-devel >= 6:5 |
2adf1e07 JB |
47 | BuildRequires: libtheora-devel >= 1.0-0.alpha7 |
48 | BuildRequires: libtool >= 2:2 | |
d8296b8a | 49 | BuildRequires: libupnp-devel |
bbb0ffde | 50 | BuildRequires: libv4l-devel |
2adf1e07 | 51 | BuildRequires: libvpx-devel >= 0.9.6 |
b49a5518 | 52 | %{?with_matroska:BuildRequires: matroska-foundation-devel} |
2adf1e07 | 53 | BuildRequires: opus-devel >= 0.9.0 |
c28fe572 | 54 | BuildRequires: ortp-devel >= 1.0.0 |
bbb0ffde | 55 | BuildRequires: pkgconfig |
574e0d82 | 56 | %{?with_portaudio:BuildRequires: portaudio-devel} |
2adf1e07 | 57 | %{?with_pulseaudio:BuildRequires: pulseaudio-devel >= 0.9.21} |
61d85515 | 58 | BuildRequires: sed >= 4.0 |
2adf1e07 | 59 | BuildRequires: spandsp-devel >= 0.0.6 |
f52b820a | 60 | BuildRequires: speex-devel >= 1:1.2-beta3 |
fed1d2a7 | 61 | BuildRequires: speexdsp-devel >= 1.2-beta3 |
c28fe572 | 62 | %{?with_srtp:BuildRequires: libsrtp2-devel} |
bbb0ffde | 63 | BuildRequires: xorg-lib-libX11-devel |
61d85515 | 64 | BuildRequires: xorg-lib-libXv-devel |
45fa5f14 | 65 | BuildRequires: xxd |
348172d7 JB |
66 | BuildRequires: zxing-cpp-devel |
67 | %{?with_bcg729:Requires: bcg729 >= 1.0.1} | |
67eb68d6 | 68 | Requires: bctoolbox >= 0.4.0 |
c28fe572 | 69 | %{?with_zrtp:Requires: bzrtp >= 1.0.6} |
2adf1e07 JB |
70 | %{?with_opengl:Requires: glew >= 1.5} |
71 | Requires: libtheora >= 1.0-0.alpha7 | |
d8296b8a | 72 | Requires: libupnp |
2adf1e07 JB |
73 | Requires: libvpx >= 0.9.6 |
74 | Requires: opus >= 0.9.0 | |
c28fe572 | 75 | Requires: ortp >= 1.0.0 |
2adf1e07 | 76 | %{?with_pulseaudio:Requires: pulseaudio-libs >= 0.9.21} |
e6d0cfff | 77 | Requires: spandsp >= 0.0.6 |
f52b820a | 78 | Requires: speex >= 1:1.2-beta3 |
fed1d2a7 | 79 | Requires: speexdsp >= 1.2-beta3 |
bbb0ffde AM |
80 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
81 | ||
82 | %description | |
83 | Mediastreamer2 is a GPL licensed library to make audio and video | |
84 | real-time streaming and processing. Written in pure C, it is based | |
85 | upon the oRTP library. | |
86 | ||
2adf1e07 JB |
87 | %description -l pl.UTF-8 |
88 | Mediastreamer2 to udostępniona na licencji GPL biblioteka do | |
89 | przesyłania i przetwarzania strumieni audio/video w czasie | |
90 | rzeczywistym. Jest napisana w czystym C, oparta na bibliotece oRTP. | |
91 | ||
bbb0ffde | 92 | %package devel |
210be78d JB |
93 | Summary: Header files and development documentation for mediastreamer libraries |
94 | Summary(pl.UTF-8): Pliki nagłówkowe i dokumentacja do bibliotek mediastreamer | |
bbb0ffde | 95 | Group: Development/Libraries |
2adf1e07 JB |
96 | Requires: %{name} = %{version}-%{release} |
97 | %{?with_opengl:Requires: OpenGL-devel} | |
574e0d82 | 98 | %{?with_alsa:Requires: alsa-lib-devel} |
348172d7 | 99 | %{?with_bcg729:Requires: bcg729-devel >= 1.0.1} |
67eb68d6 | 100 | Requires: bctoolbox-devel >= 0.4.0 |
c28fe572 | 101 | %{?with_zrtp:Requires: bzrtp-devel >= 1.0.6} |
2adf1e07 JB |
102 | Requires: ffmpeg-devel |
103 | %{?with_opengl:Requires: glew-devel >= 1.5} | |
104 | Requires: libtheora-devel >= 1.0-0.alpha7 | |
d8296b8a | 105 | Requires: libupnp-devel |
2adf1e07 JB |
106 | Requires: libv4l-devel |
107 | Requires: libvpx-devel >= 0.9.6 | |
b49a5518 | 108 | %{?with_matroska:Requires: matroska-foundation-devel} |
2adf1e07 | 109 | Requires: opus-devel >= 0.9.0 |
c28fe572 | 110 | Requires: ortp-devel >= 1.0.0 |
574e0d82 | 111 | %{?with_portaudio:Requires: portaudio-devel} |
2adf1e07 JB |
112 | %{?with_pulseaudio:Requires: pulseaudio-devel >= 0.9.21} |
113 | Requires: spandsp-devel >= 0.0.6 | |
f52b820a | 114 | Requires: speex-devel >= 1:1.2-beta3 |
fed1d2a7 | 115 | Requires: speexdsp-devel >= 1.2-beta3 |
c28fe572 | 116 | %{?with_srtp:Requires: libsrtp2-devel} |
2adf1e07 JB |
117 | Requires: xorg-lib-libX11-devel |
118 | Requires: xorg-lib-libXv-devel | |
bbb0ffde AM |
119 | |
120 | %description devel | |
210be78d JB |
121 | Header files and development documentation for mediastreamer |
122 | libraries. | |
2adf1e07 JB |
123 | |
124 | %description devel -l pl.UTF-8 | |
210be78d | 125 | Pliki nagłówkowe i dokumentacja do bibliotek mediastreamer. |
bbb0ffde AM |
126 | |
127 | %package static | |
210be78d JB |
128 | Summary: Static mediastreamer libraries |
129 | Summary(pl.UTF-8): Statyczne biblioteki mediastreamer | |
bbb0ffde | 130 | Group: Development/Libraries |
2adf1e07 | 131 | Requires: %{name}-devel = %{version}-%{release} |
bbb0ffde AM |
132 | |
133 | %description static | |
210be78d | 134 | Static mediastreamer libraries. |
bbb0ffde | 135 | |
2adf1e07 | 136 | %description static -l pl.UTF-8 |
210be78d | 137 | Statyczne biblioteki mediastreamer. |
2adf1e07 | 138 | |
bbb0ffde | 139 | %prep |
348172d7 | 140 | %setup -q -n mediastreamer2-%{version} |
9a501a0e | 141 | %patch0 -p1 |
d8296b8a | 142 | %patch2 -p1 |
c28fe572 AM |
143 | |
144 | [ ! -e gitversion.h ] && echo '#define MS2_GIT_VERSION "%{version}"' > src/gitversion.h | |
bbb0ffde AM |
145 | |
146 | %build | |
9a501a0e | 147 | %{__libtoolize} |
c28fe572 AM |
148 | %{__gettextize} |
149 | %{__intltoolize} | |
9a501a0e AM |
150 | %{__aclocal} |
151 | %{__autoconf} | |
2adf1e07 | 152 | %{__autoheader} |
9a501a0e | 153 | %{__automake} |
61d85515 | 154 | %configure \ |
e4267767 | 155 | --disable-strict \ |
db2ea059 | 156 | --disable-tests \ |
574e0d82 JB |
157 | --enable-alsa%{!?with_alsa:=no} \ |
158 | %{?with_arts:--enable-artsc} \ | |
2adf1e07 | 159 | --enable-external-ortp \ |
348172d7 | 160 | %{?with_bcg729:--enable-g729 --enable-g729bCN} \ |
2adf1e07 | 161 | %{!?with_opengl:--disable-glx} \ |
b49a5518 | 162 | %{!?with_matroska:--disable-matroska} \ |
67eb68d6 | 163 | %{!?with_pcap:--disable-pcap} \ |
574e0d82 JB |
164 | %{?with_portaudio:--enable-portaudio} \ |
165 | --enable-pulseaudio%{!?with_pulseaudio:=no} \ | |
2adf1e07 | 166 | --disable-silent-rules \ |
210be78d | 167 | %{?with_static_libs:--enable-static} \ |
348172d7 | 168 | --enable-upnp \ |
d1086c6e | 169 | %{!?with_zrtp:--disable-zrtp} \ |
574e0d82 | 170 | %{!?with_srtp:--with-srtp=none} |
61d85515 | 171 | |
bbb0ffde AM |
172 | %{__make} |
173 | ||
174 | %install | |
175 | rm -rf $RPM_BUILD_ROOT | |
176 | ||
177 | %{__make} install \ | |
ac6cb6d4 JK |
178 | DESTDIR=$RPM_BUILD_ROOT \ |
179 | install_sh=/usr/bin/install | |
bbb0ffde | 180 | |
86721f5d | 181 | # for external plugins |
dcc81caa | 182 | install -d $RPM_BUILD_ROOT%{_libdir}/mediastreamer/plugins |
86721f5d | 183 | |
61d85515 | 184 | # Remove duplicated documentation |
2adf1e07 | 185 | %{__rm} -r $RPM_BUILD_ROOT/usr/share/doc/%{name}-%{version}/html |
61d85515 | 186 | |
187 | %find_lang %{name} | |
188 | ||
bbb0ffde AM |
189 | %clean |
190 | rm -rf $RPM_BUILD_ROOT | |
191 | ||
192 | %post -p /sbin/ldconfig | |
193 | %postun -p /sbin/ldconfig | |
194 | ||
61d85515 | 195 | %files -f %{name}.lang |
bbb0ffde | 196 | %defattr(644,root,root,755) |
348172d7 | 197 | %doc CHANGELOG.md README.md |
2adf1e07 | 198 | %attr(755,root,root) %{_bindir}/mediastream |
574e0d82 | 199 | %attr(755,root,root) %{_bindir}/msaudiocmp |
2adf1e07 | 200 | %{?with_pcap:%attr(755,root,root) %{_bindir}/pcap_playback} |
45fa5f14 | 201 | %attr(755,root,root) %{_libdir}/libmediastreamer_base.so.*.* |
b16f16f5 | 202 | %attr(755,root,root) %ghost %{_libdir}/libmediastreamer_base.so.10 |
45fa5f14 | 203 | %attr(755,root,root) %{_libdir}/libmediastreamer_voip.so.*.* |
b16f16f5 | 204 | %attr(755,root,root) %ghost %{_libdir}/libmediastreamer_voip.so.10 |
dcc81caa JB |
205 | %dir %{_libdir}/mediastreamer |
206 | %dir %{_libdir}/mediastreamer/plugins | |
348172d7 | 207 | %{_datadir}/mediastreamer |
bbb0ffde AM |
208 | |
209 | %files devel | |
210 | %defattr(644,root,root,755) | |
211 | %doc help/doc/html | |
45fa5f14 JK |
212 | %attr(755,root,root) %{_libdir}/libmediastreamer_base.so |
213 | %attr(755,root,root) %{_libdir}/libmediastreamer_voip.so | |
214 | %{_libdir}/libmediastreamer_base.la | |
215 | %{_libdir}/libmediastreamer_voip.la | |
bbb0ffde AM |
216 | %{_includedir}/mediastreamer2 |
217 | %{_pkgconfigdir}/mediastreamer.pc | |
218 | ||
210be78d | 219 | %if %{with static_libs} |
bbb0ffde AM |
220 | %files static |
221 | %defattr(644,root,root,755) | |
45fa5f14 JK |
222 | %{_libdir}/libmediastreamer_base.a |
223 | %{_libdir}/libmediastreamer_voip.a | |
210be78d | 224 | %endif |