Compare commits

4 Commits

2 changed files with 22 additions and 7 deletions

View File

@@ -1,3 +1,15 @@
-------------------------------------------------------------------
Mon Jun 23 01:30:29 UTC 2025 - Steve Kowalik <steven.kowalik@suse.com>
- Switch to pyproject macros.
- No more greedy globs in %files.
-------------------------------------------------------------------
Tue Sep 24 19:11:45 UTC 2024 - Guang Yee <gyee@suse.com>
- Enable sle15_python_module_pythons.
- Use proper macro for python executable
-------------------------------------------------------------------
Thu Oct 7 12:49:49 UTC 2021 - pgajdos@suse.com

View File

@@ -1,7 +1,7 @@
#
# spec file for package python-ebcdic
#
# Copyright (c) 2021 SUSE LLC
# Copyright (c) 2025 SUSE LLC
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
@@ -16,7 +16,7 @@
#
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
%{?sle15_python_module_pythons}
Name: python-ebcdic
Version: 1.1.1
Release: 0
@@ -25,7 +25,9 @@ License: BSD-2-Clause
Group: Development/Languages/Python
URL: https://github.com/roskakori/CodecMapper
Source: https://github.com/roskakori/CodecMapper/archive/v%{version}.tar.gz
BuildRequires: %{python_module pip}
BuildRequires: %{python_module setuptools}
BuildRequires: %{python_module wheel}
BuildRequires: ant
BuildRequires: fdupes
BuildRequires: python-rpm-macros
@@ -38,17 +40,17 @@ Additional EBCDIC codecs for Python.
%prep
%setup -q -n CodecMapper-%{version}/ebcdic
# do not use venv python
sed -i -e 's:"${basedir}/venv/bin/python":"/usr/bin/python3":' ../build.xml
sed -i -e 's:"${basedir}/venv/bin/python":"${PYTHON}":' ../build.xml
%build
# first generate the py files
pushd ..
ant ebcdic
%python_expand ant ebcdic -DPYTHON="$python"
popd
%python_build
%pyproject_wheel
%install
%python_install
%pyproject_install
%python_expand %fdupes %{buildroot}%{$python_sitelib}
%check
@@ -58,6 +60,7 @@ export LANG="en_US.UTF8"
%files %{python_files}
%doc README.rst
%license LICENSE.txt
%{python_sitelib}/*
%{python_sitelib}/ebcdic
%{python_sitelib}/ebcdic-%{version}.dist-info
%changelog