File EasyMercurial.spec of Package EasyMercurial
# Copyright (c) 2019 SUSE LINUX Products GmbH, Nuernberg, Germany.
# Copyright (c) 2019 Marcin Bajor
#
# 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: EasyMercurial
Version: 1.4
Release: 0
License: GPL-2.0+
Summary: User interface for the Mercurial distributed version control system
Url: http://easyhg.org
Group: Development/Tools/Version Control
Source0: %{name}-%{version}.tar.gz
BuildRoot: %{_tmppath}/%{name}-%{version}-build
BuildRequires: libqt5-qtbase-devel
BuildRequires: update-desktop-files
BuildRequires: fdupes
Requires: mercurial >= 1.7.0
Requires: python-cryptography
Requires: python-qt5
%description
EasyMercurial is a simple user interface for the Mercurial distributed version control system. It's free, open source, and cross-platform.
%prep
%setup -q
%build
export CFLAGS="$RPM_OPT_FLAGS"
export CXXFLAGS=$CFLAGS
qmake-qt5
make %{?jobs:-j%jobs}
%install
install -D -m 755 -p EasyMercurial %{buildroot}%{_bindir}/EasyMercurial
install -D -m 755 -p easyhg-extdiff.sh %{buildroot}%{_bindir}/easyhg-extdiff.sh
install -D -m 755 -p easyhg-merge.sh %{buildroot}%{_bindir}/easyhg-merge.sh
install -D -m 0644 ./deploy/linux/EasyMercurial.desktop %{buildroot}%{_datadir}/applications/EasyMercurial.desktop
install -D -m 0644 ./images/easyhg-icon.png %{buildroot}%{_datadir}/pixmaps/easyhg-icon.png
install -D -m 0644 ./images/icon/128/easyhg-icon.png %{buildroot}%{_datadir}/icons/hicolor/128x128/apps/easyhg-icon.png
install -D -m 0644 ./images/icon/64/easyhg-icon.png %{buildroot}%{_datadir}/icons/hicolor/64x64/apps/easyhg-icon.png
install -D -m 0644 ./images/icon/48/easyhg-icon.png %{buildroot}%{_datadir}/icons/hicolor/48x48/apps/easyhg-icon.png
install -D -m 0644 ./images/icon/32/easyhg-icon.png %{buildroot}%{_datadir}/icons/hicolor/32x32/apps/easyhg-icon.png
install -D -m 0644 ./images/icon/24/easyhg-icon.png %{buildroot}%{_datadir}/icons/hicolor/24x24/apps/easyhg-icon.png
install -D -m 0644 ./images/icon/scalable/easyhg-icon.svg %{buildroot}%{_datadir}/icons/hicolor/scalable/apps/easyhg-icon.svg
%suse_update_desktop_file -r %{buildroot}%{_datadir}/applications/EasyMercurial.desktop Development RevisionControl
%fdupes %{buildroot}/%{_datadir}
%clean
rm -rf %{buildroot}
%files
%defattr(-,root,root)
%{_bindir}/EasyMercurial
%{_bindir}/easyhg-extdiff.sh
%{_bindir}/easyhg-merge.sh
%{_datadir}/applications/EasyMercurial.desktop
%{_datadir}/pixmaps/easyhg-icon.png
%{_datadir}/icons/hicolor/*/apps/*
%dir %{_datadir}/icons/hicolor
%dir %{_datadir}/icons/hicolor/*
%dir %{_datadir}/icons/hicolor/*/apps