]> git.pld-linux.org Git - packages/apache-mod_wsgi.git/blame - apache-mod_wsgi.spec
Version 3.5-1. Security update (CVE-2014-0240)
[packages/apache-mod_wsgi.git] / apache-mod_wsgi.spec
CommitLineData
cd06f811
ER
1# TODO:
2# - build py2 and py3 variants both?
3
277dec43 4#
cd06f811
ER
5# Conditional build:
6%bcond_with python3 # use CPython 3.x
7
c1cb356c
PZ
8%define mod_name wsgi
9%define apxs /usr/sbin/apxs
10Summary: WSGI interface for the Apache Web server
11Summary(pl.UTF-8): Interfejs WSGI dla serwera WWW Apache
12Name: apache-mod_%{mod_name}
43d2bec3
MK
13Version: 3.5
14Release: 1
e606faaa 15License: Apache
c1cb356c 16Group: Networking/Daemons
43d2bec3
MK
17# Source0: http://modwsgi.googlecode.com/files/mod_%{mod_name}-%{version}.tar.gz
18# https://github.com/GrahamDumpleton/mod_wsgi/archive/3.5.tar.gz
19Source0: https://github.com/GrahamDumpleton/mod_wsgi/archive/%{version}.tar.gz
20# Source0-md5: ed08ce86cf34a60441b708db05da970f
c1cb356c
PZ
21Source1: %{name}.conf
22URL: http://code.google.com/p/modwsgi/
dc5b014c 23BuildRequires: %{apxs}
c1cb356c
PZ
24BuildRequires: apache-devel >= 2.0.52-7
25BuildRequires: apr-devel >= 1:1.0.0
26BuildRequires: autoconf
27BuildRequires: automake
277dec43
AF
28%if %{with python3}
29BuildRequires: python3-devel
30%else
c1cb356c 31BuildRequires: python-devel >= 2.3
277dec43 32%endif
c1cb356c 33BuildRequires: rpmbuild(macros) >= 1.268
cd06f811 34Requires: apache(modules-api) = %{apache_modules_api}
c1cb356c 35Requires: apr >= 1:1.0.0
7d47fcb6
ER
36# http://helpful.knobs-dials.com/index.php/Mod_wsgi_notes#PyEval_AcquireThread:_non-NULL_old_thread_state
37Conflicts: apache-mod_python
c1cb356c
PZ
38BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
39
198257be
ER
40%define apacheconfdir %(%{apxs} -q SYSCONFDIR 2>/dev/null)/conf.d
41%define apachelibdir %(%{apxs} -q LIBEXECDIR 2>/dev/null)
c1cb356c
PZ
42
43%description
44The mod_wsgi adapter is an Apache module that provides a WSGI
45compliant interface for hosting Python based web applications within
46Apache. The adapter is written completely in C code against the Apache
47C runtime and for hosting WSGI applications within Apache has a lower
48overhead than using existing WSGI adapters for mod_python or CGI.
49
50%description -l pl.UTF-8
db2bc9ef 51Adapter mod_wsgi jest modułem udostępniającym interfejs WSGI dla
c1cb356c 52aplikacji WWW napisanych w języku Python i osadzonych w serwerze
db2bc9ef
JB
53Apache. Adapter jest w całości napisany w języku C w oparciu o
54bibliotekę uruchomieniową Apache i ma mniejsze wymagania niż w
55przypadku używania istniejących adapterów WSGI dla modułu mod_python
56lub CGI.
c1cb356c
PZ
57
58%prep
59%setup -q -n mod_%{mod_name}-%{version}
60
61%build
62%{__aclocal}
63%{__autoconf}
277dec43
AF
64%if %{with python3}
65PYTHONBIN=%{__python3}
66%else
67PYTHONBIN=%{__python}
68%endif
c1cb356c 69%configure \
277dec43
AF
70 --with-apxs=%{apxs} \
71 --with-python=$PYTHONBIN
c1cb356c
PZ
72
73%install
74rm -rf $RPM_BUILD_ROOT
198257be 75install -d $RPM_BUILD_ROOT{%{apachelibdir},%{apacheconfdir}}
c1cb356c
PZ
76%{__make} install \
77 DESTDIR=$RPM_BUILD_ROOT
78
cd06f811 79cp -p %{SOURCE1} $RPM_BUILD_ROOT%{apacheconfdir}/61_mod_wsgi.conf
c1cb356c
PZ
80
81%clean
82rm -rf $RPM_BUILD_ROOT
83
84%post
85%service -q httpd restart
86
87%postun
88if [ "$1" = "0" ]; then
89 %service -q httpd restart
90fi
91
92%files
93%defattr(644,root,root,755)
94%doc README
198257be
ER
95%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{apacheconfdir}/*_mod_%{mod_name}.conf
96%attr(755,root,root) %{apachelibdir}/*.so
This page took 0.097281 seconds and 4 git commands to generate.