## START: Set by rpmautospec ## (rpmautospec version 0.3.0) %define autorelease(e:s:pb:n) %{?-p:0.}%{lua: release_number = 19; base_release_number = tonumber(rpm.expand("%{?-b*}%{!?-b:1}")); print(release_number + base_release_number - 1); }%{?-e:.%{-e*}}%{?-s:.%{-s*}}%{!?-n:%{?dist}} ## END: Set by rpmautospec Name: python-dukpy Version: 0.3 Release: %autorelease Summary: JavaScript runtime environment License: MIT URL: https://github.com/kovidgoyal/dukpy Source0: https://github.com/kovidgoyal/dukpy/archive/v%{version}/%{name}-%{version}.tar.gz # Not upstreamed. Needs work. Patch0: 0001-Use-the-system-copy-of-duktape.patch BuildRequires: gcc BuildRequires: python3-devel BuildRequires: python3-setuptools BuildRequires: python3-pytest BuildRequires: duktape-devel %global _description %{expand: dukpy is a JavaScript runtime environment for Python using the duktape embeddable JavaScript engine. With dukpy, you can run JavaScript in Python.} %description %_description %package -n python3-dukpy Summary: %{summary} %{?python_provide:%python_provide python3-dukpy} # Uninstall old versions that link to outdated duktape Obsoletes: python2-dukpy < 0.3-20 %description -n python3-dukpy %_description %prep %autosetup -n dukpy-%{version} -p1 # This removed the bundled duktape. The files that form the "Duktape # 1.x compatible module loading framework" remain. They are some # compat glue that is not shipped in duktape-devel. rm src/duktape/duk_config.h src/duktape/duktape.c src/duktape/duktape.h %build %py3_build %install %py3_install %check PYTHONPATH=%{buildroot}%{python3_sitearch} %__python3 -m pytest tests.py -v %files -n python3-dukpy %{python3_sitearch}/dukpy-%{version}-py%{python3_version}.egg-info/ %{python3_sitearch}/dukpy.*.so %doc README.rst %license LICENSE.txt %changelog * Fri Jan 20 2023 Fedora Release Engineering 0.3-19 - Rebuilt for https://fedoraproject.org/wiki/Fedora_38_Mass_Rebuild * Fri Dec 16 2022 František Zatloukal 0.3-18 - Rebuilt for duktape 2.7.0 * Fri Jul 22 2022 Fedora Release Engineering 0.3-17 - Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild * Mon Jun 13 2022 Python Maint 0.3-16 - Rebuilt for Python 3.11 * Mon Mar 07 2022 Zbigniew Jędrzejewski-Szmek 0.3-15 - Make version in Obsoletes actually high enough * Sun Feb 27 2022 Zbigniew Jędrzejewski-Szmek 0.3-14 - Add Obsoletes for the python2 subpackage * Fri Jan 21 2022 Fedora Release Engineering 0.3-13 - Rebuilt for https://fedoraproject.org/wiki/Fedora_36_Mass_Rebuild * Tue Nov 02 2021 Zbigniew Jędrzejewski-Szmek 0.3-12 - Rebuild for duktape-2.6.0 * Tue Jul 27 2021 Fedora Release Engineering - 0.3-9 - Second attempt - Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild * Fri Jun 04 2021 Python Maint - 0.3-8 - Rebuilt for Python 3.10 * Wed Jan 27 2021 Fedora Release Engineering - 0.3-7 - Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild * Wed Jul 29 2020 Fedora Release Engineering - 0.3-6 - Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild * Tue May 26 2020 Miro Hrončok - 0.3-5 - Rebuilt for Python 3.9 * Thu Jan 30 2020 Fedora Release Engineering - 0.3-4 - Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild * Mon Aug 19 2019 Miro Hrončok - 0.3-3 - Rebuilt for Python 3.8 * Fri Jul 26 2019 Fedora Release Engineering - 0.3-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild * Tue Jun 18 2019 Zbigniew Jędrzejewski-Szmek - 0.3-1 - Drop python2 subpackage * Thu Jun 13 2019 Zbigniew Jędrzejewski-Szmek - 0.3-1 - Initial packaging