[Python-apps-commits] r8941 - in packages/cython/trunk/debian (5 files)

yoh at users.alioth.debian.org yoh at users.alioth.debian.org
Mon Jul 16 16:07:15 UTC 2012


    Date: Monday, July 16, 2012 @ 16:07:07
  Author: yoh
Revision: 8941

0001-Change-build-system-from-cdbs-pysupport-to-dh_python.patch (see #674073)

Modified:
  packages/cython/trunk/debian/changelog
  packages/cython/trunk/debian/compat
  packages/cython/trunk/debian/control
  packages/cython/trunk/debian/rules
Deleted:
  packages/cython/trunk/debian/pycompat

Modified: packages/cython/trunk/debian/changelog
===================================================================
--- packages/cython/trunk/debian/changelog	2012-07-14 14:40:24 UTC (rev 8940)
+++ packages/cython/trunk/debian/changelog	2012-07-16 16:07:07 UTC (rev 8941)
@@ -1,3 +1,10 @@
+cython (0.15.1-3) unstable; urgency=low
+
+  * Change build system to dh_python2
+  * Bump Standards-Version to 3.9.3
+
+ -- Bradley M. Froehle <brad.froehle at gmail.com>  Tue, 22 May 2012 17:49:14 -0700
+
 cython (0.15.1-2) unstable; urgency=low
 
   [ Jakub Wilk ]

Modified: packages/cython/trunk/debian/compat
===================================================================
--- packages/cython/trunk/debian/compat	2012-07-14 14:40:24 UTC (rev 8940)
+++ packages/cython/trunk/debian/compat	2012-07-16 16:07:07 UTC (rev 8941)
@@ -1 +1 @@
-5
+7

Modified: packages/cython/trunk/debian/control
===================================================================
--- packages/cython/trunk/debian/control	2012-07-14 14:40:24 UTC (rev 8940)
+++ packages/cython/trunk/debian/control	2012-07-16 16:07:07 UTC (rev 8941)
@@ -3,8 +3,8 @@
 Priority: optional
 Maintainer: Python Applications Packaging Team <python-apps-team at lists.alioth.debian.org>
 Uploaders: Ondrej Certik <ondrej at certik.cz>, Yaroslav Halchenko <debian at onerussian.com>
-Build-Depends: cdbs (>= 0.4.49), debhelper (>= 5.0.38), python (>= 2.4.4-6), python-all-dev (>= 2.4.4-6), python-support (>= 0.7.5), python-all-dbg, help2man (>= 1.37.1~), python-numpy
-Standards-Version: 3.9.2
+Build-Depends: debhelper (>= 7.0.50~), python-all-dev (>= 2.6.6-3~), python-all-dbg, help2man (>= 1.37.1~), python-numpy
+Standards-Version: 3.9.3
 Homepage: http://cython.org/
 Vcs-Svn: svn://svn.debian.org/svn/python-apps/packages/cython/trunk
 Vcs-Browser: http://svn.debian.org/viewsvn/python-apps/packages/cython/trunk/
@@ -14,7 +14,6 @@
 Architecture: any
 Depends: ${python:Depends}, ${misc:Depends}, ${shlibs:Depends}
 Suggests: python-dev, gcc
-XB-Python-Version: ${python:Versions}
 Description: C-Extensions for Python
  Cython is a language that makes writing C extensions for the Python language as
  easy as Python itself. Cython is based on the well-known Pyrex, but supports
@@ -34,7 +33,6 @@
 Priority: extra
 Depends: ${python:Depends}, ${misc:Depends}, ${shlibs:Depends}, cython (= ${binary:Version})
 Suggests: gcc
-XB-Python-Version: ${python:Versions}
 Description: C-Extensions for Python (Debug Build of Cython)
  This package contains Cython libraries built against versions of
  Python configured with --pydebug.

Deleted: packages/cython/trunk/debian/pycompat
===================================================================
--- packages/cython/trunk/debian/pycompat	2012-07-14 14:40:24 UTC (rev 8940)
+++ packages/cython/trunk/debian/pycompat	2012-07-16 16:07:07 UTC (rev 8941)
@@ -1 +0,0 @@
-2

Modified: packages/cython/trunk/debian/rules
===================================================================
--- packages/cython/trunk/debian/rules	2012-07-14 14:40:24 UTC (rev 8940)
+++ packages/cython/trunk/debian/rules	2012-07-16 16:07:07 UTC (rev 8941)
@@ -1,8 +1,6 @@
 #!/usr/bin/make -f
 # -*- makefile -*-
 
-DEB_PYTHON_SYSTEM=pysupport
-
 #  Apparently WGET agent is not favored by upstream's MoinMoin
 WGET_AGENT_STRING="Lynx/2.8.8dev.4 libwww-FM/2.14 SSL-MM/1.4.1 GNUTLS/2.8.6"
 WGET=wget -q --user-agent=$(WGET_AGENT_STRING)
@@ -11,57 +9,60 @@
 # Directory where to store upstream changelogs
 CHANGELOGS=debian/changelogs
 
-include /usr/share/cdbs/1/rules/debhelper.mk
-include /usr/share/cdbs/1/class/python-distutils.mk
+# Python versions
+PYDEF=$(shell pyversions -dv)
+PY2VERS=$(shell pyversions -vr)
 
-install/cython:: assure-changelogs build/cython.1
-	dh_installman build/cython.1
+%:
+	dh $@ --with python2 --buildsystem python_distutils
 
-#
-# Testing
-#
-ifeq (,$(filter nocheck,$(DEB_BUILD_OPTIONS)))
-install/cython::
-	: # Run tests battery against current default version of Python
-	PYTHONPATH=$(shell /bin/ls -d $(CURDIR)/build/lib.*$(cdbs_python_current_version)) \
-		python runtests.py --no-refnanny -v -v --work-dir=build/work-dir
-endif
-
-#
-# Debugging version -dbg
-#
-# Re-build using python-dbg
-install/cython-dbg::
-	for i in $(cdbs_python_build_versions); do \
-	  python$$i-dbg ./setup.py install $(DEB_PYTHON_INSTALL_ARGS_ALL) \
-		 --root $(CURDIR)/debian/cython-dbg; \
-	done
-	: # Keep only _d.so files for cython-dbg package
-	find debian/cython-dbg ! -type d ! -name '*_d.so' | xargs rm -f
-	: # Prune empty directories
-	find debian/cython-dbg -depth -empty -exec rmdir \{\} \;
-
-binary-predeb/cython-dbg::
-	mkdir -p debian/cython-dbg/usr/share/doc
-	ln -s cython debian/cython-dbg/usr/share/doc/cython-dbg
-
-# Fix shebang:
-binary-install/cython::
-	sed -i -e '1 s,#!.*python.*,#! /usr/bin/python,' debian/cython/usr/bin/*
-
-#
-# Custom rules used above
-#
-build/cython.1: build
+override_dh_installman:
 	: # Generate a manpage using help2man
-	PYTHONPATH="$(shell /bin/ls -d $(CURDIR)/build/lib.*-$(cdbs_python_current_version) 2>&1)" \
+	PYTHONPATH=`/bin/ls -d $(CURDIR)/build/lib.*-$(PYDEF)` \
 	  help2man --no-info --no-discard-stderr \
 		-n "compile Cython code (.pyx) into C to build a Python extension" \
 		bin/cython >| build/cython.1
 	: # Verify that manpage generated nicely -- no Errors reported
 	grep -q 'ImportError:' build/cython.1 && exit 1 || :
+	dh_installman build/cython.1
 
+override_dh_install:
+	dh_install
+
+	: # fix shebang
+	sed -i -e '1 s,#!.*python.*,#!/usr/bin/python,' debian/cython/usr/bin/*
+
+	: # remove files installed from cython.install that belong in -dbg
+	find $(CURDIR)/debian/cython/ -name "*_d.so" -delete
+
+	: # share -dbg and normal package doc dirs
+	rm -rf debian/cython-dbg/usr/share/doc/cython-dbg
+	dh_link -pcython-dbg usr/share/doc/cython usr/share/doc/cython-dbg
+
+override_dh_installchangelogs:
+	dh_installchangelogs $(CHANGELOGS)/ReleaseHistory
+
+override_dh_installdocs: assure-changelogs
+	dh_installdocs $(CHANGELOGS)/ReleaseNotes-*
+
+override_dh_auto_test:
+ifeq (,$(filter nocheck,$(DEB_BUILD_OPTIONS)))
+	set -e; for P in $(PY2VERS); do \
+	 PYTHONPATH=`/bin/ls -d $(CURDIR)/build/lib.*-$$P` \
+	  /usr/bin/python$$P runtests.py --no-refnanny -v -v --work-dir=build/work-dir; \
+	done
+endif
+
+override_dh_strip:
+	dh_strip -pcython --dbg-package=cython-dbg
+
+override_dh_auto_clean:
+	rm -rf build
+	find -name "*.py[oc]" -type f -delete
+
 # To fetch and update upstream Changelogs
+DEB_UPSTREAM_VERSION=$(shell dpkg-parsechangelog | sed -rne 's,^Version: ([^-]+).*,\1,p')
+
 # Notes:
 #  SED is used to do minor de-wikification to make text readable
 get-changelogs:
@@ -86,18 +87,3 @@
 		echo >&2 "I: Run 'debian/rules get-changelogs' or add version into $(CHANGELOGS)/skip"; \
 		exit 1; \
 	fi
-
-
-clean::
-	rm -f Cython/Compiler/Lexicon.pickle Cython/*/*.c
-	: # Just prune build entirely
-	rm -rf build
-
-# Install directly into package directory (despite multiple packages
-# due to having cython-dbg)
-DEB_DESTDIR = $(CURDIR)/debian/cython
-DEB_INSTALL_CHANGELOGS_cython = $(CHANGELOGS)/ReleaseHistory
-DEB_INSTALL_DOCS_cython = $(CHANGELOGS)/ReleaseNotes*
-# CDBS causes the puke and Yarik have no time to figure it out
-# DEB_INSTALL_DOCS_cython-dbg = --link-doc=cython
-DEB_CLEAN_EXCLUDE = $(CHANGELOGS)




More information about the Python-apps-commits mailing list