diff -u cfv-1.18.2/debian/rules cfv-1.18.2/debian/rules --- cfv-1.18.2/debian/rules +++ cfv-1.18.2/debian/rules @@ -2,55 +2,28 @@ -# Sample debian/rules that uses debhelper. -# GNU copyright 1997 to 1999 by Joey Hess. - -# Uncomment this to turn on verbose mode. -#export DH_VERBOSE=1 include /usr/share/dpatch/dpatch.make +include /usr/share/python/python.mk -# This is the debhelper compatability version to use. -export DH_COMPAT=4 - -build: build-stamp -build-stamp: patch-stamp - dh_testdir - touch build-stamp +build: patch build-stamp +build-stamp: + touch $@ clean: unpatch - dh_testdir - dh_testroot - rm -f build-stamp - - # Add here commands to clean up after the build process. - -$(MAKE) distclean + dh $@ - dh_clean - -install: build +install: build install-stamp +install-stamp: dh_testdir dh_testroot - dh_clean -k - dh_installdirs - mkdir -p `pwd`/debian/cfv/usr/lib/$(shell pyversions -d)/site-packages/ - $(MAKE) install-wrapper-only DESTDIR=`pwd`/debian/cfv/ prefix=/usr mandir=/usr/share/man - + mkdir -p debian/cfv/usr/lib/$(shell pyversions -d)/$(call py_sitename, $*) + make install-wrapper-only prefix=/usr mandir=/usr/share/man DESTDIR=debian/cfv/ pkgdir=/usr/lib/$(shell pyversions -d)/$(call py_sitename, $*) + touch $@ -# Build architecture-independent files here. binary-indep: build install dh_testdir dh_testroot - dh_installdocs - dh_installchangelogs Changelog - dh_pysupport - dh_link - dh_compress - dh_fixperms - dh_installdeb - dh_gencontrol - dh_md5sums - dh_builddeb + dh_install -i -# Build architecture-dependent files here. binary-arch: build install binary: binary-indep binary-arch -.PHONY: build clean binary-indep binary-arch binary install + dh $@ diff -u cfv-1.18.2/debian/control cfv-1.18.2/debian/control --- cfv-1.18.2/debian/control +++ cfv-1.18.2/debian/control @@ -1,13 +1,15 @@ Source: cfv Section: utils Priority: optional -Maintainer: Stefan Alfredsson -Build-Depends: python-dev, debhelper, python-support (>= 0.4), dpatch +Maintainer: Ubuntu MOTU Developers +XSBC-Original-Maintainer: Stefan Alfredsson +Build-Depends: python-dev (>= 2.5.4), debhelper (>= 7), python-support (>= 0.4), dpatch Standards-Version: 3.8.0.1 +Homepage: http://cfv.sourceforge.net/ Package: cfv Architecture: all -Depends: ${python:Depends} +Depends: ${python:Depends}, ${misc:Depends} Suggests: python-imaging, bittorrent | bittornado Description: versatile file checksum creator and verifier cfv is a utility to test and create a wide range of checksum diff -u cfv-1.18.2/debian/changelog cfv-1.18.2/debian/changelog --- cfv-1.18.2/debian/changelog +++ cfv-1.18.2/debian/changelog @@ -1,3 +1,21 @@ +cfv (1.18.2-1ubuntu1) karmic; urgency=low + + * debian/patches/02_fix_python_warnings.dpatch: + -Fix DeprecationWarning from md5 and sha modules. (LP: #158747) + * debian/rules: + - Simplify rules, make it compatible with Python 2.6. + * debian/control: + - Add versioned Build-Depends on debhelper and python packages. + - Change Maintainer to Ubuntu MOTU Developers. + - Add Homepage. + - Make package depends on ${misc:Depends}. + * debian/copyright: + - Use GPL-2 instead of GPL symlink. + * debian/compat: + - Make package compatible with debhelper 7. + + -- Krzysztof Klimonda Sat, 06 Jun 2009 03:06:22 +0200 + cfv (1.18.2-1) unstable; urgency=low * New upstream release diff -u cfv-1.18.2/debian/copyright cfv-1.18.2/debian/copyright --- cfv-1.18.2/debian/copyright +++ cfv-1.18.2/debian/copyright @@ -11 +11 @@ -License can be found in /usr/share/common-licenses/GPL file. +License can be found in /usr/share/common-licenses/GPL-2 file. diff -u cfv-1.18.2/debian/patches/00list cfv-1.18.2/debian/patches/00list --- cfv-1.18.2/debian/patches/00list +++ cfv-1.18.2/debian/patches/00list @@ -1,0 +2 @@ +02_fix_python_warnings only in patch2: unchanged: --- cfv-1.18.2.orig/debian/compat +++ cfv-1.18.2/debian/compat @@ -0,0 +1 @@ +7 only in patch2: unchanged: --- cfv-1.18.2.orig/debian/patches/02_fix_python_warnings.dpatch +++ cfv-1.18.2/debian/patches/02_fix_python_warnings.dpatch @@ -0,0 +1,48 @@ +#! /bin/sh /usr/share/dpatch/dpatch-run +## 02_fix_python_warnings.dpatch by Krzysztof Klimonda +## +## All lines beginning with `## DP:' are a description of the patch. +## DP: Fix Python DeprecationWarning from usage of old modules. + +@DPATCH@ +diff -urNad cfv-1.18.2~/cfv cfv-1.18.2/cfv +--- cfv-1.18.2~/cfv 2009-06-06 03:56:27.000000000 +0200 ++++ cfv-1.18.2/cfv 2009-06-06 04:10:51.357461185 +0200 +@@ -667,9 +667,13 @@ + stats.bytesread = stats.bytesread+s + return m.digest(),s + +-import sha ++try: ++ from hashlib import sha1 as sha ++except ImportError: ++ import sha ++ sha = sha.new + def _getfilesha1(file): +- return _getfilechecksum(file, sha.new) ++ return _getfilechecksum(file, sha) + + try: + if os.environ.get('CFV_NOFCHKSUM'): raise ImportError +@@ -696,7 +700,11 @@ + if stdprogress: progress.cleanup() + return c,s + except ImportError: +- import md5 ++ try: ++ from hashlib import md5 ++ except ImportError: ++ import md5 ++ md5 = md5.new + try: + import zlib + _crc32=zlib.crc32 +@@ -713,7 +721,7 @@ + return struct.pack('>I', self.value & 0xFFFFFFFF) + + def _getfilemd5(file): +- return _getfilechecksum(file, md5.new) ++ return _getfilechecksum(file, md5) + + def _getfilecrc(file): + return _getfilechecksum(file, CRC32)