File pychess.spec of Package pychess

#
# spec file for package pychess
#
# Copyright (c) 2020 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 https://bugs.opensuse.org/
#


%{?!python_module:%define python_module() python-%{**} python3-%{**}}
%define skip_python2 1
Name:           pychess
Version:        1.0.2
Release:        0
Summary:        Chess GUI
License:        GPL-3.0-only
Group:          Development/Languages/Python
URL:            https://github.com/pychess/pychess
Source:         https://github.com/pychess/pychess/archive/1.0.2.tar.gz#/%{name}-%{version}.tar.gz
BuildRequires:  %{python_module cairo}
BuildRequires:  %{python_module devel}
BuildRequires:  %{python_module gobject-cairo}
BuildRequires:  %{python_module gobject}
BuildRequires:  %{python_module pexpect}
BuildRequires:  %{python_module psutil}
BuildRequires:  %{python_module setuptools}
BuildRequires:  %{python_module sqlalchemy}
BuildRequires:  %{python_module websockets}
BuildRequires:  fdupes
BuildRequires:  girepository-1_0
BuildRequires:  glib2
BuildRequires:  gobject-introspection
BuildRequires:  gtk3
BuildRequires:  pango
BuildRequires:  python-rpm-macros
BuildRequires:  typelib-1_0-Gtk-3_0
BuildRequires:  typelib-1_0-Rsvg-2_0
Provides:       pychess
BuildArch:      noarch
%python_subpackages

%description
PyChess is a chess client for playing and analyzing chess games. It is
intended to be usable both for those totally new to chess as well as
advanced users who want to use a computer to further enhance their play.

PyChess has a builtin python chess engine and auto-detects most
popular chess engines (Stockfish, Rybka, Houdini, Shredder, GNU Chess,
Crafty, Fruit, and many more). These engines are available as opponents,
and are used to provide hints and analysis. PyChess also shows analysis
from opening books and Gaviota end-game tablebases.

When you get sick of playing computer players you can login to FICS (the
Free Internet Chess Server) and play against people all over the world.
PyChess has a built-in Timeseal client, so you won't lose clock time during
a game due to lag. PyChess also has pre-move support, which means you can
make (or start making) a move before your opponent has made their move.

PyChess has many other features including:
- CECP and UCI chess engine support with customizable engine configurations
- Polyglot opening book support
- Hint and Spy move arrows
- Hint, Score, and Annotation panels
- Play and analyze games in separate game tabs
- 18 chess variants including Chess960, Suicide, Crazyhouse, Shuffle, Losers, Piece Odds, and Atomic
- Reads and writes PGN, EPD and FEN chess file formats
- Undo and pause chess games
- Move animation in games
- Drag and drop chess files
- Optional game move and event sounds
- Chess piece themes with 40 built-in piece themes
- Legal move highlighting
- Direct copy+paste pgn game input via Enter Game Notation open-game dialog
- Internationalised text and Figurine Algebraic Notation (FAN) support
- Translated into 38 languages (languages with +5% strings translated)
- Easy to use and intuitive look and feel

%prep
%setup -q

%build
# fixme upstream: unkonwn setup key 'executables'
sed -i '/executables=executables/d' setup.py
%python_build

%install
%python_install
%python_expand %fdupes %{buildroot}%{$python_sitelib}

%files %{python_files}
%license LICENSE
%doc ARTISTS AUTHORS DOCUMENTERS README.md TRANSLATORS
%{python_sitelib}/*
%{_bindir}/%{name}
%dir %{_datadir}/gtksourceview-3.0
%dir %{_datadir}/gtksourceview-3.0/language-specs
%{_datadir}/gtksourceview-3.0/language-specs/pgn.lang
%{_datadir}/applications/%{name}.desktop
%{_datadir}/icons/hicolor/24x24/apps/%{name}.png
%{_datadir}/icons/hicolor/scalable/apps/%{name}.svg
%{_mandir}/man1/%{name}.1%{?ext_man}
%dir %{_datadir}/menu
%{_datadir}/menu/%{name}
%{_datadir}/metainfo/%{name}.metainfo.xml
%{_datadir}/mime/packages/%{name}.xml
%{_datadir}/pixmaps/%{name}.*
%dir %{_datadir}/%{name}
%{_datadir}/%{name}/*
%dir %{_datadir}/locale/*/LC_MESSAGES
%dir %{_datadir}/locale/*
%{_datadir}/locale/*/LC_MESSAGES/%{name}.mo

%changelog
openSUSE Build Service is sponsored by