# disable debuginfo %global debug_package %{nil} %global pkgname anyconfig-configobj-backend %global desctxt \ This is a python backend module for python-anyconfig to load and dump configobj\ data.\ \ python-anyconfig is a python library to provide common APIs to load dump\ various configuration files like INI, JSON and YAML. Name: python-%{pkgname} Version: 0.0.4 Release: 1%{?dist} Summary: Backend for python-anyconfig to load and dump configobj data Group: Development/Libraries License: MIT URL: https://github.com/ssato/python-anyconfig-configobj-backend Source0: %{pkgname}-%{version}.tar.gz BuildArch: noarch %if 0%{?fedora} || 0%{?rhel} > 7 %bcond_without python3 %else %bcond_with python3 %endif %if 0%{?rhel} == 7 BuildRequires: python-devel BuildRequires: python-setuptools %else BuildRequires: python2-devel BuildRequires: python2-setuptools %endif %if %{with python3} BuildRequires: python3-devel BuildRequires: python3-setuptools %endif %description %{desctxt} %package -n python2-%{pkgname} Summary: %{summary} Requires: python2-anyconfig %if 0%{?rhel} == 7 Requires: python-configobj %else Requires: python2-configobj %endif %{?python_provide:%python_provide python2-%{pkgname}} %description -n python2-%{pkgname} %{desctxt} %if %{with python3} %package -n python3-%{pkgname} Summary: %{summary} Requires: python3-anyconfig Requires: python3-configobj %{?python_provide:%python_provide python3-%{pkgname}} %description -n python3-%{pkgname} %{desctxt} %endif %prep %autosetup -n %{pkgname}-%{version} %build %py2_build %if %{with python3} %py3_build %endif %install %py2_install %if %{with python3} %py3_install %endif %files -n python2-%{pkgname} %doc README.rst %if 0%{?rhel} == 7 %{python_sitelib}/* %else %{python2_sitelib}/* %endif %if %{with python3} %files -n python3-%{pkgname} %doc README.rst %{python3_sitelib}/* %endif %changelog * Tue Jan 9 2018 Satoru SATOH - 0.0.4-1 - fix: do not install tests/*.py - fix: s/install_require/install_requires/ in setup.py - other misc refactoring, code cleanups and fixes * Mon Jan 8 2018 Satoru SATOH - 0.0.3-1 - enhancement/fix: import a lot of enhancements and fixes from (anyconfig)/tests/backend/configobj.py - enhancement/fix: import a lot of enhancements and fixes from python-anyconfig-cbor-backend.git/setup.py - fix: pep8 was renamed to pycodestyle - fix: make it buildable w/ RHEL 7 environment - fix: add runtime requirements - refactor/fix: clean up the RPM SPEC w/ using macros such as py2_{build,install}, autosetup and bcond_with{,out} - other misc refactoring, code cleanups and fixes * Tue Apr 30 2013 Satoru SATOH - 0.0.2-1 - Simplify the implementation by following the internal API changes in the config parser base class - Refactor the RPM SPEC * Tue Apr 23 2013 Satoru SATOH - 0.0.1-1 - Initial packaging