File hamster-time-tracker.spec of Package hamster-time-tracker

#
# spec file for package hamster-time-tracker
#
# 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:           hamster-time-tracker
Version:        1.03.3
Release:        0
Summary:        A time tracker for GNOME
License:        GPL-3.0+ and CC-BY-SA-3.0
Group:          Productivity/Other
Url:            http://projecthamster.wordpress.com/
# The download_files source verification script barks.. even though it should be fine.
# Source0:        https://github.com/projecthamster/hamster/archive/%{name}-%{version}.tar.gz
Source0:        %{name}-%{version}.tar.gz
BuildRequires:  fdupes
BuildRequires:  gconf2-devel
BuildRequires:  glib2-devel
BuildRequires:  gnome-doc-utils-devel
BuildRequires:  intltool
BuildRequires:  python-devel
BuildRequires:  translation-update-upstream
BuildRequires:  update-desktop-files
BuildRequires:  pkgconfig(gnome-keybindings)
# Note:
# - we do not have the gnomeapplet bindings anymore (it doesn't work with
#   GNOME 3), so we don't add a Requires/Recommends for it.
# - the gnome python module is needed only for the applet, and since we don't
#   have it, we don't need a dependency on python-gnome
Requires:       dbus-1-python
Requires:       python-gconf
Requires:       python-gtk
Requires:       python-wnck
Requires:       python-xdg
Recommends:     %{name}-lang
Recommends:     python-evolution
# hamster-time-tracker used to be developed as hamster-applet. Last ever release was 2.91.2
Obsoletes:      docky-hamster-applet <= 2.91.2
Obsoletes:      hamster-applet <= 2.91.2
BuildRoot:      %{_tmppath}/%{name}-%{version}-build
BuildArch:      noarch
%{py_requires}
%gconf_schemas_prereq

%description
Project Hamster is time tracking for masses. It helps you to keep track
on how much time you have spent during the day on activities you have
set up.

%lang_package
%prep
%setup -q -n hamster-%{name}-%{version}

%build
./waf --prefix=%{_prefix} configure build

%install
./waf install --destdir=%{buildroot} --libdir=%{_libdir} --libexecdir=%{_libexecdir}
%find_gconf_schemas
%find_lang %{name} %{?no_lang_C}
%suse_update_desktop_file hamster-time-tracker X-SuSE-TimeUtility
%suse_update_desktop_file hamster-time-tracker-overview X-SuSE-TimeUtility
%fdupes %{buildroot}

%pre -f %{name}.schemas_pre

%post
%desktop_database_post
%icon_theme_cache_post

%preun -f %{name}.schemas_preun

%postun
%desktop_database_postun
%icon_theme_cache_postun

%posttrans -f %{name}.schemas_posttrans

%clean
rm -rf %{buildroot}

%files -f %{name}.schemas_list
%defattr(-, root, root)
%doc AUTHORS NEWS
%dir %{_datadir}/gnome/
%dir %{_datadir}/gnome/help/
%dir %{_datadir}/gnome/help/%{name}/
%doc %{_datadir}/gnome/help/%{name}/C/
%{_bindir}/hamster
%{_datadir}/applications/hamster-time-tracker.desktop
%{_datadir}/applications/hamster-time-tracker-overview.desktop
%{_datadir}/applications/hamster-windows-service.desktop
%{_datadir}/dbus-1/services/org.gnome.hamster.service
%{_datadir}/dbus-1/services/org.gnome.hamster.Windows.service
%{_datadir}/icons/hicolor/*/apps/*.png
%{_datadir}/icons/hicolor/scalable/apps/*.svg
%{_datadir}/%{name}/
%{_libexecdir}/%{name}/
%{python_sitelib}/hamster/
%{_sysconfdir}/bash_completion.d/hamster.bash

%files lang -f %{name}.lang

%changelog
openSUSE Build Service is sponsored by