[Python-modules-commits] r14224 - in packages/mod-wsgi/trunk/debian (9 files)
piotr at users.alioth.debian.org
piotr at users.alioth.debian.org
Thu Aug 19 10:07:29 UTC 2010
Date: Thursday, August 19, 2010 @ 10:07:27
Author: piotr
Revision: 14224
* New upstream release
* Move Python 3.X extension to new libapache2-mod-wsgi-py3 binary package
* Bump Standards-Version to 3.9.1 (no changes needed)
Added:
packages/mod-wsgi/trunk/debian/libapache2-mod-wsgi-py3.docs
packages/mod-wsgi/trunk/debian/libapache2-mod-wsgi-py3.install
packages/mod-wsgi/trunk/debian/libapache2-mod-wsgi-py3.postinst
packages/mod-wsgi/trunk/debian/libapache2-mod-wsgi-py3.prerm
packages/mod-wsgi/trunk/debian/libapache2-mod-wsgi-py3.rtupdate
Modified:
packages/mod-wsgi/trunk/debian/changelog
packages/mod-wsgi/trunk/debian/control
packages/mod-wsgi/trunk/debian/copyright
packages/mod-wsgi/trunk/debian/rules
Modified: packages/mod-wsgi/trunk/debian/changelog
===================================================================
--- packages/mod-wsgi/trunk/debian/changelog 2010-08-19 07:44:12 UTC (rev 14223)
+++ packages/mod-wsgi/trunk/debian/changelog 2010-08-19 10:07:27 UTC (rev 14224)
@@ -1,4 +1,4 @@
-mod-wsgi (3.2-3) UNRELEASED; urgency=low
+mod-wsgi (3.3-1) unstable; urgency=low
[ Sameer Rahmani ]
* watch file fixed.
@@ -10,9 +10,12 @@
rebuild of mod-wsgi), but it needs to be handled properly.
[ Piotr Ożarowski ]
+ * New upstream release
+ * Move Python 3.X extension to new libapache2-mod-wsgi-py3 binary package
* Provide httpd-wsgi (see #588497)
+ * Bump Standards-Version to 3.9.1 (no changes needed)
- -- Bernd Zeimetz <bzed at debian.org> Fri, 02 Jul 2010 13:54:04 +0200
+ -- Piotr Ożarowski <piotr at debian.org> Wed, 18 Aug 2010 23:40:10 +0200
mod-wsgi (3.2-2) unstable; urgency=low
Modified: packages/mod-wsgi/trunk/debian/control
===================================================================
--- packages/mod-wsgi/trunk/debian/control 2010-08-19 07:44:12 UTC (rev 14223)
+++ packages/mod-wsgi/trunk/debian/control 2010-08-19 10:07:27 UTC (rev 14224)
@@ -5,7 +5,7 @@
Uploaders: Bernd Zeimetz <bzed at debian.org>, Piotr Ożarowski <piotr at debian.org>
Build-Depends: debhelper (>= 5), python-all-dev, python3-all-dev, apache2-threaded-dev
Homepage: http://www.modwsgi.org/
-Standards-Version: 3.8.4
+Standards-Version: 3.9.1
Vcs-Svn: svn://svn.debian.org/python-modules/packages/mod-wsgi/trunk/
Vcs-Browser: http://svn.debian.org/viewsvn/python-modules/packages/mod-wsgi/trunk/
@@ -20,3 +20,20 @@
web applications written in Python) compliant interface for hosting Python
based web applications within Apache. The adapter provides significantly
better performance than using existing WSGI adapters for mod_python or CGI.
+ .
+ This package provides module for Python 2.X.
+
+Package: libapache2-mod-wsgi-py3
+Architecture: any
+Depends: apache2, apache2.2-common, ${shlibs:Depends}, ${misc:Depends}, ${python3:Depends}
+Suggests: apache2-mpm-worker | apache2-mpm-event
+Conflicts: libapache2-mod-wsgi
+Provides: httpd-wsgi
+Description: Python 3 WSGI adapter module for Apache
+ The mod_wsgi adapter is an Apache module that provides a WSGI (Web Server
+ Gateway Interface, a standard interface between web server software and
+ web applications written in Python) compliant interface for hosting Python
+ based web applications within Apache. The adapter provides significantly
+ better performance than using existing WSGI adapters for mod_python or CGI.
+ .
+ This package provides module for Python 3.X.
Modified: packages/mod-wsgi/trunk/debian/copyright
===================================================================
--- packages/mod-wsgi/trunk/debian/copyright 2010-08-19 07:44:12 UTC (rev 14223)
+++ packages/mod-wsgi/trunk/debian/copyright 2010-08-19 10:07:27 UTC (rev 14224)
@@ -9,7 +9,7 @@
Copyright:
- Copyright 2007-2009 GRAHAM DUMPLETON
+ Copyright 2007-2010 GRAHAM DUMPLETON
License:
@@ -28,5 +28,5 @@
On Debian systems the full text of the Apache License, Version 2,
can be found in `/usr/share/common-licenses/Apache-2.0'.
-The Debian packaging is © 2007-2009, Bernd Zeimetz <bernd at bzed.de> and
+The Debian packaging is © 2007-2010, Bernd Zeimetz <bernd at bzed.de> and
is licensed under the Apache License, Version 2.0, see below.
Added: packages/mod-wsgi/trunk/debian/libapache2-mod-wsgi-py3.docs
===================================================================
--- packages/mod-wsgi/trunk/debian/libapache2-mod-wsgi-py3.docs (rev 0)
+++ packages/mod-wsgi/trunk/debian/libapache2-mod-wsgi-py3.docs 2010-08-19 10:07:27 UTC (rev 14224)
@@ -0,0 +1 @@
+README
Added: packages/mod-wsgi/trunk/debian/libapache2-mod-wsgi-py3.install
===================================================================
--- packages/mod-wsgi/trunk/debian/libapache2-mod-wsgi-py3.install (rev 0)
+++ packages/mod-wsgi/trunk/debian/libapache2-mod-wsgi-py3.install 2010-08-19 10:07:27 UTC (rev 14224)
@@ -0,0 +1,2 @@
+debian/wsgi.load etc/apache2/mods-available
+debian/wsgi.conf etc/apache2/mods-available
Added: packages/mod-wsgi/trunk/debian/libapache2-mod-wsgi-py3.postinst
===================================================================
--- packages/mod-wsgi/trunk/debian/libapache2-mod-wsgi-py3.postinst (rev 0)
+++ packages/mod-wsgi/trunk/debian/libapache2-mod-wsgi-py3.postinst 2010-08-19 10:07:27 UTC (rev 14224)
@@ -0,0 +1,39 @@
+#!/bin/sh
+
+set -e
+
+apache_force_reload() {
+ if apache2ctl configtest 2>/dev/null; then
+ #invoke-rc.d apache2 force-reload || true
+ # use "restart" as a workaround for bug #558608
+ invoke-rc.d apache2 restart || true
+ else
+ echo "Your apache2 configuration is broken, please fix it and restart apache2 manually."
+ fi
+}
+
+update_symlink() {
+ wsgi_py=`readlink /usr/lib/apache2/modules/mod_wsgi.so | sed 's,.*-,,'`
+ py_default=`dpkg -s python | grep '^Version' | sed 's,Version: \([^.]*.[^.]*\).*,\1,'`
+ if [ ! "${wsgi_py}" = "${py_default}" ]; then
+ ln -sf mod_wsgi.so-${py_default} /usr/lib/apache2/modules/mod_wsgi.so
+ fi
+}
+
+if [ -z "$2" ]; then
+ update_symlink
+ if [ -e /etc/apache2/apache2.conf ]; then
+ a2enmod wsgi >/dev/null || true
+ apache_force_reload
+ fi
+else
+ #we're upgrading
+ update_symlink
+ if [ -e /etc/apache2/mods-enabled/wsgi.load ]; then
+ apache_force_reload
+ fi
+fi
+
+#DEBHELPER#
+
+exit 0
Added: packages/mod-wsgi/trunk/debian/libapache2-mod-wsgi-py3.prerm
===================================================================
--- packages/mod-wsgi/trunk/debian/libapache2-mod-wsgi-py3.prerm (rev 0)
+++ packages/mod-wsgi/trunk/debian/libapache2-mod-wsgi-py3.prerm 2010-08-19 10:07:27 UTC (rev 14224)
@@ -0,0 +1,11 @@
+#!/bin/sh
+
+set -e
+
+if [ "$1" = "remove" ] || [ "$1" = "purge" ]; then
+ a2dismod wsgi || true
+fi
+
+#DEBHELPER#
+
+exit 0
Added: packages/mod-wsgi/trunk/debian/libapache2-mod-wsgi-py3.rtupdate
===================================================================
--- packages/mod-wsgi/trunk/debian/libapache2-mod-wsgi-py3.rtupdate (rev 0)
+++ packages/mod-wsgi/trunk/debian/libapache2-mod-wsgi-py3.rtupdate 2010-08-19 10:07:27 UTC (rev 14224)
@@ -0,0 +1,8 @@
+#!/bin/sh
+
+set -e
+
+if [ "$1" = rtupdate ]; then
+ new_version=`echo ${3} | sed 's,^python,,'`
+ ln -sf mod_wsgi.so-${new_version} /usr/lib/apache2/modules/mod_wsgi.so
+fi
Modified: packages/mod-wsgi/trunk/debian/rules
===================================================================
--- packages/mod-wsgi/trunk/debian/rules 2010-08-19 07:44:12 UTC (rev 14223)
+++ packages/mod-wsgi/trunk/debian/rules 2010-08-19 10:07:27 UTC (rev 14224)
@@ -5,14 +5,16 @@
# Uncomment this to turn on verbose mode.
#export DH_VERBOSE=1
-
APXS2=/usr/bin/apxs2
PYVERS=$(shell pyversions -vs)
-# add Python 3.X versions:
-PYVERS += $(shell dpkg-query -W -f='$${Depends}' python3-all-dev | grep -o 'python3.[0-9]-dev' | grep -o '3.[0-9]')
PYDEFAULT=$(shell pyversions -dv)
PYMIN=$(shell echo $(PYVERS) | awk '{print $$1}')
PYMAX=$(shell echo $(PYVERS) | LANG=C awk '{print $$NF+0.1}')
+PY3VERS=$(shell py3versions -vs)
+PY3DEFAULT=$(shell py3versions -dv)
+PY3MIN=$(shell echo $(PY3VERS) | awk '{print $$1}')
+PY3MAX=$(shell echo $(PY3VERS) | LANG=C awk '{print $$NF+0.1}')
+pkgdir = $(CURDIR)/debian/$(PACKAGE)$(if $(patsubst 3.%,,$(1)),,-py3)
build-%/config.status:
dh_testdir
@@ -26,7 +28,7 @@
$(MAKE) -C build-$*
touch $@
-build: $(PYVERS:%=build-%/build-stamp)
+build: $(PYVERS:%=build-%/build-stamp) $(PY3VERS:%=build-%/build-stamp)
clean:
dh_testdir
@@ -41,11 +43,11 @@
dh_installdirs
install-%: build-%/build-stamp
- $(MAKE) -C build-$* DESTDIR=$(CURDIR)/debian/$(PACKAGE) install
- mv $(CURDIR)/debian/$(PACKAGE)/usr/lib/apache2/modules/mod_wsgi.so \
- $(CURDIR)/debian/$(PACKAGE)/usr/lib/apache2/modules/mod_wsgi.so-$*
+ $(MAKE) -C build-$* DESTDIR=$(call pkgdir,$*) install
+ mv $(call pkgdir,$*)/usr/lib/apache2/modules/mod_wsgi.so \
+ $(call pkgdir,$*)/usr/lib/apache2/modules/mod_wsgi.so-$*
-install: build install-clean $(PYVERS:%=install-%)
+install: build install-clean $(PYVERS:%=install-%) $(PY3VERS:%=install-%)
# Build architecture-independent files here.
binary-indep: build install
@@ -58,9 +60,12 @@
dh_installdocs
dh_install
install -d -m 755 debian/$(PACKAGE)/usr/share/python/runtime.d
- install -m 755 debian/*.rtupdate debian/$(PACKAGE)/usr/share/python/runtime.d/
+ install -d -m 755 debian/$(PACKAGE)-py3/usr/share/python3/runtime.d
+ install -m 755 debian/$(PACKAGE).rtupdate debian/$(PACKAGE)/usr/share/python/runtime.d/
+ install -m 755 debian/$(PACKAGE)-py3.rtupdate debian/$(PACKAGE)-py3/usr/share/python3/runtime.d/
dh_installman
- dh_link usr/lib/apache2/modules/mod_wsgi.so-$(PYDEFAULT) usr/lib/apache2/modules/mod_wsgi.so
+ dh_link -p $(PACKAGE) /usr/lib/apache2/modules/mod_wsgi.so-$(PYDEFAULT) usr/lib/apache2/modules/mod_wsgi.so
+ dh_link -p $(PACKAGE)-py3 /usr/lib/apache2/modules/mod_wsgi.so-$(PY3DEFAULT) usr/lib/apache2/modules/mod_wsgi.so
dh_strip
dh_compress
dh_fixperms
@@ -72,6 +77,8 @@
# Generate dependencies manually as there are no public modules
echo 'python:Depends=python (>= $(PYMIN)), python (<< $(PYMAX))' \
>> $(CURDIR)/debian/$(PACKAGE).substvars
+ echo 'python3:Depends=python3 (>= $(PY3MIN)), python3 (<< $(PY3MAX))' \
+ >> $(CURDIR)/debian/$(PACKAGE)-py3.substvars
dh_gencontrol
dh_md5sums
dh_builddeb
More information about the Python-modules-commits
mailing list