File libaccounts-qt5.spec of Package libaccounts-qt5
#
# spec file for package libaccounts-qt
#
# 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/
#
%define _soname 1
Name: libaccounts-qt5
Version: 1.13
Release: 0
Summary: Qt library for Single Sign On
License: LGPL-2.1
Group: System/Libraries
Url: http://code.google.com/p/accounts-sso/
Source: accounts-qt-%{version}.tar.bz2
BuildRequires: doxygen
BuildRequires: fdupes
BuildRequires: pkgconfig(Qt5Core)
BuildRequires: pkgconfig(Qt5Xml)
BuildRequires: pkgconfig(Qt5Test)
BuildRequires: pkgconfig(glib-2.0)
BuildRequires: pkgconfig(libaccounts-glib)
%description
This package contains the Qt library for Single Sign On.
%package -n libaccounts-qt5-%{_soname}
Summary: Qt library for Single Sign On
Group: System/Libraries
%description -n libaccounts-qt5-%{_soname}
This package contains the Qt library for Single Sign On.
%package devel
Summary: Development files for libaccounts-qt
Group: Development/Libraries/C and C++
Requires: libaccounts-qt5-%{_soname} = %{version}-%{release}
%description devel
This package contains the development files for the accounts-qt library.
%package tools
Summary: Tools for libaccounts-qt
Group: Development/Tools/Other
Requires: libaccounts-qt5-%{_soname} = %{version}-%{release}
%description tools
This package contains the tools for the accounts-qt library.
%package doc
Summary: Documentation for libaccounts-qt
Group: Documentation/HTML
BuildArch: noarch
%description doc
This package contains the documentation for the accounts-qt library.
%prep
%setup -q -n accounts-qt-%{version}
# Fix documentation directory
sed -i '/^documentation.path/ s/doc\//doc\/packages\//' doc/doc.pri
# Disable rpath
sed -i '/QMAKE_RPATHDIR/d' tests/accountstest.pro
%build
%qmake5 \
PREFIX=%{_prefix} \
LIBDIR=%{_libdir}
make %{?_smp_mflags}
%install
make install INSTALL_ROOT=%{buildroot}
# Silence rpmlint
find -type d -name '.moc' -exec rm -rvf {} \+
%fdupes %{buildroot}%{_docdir}/
%post -n libaccounts-qt5-%{_soname} -p /sbin/ldconfig
%postun -n libaccounts-qt5-%{_soname} -p /sbin/ldconfig
%files -n libaccounts-qt5-%{_soname}
%defattr(-,root,root)
%doc COPYING
%{_libdir}/libaccounts-qt5.so.*
%files devel
%defattr(-,root,root)
%{_includedir}/accounts-qt5/
%{_libdir}/libaccounts-qt5.so
%{_libdir}/pkgconfig/accounts-qt5.pc
%dir %{_libdir}/cmake/
%{_libdir}/cmake/AccountsQt5/
%files tools
%defattr(-,root,root)
%{_bindir}/accountstest
%{_datadir}/libaccounts-qt-tests/
%files doc
%defattr(-,root,root)
%doc %{_docdir}/accounts-qt/
%changelog