--- pkpgcounter-3.50.orig/debian/compat +++ pkpgcounter-3.50/debian/compat @@ -0,0 +1 @@ +5 --- pkpgcounter-3.50.orig/debian/changelog +++ pkpgcounter-3.50/debian/changelog @@ -0,0 +1,132 @@ +pkpgcounter (3.50-4ubuntu1) jaunty; urgency=low + + * Python 2.6 transition: + + add $(py_setup_install_args) + + -- Michael Bienia Sun, 15 Mar 2009 15:26:09 +0100 + +pkpgcounter (3.50-4) unstable; urgency=low + + * debian/control: + + Don't suggest pcl6, gspcl, ghostpcl and ghostpdl + + Correct to recommend texlive-latex-base. + + -- Kumar Appaiah Sat, 06 Dec 2008 09:19:42 -0600 + +pkpgcounter (3.50-3) unstable; urgency=low + + * debian/control + + switch Vcs-Browser field to viewsvn + + Use standards version 3.8.0 (no changes needed). + + Use quilt for patches. + + Don't depend obsolete gs, gs-esp. + + Recommend texlive-latex-bin instead of tetex-bin. + + Change my e-mail address to use debian.org address. + + fix capitalization in short description. + * debian/rules: + + Adapt for use with quilt. + + Remove ugly rmdir hack. + * debian/patches/01_fix_tempfile.diff + + Ensure temporary files are closed. (Closes: #507770) + * debian/copyright: + + Update e-mail addresses, dates. + + Refer explicitly to GPL v3. + + -- Kumar Appaiah Thu, 04 Dec 2008 07:53:44 -0600 + +pkpgcounter (3.50-2) unstable; urgency=low + + [ Jerome Alet ] + * debian/control: + + Recommend xauth instead of xbase-clients. (Closes: #475386) + + -- Kumar Appaiah Thu, 10 Apr 2008 22:04:16 +0530 + +pkpgcounter (3.50-1) unstable; urgency=low + + [ Jerome Alet ] + * New upstream release. + * Upgraded list of supported file formats in control. + * Removed unneeded dependency on python-dev. + * Added ghostscript as an alternative dependency. + * Removed debian/dirs, not needed. + * Added missing dependencies. + * Removed unnecessary spaces in control. + * Changed short description in control. + + [ Kumar Appaiah ] + * debian/rules: + + Remove emptly usr/lib directory. + + No need to call dpatch, as there are no patches. + * debian/control: + + No patches, so remove dpatch dependency. + + -- Jerome Alet Mon, 10 Dec 2007 22:04:52 +0100 + +pkpgcounter (3.40-1) unstable; urgency=low + + * New upstream release. + * Removed the manual page patch which is already done upstream. + * Remove accented characters in upstream author's name in copyright file. + * Added several third party software to Recommends, which are only needed + in some use cases. + * Changed description to match upstream's one. + * Update Standards-Version to 3.7.3. + + -- Jerome Alet Fri, 30 Nov 2007 11:01:35 +0100 + +pkpgcounter (3.30-1) unstable; urgency=low + + * New upstream release + * Added imagemagick to Recommends + * Changed long description to reflect upstream's. + + -- Jerome Alet Fri, 23 Nov 2007 11:26:57 +0100 + +pkpgcounter (3.20-1) unstable; urgency=low + + * New upstream release + * Rename XS-Vcs-* fields to Vcs-* (dpkg supports them now) + + -- Kumar Appaiah Mon, 08 Oct 2007 12:31:06 +0530 + +pkpgcounter (3.10-1) unstable; urgency=low + + * New upstream release. + * Add package to Debian's Python Application Packaging Team. + * Added XS-Vcs-Svn and XS-Vcs-Browser. + * Add upstream to Uploaders for co-maintenance. + * Merge upstream's debian/ directory features, especially control file. + * Update 01fix_man.dpatch to fix manpage hyphens. + * Add Homepage field to control. + + -- Kumar Appaiah Fri, 21 Sep 2007 18:17:58 +0530 + +pkpgcounter (3.00-1) unstable; urgency=low + + * New upstream release + * Use 01_fix_man.dpatch to fix man page. + * Remove redundant license + * Update watch file + * Update copyright to GPL-3. + + -- Kumar Appaiah Tue, 11 Sep 2007 13:31:55 +0530 + +pkpgcounter (2.18-2) unstable; urgency=low + + * Change section to utils. + * Depend only on python-dev. + * Remove incorrect XS-Vcs-Svn. + * Fix hyphens in man page. + * Add dependency on python-imaging. + * Add "Recommends" for python-psyco + * Clean up rules. + + -- Kumar Appaiah Wed, 08 Aug 2007 01:03:40 +0530 + +pkpgcounter (2.18-1) unstable; urgency=low + + * Initial release (Closes: #435030) + + -- Kumar Appaiah Sat, 28 Jul 2007 20:57:47 +0530 + --- pkpgcounter-3.50.orig/debian/pkpgcounter.examples +++ pkpgcounter-3.50/debian/pkpgcounter.examples @@ -0,0 +1,7 @@ +tests/colors.pdf +tests/master.ps.gz +tests/README +tests/gstests.py +tests/runcolors.py +tests/runtest.sh + --- pkpgcounter-3.50.orig/debian/watch +++ pkpgcounter-3.50/debian/watch @@ -0,0 +1,4 @@ +version=3 +opts="downloadurlmangle=s/gz\/view/gz/,filenamemangle=s/.*pkpgcounter-(.*)\.tar\.gz\/view/pkpgcounter-$1.tar.gz/" \ + http://www.pykota.com/software/pkpgcounter/download/tarballs \ + http://www.pykota.com/software/pkpgcounter/download/tarballs/pkpgcounter-(.*)\.tar\.gz/view --- pkpgcounter-3.50.orig/debian/copyright +++ pkpgcounter-3.50/debian/copyright @@ -0,0 +1,35 @@ +This package was debianized by Kumar Appaiah on +Sat, 28 Jul 2007 20:57:47 +0530. + +It was downloaded from http://www.pykota.com/software/pkpgcounter + +Upstream Author: + + Jerome Alet + +Copyright: + + Copyright (C) 2003, 2004, 2005, 2006, 2007 Jerome Alet + +License: + + This package is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 3 of the License, or + (at your option) any later version. + + This package is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this package; if not, write to the Free Software + Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA + +On Debian systems, the complete text of the GNU General Public License +version 3 can be found in `/usr/share/common-licenses/GPL-3'. + +The Debian packaging is (C) 2007-2008, Kumar Appaiah +and and Jerome Alet , and is licensed under +the GPL 3, see above. --- pkpgcounter-3.50.orig/debian/rules +++ pkpgcounter-3.50/debian/rules @@ -0,0 +1,56 @@ +#!/usr/bin/make -f +# -*- makefile -*- +#export DH_VERBOSE=1 + +# The versions of python currently supported +PYTHON=$(shell pyversions -r) + +include /usr/share/quilt/quilt.make +include /usr/share/python/python.mk + +build: build-stamp + +build-stamp: patch + dh_testdir + $(PYTHON) setup.py build + touch $@ + +clean: unpatch + dh_testdir + dh_testroot + rm -f *-stamp + rm -rf compile build + ./clean.sh + dh_clean + +install: build install-$(PYTHON) + +install-$(PYTHON): + dh_testdir + dh_testroot + $(PYTHON) setup.py install --root `pwd`/debian/pkpgcounter/ $(py_setup_install_args) + find ./debian/pkpgcounter/usr/lib -name '*\.py' | xargs sed -i -e '1 s|^#\!.*python.*||' + sed -i -e '1 s|^#\!.*python.*|#!/usr/bin/python|' ./debian/pkpgcounter/usr/bin/pkpgcounter + rm ./debian/pkpgcounter/usr/share/doc/pkpgcounter/COPYING + +# Build architecture-independent files here. +# Pass to all debhelper commands in this target to reduce clutter. +binary-indep: build install + dh_testdir + dh_testroot + dh_installdocs + dh_installexamples + dh_installchangelogs + dh_pycentral + dh_compress -X.py + dh_fixperms + dh_installdeb + dh_gencontrol + dh_md5sums + dh_builddeb + +binary: binary-indep + +binary-arch: + +.PHONY: build clean binary-indep binary install --- pkpgcounter-3.50.orig/debian/control +++ pkpgcounter-3.50/debian/control @@ -0,0 +1,54 @@ +Source: pkpgcounter +Section: utils +Priority: optional +Maintainer: Ubuntu MOTU Developers +XSBC-Original-Maintainer: Python Applications Packaging Team +Uploaders: Kumar Appaiah , Jerome Alet +Build-Depends-Indep: python, python-central (>= 0.5), python-imaging +Build-Depends: debhelper (>= 5.0.37.3), quilt +Standards-Version: 3.8.0 +XS-Python-Version: current +Vcs-Svn: svn://svn.debian.org/python-apps/packages/pkpgcounter/trunk +Vcs-Browser: http://svn.debian.org/viewsvn/python-apps/packages/pkpgcounter/trunk/ +Homepage: http://www.pykota.com/software/pkpgcounter + +Package: pkpgcounter +Architecture: all +Depends: ${python:Depends}, ${misc:Depends}, python-imaging (>= 1.1.2-3.2), ghostscript +Recommends: python-psyco [i386 hurd-i386 netbsd-i386 kfreebsd-i386], + imagemagick, xvfb, xauth, abiword, texlive-latex-base +XB-Python-Version: ${python:Versions} +Description: computes number of pages or quantity of ink needed to print documents + pkpgcounter is a generic Page Description Language parser which can + either count the number of pages or compute the percent of ink + coverage needed to print various types of documents. It is written in + Python. + . + It currently recognizes the following file formats : + . + * PostScript (both DSC compliant and binary) + * PDF + * PCL3/4/5 + * PCLXL (aka PCL6) + * DVI + * OpenDocument (ISO/IEC DIS 26300) + * Microsoft Word (c) (tm) (r) (etc...) + * Plain text + * TIFF + * Several other image formats + * ESC/P2 + * Zenographics ZjStream + * Samsung QPDL (aka SPL2) + * Samsung SPL1 + * ESC/PageS03 + * Brother HBP + * Hewlett-Packard Lightweight Imaging Device Interface Language + * Structured Fax + * Canon BJ/BJC + * ASCII PNM (Netpbm) + . + The ten latter ones, as well as some TIFF documents, are currently + only supported in page counting mode. + . + pkpgcounter is often used in combination with print + accounting solutions like PyKota or JasMine. --- pkpgcounter-3.50.orig/debian/docs +++ pkpgcounter-3.50/debian/docs @@ -0,0 +1,3 @@ +BUGS +NEWS +README --- pkpgcounter-3.50.orig/debian/patches/01_fix_tempfile.diff +++ pkpgcounter-3.50/debian/patches/01_fix_tempfile.diff @@ -0,0 +1,58 @@ +This patch backports some fixes which remove unneeded temporary +files upon exit, thus preventing accumulation of temporary files. + +Index: pkpgcounter-3.50/pkpgpdls/analyzer.py +=================================================================== +--- pkpgcounter-3.50.orig/pkpgpdls/analyzer.py 2008-12-04 07:35:51.000000000 -0600 ++++ pkpgcounter-3.50/pkpgpdls/analyzer.py 2008-12-04 07:37:31.000000000 -0600 +@@ -55,7 +55,6 @@ + self.options = options + self.filename = filename + self.workfile = None +- self.mustclose = None + + def getJobSize(self) : + """Returns the job's size.""" +@@ -97,7 +96,6 @@ + + def openFile(self) : + """Opens the job's data stream for reading.""" +- self.mustclose = False # by default we don't want to close the file when finished + if hasattr(self.filename, "read") and hasattr(self.filename, "seek") : + # filename is in fact a file-like object + infile = self.filename +@@ -107,7 +105,6 @@ + else : + # normal file + self.workfile = open(self.filename, "rb") +- self.mustclose = True + return + + # Use a temporary file, always seekable contrary to standard input. +@@ -123,8 +120,7 @@ + + def closeFile(self) : + """Closes the job's data stream if we have to.""" +- if self.mustclose : +- self.workfile.close() ++ self.workfile.close() + + def readFirstAndLastBlocks(self, inputfile) : + """Reads the first and last blocks of data.""" +--- pkpgcounter-3.50.orig/pkpgpdls/pjl.py ++++ pkpgcounter-3.50/pkpgpdls/pjl.py +@@ -129,12 +129,12 @@ + klass = PJLParser + if arg == "-" : + infile = sys.stdin +- mustclose = 0 ++ mustclose = False + else : + if arg.endswith(".ejl") : + klass = EJLParser + infile = open(arg, "rb") +- mustclose = 1 ++ mustclose = True + try : + parser = klass(infile.read(), debug=1) + except PJLParserError, msg : --- pkpgcounter-3.50.orig/debian/patches/series +++ pkpgcounter-3.50/debian/patches/series @@ -0,0 +1 @@ +01_fix_tempfile.diff