File archmage.spec of Package archmage

# spec file for package archmage
# Copyright (c) 2021 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

Name:           archmage
Release:        0
Summary:        A reader and decompiler for files in the CHM format
License:        GPL-2.0-or-later
Group:          Productivity/Archiving/Compression
BuildRequires:  %{python_module setuptools}
BuildRequires:  fdupes
BuildRequires:  python-rpm-macros
Requires:       python3-beautifulsoup4
Requires:       python3-pychm
Requires:       python3-setuptools
Requires:       python3-sgmllib3k
Requires(post): update-alternatives
Requires(postun): update-alternatives
BuildArch:      noarch
Provides:       archmage = %{version}
Obsoletes:      archmage < %{version}

arCHMage is a reader and decompiler for files in the CHM format. This is
the format used by Microsoft HTML Help, and is also known as Compiled HTML.


echo %{version} > RELEASE-VERSION

install -Dpm 0644 %{name}.1 \
%python_clone -a %{buildroot}%{_bindir}/archmage
%python_clone -a %{buildroot}%{_mandir}/man1/archmage.1
%python_expand %fdupes %{buildroot}%{$python_sitelib}

%python_install_alternative archmage

%python_uninstall_alternative archmage

%files %{python_files}
%license COPYING
%python_alternative %{_bindir}/archmage
%python_alternative %{_mandir}/man1/archmage.1%{?ext_man}

openSUSE Build Service is sponsored by