%define betaver beta3 %define tclver 0.2 %define mainver 2.1 %{!?tcl_version: %define tcl_version %(echo 'puts $tcl_version' | tclsh)} %{!?tcl_sitearch: %define tcl_sitearch %{_libdir}/tcl%{tcl_version}} %ifarch sparcv9 %define tkphonearch sparc %else %define tkphonearch %{_arch} %endif Name: iaxclient Version: %{mainver} Release: 0.7.%{betaver}%{?dist} Summary: Library for creating telephony solutions that interoperate with Asterisk Group: System Environment/Libraries License: LGPLv2+ URL: http://iaxclient.wiki.sourceforge.net/ Source0: http://downloads.sourceforge.net/iaxclient/%{name}-%{version}%{betaver}.tar.gz Source1: tkiaxphone.desktop Source2: wxiax.desktop Source3: phone.png Source4: run-tkiaxphone.sh Patch0: iaxclient-2.1beta3-wxGTK28.patch Patch1: iaxclient-2.1beta3-tkphone-cleanups.patch Patch2: iaxclient-2.1beta3-tcl-includedir.patch Patch3: iaxclient-2.1beta3-tcl-libdir.patch Patch4: iaxclient-2.1beta3-tcl-nodoc.patch Patch5: iaxclient-2.1beta3-theora-detection.patch Patch6: iaxclient-2.1beta3-implicit-DSO-libm.patch BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildRequires: speex-devel, libtheora-devel, gsm-devel, portaudio-devel, iax-devel BuildRequires: tk-devel, gtk2-devel, SDL-devel, libogg-devel, liboggz-devel BuildRequires: wxGTK-devel, libvidcap-devel, desktop-file-utils, libtool %description Iaxclient is an open source, multiplatform library for creating telephony solutions that interoperate with Asterisk, the Open Source PBX. Although asterisk supports other VOIP protocols (including SIP, and with patches, H.323), IAX's simple, lightweight nature gives it several advantages, particularly in that it can operate easily through NAT and packet firewalls, and it is easily extensible and simple to understand. Iaxclient pulls together the wide array of open source technologies required for telephony applications. %package devel Summary: Development files for %{name} Group: Development/Libraries Requires: pkgconfig Requires: %{name} = %{mainver}-%{release} %description devel The %{name}-devel package contains libraries and header files for developing applications that use %{name}. %package -n tcl-iaxclient Summary: Tcl interface to iax2 client lib Version: %{tclver} Group: System Environment/Libraries License: BSD Requires: tcl(abi) = 8.5 Requires: %{name} = %{mainver}-%{release} %description -n tcl-iaxclient Tcl extensions to iaxclient libraries. %package -n tkiaxphone Summary: Tk IAX Phone Client Version: %{mainver} Group: Applications/Internet License: LGPLv2+ Requires: tcl(abi) = 8.5 Requires: %{name} = %{mainver}-%{release} %description -n tkiaxphone Tk IAX Phone Client. %package -n wxiax Summary: wx IAX Phone Client Version: %{mainver} Group: Applications/Internet License: LGPLv2+ Requires: %{name} = %{mainver}-%{release} %description -n wxiax wx IAX Phone Client. %prep %setup -q -n %{name}-%{mainver}%{betaver} %patch0 -p1 -b .wxGTK28 %patch1 -p1 -b .tkphone %patch2 -p1 -b .includedir %patch3 -p1 -b .libdir %patch4 -p1 -b .nodoc %patch5 -p1 -b .theoradetect %patch6 -p1 -b .DSO autoreconf chmod -x contrib/tcl/README.txt sed -i 's|/usr/lib|%{_libdir}|g' lib/libiax2/iax-config.in %build %configure --disable-static # sed -i 's|^hardcode_libdir_flag_spec=.*|hardcode_libdir_flag_spec=""|g' libtool # sed -i 's|^runpath_var=LD_RUN_PATH|runpath_var=DIE_RPATH_DIE|g' libtool make %{?_smp_mflags} LIBTOOL="%{_bindir}/libtool" cd contrib/tcl/ %configure make %{?_smp_mflags} LIBTOOL="%{_bindir}/libtool" %install rm -rf %{buildroot} make install DESTDIR=%{buildroot} LIBTOOL="%{_bindir}/libtool" find %{buildroot} -name '*.la' -exec rm -f {} ';' find %{buildroot} -name '*.a' -exec rm -f {} ';' install -d %{buildroot}%{tcl_sitearch} mv %{buildroot}%{_libdir}/iaxclient %{buildroot}%{tcl_sitearch}/ cd contrib/tcl make install DESTDIR=%{buildroot} LIBTOOL="%{_bindir}/libtool" mv %{buildroot}%{_libdir}/tcliaxclient0.2 %{buildroot}%{tcl_sitearch}/tcliaxclient0.2 chmod +x %{buildroot}%{tcl_sitearch}/iaxclient/tkphone/phone.ui.tcl chmod +x %{buildroot}%{tcl_sitearch}/iaxclient/tkphone/pref.ui.tcl install -p %{SOURCE4} %{buildroot}%{_bindir} mkdir %{buildroot}%{_datadir}/pixmaps/ install -p %{SOURCE3} %{buildroot}%{_datadir}/pixmaps/tkiaxphone.png install -p %{SOURCE3} %{buildroot}%{_datadir}/pixmaps/wxiax.png mkdir %{buildroot}%{_datadir}/applications/ desktop-file-install --vendor "" \ --dir $RPM_BUILD_ROOT%{_datadir}/applications \ %{SOURCE1} desktop-file-install --vendor "" \ --dir $RPM_BUILD_ROOT%{_datadir}/applications \ %{SOURCE2} cd %{buildroot}%{tcl_sitearch}/iaxclient/tkphone/ ln -s iaxcli iaxcli-Linux-%{tkphonearch} %clean rm -rf %{buildroot} %post -p /sbin/ldconfig %postun -p /sbin/ldconfig %files %defattr(-,root,root,-) %doc AUTHORS COPYING.LIB ChangeLog README %{_bindir}/iaxcomm %{_bindir}/iaxphone %{_datadir}/iaxcomm/ %{_libdir}/libiaxclient.so.* %files devel %defattr(-,root,root,-) %{_bindir}/stresstest %{_bindir}/testcall %{_bindir}/vtestcall %{_includedir}/iaxclient.h %{_libdir}/libiaxclient.so %{_libdir}/pkgconfig/iaxclient.pc %files -n tcl-iaxclient %defattr(-,root,root,-) %doc contrib/tcl/README.txt %{tcl_sitearch}/tcliaxclient0.2/ %files -n tkiaxphone %defattr(-,root,root,-) %{_bindir}/run-tkiaxphone.sh %{_bindir}/tkiaxphone %{tcl_sitearch}/iaxclient/ %{_datadir}/applications/tkiaxphone.desktop %{_datadir}/pixmaps/tkiaxphone.png %files -n wxiax %defattr(-,root,root,-) %{_bindir}/wxiax %{_datadir}/applications/wxiax.desktop %{_datadir}/pixmaps/wxiax.png %changelog * Wed Jul 14 2010 Dan Horák <dan@danny.cz> - 2.1-0.7.beta3 - rebuilt against wxGTK-2.8.11-2 * Wed Jun 02 2010 Rakesh Pandit <rakesh@fedoraproject.org> - 2.1-0.6.beta3 - Bump for new liboggz lib * Wed Feb 10 2010 Tom "spot" Callaway <tcallawa@redhat.com> - 2.1-0.5.beta3 - fix implicit DSO linking issue with libm * Fri Jul 24 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2.1-0.4.beta3 - Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild * Thu Mar 12 2009 Tom "spot" Callaway <tcallawa@redhat.com> 2.1-0.3.beta3 - fix lib/libiax2/iax-config.in to not use wrong /usr/lib * Mon Nov 3 2008 Tom "spot" Callaway <tcallawa@redhat.com> 2.1-0.2.beta3 - fix theora detection * Tue Jun 10 2008 Tom "spot" Callaway <tcallawa@redhat.com> 2.1-0.1.beta3 - Initial package for Fedora