Name: dianara
Summary: Pump.io application for the desktop
Version: 1.4.1
Release: 2%{?dist}
License: GPLv2+
URL: https://jancoding.wordpress.com/dianara/
Source0: http://download.savannah.gnu.org/releases/dianara/dianara-v%{version}.tar.gz
BuildRequires: gcc-c++
BuildRequires: qt5-qtbase-devel, qt5-qtsvg-devel
BuildRequires: qoauth-qt5-devel
BuildRequires: file-devel
BuildRequires: desktop-file-utils
BuildRequires: libappstream-glib
Requires: qca-qt5-ossl
Requires: hicolor-icon-theme
%description
Dianara is a pump.io client, a desktop application that allows users
to manage their Pump.io social networking accounts without the need
to use a web browser, and provides many features not available
in the standard web interface.
%prep
%setup -q -n %{name}-v%{version}
%build
mkdir build && pushd build
%{qmake_qt5} ../Dianara.pro \
QMAKE_CFLAGS_RELEASE="$RPM_OPT_FLAGS" \
QMAKE_CXXFLAGS_RELEASE="$RPM_OPT_FLAGS" \
QMAKE_LFLAGS="$RPM_LD_FLAGS"
%make_build
popd
%install
%make_install -C build INSTALL_ROOT=$RPM_BUILD_ROOT
%post
/bin/touch --no-create %{_datadir}/icons/hicolor &>/dev/null || :
%postun
if [ $1 -eq 0 ] ; then
/bin/touch --no-create %{_datadir}/icons/hicolor &>/dev/null
/usr/bin/gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || :
fi
%posttrans
/usr/bin/gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || :
%check
desktop-file-validate $RPM_BUILD_ROOT%{_datadir}/applications/%{name}.desktop
appstream-util validate-relax --nonet $RPM_BUILD_ROOT%{_datadir}/metainfo/*.appdata.xml
%files
%license LICENSE
%doc README BUGS
%{_bindir}/%{name}
%{_datadir}/applications/%{name}.desktop
%{_datadir}/metainfo/%{name}*.xml
%{_mandir}/man1/dianara.*
%{_datadir}/icons/hicolor/32x32/apps/dianara.png
%{_datadir}/icons/hicolor/64x64/apps/dianara.png
%changelog
* Mon Jan 01 2018 Antonio Trande <sagitterATfedoraproject.org> 1.4.1-2
- Fix scriptles
* Sat Dec 30 2017 Antonio Trande <sagitterATfedoraproject.org> 1.4.1-1
- First package