File linphone.spec of Package linphone
#
# spec file for package linphone
#
# Copyright (c) 2014 SUSE LINUX Products GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via http://bugs.opensuse.org/
#
Name: linphone
Version: 3.7.0
Release: 0
Summary: Web Phone
License: GPL-2.0+
Group: Productivity/Networking/Other
Url: http://www.linphone.org
Source0: http://download.savannah.gnu.org/releases/linphone/3.7.x/sources/%{name}-%{version}.tar.gz
Source1: %{name}-manual.tar.bz2
BuildRequires: gcc-c++
BuildRequires: intltool
BuildRequires: libeXosip2-devel
BuildRequires: libgsm-devel
BuildRequires: libtool
BuildRequires: readline-devel
BuildRequires: pkgconfig(alsa)
BuildRequires: pkgconfig(belle-sip)
BuildRequires: pkgconfig(gtk+-2.0) >= 2.18.0
BuildRequires: pkgconfig(libnotify)
BuildRequires: pkgconfig(libosip2)
BuildRequires: pkgconfig(libpulse)
BuildRequires: pkgconfig(libsoup-2.4)
BuildRequires: pkgconfig(libv4l2) >= 0.8.4
BuildRequires: pkgconfig(libzrtpcpp) >= 4.0
BuildRequires: pkgconfig(mediastreamer) >= 2.10.0
BuildRequires: pkgconfig(ortp) >= 0.23.0
BuildRequires: pkgconfig(speex)
BuildRequires: pkgconfig(sqlite3)
%if 0%{?suse_version}
BuildRequires: fdupes
BuildRequires: translation-update-upstream
BuildRequires: update-desktop-files
%endif
# Video support - disabled by default due to patent issues
%if 0%{?packman_bs}
BuildRequires: libffmpeg-devel
BuildRequires: pkgconfig(gl)
BuildRequires: pkgconfig(glew)
BuildRequires: pkgconfig(vpx)
BuildRequires: pkgconfig(xv)
%endif
BuildRoot: %{_tmppath}/%{name}-%{version}-build
%description
Linphone is a Web phone with a GNOME interface. It lets you make
two-party calls over IP networks such as the Internet. It uses the IETF
protocols SIP (Session Initiation Protocol) and RTP (Realtime TransporT
Protocol) to make calls, so it should be able to communicate with other
SIP-based Web phones. With several codecs available, it can be used
with high speed connections as well as 28k modems.
%package devel
Summary: Web Phone
Group: Development/Libraries/Other
Requires: %{name} = %{version}
Requires: glibc-devel
Requires: libeXosip2-devel
Requires: libosip2-devel
Requires: pkgconfig(alsa)
Requires: pkgconfig(glib-2.0)
Requires: pkgconfig(speex)
%if 0%{?packman_bs}
Requires: libffmpeg-devel
Requires: pkgconfig(xv)
%endif
%description devel
Linphone is a Web phone with a GNOME interface. It lets you make
two-party calls over IP networks such as the Internet. It uses the IETF
protocols SIP (Session Initiation Protocol) and RTP (Realtime TransporT
Protocol) to make calls, so it should be able to communicate with other
SIP-based Web phones. With several codecs available, it can be used
with high speed connections as well as 28k modems.
%prep
%setup -q
# set tutorial path inside linphone in _datadir
sed -e "s|\$(datadir)/tutorials/linphone|\$(datadir)/linphone/tutorials|" -i coreapi/help/Makefile.{in,am}
%build
%configure \
--disable-strict \
--docdir=%{_docdir} \
--enable-alsa \
--enable-pulseaudio \
--enable-ipv6 \
--enable-external-ortp \
--enable-external-mediastreamer \
--enable-zrtp \
%if !0%{?packman_bs}
--disable-video \
%endif
--disable-static
make %{?_smp_mflags}
%install
%makeinstall
# install manual
tar -xjC %{buildroot}%{_datadir}/gnome/help/ -f %{SOURCE1}
# install desktop file
%suse_update_desktop_file -r -D "linphone/index.xml.html" -G "SIP Phone" %{name} Network Telephony
%find_lang %{name}
# delete unused man pages
rm -rf %{buildroot}%{_mandir}/cs/
# no need to package la files
rm -f %{buildroot}%{_libdir}/*.*a
# remove duplicate COPYING
rm -rf %{buildroot}%{_datadir}/%{name}/COPYING
%fdupes %{buildroot}
%post -p /sbin/ldconfig
%postun -p /sbin/ldconfig
%files -f %{name}.lang
%defattr(-,root,root)
%{_bindir}/*
%{_datadir}/sounds/linphone
%{_libdir}/*.so.*
%{_datadir}/linphone
%exclude %{_datadir}/linphone/tutorials
%{_datadir}/pixmaps/linphone
%doc %{_mandir}/man1/*.*
%{_datadir}/applications/linphone.desktop
%dir %{_datadir}/gnome
%dir %{_datadir}/gnome/help
%doc NEWS AUTHORS COPYING
%files devel
%defattr(-,root,root)
%{_includedir}/linphone
%{_libdir}/*.so
%{_libdir}/pkgconfig/*.pc
%{_datadir}/linphone/tutorials
%changelog