From 1c807c07c4fe043ae45f7d5658479efb9949a11e Mon Sep 17 00:00:00 2001 From: Rex Dieter Date: Aug 14 2018 14:08:34 +0000 Subject: provide python?-pyqt4-sip too tighten dir ownership of sip python module dir(s) --- diff --git a/sip.spec b/sip.spec index 98c6912..789c9c9 100644 --- a/sip.spec +++ b/sip.spec @@ -20,7 +20,7 @@ Summary: SIP - Python/C++ Bindings Generator Name: sip Version: 4.19.12 -Release: 5%{?dist} +Release: 6%{?dist} # sipgen/parser.{c.h} is GPLv3+ with exceptions (bison) License: GPLv2 or GPLv3 and (GPLv3+ with exceptions) @@ -77,6 +77,13 @@ Provides: python2-sip-api(%{_sip_api_major})%{?_isa} = %{_sip_api} %{?python_provide:%python_provide python2-sip} %description -n python2-sip %_description +%package -n python2-pyqt4-sip +Summary: %summary +Provides: python2-pyqt4-sip-api(%{_sip_api_major}) = %{_sip_api} +Provides: python2-pyqt4-sip-api(%{_sip_api_major})%{?_isa} = %{_sip_api} +%{?python_provide:%python_provide python2-pyqt4-sip} +%description -n python2-pyqt4-sip %_description + %package -n python2-pyqt5-sip Summary: %summary Provides: python2-pyqt5-sip-api(%{_sip_api_major}) = %{_sip_api} @@ -95,6 +102,14 @@ This is the Python 3 build of SIP. %_description +%package -n python%{python3_pkgversion}-pyqt4-sip +Summary: SIP - Python 3/C++ Bindings Generator for pyqt4 +BuildRequires: python%{python3_pkgversion}-devel +Provides: python%{python3_pkgversion}-pyqt4-sip-api(%{_sip_api_major}) = %{_sip_api} +Provides: python%{python3_pkgversion}-pyqt4-sip-api(%{_sip_api_major})%{?_isa} = %{_sip_api} +%description -n python%{python3_pkgversion}-pyqt4-sip +This is the Python 3 build of pyqt4-SIP. + %package -n python%{python3_pkgversion}-pyqt5-sip Summary: SIP - Python 3/C++ Bindings Generator for pyqt5 BuildRequires: python%{python3_pkgversion}-devel @@ -147,6 +162,16 @@ pushd %{_target_platform}-python2 %make_build popd +mkdir %{_target_platform}-python2-pyqt4 +pushd %{_target_platform}-python2-pyqt4 +%{__python2} ../configure.py \ + --no-dist-info \ + --sip-module=PyQt4.sip \ + CFLAGS+="%{optflags}" CXXFLAGS+="%{optflags}" LFLAGS+="%{?__global_ldflags}" + +%make_build +popd + mkdir %{_target_platform}-python2-pyqt5 pushd %{_target_platform}-python2-pyqt5 %{__python2} ../configure.py \ @@ -168,6 +193,16 @@ pushd %{_target_platform}-python3 %make_build popd +mkdir %{_target_platform}-python3-pyqt4 +pushd %{_target_platform}-python3-pyqt4 +%{__python3} ../configure.py \ + --no-dist-info \ + --sip-module=PyQt4.sip \ + CXXFLAGS+="%{optflags}" CFLAGS+="%{optflags}" LFLAGS+="%{?__global_ldflags}" + +%make_build +popd + mkdir %{_target_platform}-python3-pyqt5 pushd %{_target_platform}-python3-pyqt5 %{__python3} ../configure.py \ @@ -187,6 +222,7 @@ popd %if %{with python3} %make_install -C %{_target_platform}-python3 ln -s sip %{buildroot}%{_bindir}/python3-sip +%make_install -C %{_target_platform}-python3-pyqt4 %make_install -C %{_target_platform}-python3-pyqt5 ## toplevel __pycache__ creation is ... inconsistent @@ -196,6 +232,7 @@ mkdir -p %{buildroot}%{python3_sitearch}/__pycache__/exclude_rpm_hack # Python 2 installation: %make_install -C %{_target_platform}-python2 +%make_install -C %{_target_platform}-python2-pyqt4 %make_install -C %{_target_platform}-python2-pyqt5 mkdir -p %{buildroot}%{_datadir}/sip @@ -219,13 +256,20 @@ install -D -p -m644 %{SOURCE1} %{buildroot}%{rpm_macros_dir}/macros.sip %files -n python2-sip %doc NEWS README %license LICENSE LICENSE-GPL2 LICENSE-GPL3 -%{python2_sitearch}/sip.so -%{python2_sitearch}/sip*.py* +%{python2_sitearch}/sip.* +%{python2_sitearch}/sipconfig.py* +%{python2_sitearch}/sipdistutils.py* + +%files -n python2-pyqt4-sip +%doc NEWS README +%license LICENSE LICENSE-GPL2 LICENSE-GPL3 +%{python2_sitearch}/PyQt4/ %files -n python2-pyqt5-sip %doc NEWS README %license LICENSE LICENSE-GPL2 LICENSE-GPL3 -%{python2_sitearch}/PyQt5/ +%dir %{python2_sitearch}/PyQt5/ +%{python2_sitearch}/PyQt5/sip.* %if %{with python3} %files -n python%{python3_pkgversion}-sip-devel @@ -234,21 +278,35 @@ install -D -p -m644 %{SOURCE1} %{buildroot}%{rpm_macros_dir}/macros.sip %files -n python%{python3_pkgversion}-sip %doc NEWS README %license LICENSE LICENSE-GPL2 LICENSE-GPL3 -%{python3_sitearch}/sip.so -%{python3_sitearch}/sip*.py* +%{python3_sitearch}/sip.* +%{python3_sitearch}/sipconfig.py* +%{python3_sitearch}/sipdistutils.py* +%{python3_sitearch}/__pycache__/* +%exclude %{python3_sitearch}/__pycache__/exclude_rpm_hack + +%files -n python%{python3_pkgversion}-pyqt4-sip +%doc NEWS README +%license LICENSE LICENSE-GPL2 LICENSE-GPL3 +%dir %{python3_sitearch}/PyQt4/ +%{python3_sitearch}/PyQt4/sip.* %{python3_sitearch}/__pycache__/* %exclude %{python3_sitearch}/__pycache__/exclude_rpm_hack %files -n python%{python3_pkgversion}-pyqt5-sip %doc NEWS README %license LICENSE LICENSE-GPL2 LICENSE-GPL3 -%{python3_sitearch}/PyQt5/ +%dir %{python3_sitearch}/PyQt5/ +%{python3_sitearch}/PyQt5/sip.* %{python3_sitearch}/__pycache__/* %exclude %{python3_sitearch}/__pycache__/exclude_rpm_hack %endif %changelog +* Tue Aug 14 2018 Rex Dieter - 4.19.12-6 +- provide python?-pyqt4-sip too +- tighten dir ownership of sip python module dir(s) + * Mon Jul 16 2018 Rex Dieter - 4.19.12-5 - python?-devel: Requires: python?-sip - add python3-sip compat symlink