- compile even when older python-rpm-macros don't have the

python_compileall macro

OBS-URL: https://build.opensuse.org/package/show/KDE:Qt:PyQt/python-sip4?expand=0&rev=2
This commit is contained in:
Benjamin Greiner 2021-07-05 22:29:33 +00:00 committed by Git OBS Bridge
parent c655dc8517
commit 83afa8d330
2 changed files with 8 additions and 0 deletions

View File

@ -1,3 +1,9 @@
-------------------------------------------------------------------
Mon Jul 5 22:28:42 UTC 2021 - Ben Greiner <code@bnavigator.de>
- compile even when older python-rpm-macros don't have the
python_compileall macro
-------------------------------------------------------------------
Sat Feb 27 11:03:17 UTC 2021 - Benjamin Greiner <code@bnavigator.de>

View File

@ -238,6 +238,8 @@ grep '%%requires_%{python3_prefix}_sip_api' %{buildroot}%{_rpmconfigdir}/macros
echo "%%requires_%{python3_prefix}_sip_api Requires: %{python_prefix}-sip(api) = %%python_sip_api_ver" >> %{buildroot}%{_rpmconfigdir}/macros.d/macros.python_all-sip4
%endif
%{?python_compileall}
%{?!python_compileall:%python_exec -m compileall %{buildroot}%{$python_sitearch}}
%{?!python_compileall:%python_exec -O -m compileall %{buildroot}%{$python_sitearch}}
%python_clone -a %{buildroot}/%{_bindir}/sip
%python_expand %fdupes %{buildroot}%{$python_sitearch}
mkdir -p %{buildroot}%{_datadir}/sip