File gtg.spec of Package gtg

# spec file for package gtg
# Copyright (c) 2022 SUSE LLC
# 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

# TODO 1) Report unused itstool build requirement, despite it being
#         checked by the build script.
#      2) Meson is throwing out (gtg-0.6):
#         "NOTICE: Future-deprecated features used:
#                  0.56.0: {'meson.source_root'}"
#      3) Report unneeded shebang in Python modules and executable bits
#         on

Name:           gtg
Version:        0.6
Release:        0
Summary:        Personal Organizer for GNOME
License:        GPL-3.0-or-later
Group:          Productivity/Office/Organizers

BuildRequires:  fdupes
BuildRequires:  gettext-tools
BuildRequires:  itstool
BuildRequires:  meson
BuildRequires:  python-rpm-macros
BuildRequires:  python3-cairo
BuildRequires:  python3-caldav
BuildRequires:  python3-gobject
BuildRequires:  python3-liblarch
BuildRequires:  python3-lxml
BuildRequires:  update-desktop-files
BuildRequires:  typelib(GLib)
BuildRequires:  typelib(GdkPixbuf)
BuildRequires:  typelib(Gtk) = 3.0
BuildRequires:  typelib(GtkSource) = 4
BuildRequires:  typelib(Pango)
## Run-time Requirements
Requires:       python3-gobject-Gdk
Requires:       python3-liblarch
Requires:       python3-liblarch-gtk
Requires:       python3-lxml
Requires:       python3-pycairo
## For GTG's plugins
# Hamster Time Tracker Integration
Recommends:     hamster-time-tracker
BuildArch:      noarch

Getting Things GNOME! (GTG) is a personal organizer for the GNOME desktop
environment inspired by the Getting Things Done (GTD) methodology. GTG is
designed with flexibility, adaptability, and ease of use in mind so it can be
used as more than just GTD software.

GTG is intended to help you track everything you need to do and need to know,
from small tasks to large projects.


%autosetup -p1

## Fix shebang issues
pushd GTG
sed -i -e '1s/env //'
sed -i -r '1s,(#!/bin/sh),# \1,' \
for file in core/ core/; do
    sed -i -r '1s,^(#!/usr/bin/(|env )python3),# \1,' $file
    chmod -x $file

%meson %{nil}

%suse_update_desktop_file org.gnome.GTG

%find_lang %{name} %{?no_lang_C}
%fdupes -s %{buildroot}

%license LICENSE
%doc %{_datadir}/help/C/%{name}/

%files lang -f %{name}.lang

openSUSE Build Service is sponsored by