File twinkle.spec of Package twinkle
#
# spec file for package twinkle
#
# Copyright (c) 2015 SUSE LINUX 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: twinkle
BuildRequires: alsa-devel
BuildRequires: bison
BuildRequires: cmake
BuildRequires: fdupes
BuildRequires: file-devel
BuildRequires: flex
BuildRequires: libqt5-qtbase-devel
BuildRequires: libqt5-qttools-devel
BuildRequires: libsndfile-devel
BuildRequires: libzrtpcpp-devel >= 2.0.0
BuildRequires: pkgconfig
BuildRequires: readline-devel
BuildRequires: update-desktop-files
BuildRequires: xorg-x11-devel
BuildRequires: pkgconfig(Qt5Declarative)
BuildRequires: pkgconfig(Qt5Quick)
BuildRequires: pkgconfig(commoncpp)
BuildRequires: pkgconfig(libxml-2.0)
BuildRequires: pkgconfig(speex)
BuildRequires: pkgconfig(speexdsp)
%if 0%{?suse_version} <= 1320
BuildRequires: boost-devel
%endif
%if 0%{?suse_version} > 1320 || (0%{?suse_version} == 1315 && 0%{?is_opensuse})
BuildRequires: ilbc-devel
%else
BuildRequires: ilbc
%endif
Summary: A SIP Soft Phone
License: GPL-2.0+
Group: Productivity/Telephony/SIP/Clients
Version: 1.9.0
Release: 0
Source: %{name}-%{version}.tar.xz
Patch11: Revert-Build-fix-for-a-probably-broken-std-match_res.patch
Patch12: Revert-Replaced-Boost-regex-dependency-with-C-11-reg.patch
Url: https://twinkle.dolezel.info/
%description
Twinkle is a SIP-based soft phone for making telephone calls over IP
networks.
%prep
%setup -q
# workaround for broken std::regex in gcc 4.8
%if 0%{?suse_version} <= 1320
%patch11 -p1
%patch12 -p1
%endif
%build
cmake \
-DCMAKE_INSTALL_PREFIX=%{_prefix} \
-DCMAKE_CXX_FLAGS="$RPM_OPT_FLAGS" \
-DWITH_ZRTP=ON -DWITH_SPEEX=ON -DWITH_ILBC=ON \
-DWITH_ALSA=ON -DWITH_QT5=ON .
make %{?_smp_mflags}
%install
%makeinstall
install -d 755 %{buildroot}%{_datadir}/pixmaps
%suse_update_desktop_file -c twinkle Twinkle "SIP VoIP Phone" twinkle twinkle Network Telephony
%fdupes %{buildroot}%{_prefix}
%files
%defattr(-, root, root)
%doc AUTHORS COPYING README.md
%{_bindir}/twinkle
%{_bindir}/twinkle-console
%{_datadir}/%{name}
%{_datadir}/pixmaps/twinkle.png
%{_datadir}/applications/twinkle.desktop
%changelog