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