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