]> git.pld-linux.org Git - packages/opal.git/blame - opal.spec
- changed exceptions patch so that it affects only vpb plugin;
[packages/opal.git] / opal.spec
CommitLineData
4811172d 1# TODO:
a7e6bfef 2# SBC plugin is missing bluez_sbc subdir
c0a25d84 3# fix static libname (libopal_s.a)
7d38eb5a 4# MPEG4 rate control correction requires libavcodec sources
9008d5d2 5# NOTE: IPv6 support requires IPv6 support in ptlib
5683c404 6#
383877b6 7# WARNING: opal version should match Ekiga and ptlib versions
5b46c6b6 8# Recommendations: http://wiki.ekiga.org/index.php/Download_Ekiga_sources
383877b6 9#
12913987 10# Conditional build:
9008d5d2 11%bcond_with sip_fax_only # minimal build for t38modem + SIP
a7e6bfef 12%bcond_without celt # CELT codec support
9008d5d2 13%bcond_without srtp # SRTP protocol support (mutually exclusive with zrtp)
cee58fd7 14%bcond_with zrtp # ZRTP protocol support (mutually exclusive with zrtp; broken as of 3.10.9)
9008d5d2 15%bcond_without capi # CAPI support
b3f5804c
JB
16%bcond_without vpb # Voicetronix VPB support
17%bcond_with java # Java JNI interface (only swig wrapper, Java part not built)
18%bcond_with ruby # Ruby interface (very initial, only swig wrapper)
12913987 19#
9008d5d2
JB
20%if %{with zrtp}
21%undefine with_srtp
22%endif
23%if %{with sip_fax_only}
b3f5804c
JB
24%undefine with_java
25%undefine with_ruby
9008d5d2
JB
26%undefine with_srtp
27%undefine with_zrtp
28%endif
aaf12cf0 29Summary: Open Phone Abstraction Library (aka OpenH323 v2)
075bc36b 30Summary(pl.UTF-8): Biblioteka Open Phone Abstraction Library (aka OpenH323 v2)
aaf12cf0 31Name: opal
a7e6bfef
JB
32Version: 3.10.9
33Release: 1
34License: MPL v1.0
aaf12cf0 35Group: Libraries
f7ddb932 36Source0: http://downloads.sourceforge.net/opalvoip/%{name}-%{version}.tar.bz2
a7e6bfef 37# Source0-md5: f5dee986b7ae0d840bcc502785ea5bd7
e377535f 38Patch0: %{name}-build.patch
a7e6bfef
JB
39Patch1: %{name}-ffmpeg10.patch
40Patch2: %{name}-sh.patch
41Patch3: %{name}-libilbc.patch
42Patch4: %{name}-ah.patch
cee58fd7 43Patch5: %{name}-exceptions.patch
b3f5804c 44Patch6: %{name}-ruby.patch
a7e6bfef
JB
45URL: http://www.opalvoip.org/
46BuildRequires: autoconf >= 2.50
105bdcf7 47BuildRequires: automake
9008d5d2 48%{?with_capi:BuildRequires: capi4k-utils-devel}
24ae7846 49%{?with_celt:BuildRequires: celt-devel}
105bdcf7 50BuildRequires: expat-devel
12913987 51BuildRequires: libstdc++-devel
cee58fd7 52%{?with_zrtp:BuildRequires: libzrtp-devel}
12913987 53BuildRequires: pkgconfig
a7e6bfef 54BuildRequires: ptlib-devel >= 1:2.10.9
12913987 55BuildRequires: sed >= 4.0
9008d5d2
JB
56# with speexdsp
57BuildRequires: speex-devel >= 1:1.2
58%{?with_srtp:BuildRequires: srtp-devel}
12913987
MM
59%if %{without sip_fax_only}
60BuildRequires: SDL-devel
a7e6bfef 61# libavcodec >= 51.11.0 libavutil
7d38eb5a 62BuildRequires: ffmpeg-devel
a7e6bfef 63%{?with_java:BuildRequires: jdk}
7d38eb5a 64BuildRequires: libgsm-devel
7d38eb5a 65BuildRequires: libtheora-devel
cee58fd7 66%{?with_vpb:BuildRequires: vpb-devel}
a7e6bfef
JB
67# ABI 0.102
68BuildRequires: libx264-devel >= 0.1.3-1.20101031_2245.1
b4fd80b4 69BuildRequires: webrtc-libilbc-devel
fda4b81c 70BuildRequires: openssl-devel
a7e6bfef 71%{?with_ruby:BuildRequires: ruby-devel}
a7e6bfef
JB
72BuildRequires: spandsp-devel
73BuildRequires: swig
105bdcf7 74BuildRequires: unixODBC-devel
12913987 75%endif
d2161d53 76%requires_eq ptlib
aaf12cf0
PG
77BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
78
79%description
0a401c5c
CM
80The OPAL project aims to create a full featured, interoperable, Open
81Source implementation of the ITU H.323 teleconferencing protocol that
82can be used by personal developers and commercial users without
aaf12cf0
PG
83charge.
84
a2a27970
JR
85%description -l pl.UTF-8
86Celem projektu OPAL jest stworzenie w pełni funkcjonalnej i
87wyposażonej implementacji protokołu telekonferencyjnego ITU H.323,
88który może być używany przez użytkowników prywatnych i komercyjnych
89bez opłat.
aaf12cf0 90
b3f5804c
JB
91%package lid-vpb
92Summary: Opal LID plugin for Voicetronix VPB devices
93Summary(pl.UTF-8): Wtyczka Opal LID dla urządzeń VPB firmy Voicetronix
94Group: Libraries
95Requires: %{name} = %{version}-%{release}
96
97%description lid-vpb
98Opal LID plugin for Voicetronix VPB devices.
99
100%description lid-vpb -l pl.UTF-8
101Wtyczka Opal LID dla urządzeń VPB firmy Voicetronix.
102
aaf12cf0
PG
103%package devel
104Summary: Opal development files
075bc36b 105Summary(pl.UTF-8): Pliki dla developerów Opal
aaf12cf0 106Group: Development/Libraries
5e9f9381 107Requires: %{name} = %{version}-%{release}
9008d5d2 108%{?with_capi:Requires: capi4k-utils-devel}
aaf12cf0 109Requires: libstdc++-devel
cee58fd7 110%{?with_zrtp:Requires: libzrtp-devel}
a7e6bfef 111Requires: ptlib-devel >= 1:2.10.9
9008d5d2
JB
112Requires: speex-devel >= 1:1.2
113%{?with_srtp:Requires: srtp-devel}
aaf12cf0
PG
114
115%description devel
0a401c5c 116Header files and libraries for developing applications that use OPAL.
aaf12cf0 117
a2a27970
JR
118%description devel -l pl.UTF-8
119Pliki nagłówkowe i biblioteki konieczne do rozwoju aplikacji
120używających OPAL.
aaf12cf0 121
0a847dbc 122%package static
296d779e 123Summary: OPAL static libraries
075bc36b 124Summary(pl.UTF-8): Biblioteki statyczne OPAL
0a847dbc 125Group: Development/Libraries
5e9f9381 126Requires: %{name}-devel = %{version}-%{release}
aaf12cf0 127
0a847dbc 128%description static
296d779e 129OPAL static libraries.
aaf12cf0 130
a2a27970 131%description static -l pl.UTF-8
296d779e 132Biblioteki statyczne OPAL.
aaf12cf0
PG
133
134%prep
8db2f0fb 135%setup -q
e377535f
JR
136%patch0 -p1
137%patch1 -p1
79955eae 138%patch2 -p1
a7e6bfef
JB
139%patch3 -p1
140%patch4 -p1
b3f5804c
JB
141%patch5 -p1
142%patch6 -p1
aaf12cf0
PG
143
144%build
b0b5ec3f 145PWLIBDIR=%{_prefix}; export PWLIBDIR
296d779e 146OPALDIR=`pwd`; export OPALDIR
c1724659 147OPAL_BUILD="yes"; export OPAL_BUILD
323ecc81
SS
148%{__aclocal}
149%{__autoconf}
a7e6bfef 150# don't run autoheader here, include/opal/buildopts.h.in is manually written
b8ea5cae 151cd plugins
0a401c5c 152%{__aclocal}
b8ea5cae 153%{__autoconf}
a7e6bfef 154%{__autoheader}
b8ea5cae 155cd ..
12913987 156# Run grep '^OPAL_.*=' configure.ac|grep 'yes\|no' to check current defaults
7d38eb5a 157%configure \
b3f5804c 158 %{?with_java:JDK_ROOT=%{_jvmdir}/java} \
12913987 159%if %{with sip_fax_only}
a7e6bfef
JB
160 --disable-aec \
161 --disable-g711plc \
12913987
MM
162 --disable-h224 \
163 --disable-h281 \
a7e6bfef 164 --disable-h323 \
12913987
MM
165 --disable-h450 \
166 --disable-h460 \
167 --disable-h501 \
a7e6bfef 168 --disable-iax \
12913987 169 --disable-ivr \
a7e6bfef 170 --disable-lid \
12913987 171 --disable-plugins
a7e6bfef
JB
172 --disable-rfc4103 \
173 --disable-rfc4175 \
174 --disable-sipim \
175 --disable-video \
12913987 176%else
b3f5804c
JB
177 --enable-ixj \
178%endif
9008d5d2 179 %{!?with_capi:--disable-capi} \
a7e6bfef 180 %{!?with_celt:--disable-celt} \
b3f5804c
JB
181 %{!?with_java:--disable-java} \
182 %{!?with_ruby:--disable-ruby} \
9008d5d2
JB
183 %{!?with_srtp:--disable-srtp} \
184 %{?with_vpb:--enable-vpb} \
cee58fd7
JB
185%if %{with zrtp}
186 --enable-zrtp \
187 --with-bn-includedir=/usr/include \
188 --with-bn-libdir=%{_libdir} \
189 --with-zrtp-includedir=/usr/include/libzrtp \
190 --with-zrtp-libdir=%{_libdir}
191%endif
12913987 192
c1724659 193%{__make} %{?debug:debug}%{!?debug:opt} \
296d779e
JR
194 CC="%{__cc}" \
195 CPLUS="%{__cxx}" \
a7e6bfef
JB
196 OPTCCFLAGS="%{rpmcflags} %{!?debug:-DNDEBUG}" \
197 VERBOSE=1
b0b5ec3f 198
c0a25d84 199%{__cp} -a */libopal* .
12913987 200%if %{without sip_fax_only}
c1724659 201%{__make} -C samples/simple %{?debug:debug}%{!?debug:opt} \
296d779e 202 CC="%{__cc}" \
5ce6a9aa 203 CPLUS="%{__cxx}" \
c0a25d84
SS
204 CFLAGS="%{rpmcflags} %{!?debug:-DNDEBUG} -I`pwd`/include" \
205 LDFLAGS="%{rpmldflags} -L`pwd` -lpt -lopal"
12913987 206%endif
aaf12cf0
PG
207
208%install
209rm -rf $RPM_BUILD_ROOT
4733c726 210install -d $RPM_BUILD_ROOT%{_bindir}
b0b5ec3f 211
212%{__make} install \
213 DESTDIR=$RPM_BUILD_ROOT
aaf12cf0 214
12913987
MM
215%{!?with_sip_fax_only:install samples/simple/obj/simpleopal $RPM_BUILD_ROOT%{_bindir}}
216
4a7dfbfa 217# This needs to be done after 'make install'
7057c46b
JB
218%{__sed} \
219 -e 's,^OPALDIR.*=.*$,OPALDIR\t\t\t\t= %{_libdir}/opal-%{version},;' \
220 -e 's,^OPAL_SRCDIR.*=.*$,OPAL_SRCDIR\t\t\t= %{_usrsrc}/debug/opal-%{version},;' \
221 -e 's,^OPAL_INCDIR.*=.*$,OPAL_INCDIR\t\t\t= %{_includedir}/opal,;' \
222 -e 's,^OPAL_LIBDIR.*=.*$,OPAL_LIBDIR\t\t\t= %{_libdir},;' \
223 opal_defs.mak > $RPM_BUILD_ROOT%{_includedir}/opal/opal_defs.mak
224cp -p opal_inc.mak $RPM_BUILD_ROOT%{_includedir}/opal
aaf12cf0
PG
225
226%clean
227rm -rf $RPM_BUILD_ROOT
228
229%post -p /sbin/ldconfig
230%postun -p /sbin/ldconfig
231
232%files
233%defattr(644,root,root,755)
a7e6bfef 234%attr(755,root,root) %{_libdir}/libopal.so.%{version}
12913987 235%if %{without sip_fax_only}
a7e6bfef 236%attr(755,root,root) %{_bindir}/simpleopal
0dd5a601 237%dir %{_libdir}/opal-%{version}
238%dir %{_libdir}/opal-%{version}/codecs
239%dir %{_libdir}/opal-%{version}/codecs/audio
24ae7846
JR
240%{?with_celt:%attr(755,root,root) %{_libdir}/opal-%{version}/codecs/audio/celt_ptplugin.so}
241%attr(755,root,root) %{_libdir}/opal-%{version}/codecs/audio/g722_ptplugin.so
242%attr(755,root,root) %{_libdir}/opal-%{version}/codecs/audio/g7221_ptplugin.so
243%attr(755,root,root) %{_libdir}/opal-%{version}/codecs/audio/g7222_ptplugin.so
244%attr(755,root,root) %{_libdir}/opal-%{version}/codecs/audio/g726_ptplugin.so
245%attr(755,root,root) %{_libdir}/opal-%{version}/codecs/audio/gsm0610_ptplugin.so
246%attr(755,root,root) %{_libdir}/opal-%{version}/codecs/audio/gsmamrcodec_ptplugin.so
247%attr(755,root,root) %{_libdir}/opal-%{version}/codecs/audio/iLBC_ptplugin.so
248%attr(755,root,root) %{_libdir}/opal-%{version}/codecs/audio/ima_adpcm_ptplugin.so
249%attr(755,root,root) %{_libdir}/opal-%{version}/codecs/audio/lpc10_ptplugin.so
250%attr(755,root,root) %{_libdir}/opal-%{version}/codecs/audio/silk_ptplugin.so
251%attr(755,root,root) %{_libdir}/opal-%{version}/codecs/audio/speex_ptplugin.so
a7e6bfef 252%dir %{_libdir}/opal-%{version}/codecs/video
24ae7846
JR
253%attr(755,root,root) %{_libdir}/opal-%{version}/codecs/video/h261_vic_ptplugin.so
254%attr(755,root,root) %{_libdir}/opal-%{version}/codecs/video/h263_ffmpeg_ptplugin.so
bc09e567 255%attr(755,root,root) %{_libdir}/opal-%{version}/codecs/video/h264_video_pwplugin_helper
24ae7846
JR
256%attr(755,root,root) %{_libdir}/opal-%{version}/codecs/video/h264_x264_ptplugin.so
257%attr(755,root,root) %{_libdir}/opal-%{version}/codecs/video/mpeg4_ffmpeg_ptplugin.so
258%attr(755,root,root) %{_libdir}/opal-%{version}/codecs/video/theora_ptplugin.so
a7e6bfef
JB
259%dir %{_libdir}/opal-%{version}/fax
260%attr(755,root,root) %{_libdir}/opal-%{version}/fax/spandsp_ptplugin.so
261%dir %{_libdir}/opal-%{version}/lid
0dd5a601 262%attr(755,root,root) %{_libdir}/opal-%{version}/lid/ixj_lid_pwplugin.so
b3f5804c
JB
263%endif
264
265%if %{with vpb}
266%files lid-vpb
267%defattr(644,root,root,755)
268%attr(755,root,root) %{_libdir}/opal-%{version}/lid/vpb_ptplugin.so
12913987 269%endif
aaf12cf0
PG
270
271%files devel
272%defattr(644,root,root,755)
a7e6bfef 273%attr(755,root,root) %{_libdir}/libopal.so
4733c726
SS
274%{_includedir}/opal
275%{_pkgconfigdir}/opal.pc
aaf12cf0 276
296d779e
JR
277%files static
278%defattr(644,root,root,755)
a7e6bfef 279%{_libdir}/libopal_s.a
This page took 0.573729 seconds and 4 git commands to generate.