restore this lost change: disable multiple python version cohexistence because it is not possible with apache [release 4.6.7-2mamba;Sun Aug 11 2019]

This commit is contained in:
Silvan Calarco 2024-01-05 20:29:19 +01:00
parent 97a984ea2b
commit d7c401928b

View File

@ -1,13 +1,13 @@
Name: apache-mod_wsgi Name: apache-mod_wsgi
Version: 4.6.4 Version: 4.6.7
Release: 1mamba Release: 2mamba
Summary: an Apache module that implements a WSGI compliant interface for hosting Python based web applications Summary: an Apache module that implements a WSGI compliant interface for hosting Python based web applications
Group: System/Libraries Group: System/Libraries
Vendor: openmamba Vendor: openmamba
Distribution: openmamba Distribution: openmamba
Packager: Silvan Calarco <silvan.calarco@mambasoft.it> Packager: Silvan Calarco <silvan.calarco@mambasoft.it>
URL: https://pypi.python.org/pypi/mod_wsgi URL: https://pypi.python.org/pypi/mod_wsgi
Source: https://pypi.python.org/packages/source/m/mod_wsgi/mod_wsgi-%{version}.tar.gz Source: https://pypi.debian.net/mod-wsgi/mod_wsgi-%{version}.tar.gz
Source1: wsgi-tmpfile.conf Source1: wsgi-tmpfile.conf
Source2: wsgi-apache.conf Source2: wsgi-apache.conf
License: Apache License 2.0 License: Apache License 2.0
@ -15,6 +15,7 @@ License: Apache License 2.0
BuildRequires: glibc-devel BuildRequires: glibc-devel
BuildRequires: libpython3-devel BuildRequires: libpython3-devel
## AUTOBUILDREQ-END ## AUTOBUILDREQ-END
BuildRequires: libpython3-devel >= 3.7.4
BuildRequires: libpython-devel BuildRequires: libpython-devel
BuildRequires: apache >= 2.4 BuildRequires: apache >= 2.4
Requires: apache >= 2.4 Requires: apache >= 2.4
@ -53,40 +54,46 @@ sed -i "s,.*/man/.*,&.gz," %{name}.filelist
%makeinstall %makeinstall
install -D -m0644 %{SOURCE1} %{buildroot}%{_tmpfilesdir}/wsgi%{?pyappend:-%pyappend}.conf install -D -m0644 %{SOURCE1} %{buildroot}%{_tmpfilesdir}/wsgi.conf
install -D -m0644 %{SOURCE2} %{buildroot}%{_sysconfdir}/httpd/httpd.d/wsgi%{?pyappend:-%pyappend}.conf install -D -m0644 %{SOURCE2} %{buildroot}%{_sysconfdir}/httpd/httpd.d/wsgi.conf
%if 0%{?with_pyver} #%if 0%{?with_pyver}
mv %{buildroot}%{_libdir}/apache/mod_wsgi.so %{buildroot}%{_libdir}/apache/mod_wsgi%{?pyappend:-%pyappend}.so #mv %{buildroot}%{_libdir}/apache/mod_wsgi.so %{buildroot}%{_libdir}/apache/mod_wsgi%{?pyappend:-%pyappend}.so
mv %{buildroot}%{_bindir}/mod_wsgi-express %{buildroot}%{_bindir}/mod_wsgi-express%{?pyappend:-%pyappend} #mv %{buildroot}%{_bindir}/mod_wsgi-express %{buildroot}%{_bindir}/mod_wsgi-express%{?pyappend:-%pyappend}
sed -i "s|%{_bindir}/mod_wsgi-express|%{_bindir}/mod_wsgi-express%{?pyappend:-%pyappend}|" %{name}.filelist #sed -i "s|%{_bindir}/mod_wsgi-express|%{_bindir}/mod_wsgi-express%{?pyappend:-%pyappend}|" %{name}.filelist
%endif #%endif
%post %{?pyappend} %post %{?pyappend}
if [ $1 -ge 1 ]; then if [ $1 -ge 1 ]; then
# WORKAROUND: using tmpfiles_create macro unsets %pyappend variable for yet unknown reasons # WORKAROUND: using tmpfiles_create macro unsets %pyappend variable for yet unknown reasons
#% tmpfiles_create wsgi%{?pyappend:-%pyappend}.conf #% tmpfiles_create wsgi.conf
systemd-tmpfiles --create wsgi%{?pyappend:-%pyappend}.conf >/dev/null 2>&1 || : systemd-tmpfiles --create wsgi.conf >/dev/null 2>&1 || :
systemctl -q daemon-reload systemctl -q daemon-reload
%{_bindir}/apxs -e -a -n wsgi%{?pyappend} %{_libdir}/apache/mod_wsgi%{?pyappend:-%pyappend}.so > /dev/null %{_bindir}/apxs -e -a -n wsgi %{_libdir}/apache/mod_wsgi.so > /dev/null
fi fi
: :
%preun %{?pyappend} %preun %{?pyappend}
if [ $1 -eq 0 ]; then if [ $1 -eq 0 ]; then
systemctl -q daemon-reload systemctl -q daemon-reload
%{_bindir}/apxs -e -A -n wsgi%{?pyappend} %{_libdir}/apache/mod_wsgi%{?pyappend:-%pyappend}.so > /dev/null %{_bindir}/apxs -e -A -n wsgi %{_libdir}/apache/mod_wsgi.so > /dev/null
fi fi
: :
%files %{?pyappend} -f %{name}.filelist %files %{?pyappend} -f %{name}.filelist
%defattr(-,root,root) %defattr(-,root,root)
%{_sysconfdir}/httpd/httpd.d/wsgi%{?pyappend:-%pyappend}.conf %{_sysconfdir}/httpd/httpd.d/wsgi.conf
%{_libdir}/apache/mod_wsgi%{?pyappend:-%pyappend}.so %{_libdir}/apache/mod_wsgi.so
%{_tmpfilesdir}/wsgi%{?pyappend:-%pyappend}.conf %{_tmpfilesdir}/wsgi.conf
%doc LICENSE %doc LICENSE
%changelog %changelog
* Sun Aug 11 2019 Silvan Calarco <silvan.calarco@mambasoft.it> 4.6.7-2mamba
- restore this lost change: disable multiple python version cohexistence because it is not possible with apache
* Thu Aug 08 2019 Silvan Calarco <silvan.calarco@mambasoft.it> 4.6.7-1mamba
- update to 4.6.7
* Thu Sep 06 2018 Silvan Calarco <silvan.calarco@mambasoft.it> 4.6.4-1mamba * Thu Sep 06 2018 Silvan Calarco <silvan.calarco@mambasoft.it> 4.6.4-1mamba
- update to 4.6.4 - update to 4.6.4