File gtimelog.spec of Package gtimelog

#
# spec file for package python-gtimelog
#
# Copyright (c) 2013 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:           gtimelog
Version:        0.6.0
Release:        1
License:        GPL-2.0
Summary:        A Gtk+ time tracking application
Url:            https://gitlab.collabora.com/collabora/gtimelog.git
Group:          Productivity/Office/Management
Source:         https://gitlab.collabora.com/collabora/gtimelog/-/archive/master/gtimelog-0.6.0-g8395ec4.tar.gz
BuildRequires:  python3-setuptools
Requires:       typelib-1_0-Gtk-3_0
Requires:       typelib-1_0-Soup-2_4
Requires:       typelib-1_0-Secret-1
Requires:       python3-gobject-Gdk
BuildRoot:      %{_tmppath}/%{name}-%{version}-build
%if 0%{?suse_version} && 0%{?suse_version} <= 1110
%{!?python_sitelib: %global python_sitelib %(python3 -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")}
%else
BuildArch:      noarch
%endif

%description
Simple and unintrusive time-tracking application.

There are screenshots at http://mg.pov.lt/gtimelog.

Mailing list: http://groups.google.com/group/gtimelog

Bugs: http://bugs.launchpad.net/gtimelog/

Source code: http://code.launchpad.net/gtimelog/


%prep
%setup -q -n gtimelog-master-8395ec4576cf54411d974675d26f64208acdcee0

%build
python3 setup.py build

%install
python3 setup.py install --prefix=%{_prefix} --root=%{buildroot}
mkdir -p %{buildroot}/usr/share/pixmaps
cp src/gtimelog/gtimelog.png %{buildroot}/usr/share/pixmaps
mkdir -p %{buildroot}/usr/share/applications
sed -i 's|Categories=Application;Utility;|Categories=Office;ProjectManagement;|' gtimelog.desktop
sed -i 's|Icon=gnome-week.png|Icon=gtimelog|' gtimelog.desktop
cp gtimelog.desktop %{buildroot}/usr/share/applications

%files
%defattr(-,root,root,-)
%doc README.txt NEWS.txt
%{python3_sitelib}/*
/usr/bin/gtimelog
/usr/bin/rltimelog
/usr/share/applications/gtimelog.desktop
/usr/share/pixmaps/gtimelog.png

%changelog
openSUSE Build Service is sponsored by