]>
Commit | Line | Data |
---|---|---|
574e0d82 | 1 | # TODO: |
210be78d | 2 | # - switch to mbledtls when 2.x is supported (mbed_ssl_init instead of ssl_init) |
b49a5518 | 3 | # - dtls (polarssl/mbedtls >= 1.4 with DTLS-SRTP support, not released yet) |
2adf1e07 JB |
4 | # |
5 | # Conditional build: | |
574e0d82 | 6 | %bcond_without bcg729 # support for G279AnnexB in RTC3389 implementation of Comfort Noise Payload |
b49a5518 | 7 | %bcond_without srtp # SRTP (secure RTP) support |
d1086c6e | 8 | %bcond_without zrtp # support for RFC 6189: Media Path Key Agreement for Unicast Secure RTP |
b49a5518 | 9 | %bcond_without matroska # Matroska support via libebml2/libmatroska2 |
2adf1e07 JB |
10 | %bcond_without opengl # X11+OpenGL rendering support |
11 | %bcond_with pcap # audio playing from PCAP files | |
574e0d82 JB |
12 | # audio I/O |
13 | %bcond_without alsa # ALSA sound I/O support | |
14 | %bcond_with arts # aRts sound I/O support | |
15 | %bcond_with portaudio # PortAudio sound I/O support | |
16 | %bcond_without pulseaudio # PulseAudio sound I/O support | |
210be78d | 17 | %bcond_without static_libs # static library |
2adf1e07 | 18 | # |
bbb0ffde | 19 | Summary: Audio/Video real-time streaming |
2adf1e07 | 20 | Summary(pl.UTF-8): Przesyłanie strumieni audio/video w czasie rzeczywistym |
bbb0ffde | 21 | Name: mediastreamer |
ac6cb6d4 | 22 | Version: 2.12.1 |
a47a4ae0 | 23 | Release: 4 |
2adf1e07 | 24 | License: GPL v2+ |
bbb0ffde | 25 | Group: Libraries |
2adf1e07 | 26 | Source0: http://download-mirror.savannah.gnu.org/releases/linphone/mediastreamer/%{name}-%{version}.tar.gz |
ac6cb6d4 | 27 | # Source0-md5: 1ca115e94a718638fbecf8352c169861 |
45fa5f14 | 28 | Patch0: %{name}-imagedir.patch |
210be78d | 29 | Patch1: %{name}-ffmpeg.patch |
5451b942 | 30 | Patch2: %{name}-werror.patch |
e4267767 | 31 | Patch3: ffmpeg4.patch |
b49a5518 | 32 | URL: http://www.linphone.org/technical-corner/mediastreamer2/overview |
2adf1e07 JB |
33 | %{?with_opengl:BuildRequires: OpenGL-GLX-devel} |
34 | BuildRequires: SDL-devel >= 1.2.0 | |
574e0d82 JB |
35 | %{?with_alsa:BuildRequires: alsa-lib-devel} |
36 | %{?with_arts:BuildRequires: artsc-devel} | |
bbb0ffde | 37 | BuildRequires: autoconf >= 2.53 |
aa0ebe9a | 38 | BuildRequires: automake >= 1:1.9 |
574e0d82 | 39 | %{?with_bcg729:BuildRequires: bcg729-devel >= 1.0} |
d1086c6e | 40 | %{?with_zrtp:BuildRequires: bzrtp-devel >= 1.0.0} |
bbb0ffde | 41 | BuildRequires: doxygen |
2adf1e07 | 42 | # libavcodec >= 51.0.0, libswscale >= 0.7.0 |
bbb0ffde | 43 | BuildRequires: ffmpeg-devel |
c07fcbab | 44 | BuildRequires: gettext-tools |
2adf1e07 | 45 | %{?with_opengl:BuildRequires: glew-devel >= 1.5} |
bbb0ffde | 46 | BuildRequires: jack-audio-connection-kit-devel |
2adf1e07 | 47 | BuildRequires: intltool >= 0.40 |
bbb0ffde | 48 | BuildRequires: libgsm-devel |
2adf1e07 JB |
49 | %{?with_pcap:BuildRequires: libpcap-devel} |
50 | BuildRequires: libtheora-devel >= 1.0-0.alpha7 | |
51 | BuildRequires: libtool >= 2:2 | |
52 | BuildRequires: libupnp-devel >= 1.6 | |
53 | BuildRequires: libupnp-devel < 1.7 | |
bbb0ffde | 54 | BuildRequires: libv4l-devel |
2adf1e07 | 55 | BuildRequires: libvpx-devel >= 0.9.6 |
b49a5518 | 56 | %{?with_matroska:BuildRequires: matroska-foundation-devel} |
2adf1e07 | 57 | BuildRequires: opus-devel >= 0.9.0 |
574e0d82 | 58 | BuildRequires: ortp-devel >= 0.24.0 |
bbb0ffde | 59 | BuildRequires: pkgconfig |
574e0d82 JB |
60 | BuildRequires: polarssl-devel |
61 | %{?with_portaudio:BuildRequires: portaudio-devel} | |
2adf1e07 | 62 | %{?with_pulseaudio:BuildRequires: pulseaudio-devel >= 0.9.21} |
61d85515 | 63 | BuildRequires: sed >= 4.0 |
2adf1e07 | 64 | BuildRequires: spandsp-devel >= 0.0.6 |
f52b820a | 65 | BuildRequires: speex-devel >= 1:1.2-beta3 |
fed1d2a7 | 66 | BuildRequires: speexdsp-devel >= 1.2-beta3 |
574e0d82 | 67 | %{?with_srtp:BuildRequires: srtp-devel} |
bbb0ffde | 68 | BuildRequires: xorg-lib-libX11-devel |
61d85515 | 69 | BuildRequires: xorg-lib-libXv-devel |
45fa5f14 | 70 | BuildRequires: xxd |
574e0d82 | 71 | %{?with_bcg729:Requires: bcg729 >= 1.0} |
d1086c6e | 72 | %{?with_zrtp:Requires: bzrtp >= 1.0.0} |
2adf1e07 JB |
73 | %{?with_opengl:Requires: glew >= 1.5} |
74 | Requires: libtheora >= 1.0-0.alpha7 | |
75 | Requires: libupnp >= 1.6 | |
76 | Requires: libvpx >= 0.9.6 | |
77 | Requires: opus >= 0.9.0 | |
574e0d82 | 78 | Requires: ortp >= 0.24.0 |
2adf1e07 | 79 | %{?with_pulseaudio:Requires: pulseaudio-libs >= 0.9.21} |
e6d0cfff | 80 | Requires: spandsp >= 0.0.6 |
f52b820a | 81 | Requires: speex >= 1:1.2-beta3 |
fed1d2a7 | 82 | Requires: speexdsp >= 1.2-beta3 |
bbb0ffde AM |
83 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
84 | ||
85 | %description | |
86 | Mediastreamer2 is a GPL licensed library to make audio and video | |
87 | real-time streaming and processing. Written in pure C, it is based | |
88 | upon the oRTP library. | |
89 | ||
2adf1e07 JB |
90 | %description -l pl.UTF-8 |
91 | Mediastreamer2 to udostępniona na licencji GPL biblioteka do | |
92 | przesyłania i przetwarzania strumieni audio/video w czasie | |
93 | rzeczywistym. Jest napisana w czystym C, oparta na bibliotece oRTP. | |
94 | ||
bbb0ffde | 95 | %package devel |
210be78d JB |
96 | Summary: Header files and development documentation for mediastreamer libraries |
97 | Summary(pl.UTF-8): Pliki nagłówkowe i dokumentacja do bibliotek mediastreamer | |
bbb0ffde | 98 | Group: Development/Libraries |
2adf1e07 JB |
99 | Requires: %{name} = %{version}-%{release} |
100 | %{?with_opengl:Requires: OpenGL-devel} | |
574e0d82 JB |
101 | %{?with_alsa:Requires: alsa-lib-devel} |
102 | %{?with_bcg729:Requires: bcg729-devel >= 1.0} | |
d1086c6e | 103 | %{?with_zrtp:Requires: bzrtp-devel >= 1.0.0} |
2adf1e07 JB |
104 | Requires: ffmpeg-devel |
105 | %{?with_opengl:Requires: glew-devel >= 1.5} | |
106 | Requires: libtheora-devel >= 1.0-0.alpha7 | |
107 | Requires: libupnp-devel >= 1.6 | |
108 | Requires: libupnp-devel < 1.7 | |
109 | Requires: libv4l-devel | |
110 | Requires: libvpx-devel >= 0.9.6 | |
b49a5518 | 111 | %{?with_matroska:Requires: matroska-foundation-devel} |
2adf1e07 | 112 | Requires: opus-devel >= 0.9.0 |
574e0d82 JB |
113 | Requires: ortp-devel >= 0.24.0 |
114 | Requires: polarssl-devel | |
115 | %{?with_portaudio:Requires: portaudio-devel} | |
2adf1e07 JB |
116 | %{?with_pulseaudio:Requires: pulseaudio-devel >= 0.9.21} |
117 | Requires: spandsp-devel >= 0.0.6 | |
f52b820a | 118 | Requires: speex-devel >= 1:1.2-beta3 |
fed1d2a7 | 119 | Requires: speexdsp-devel >= 1.2-beta3 |
574e0d82 | 120 | %{?with_srtp:Requires: srtp-devel} |
2adf1e07 JB |
121 | Requires: xorg-lib-libX11-devel |
122 | Requires: xorg-lib-libXv-devel | |
bbb0ffde AM |
123 | |
124 | %description devel | |
210be78d JB |
125 | Header files and development documentation for mediastreamer |
126 | libraries. | |
2adf1e07 JB |
127 | |
128 | %description devel -l pl.UTF-8 | |
210be78d | 129 | Pliki nagłówkowe i dokumentacja do bibliotek mediastreamer. |
bbb0ffde AM |
130 | |
131 | %package static | |
210be78d JB |
132 | Summary: Static mediastreamer libraries |
133 | Summary(pl.UTF-8): Statyczne biblioteki mediastreamer | |
bbb0ffde | 134 | Group: Development/Libraries |
2adf1e07 | 135 | Requires: %{name}-devel = %{version}-%{release} |
bbb0ffde AM |
136 | |
137 | %description static | |
210be78d | 138 | Static mediastreamer libraries. |
bbb0ffde | 139 | |
2adf1e07 | 140 | %description static -l pl.UTF-8 |
210be78d | 141 | Statyczne biblioteki mediastreamer. |
2adf1e07 | 142 | |
bbb0ffde AM |
143 | %prep |
144 | %setup -q | |
9a501a0e | 145 | %patch0 -p1 |
210be78d | 146 | %patch1 -p1 |
5451b942 | 147 | %patch2 -p1 |
e4267767 | 148 | %patch3 -p1 |
bbb0ffde AM |
149 | |
150 | %build | |
9a501a0e AM |
151 | %{__libtoolize} |
152 | %{__aclocal} | |
153 | %{__autoconf} | |
2adf1e07 | 154 | %{__autoheader} |
9a501a0e | 155 | %{__automake} |
61d85515 | 156 | %configure \ |
e4267767 | 157 | --disable-strict \ |
574e0d82 JB |
158 | --enable-alsa%{!?with_alsa:=no} \ |
159 | %{?with_arts:--enable-artsc} \ | |
160 | %{?with_bcg729:--enable-bcg729} \ | |
2adf1e07 JB |
161 | --enable-external-ortp \ |
162 | %{!?with_opengl:--disable-glx} \ | |
b49a5518 | 163 | %{!?with_matroska:--disable-matroska} \ |
2adf1e07 | 164 | %{?with_pcap:--enable-pcap} \ |
574e0d82 JB |
165 | %{?with_portaudio:--enable-portaudio} \ |
166 | --enable-pulseaudio%{!?with_pulseaudio:=no} \ | |
2adf1e07 | 167 | --disable-silent-rules \ |
210be78d | 168 | %{?with_static_libs:--enable-static} \ |
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) |
2adf1e07 JB |
197 | %doc AUTHORS ChangeLog NEWS README |
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.*.* |
210be78d | 202 | %attr(755,root,root) %ghost %{_libdir}/libmediastreamer_base.so.6 |
45fa5f14 | 203 | %attr(755,root,root) %{_libdir}/libmediastreamer_voip.so.*.* |
210be78d | 204 | %attr(755,root,root) %ghost %{_libdir}/libmediastreamer_voip.so.6 |
dcc81caa JB |
205 | %dir %{_libdir}/mediastreamer |
206 | %dir %{_libdir}/mediastreamer/plugins | |
45fa5f14 | 207 | %{_pixmapsdir}/%{name} |
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 |