--- foo2zjs-20090908dfsg.orig/debian/NEWS
+++ foo2zjs-20090908dfsg/debian/NEWS
@@ -0,0 +1,13 @@
+foo2zjs (20090908dfsg-2) unstable; urgency=low
+
+  Starting with this version all HP firmwares are looked for into
+  /lib/firmware/hp/ instead of upstream /usr/share/foo2zjs/firmware/
+  (thus solving bug #517957).
+
+  The upstream /usr/bin/getweb and /usr/sbin/hplj1000 scripts have
+  been patched to use this new location.  foo2zjs postinst should
+  automatically handle the migration of every firmware present in
+  the old location to the new one.
+
+ -- Luca Capello <luca@pca.it>  Mon, 22 Mar 2010 13:15:37 +0100
+
--- foo2zjs-20090908dfsg.orig/debian/copyright
+++ foo2zjs-20090908dfsg/debian/copyright
@@ -0,0 +1,72 @@
+This package was debianized by Chris Lawrence <lawrencc@debian.org> on
+Tue, 27 May 2003 16:03:54 -0500.
+
+It was downloaded from http://foo2zjs.rkkda.com/foo2zjs.tar.gz
+
+Upstream Authors: Rick Richardson <rick.richardson@comcast.net>
+		  Main Developer
+
+		  Easy Software Products Copyright (C) 1997-2006
+		  List of files:
+cups.h (from the CUPS Imaging library)
+
+		  Paul Laufer Copyright (C) 2001
+		  List of files:
+msexpand
+
+		  Gerhard Fuernkranz Copyright (C) 2004
+		  List of files:
+crd/prolog.ps
+		  
+		  Marti Maria Copyright (C) 1998-2001
+		  List of files:
+icc2ps/cmscam97.c
+icc2ps/cmscnvrt.c
+icc2ps/cmserr.c
+icc2ps/cmsgamma.c
+icc2ps/cmsgmt.c
+icc2ps/cmsintrp.c
+icc2ps/cmsio1.c
+icc2ps/cmslut.c
+icc2ps/cmsmatsh.c
+icc2ps/cmsmtrx.c
+icc2ps/cmsnamed.c
+icc2ps/cmspack.c
+icc2ps/cmspcs.c
+icc2ps/cmsps2.c
+icc2ps/cmssamp.c
+icc2ps/cmswtpnt.c
+icc2ps/cmsxform.c
+icc2ps/icc2ps.c
+icc2ps/lcms.
+		 
+		  SunSoft, Inc. Copyright (c) 1994-1996
+		  List of files:
+icc2ps/icc34.h
+
+The rest of the debian packaging is also licensed under the
+GPL v. 2 as listed below.
+
+Copyright:
+
+   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; version 2 dated June, 1991.
+
+   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.
+
+On Debian systems, the complete text of the GNU General
+Public License can be found in `/usr/share/common-licenses/GPL-2'.
+
+PATENTS
+It is possible that certain products which can be built using the jbig
+software module might form inventions protected by patent rights in
+some countries (e.g., by patents about arithmetic coding algorithms
+owned by IBM and AT&T in the USA). Provision of this software by the
+author does NOT include any licences for any patents. In those
+countries where a patent licence is required for certain applications
+of this software module, you will have to obtain such a licence
+yourself.
--- foo2zjs-20090908dfsg.orig/debian/watch
+++ foo2zjs-20090908dfsg/debian/watch
@@ -0,0 +1 @@
+# We track foo2zjs SVN revisions, thus no need for a watch file.
--- foo2zjs-20090908dfsg.orig/debian/compat
+++ foo2zjs-20090908dfsg/debian/compat
@@ -0,0 +1 @@
+5
--- foo2zjs-20090908dfsg.orig/debian/foo2zjs.preinst
+++ foo2zjs-20090908dfsg/debian/foo2zjs.preinst
@@ -0,0 +1,15 @@
+#!/bin/sh
+
+set -e
+
+if [ "$1" = install ] || [ "$1" = upgrade ]; then
+	if [ -e "/etc/udev/rules.d/11-hplj10xx.rules" ]; then
+		if [ "`md5sum \"/etc/udev/rules.d/11-hplj10xx.rules\" | sed -e \"s/ .*//\"`" = \
+		     "`dpkg-query -W -f='${Conffiles}' foo2zjs | sed -n -e \"\\\\' /etc/udev/rules.d/11-hplj10xx.rules's/.* //p\"`" ]
+		then
+			rm -f "/etc/udev/rules.d/11-hplj10xx.rules"
+		fi
+	fi
+fi
+
+#DEBHELPER#
--- foo2zjs-20090908dfsg.orig/debian/control
+++ foo2zjs-20090908dfsg/debian/control
@@ -0,0 +1,30 @@
+Source: foo2zjs
+Section: text
+Priority: optional
+Maintainer: Debian Foo2zjs Maintainers <foo2zjs-maintainer@lists.alioth.debian.org>
+Uploaders: Michael Koch <konqueror@gmx.de>, Steffen Joeris <white@debian.org>, Luca Capello <luca@pca.it>
+Build-Depends: debhelper (>= 7), ghostscript, quilt (>= 0.40), foomatic-filters, libcups2-dev
+Standards-Version: 3.9.1
+Homepage: http://foo2zjs.rkkda.com/
+Vcs-Svn: svn://svn.debian.org/foo2zjs
+Vcs-Browser: http://svn.debian.org/viewsvn/foo2zjs/
+
+Package: foo2zjs
+Architecture: any
+Depends: ${shlibs:Depends}, ${misc:Depends}, foomatic-filters, dc
+Recommends: foomatic-db-engine, wget, unzip
+Suggests: psutils, hannah-foo2zjs, tk8.4, tix
+Breaks: udev (<< 136-1)
+Description: Support for printing to ZjStream-based printers
+ foo2zjs is an open source printer driver for printers that use the
+ Zenographics ZjStream wire protocol for their print data, such as the
+ Minolta magicolor 2200/2300/2430 DL, Minolta Color PageWorks/Pro L and
+ HP LaserJet 1000/1005/1018/1020/1022. These printers are often
+ erroneously referred to as "winprinters" or "GDI printers".
+ .
+ This package provides the following drivers: foo2hiperc, foo2hp,
+ foo2lava, foo2oak, foo2qpdl, foo2slx, foo2xqx, foo2zjs.
+ .
+ The foomatic-db-engine package is recommended to simplify configuring
+ this printer driver.  The psutils package is needed to enable n-up
+ printing support.
--- foo2zjs-20090908dfsg.orig/debian/manpages
+++ foo2zjs-20090908dfsg/debian/manpages
@@ -0,0 +1 @@
+debian/foo2zjs-icc2ps.1
--- foo2zjs-20090908dfsg.orig/debian/foo2zjs-icc2ps.1
+++ foo2zjs-20090908dfsg/debian/foo2zjs-icc2ps.1
@@ -0,0 +1,32 @@
+.\"                                      Hey, EMACS: -*- nroff -*-
+.\" First parameter, NAME, should be all caps
+.\" Second parameter, SECTION, should be 1-8, maybe w/ subsection
+.\" other parameters are allowed: see man(7), man(1)
+.TH FOO2ZJS-ICC2PS 1 "November  20, 2005"
+.SH NAME
+foo2zjs-icc2ps \- part of the printer driver foo2zjs
+.SH SYNOPSIS
+.B foo2zjs-icc2ps [flags] [output file]
+.SH DESCRIPTION
+.B foo2zjs-icc2ps
+generates PostScript CRD or CSA from ICC profiles.
+If no file is given, output goes to stdout.
+You can specify by -i or -o the desired profile(s).
+Devicelink profiles are accepted as long as input
+for CRD / output for CSA were XYZ or Lab.
+.PP
+.SH Flags
+.TP
+.B \-i<profile>
+Input profile: Generates Color Space Array (CSA)
+.TP
+.B \-o<profile>
+Output profile: Generates Color Rendering Dictionary (CRD)
+.TP
+.B \-t<0,1,2,3>
+Intent (0=Perceptual, 1=Colorimetric, 2=Saturation, 3=Absolute)
+.SH AUTHOR
+foo2zjs-icc2ps was written by Rick Richardson <rickr@mn.rr.com> .
+.PP
+This manual page was written by Steffen Joeris <steffen.joeris@skolelinux.de>,
+for the Debian project (but may be used by others).
--- foo2zjs-20090908dfsg.orig/debian/changelog
+++ foo2zjs-20090908dfsg/debian/changelog
@@ -0,0 +1,541 @@
+foo2zjs (20090908dfsg-5.1+squeeze0) stable-proposed-updates; urgency=low
+
+  * Non-maintainer upload.
+  * Update debian/patches/60-getweb.in.patch:
+    Fix CVE-2011-2684 "Insecure Temporary File" (CWE-277) in /usr/bin/getweb
+    by creating a safe temporary directory with mktemp (Closes: #633870) and
+    running the script with -e.
+
+ -- Didier Raboud <odyx@debian.org>  Wed, 27 Jul 2011 18:51:20 +0200
+
+foo2zjs (20090908dfsg-5.1) unstable; urgency=low
+
+  * Non-maintainer upload.
+  * debian/control:
+    + Depends: on dc (Closes: #609761).
+
+ -- Didier Raboud <odyx@debian.org>  Wed, 12 Jan 2011 14:49:08 +0100
+
+foo2zjs (20090908dfsg-5) unstable; urgency=low
+
+  [ Luca Capello ]
+  * debian/README.Debian:
+    + add a note about the "HPLJ 10xx Replaced Paper" GUI requiring
+      tk8.4 and tix, now Suggests:.
+  * debian/control:
+    + Standards-Version to 3.9.1, no changes needed, thanks to lintian.
+  * debian/copyright:
+    + add information for cups.h (from the CUPS Imaging library).
+    + add information for msexpand (Perl, no relationship with the
+      one from the mscompress package).
+    - remove obsolete information for hannah-foo2zjs.
+
+  [ Till Kamppeter ]
+  * Merge from Ubuntu maverick.
+  * debian/control:
+    + Depends: on foomatic-filters.
+  * debian/patches/series: update.
+  * debian/patches/92-udev-firmware-script-fixes.patch:
+    + When loading firmware into the printer via UDEV script, wait 3
+      seconds, so that UDEV scripts for automatic printer setup do not
+      interfere with the firmware transfer to the printer.
+
+  [ Steve Langasek ]
+  * Merge from Ubuntu maverick.
+  * debian/control:
+    - Drop tk8.4 and tix Recommends: to Suggests: (Closes: #601591).
+
+ -- Luca Capello <luca@pca.it>  Sun, 14 Nov 2010 19:45:26 +0100
+
+foo2zjs (20090908dfsg-4) unstable; urgency=low
+
+  * debian/control:
+    + list all the provided drivers for better searching, thanks to
+      Sam Morris <sam@robots.org.uk> (Closes: #579962).
+  * debian/foo2zjs.doc-base:
+    + new file to register the documentation via doc-base, thanks to
+      lintian.
+  * debian/NEWS:
+    + add trailing blank line for apt-listchanges, thanks to lintian.
+  * debian/README.Debian:
+    + add paragraph titles.
+    + add paragraph about "HPLJ 10xx Replaced Paper" icon (see #579154).
+  * debian/source/format:
+    + new file, keep 1.0 format for now, thanks to lintian.
+
+ -- Luca Capello <luca@pca.it>  Sat, 15 May 2010 19:21:25 +0200
+
+foo2zjs (20090908dfsg-3) unstable; urgency=low
+
+  * debian/foo2zjs.postinst:
+    + move firmware files only if they are present, thus avoiding a
+      "No such file or directory" error from mv during upgrades.
+
+ -- Luca Capello <luca@pca.it>  Tue, 23 Mar 2010 11:54:44 +0100
+
+foo2zjs (20090908dfsg-2) unstable; urgency=low
+
+  [ Luca Capello ]
+  * debian/control:
+    + Standards-Version to 3.8.4, no changes needed, thanks to lintian.
+    + Build-Depends: on quilt to manage patches.
+    + Recommends: unzip for 'getexe' function in getweb script.
+    + add ${misc:Depends}, thanks to lintian.
+  * debian/foo2zjs.dirs:
+    + add /lib/firmware/hp/.
+    - remove now useless /usr/share/foo2zjs/tmp/.
+  * debian/foo2zjs.postinst:
+    + move user-downloaded firmwares to /lib/firwmare/hp/.
+  * debian/NEWS:
+    + notice the new location for firmwares.
+  * debian/patches/*:
+    + convert to quilt and refresh.
+  * debian/patches/60-getweb.in.patch:
+    + working directory is /tmp/foo2zjs/.
+    + new 'puticm' function to install ICM files.
+    + extract firmware for HP LaserJet P1006/1008/1505 printers as well.
+    - remove wrong 'putfw' call for Minolta 2200 DL.
+  * debian/patches/70-lib-firmware-hp.patch:
+    + firmware directory is /lib/firmware/hp/ (Closes: #517957).
+  * debian/README.source:
+    + adapt to quilt.
+  * debian/rules:
+    + adapt to quilt.
+    - remove touch call for /usr/share/foo2zjs/tmp/.placeholder.
+
+  [ Michael Koch ]
+  * Removed Luca Bedogni from Uploaders as he is MIA (Closes: 550268).
+  * Updated Build-Depends on debhelper to level 7.
+  * Replaced dh_clean -h by dh_prep.
+
+  [ Steve Langasek ]
+  * debian/control: Breaks: udev (<< 136-1) to ensure the correct udev
+    version is used.
+  * debian/foo2zjs.preinst: when installing or upgrading, remove the
+    old udev rules file /etc/udev/rules.d/11-hplj10xx.rules if it has
+    not been locally modified.
+  * debian/patches/30-udev-rules.dpatch (Closes: #558978):
+    + 'BUS=="usb"' is deprecated, replaced with 'SUBSYSTEMS=="usb"'.
+    + Removed UDEV rule items which conflict with the general UDEV rules
+      for USB printers: 'NAME="usb/%k"', 'MODE="0666"'.
+    + Change SYSFS to ATTRS.
+  * debian/rules: install the udev rules file as
+    /lib/udev/rules.d/85-hplj10xx.rules.
+
+ -- Luca Capello <luca@pca.it>  Mon, 22 Mar 2010 17:09:44 +0100
+
+foo2zjs (20090908dfsg-1) unstable; urgency=low
+
+  * New upstream release.
+    - supports Minolta mc1690MF (Closes: #545950)
+  * debian/patches/60-hplj1000.dpatch: Removed last hunk as it is
+    applied upstream.
+  * debian/patches/70-printer-profile.dpatch: Added to work around
+    deleting of printer-profile script in upstream Makefile.
+  * debian/patches/90-manpages.dpatch: Updated to also fix manpage
+    of printer-profile.
+  * debian/README.source: Renamed from debian/README.Debian-source.
+
+ -- Michael Koch <konqueror@gmx.de>  Mon, 14 Sep 2009 20:21:07 +0200
+
+foo2zjs (20090301dfsg-5) unstable; urgency=low
+
+  * Remove hannah-foo2zjs package as its now in its own source package.
+  * debian/README.Debian-source: New file to describe usage of dpatch.
+  * debian/control: Updated Standards-Version to 3.8.3.
+  * debian/control: Add Vcs-Browser field.
+
+ -- Michael Koch <konqueror@gmx.de>  Wed, 02 Sep 2009 08:49:26 +0200
+
+foo2zjs (20090301dfsg-4) unstable; urgency=low
+
+  * debian/hannah-package/gui.cpp: Fix list of argument names for getweb
+    (Closes: #537325).
+  * debian/patches/40-hplj1000.dpatch: Updated to also guard globbered
+    names in find call (Closes: #526781).
+  * debian/README.Debian: Clarify how hannah-foo2zjs and getweb are used
+    (Closes: #503373, #529300).
+  * debian/copyright: Link to /usr/share/common-licenses/GPL-2
+    instead of /usr/share/common-licenses/GPL.
+  * debian/control:
+    + hannah-foo2zjs: Tighten Depends on kdebase-bin to (<< 4:4.4.0-1)
+      (Closes: #460480).
+    + Updated Standards-Version to 3.8.2.
+  * debian/patches/60-getweb.in.dpatch: Exit with failure when called
+    as non-root.
+  * debian/patches/90-manpages.dpatch: New dpatch to fix manpage errors.
+
+ -- Michael Koch <konqueror@gmx.de>  Sat, 01 Aug 2009 14:01:43 +0200
+
+foo2zjs (20090301dfsg-3) unstable; urgency=low
+
+  * debian/control:
+    + s/tik/tix/ in Recommends:, my fault.
+  * debian/foo2zjs.dirs:
+    + sort alphabetically.
+    + add /usr/share/pixmaps (Closes: #521992).
+  * debian/foo2zjs.links:
+    + list all links to be created for the hplj* helper programs.
+    + install links for HP LaserJet P1xxx printers.
+  * debian/patches/00list: update.
+  * debian/patches/60-getweb.in.dpatch:
+    + extract firmware for HP LaserJet P1005/1007 printers as well.
+  * debian/patches/60-hplj1000.dpatch:
+    + always load firmwares from /usr/share/foo2zjs/firmware.
+  * debian/rules:
+    + call dh_link only once.
+
+ -- Luca Capello <luca@pca.it>  Thu, 02 Apr 2009 18:07:52 +0200
+
+foo2zjs (20090301dfsg-2) unstable; urgency=low
+
+  * debian/patches/30-udev-rules.dpatch:
+    + for some printers, HP is lowercase, thanks to ilf
+      <ilf@zeromail.org> (Closes: #519628).
+
+ -- Luca Capello <luca@pca.it>  Wed, 18 Mar 2009 22:32:41 +0100
+
+foo2zjs (20090301dfsg-1) unstable; urgency=low
+
+  * New upstream version (Closes: #466758)
+  * DFSG repack
+    - remove binary file c5200mono.prn
+    - remove crd/qpdl/CLP* , because copyright is unclear
+  * debian/*.1:
+    - remove, use upstream instead.
+  * debian/control:
+    + Recommends: tk8.4 and tik for hplj10xx_gui.tcl, thanks to lintian.
+  * debian/hannah-package/hanna.desktop:
+    - remove now useless Encoding key, thanks to lintian.
+  * debian/manpages:
+    + install foo2zjs-icc2ps.1 only.
+  * debian/patches/00list: update.
+  * debian/patches/10-makefile.dpatch: refresh.
+  * debian/patches/30-udevs-rules.dpatch: refresh.
+  * debian/patches/40-desktop-encoding-correction.dpatch:
+    - remove now useless Encoding key, thanks to lintian.
+  * debian/patches/40-path-correction.dpatch: refresh.
+  * debian/patches/50-fix-grotty-warnings:
+    - do not apply, it requires a too long refresh and a better
+      solution would be to fix the upstream manpage generation system.
+  * debian/patches/60-getweb.in.dpatch: refresh.
+  * debian/patches/70-getweb.in.dpatch:
+    - remove, no more needed.
+  * debian/watch:
+    + new dummy file, thanks to lintian.
+
+ -- Luca Capello <luca@pca.it>  Tue, 03 Mar 2009 09:43:35 +0100
+
+foo2zjs (20070718dfsg-9) unstable; urgency=low
+
+  * debian/control:
+    + add myself to Uploaders:.
+  * debian/patches/30-udev-rules.dpatch:
+    + backport upstream fix to support udev hotplugging, thanks to
+      ilf <ilf@zeromail.org> (Closes: #477923).
+
+ -- Luca Capello <luca@pca.it>  Mon, 22 Dec 2008 13:13:25 +0100
+
+foo2zjs (20070718dfsg-8) unstable; urgency=low
+
+  * Fixed bashism in debian/patches/60-getweb.in.dpatch. Closes: #489576
+  * Use su-to-root in debian/hannah-foo2zjs.menu and
+    debian/hannah-package/hannah.desktop.
+  * Use menu section Applications/System/Administration instead of
+    Applications/System.
+  * Use the Suggests from menu package for the Depends of hannah-foo2zjs
+    to make su-to-root -X work always.
+  * Build-Depends on ghostscript instead of gs-gpl.
+  * Build-Depends on libcups2-dev instead of libcupsys2-dev.
+  * Added Recommends for foo2zjs on wget. Neede by getweb script.
+  * Exclude the manual.pdf from dh_compress.
+
+ -- Michael Koch <konqueror@gmx.de>  Thu, 21 Aug 2008 18:16:23 +0200
+
+foo2zjs (20070718dfsg-7.1) unstable; urgency=medium
+
+  * Non-maintainer upload.
+  * Add '80-getweb.in.dpatch' to fix bashism in /bin/sh script
+    (Closes: #472895)
+  * Bump Standards-Version to 3.8.0.
+
+ -- Chris Lamb <chris@chris-lamb.co.uk>  Sat, 07 Jun 2008 20:17:48 +0100
+
+foo2zjs (20070718dfsg-7) unstable; urgency=medium
+
+  * Added menu file for hannah-foo2zjs package (Closes: #444850).
+   - Call dh_installmenu in debian/rules
+   - Adjust debian/hannah-foo2zjs.dirs accordingly
+  * Modified debian/rules to use /usr/share/dpatch/dpatch.make
+  * Added a patch from a newer getweb because the firmware location has
+  changed (Closes: #449426).
+
+ -- Luca Bedogni <me@lucabedogni.it>  Thu, 15 Nov 2007 17:40:37 +1100
+
+foo2zjs (20070718dfsg-6) unstable; urgency=low
+
+  * debian/control:
+        - Added the Homepage tag insted of displaing it in the long description
+          (Closes: #439579).
+        - Added Vcs-Svn tag.
+  * Now hannah-foo2zjs display the output of an error (Closes:444852) 
+
+ -- Luca Bedogni <me@lucabedogni.it>  Fri, 02 Nov 2007 01:06:58 +0100
+
+foo2zjs (20070718dfsg-5) experimental; urgency=low
+
+  * Change name of package hannah to hannah-foo2zjs to make
+    it more related to foo2zjs (and because there is already
+    a package in the archive called hannah)
+   - Also rename the binary to hannah-foo2zjs and its references
+
+ -- Steffen Joeris <white@debian.org>  Sun, 07 Oct 2007 17:13:46 +1000
+
+foo2zjs (20070718dfsg-4) experimental; urgency=low
+
+  [ Luca Bedogni ]
+  * Now hannah is a standalone package
+   - Moved debian/hannah to debian/hannah-package
+   - Added the clean call for hannah-package in debian/rules
+   - Added new package information to debian/control
+  * Modified menu file for opening hannah with kdesu or gksu
+    (Closes: #444850)
+
+  [ Steffen Joeris ]
+  * Fix cleanup for hannah and call it with make distclean
+  * Remove dependency against kdebase-bin | gksu from foo2zjs, because
+    this is satisfied via hannah now
+  * Add hannah as a suggests for foo2zjs
+  * Add foo2zjs as a depends to hannah
+  * Add debian/copyright information
+
+ -- Luca Bedogni <me@lucabedogni.it>  Sun, 07 Oct 2007 16:24:58 +1000
+
+foo2zjs (20070718dfsg-3) experimental; urgency=low
+
+  * Include first version of Hannah (GUI for downloading and installing
+    the printer firmware) (Closes: #443994)
+   - Add Hannah code to debian/hannah/*
+   - Modify debian/rules to build hannah from source
+   - Add build-depends against libqt4-dev
+   - Generate the standard directory for .desktop files in debian/dirs
+   - Install hannah.desktop into the standard desktop directory
+   - Update README.Debian to point to Hannah
+   - Renamed dpatch to 60-getweb.in.dpatch and adjusted it to match
+     for Hannah
+   - Use tmp file under /usr/share/foo2zjs/tmp for unpacking and
+     preparing downloaded firmware
+   - Add a depends against kdebase-bin | gksu to use either of both
+     programs to become root, when calling hannah
+  * Fix breaking line in 11-hplj10xx.rules to repair it
+   (Closes: #443917) Thanks to Cristian Ionescu-Idbohrn for the patch
+
+
+ -- Steffen Joeris <white@debian.org>  Sun, 30 Sep 2007 18:10:33 +1000
+
+foo2zjs (20070718dfsg-2) unstable; urgency=low
+
+  [ Luca Bedogni ]
+  * Added 60-getweb.dpatch for improving the getweb script to install the
+    firmware too, instead of download-only (Closes: #419038)
+
+  [ Steffen Joeris ]
+  * Update README.Debian and remove some useless information
+
+  [ Michael Koch ]
+  * Improved 60-getweb.dpatch to delete local files after putting them into
+    firmware directory
+
+ -- Michael Koch <konqueror@gmx.de>  Sat, 22 Sep 2007 21:58:30 +0200
+
+foo2zjs (20070718dfsg-1) experimental; urgency=low
+
+  [ Luca Bedogni ]
+  * Modified patches to fit with new version
+  * Removed Finn-Arne Johansen (Requested on #427678)
+  * Added me (Luca Bedogni) as co-maintainer
+  * Added Michael Koch as co-maintainer
+
+  [ Steffen Joeris ]
+  * Put the alioth list as maintainer and myself as co-maintainer
+   - The package is now team maintained (Closes: #429872)
+  * New upstream version (Closes: #427678)
+  * DFSG repack
+   - Removed binary file c5200mono.prn
+   - Removed crd/qpdl/CLP* , because copyright is unclear
+  * Make sure that the PPD files are installed (Closes: #427665)
+
+ -- Steffen Joeris <white@debian.org>  Fri, 20 Jul 2007 18:07:24 +0200
+
+foo2zjs (20061224-3) unstable; urgency=low
+
+  * Make sure that the patches are cleaned up before the general
+    cleanup and therefore avoid FTBFS during second build
+    (Closes: #424277)
+  * Make sure that upstream documentation and copyright information are
+    not installed as they are not needed for debian
+  * Make sure that the cleanup target is complete
+
+ -- Steffen Joeris <white@debian.org>  Wed, 16 May 2007 15:44:32 +1000
+
+foo2zjs (20061224-2) unstable; urgency=low
+
+  * Upload to unstable
+
+ -- Steffen Joeris <white@debian.org>  Sun, 06 May 2007 18:57:46 +1000
+ 
+foo2zjs (20061224-1) experimental; urgency=low
+
+  * New upstream release
+  * Bump debhelper level to 5
+  * Change my maintainer address
+  * Change 30-udev-rules.dpatch to patch the path for the program
+  * Change the path for the hplj1000 script (Closes: #402633)
+  * Install the ChangeLog file from upstream
+  * Still provide the hplj1000 script
+  * Improve package description (Closes: #400036)
+  * Remove old debian diversions file
+  * Update debian/copyright
+  * Patch the build system properly (10-makefile.dpatch)
+
+ -- Steffen Joeris <white@debian.org>  Sat,  6 Jan 2007 00:56:38 +0100
+
+foo2zjs (20060625dfsg-4) unstable; urgency=medium
+
+  * Make sure that the symlinks are available (Closes: #390948)
+    Thanks to Petre Todorov
+
+ -- Steffen Joeris <steffen.joeris@skolelinux.de>  Sun,  8 Oct 2006 14:21:29 +1000
+
+foo2zjs (20060625dfsg-3) unstable; urgency=medium
+
+  * Correct the udev rules (30-udev-rules.dpatch) to make sure all of 
+    the supported hp models work as expected (Closes: #390948)
+  * Correct the path of the program location in hplj1000
+    (40-path-correction.dpatch)
+
+ -- Steffen Joeris <steffen.joeris@skolelinux.de>  Fri,  6 Oct 2006 19:21:40 +1000
+
+foo2zjs (20060625dfsg-2) unstable; urgency=low
+
+  * Upload this version to unstable
+
+  * Upload sponsored by Petter Reinholdtsen.
+
+ -- Steffen Joeris <steffen.joeris@skolelinux.de>  Fri, 11 Aug 2006 20:58:53 +1000
+
+foo2zjs (20060625dfsg-1) experimental; urgency=low
+
+  * New upstream release
+  * Bump standards version, no changes needed
+  * Repack for DFSG compatibility
+  * Provide usb_printerid again (Closes: #355576)
+  * Provide the new firmware download scripts from upstream
+  * Use modified hp10xx.rules file from upstream
+  * Thanks for suggestions from Philippe Teuwen
+  * Add build-dependency against foomatic-filters to make sure foomatic-rip
+    is available
+
+  * Upload sponsored by Morten Werner Olsen.
+
+ -- Steffen Joeris <steffen.joeris@skolelinux.de>  Thu, 27 Jul 2006 18:20:54 +1000
+
+foo2zjs (20060124dfsg-1) unstable; urgency=low
+
+  * new upstream release (Closes: #351413)
+  * repack for DFSG compatibility
+  * wrote manpage for okidecode, used authors description
+
+  * Upload sponsored by Petter Reinholdtsen.
+
+ -- Steffen Joeris <steffen.joeris@skolelinux.de>  Sun,  5 Feb 2006 15:31:09 +0100
+
+foo2zjs (20051220dfsg-1) unstable; urgency=low
+
+  * new upstream release
+  * again have to repack it for DFSG compatibility
+  * add additional explanation 
+    (e.g. reason for repack and reformat of manpages) to README.Debian
+
+  * Upload sponsored by Petter Reinholdtsen.
+
+ -- Steffen Joeris <steffen.joeris@skolelinux.de>  Sun, 01 Jan 2006 14:45:28 +0100
+
+foo2zjs (20051120dfsg-1) unstable; urgency=low
+
+  [ Changes by Steffen Joeris ]
+  * new upstream release
+  * add some clean targets to debian/rules
+  * modify make install in debian/rules
+  * repack and rename to *dfsg because of binaries in source ;(
+  * modify Makefile to recognize the dfsg changes
+  * wrote README.Debian to inform users about the changes
+
+  [ Changes by Finn-Arne Johansen ]
+  * Added code to honour /etc/papersize (Closes: #237967)
+    (20-honour-papersize.dpatch)
+
+  * Upload sponsored by Petter Reinholdtsen.
+
+ -- Finn-Arne Johansen <faj@bzz.no>  Fri,  2 Dec 2005 16:16:09 +0100
+
+foo2zjs (20051113-1) unstable; urgency=low
+
+  * New Maintainer and Co-Maintainer (Closes: #294813) 
+  * New upstream release (Closes: #339761)
+  * Added new clean rules because of new version
+  * bumped standard version
+  * cleaned up the debian/control
+  * provide the full source from the author (Closes: #279830, #279829)
+  * wrote all authors to debian/copyright
+  * reformat the manpages to make the package completely lintian clean
+
+ -- Steffen Joeris <steffen.joeris@skolelinux.de>  Fri, 18 Nov 2005 18:40:40 +0100
+
+foo2zjs (20050217-1) unstable; urgency=low
+
+  * New upstream release.
+  * Please note that there is an RFA for this package.
+
+ -- Chris Lawrence <lawrencc@debian.org>  Thu, 17 Feb 2005 23:26:51 -0600
+
+foo2zjs (20040210-2) unstable; urgency=low
+
+  * Remove the binary-only components from the generated package; if you
+    need foo2oak, see http://foo2oak.rkkda.com/.  (Closes: #233311)
+
+ -- Chris Lawrence <lawrencc@debian.org>  Tue, 17 Feb 2004 21:05:36 -0600
+
+foo2zjs (20040210-1) unstable; urgency=low
+
+  * New upstream release.
+
+ -- Chris Lawrence <lawrencc@debian.org>  Sun, 15 Feb 2004 02:04:03 -0600
+
+foo2zjs (20030807-1) unstable; urgency=low
+
+  * New upstream release.
+
+ -- Chris Lawrence <lawrencc@debian.org>  Sun,  7 Sep 2003 12:32:07 -0500
+
+foo2zjs (20030702-1) unstable; urgency=low
+
+  * New upstream release:
+  	+ Add XML files for Minolta Color PageWorks/Pro L
+        + If color has been selected, but there isn't any color on the page,
+	  then produce a monochrome ZjStream.
+
+ -- Chris Lawrence <lawrencc@debian.org>  Wed,  2 Jul 2003 22:55:33 -0500
+
+foo2zjs (20030531-1) unstable; urgency=low
+
+  * New upstream release.
+
+ -- Chris Lawrence <lawrencc@debian.org>  Fri,  6 Jun 2003 22:55:43 -0500
+
+foo2zjs (20030526-1) unstable; urgency=low
+
+  * Initial Release.  (Closes: #194572)
+
+ -- Chris Lawrence <lawrencc@debian.org>  Tue, 27 May 2003 16:03:54 -0500
+
--- foo2zjs-20090908dfsg.orig/debian/README.source
+++ foo2zjs-20090908dfsg/debian/README.source
@@ -0,0 +1,10 @@
+Debian foo2zjs source
+---------------------
+
+This package uses quilt to manage all modifications to the upstream
+source.  Changes are stored in the source package as diffs in
+debian/patches and applied during the build.
+
+Read /usr/share/doc/quilt/README.source for further explanations.
+
+ -- Luca Capello <luca@pca.it>, Sat, 13 Mar 2010 15:28:40 +0100
--- foo2zjs-20090908dfsg.orig/debian/foo2zjs.dirs
+++ foo2zjs-20090908dfsg/debian/foo2zjs.dirs
@@ -0,0 +1,7 @@
+lib/firmware/hp
+usr/bin
+usr/sbin
+usr/share/applications
+usr/share/man/man1
+usr/share/pixmaps
+usr/share/ppd
--- foo2zjs-20090908dfsg.orig/debian/README.Debian
+++ foo2zjs-20090908dfsg/debian/README.Debian
@@ -0,0 +1,52 @@
+foo2zjs for Debian
+------------------
+
+* Files removed from upstream tarball
+
+Please understand that I had to delete some files which the author is
+still providing, because I got no source code for them.
+This is necessary to get the package into Debian main.
+If you really need these programs, please freel free to download
+them from http://foo2zjs.rkkda.com/foo2zjs.tar.gz on your own risk.
+In addition to that I also deleted all  binary files (.e.g. .icm).
+(Type "wget http://foo2zjs.rkkda.com/foo2zjs.tar.gz").
+Then run the following commands:
+
+tar -xvvzf foo2zjs.tar.gz
+cd foo2zjs
+make
+
+
+* Additional firmwares required by some printers
+
+Some printers need additional firmware to be installed. For downloading and
+installing the right firmware for your printer, you can use the Foo2ZJS
+firmware downloader and installer (codename Hannah). You will find it in
+your Desktop Menu or by running the command "hannah-foo2zjs" as the root
+user. Note that "hannah-foo2zjs" is not part of the "foo2zjs" package but
+in its own package also called "hannah-foo2zjs".
+
+It's also possible to use a pure command line tool called "getweb". This
+tools allows download and installation without using a graphical user
+interface, e.g. on servers.
+
+
+* Replacing paper for the HP LaserJet 10xx printers
+
+Upstream provides a GUI to replace the paper on HP LaserJet 10xx
+printers, whose entry is available in the "Applications -> System
+Tools" menu.
+
+However, the GNOME maintainers thinks this entry clutters the default
+GNOME menu on Debian and thus they have disabled it:
+
+  http://bugs.debian.org/579154
+
+To re-enable it, please use the menu editor available via the
+"System -> Preferences -> Main Menu" entry.
+
+Please also note that you need to install the suggested "tk8.4" and
+"tix" packages.
+
+
+ -- Luca Capello <luca@pca.it>, Wed, 13 Oct 2010 01:37:57 +0200
--- foo2zjs-20090908dfsg.orig/debian/rules
+++ foo2zjs-20090908dfsg/debian/rules
@@ -0,0 +1,91 @@
+#!/usr/bin/make -f
+
+# Uncomment this to turn on verbose mode.
+#export DH_VERBOSE=1
+
+include /usr/share/quilt/quilt.make
+
+CFLAGS = -Wall -g
+
+ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS)))
+	CFLAGS += -O0
+else
+	CFLAGS += -O2
+endif
+ifeq (,$(findstring nostrip,$(DEB_BUILD_OPTIONS)))
+	INSTALL_PROGRAM += -s
+endif
+
+MAKE = make
+QMAKE = qmake-qt4
+
+configure: configure-stamp
+configure-stamp: $(QUILT_STAMPFN)
+	dh_testdir
+	touch configure-stamp
+
+build: build-stamp
+
+build-stamp: configure-stamp 
+	dh_testdir
+	cp printer-profile.in printer-profile
+	$(MAKE) CFLAGS="$(CFLAGS)"
+	touch build-stamp
+
+clean: unpatch
+	dh_testdir
+	dh_testroot
+	rm -f build-stamp configure-stamp
+	rm -rf debian/patched
+	[ ! -f Makefile ] || $(MAKE) clean
+	-rm -f foo2hp
+	-rm -f foo2hp.o
+	-rm -f arm2hpdl
+	-rm -f usb_printerid
+	-rm -f foo2oak
+	-rm -f oakdecode
+	-rm -f oakdecode.o
+	-rm -f foo2hp2600-wrapper
+	-rm -f foo2oak-wrapper
+	-rm -f foo2zjs-wrapper
+	-rm -f okidecode
+	dh_clean
+
+install: build
+	dh_testdir
+	dh_testroot
+	dh_prep
+	dh_installdirs
+	$(MAKE) install PREFIX=$(CURDIR)/debian/foo2zjs/usr MODEL=$(CURDIR)/debian/foo2zjs/usr/share/cups/model FOODB=$(CURDIR)/debian/foo2zjs/usr/share/foomatic/db/source PPD=$(CURDIR)/debian/foo2zjs/usr/share/ppd
+	rm -f $(CURDIR)/debian/foo2zjs/usr/share/doc/foo2zjs/COPYING
+	rm -f $(CURDIR)/debian/foo2zjs/usr/share/doc/foo2zjs/INSTALL
+	rm -f $(CURDIR)/debian/foo2zjs/usr/share/doc/foo2zjs/INSTALL.osx
+	install -D -m 644 hplj10xx.rules $(CURDIR)/debian/foo2zjs/lib/udev/rules.d/85-hplj10xx.rules
+	install -m 755 hplj1000 $(CURDIR)/debian/foo2zjs/usr/sbin/hplj1000
+	install -m 755 getweb $(CURDIR)/debian/foo2zjs/usr/bin/getweb
+
+# Build architecture-independent files here.
+binary-indep: build install
+# We have nothing to do by default.
+
+# Build architecture-dependent files here.
+binary-arch: build install
+	dh_testdir
+	dh_testroot
+	dh_installchangelogs ChangeLog
+	dh_installdocs
+	dh_installexamples
+	dh_installmenu
+	dh_installman
+	dh_link
+	dh_strip
+	dh_compress -Xmanual.pdf
+	dh_fixperms
+	dh_installdeb
+	dh_shlibdeps
+	dh_gencontrol
+	dh_md5sums
+	dh_builddeb
+
+binary: binary-indep binary-arch
+.PHONY: build clean binary-indep binary-arch binary install configure
--- foo2zjs-20090908dfsg.orig/debian/svn-deblayout
+++ foo2zjs-20090908dfsg/debian/svn-deblayout
@@ -0,0 +1 @@
+origDir=../upstream
--- foo2zjs-20090908dfsg.orig/debian/foo2zjs.doc-base
+++ foo2zjs-20090908dfsg/debian/foo2zjs.doc-base
@@ -0,0 +1,11 @@
+Document: foo2zjs
+Title: foo2zjs Manual
+Author: Rick Richardson
+Abstract: foo2zjs is an open source printer driver for printers that
+ use the Zenographics ZjStream wire protocol for their print data.
+ This document contains all the manual pages for the different
+ binaries included with foo2zjs.
+Section: System/Hardware
+
+Format: PDF
+Files: /usr/share/doc/foo2zjs/manual.pdf
--- foo2zjs-20090908dfsg.orig/debian/foo2zjs.postinst
+++ foo2zjs-20090908dfsg/debian/foo2zjs.postinst
@@ -0,0 +1,11 @@
+#!/bin/sh
+
+set -e
+
+if [ "$1" = configure ]; then
+	if ls /usr/share/foo2zjs/firmware/*.dl >/dev/null 2>/dev/null; then
+		mv /usr/share/foo2zjs/firmware/*.dl /lib/firmware/hp/ 2>/dev/null
+	fi
+fi
+
+#DEBHELPER#
--- foo2zjs-20090908dfsg.orig/debian/docs
+++ foo2zjs-20090908dfsg/debian/docs
@@ -0,0 +1 @@
+README
--- foo2zjs-20090908dfsg.orig/debian/foo2zjs.links
+++ foo2zjs-20090908dfsg/debian/foo2zjs.links
@@ -0,0 +1,8 @@
+usr/sbin/hplj1000 usr/sbin/hplj1005
+usr/sbin/hplj1000 usr/sbin/hplj1018
+usr/sbin/hplj1000 usr/sbin/hplj1020
+usr/sbin/hplj1000 usr/sbin/hpljP1005
+usr/sbin/hplj1000 usr/sbin/hpljP1006
+usr/sbin/hplj1000 usr/sbin/hpljP1007
+usr/sbin/hplj1000 usr/sbin/hpljP1008
+usr/sbin/hplj1000 usr/sbin/hpljP1505
--- foo2zjs-20090908dfsg.orig/debian/patches/70-lib-firwmare-hp.patch
+++ foo2zjs-20090908dfsg/debian/patches/70-lib-firwmare-hp.patch
@@ -0,0 +1,54 @@
+Firmware directory is /lib/firmware/hp/ (Closes: #517957)
+--- foo2zjs-20090908dfsg.orig/getweb.in
++++ foo2zjs-20090908dfsg/getweb.in
+@@ -114,7 +114,7 @@
+ putfw() {
+     inputname=$1
+     outputname=$2
+-    $ARM2HPDL $inputname > /usr/share/foo2zjs/firmware/$outputname
++    $ARM2HPDL $inputname > /lib/firmware/hp/$outputname
+     rm $inputname
+ }
+ 
+--- foo2zjs-20090908dfsg.orig/hplj1000
++++ foo2zjs-20090908dfsg/hplj1000
+@@ -35,7 +35,7 @@
+ #
+ # Directory to find downloadable HP firmware files sihpMMMM.dl
+ #
+-FWDIR=/usr/share/foo2zjs/firmware
++FWDIR=/lib/firmware/hp
+ 
+ #
+ # Program used to determine USB printer id information
+--- foo2zjs-20090908dfsg.orig/usb_printerid.1in
++++ foo2zjs-20090908dfsg/usb_printerid.1in
+@@ -26,7 +26,7 @@
+ MFG:Hewlett-Packard;MDL:HP LaserJet 1020;CMD:ACL;CLS:PRINTER;\e
+ DES:HP LaserJet 1020;
+ 
+-# cp /usr/share/foo2zjs/firmware/sihp1020.dl /dev/usb/lp0
++# cp /lib/firmware/hp/sihp1020.dl /dev/usb/lp0
+ 
+ # usb_printerid /dev/usb/lp0
+ GET_DEVICE_ID string:
+@@ -37,7 +37,7 @@
+ 
+ .SH FILES
+ .BR /usr/bin/usb_printerid,
+-.BR /usr/share/foo2*/firmware/*
++.BR /lib/firmware/hp/*
+ .SH SEE ALSO
+ .BR arm2hpdl (1)
+ .SH "AUTHOR"
+--- foo2zjs-20090908dfsg.orig/arm2hpdl.1in
++++ foo2zjs-20090908dfsg/arm2hpdl.1in
+@@ -31,7 +31,7 @@
+ 
+ .SH FILES
+ .BR /usr/bin/arm2hpdl,
+-.BR /usr/share/foo2*/firmware/
++.BR /lib/firmware/hp/*
+ .SH SEE ALSO
+ .BR foo2zjs (1)
+ .SH "AUTHOR"
--- foo2zjs-20090908dfsg.orig/debian/patches/series
+++ foo2zjs-20090908dfsg/debian/patches/series
@@ -0,0 +1,12 @@
+10-makefile.patch
+20-honour-papersize.patch
+30-udev-rules.patch
+40-desktop-encoding-correction.patch
+40-path-correction.patch
+60-getweb.in.patch
+60-hplj1000.patch
+70-lib-firwmare-hp.patch
+70-printer-profile.patch
+80-getweb.in.patch
+90-manpages.patch
+92-udev-firmware-script-fixes.patch
--- foo2zjs-20090908dfsg.orig/debian/patches/10-makefile.patch
+++ foo2zjs-20090908dfsg/debian/patches/10-makefile.patch
@@ -0,0 +1,67 @@
+Patch the Makefile
+--- foo2zjs-20090908dfsg.orig/Makefile
++++ foo2zjs-20090908dfsg/Makefile
+@@ -16,9 +16,7 @@
+ VERSION=0.0
+ 
+ # Installation prefix...
+-PREFIX=/usr/local
+ PREFIX=/usr
+-PREFIX=$(DESTDIR)/usr
+ 
+ # Pathnames for this package...
+ BIN=$(PREFIX)/bin
+@@ -35,7 +33,7 @@
+ INSTALL=install
+ 
+ # Pathnames for referenced packages...
+-FOODB=$(DESTDIR)/usr/share/foomatic/db/source
++FOODB=$(PREFIX)/share/foomatic/db/source
+ 
+ # User ID's
+ LPuid=-oroot
+@@ -544,8 +542,6 @@
+ 	#
+     
+ 
+-UDEVBIN=$(DESTDIR)/bin/
+-
+ install-prog:
+ 	#
+ 	# Install driver, wrapper, and development tools
+@@ -553,8 +549,7 @@
+ 	$(INSTALL) -d $(BIN)
+ 	$(INSTALL) -c $(PROGS) $(SHELLS) $(BIN)/
+ 	if [ "$(BINPROGS)" != "" ]; then \
+-	    $(INSTALL) -d $(UDEVBIN); \
+-	    $(INSTALL) -c $(BINPROGS) $(UDEVBIN); \
++	    $(INSTALL) -c $(BINPROGS) $(BIN); \
+ 	fi
+ 	#
+ 	# Install gamma correction files.  These are just templates,
+@@ -722,9 +717,9 @@
+ 	    fi; \
+ 	done
+ 
+-MODEL=$(DESTDIR)/usr/share/cups/model
+-LOCALMODEL=$(DESTDIR)/usr/local/share/cups/model
+-PPD=$(DESTDIR)/usr/share/ppd
++MODEL=$(PREFIX)/share/cups/model
++LOCALMODEL=$(PREFIX)/local/share/cups/model
++PPD=$(PREFIX)/share/ppd
+ VARPPD=/var/lp/ppd
+ install-ppd:
+ 	#
+@@ -767,9 +762,9 @@
+ 	    done; \
+ 	fi
+ 
+-APPL=$(DESTDIR)/usr/share/applications
+-OLDAPPL=$(DESTDIR)/usr/share/gnome/apps/System
+-PIXMAPS=$(DESTDIR)/usr/share/pixmaps
++APPL=$(PREFIX)/share/applications
++OLDAPPL=$(PREFIX)/share/gnome/apps/System
++PIXMAPS=$(PREFIX)/share/pixmaps
+ 
+ install-desktop:
+ 	#
--- foo2zjs-20090908dfsg.orig/debian/patches/90-manpages.patch
+++ foo2zjs-20090908dfsg/debian/patches/90-manpages.patch
@@ -0,0 +1,281 @@
+Fixes errors in manpages
+--- foo2zjs-20090908dfsg.orig/foo2hp.1in
++++ foo2zjs-20090908dfsg/foo2hp.1in
+@@ -195,7 +195,4 @@
+ Rick Richardson <rick.richardson@comcast.net>
+ .br
+ ${URLHP}/
+-'/"
+-'/"
+-'/"
+ .em pdf_outline
+--- foo2zjs-20090908dfsg.orig/foo2qpdl-wrapper.1in
++++ foo2zjs-20090908dfsg/foo2qpdl-wrapper.1in
+@@ -224,7 +224,4 @@
+ Rick Richardson <rick.richardson@comcast.net>
+ .br
+ ${URLQPDL}/
+-'/"
+-'/"
+-'/"
+ .em pdf_outline
+--- foo2zjs-20090908dfsg.orig/arm2hpdl.1in
++++ foo2zjs-20090908dfsg/arm2hpdl.1in
+@@ -38,7 +38,4 @@
+ Rick Richardson <rick.richardson@comcast.net>
+ .br
+ ${URLZJS}/
+-'/"
+-'/"
+-'/"
+ .em pdf_outline
+--- foo2zjs-20090908dfsg.orig/foo2hp2600-wrapper.1in
++++ foo2zjs-20090908dfsg/foo2hp2600-wrapper.1in
+@@ -230,7 +230,4 @@
+ Rick Richardson <rick.richardson@comcast.net>
+ .br
+ ${URLHP}/
+-'/"
+-'/"
+-'/"
+ .em pdf_outline
+--- foo2zjs-20090908dfsg.orig/hipercdecode.1in
++++ foo2zjs-20090908dfsg/hipercdecode.1in
+@@ -162,7 +162,4 @@
+ Rick Richardson <rick.richardson@comcast.net>
+ .br
+ ${URLHC}/
+-'/"
+-'/"
+-'/"
+ .em pdf_outline
+--- foo2zjs-20090908dfsg.orig/foo2hiperc-wrapper.1in
++++ foo2zjs-20090908dfsg/foo2hiperc-wrapper.1in
+@@ -205,7 +205,4 @@
+ Rick Richardson <rick.richardson@comcast.net>
+ .br
+ ${URLHC}/
+-'/"
+-'/"
+-'/"
+ .em pdf_outline
+--- foo2zjs-20090908dfsg.orig/foo2xqx.1in
++++ foo2zjs-20090908dfsg/foo2xqx.1in
+@@ -152,7 +152,4 @@
+ Rick Richardson <rick.richardson@comcast.net>
+ .br
+ ${URLXQX}/
+-'/"
+-'/"
+-'/"
+ .em pdf_outline
+--- foo2zjs-20090908dfsg.orig/qpdldecode.1in
++++ foo2zjs-20090908dfsg/qpdldecode.1in
+@@ -126,7 +126,4 @@
+ Rick Richardson <rick.richardson@comcast.net>
+ .br
+ ${URLQPDL}/
+-'/"
+-'/"
+-'/"
+ .em pdf_outline
+--- foo2zjs-20090908dfsg.orig/usb_printerid.1in
++++ foo2zjs-20090908dfsg/usb_printerid.1in
+@@ -44,7 +44,4 @@
+ Rick Richardson <rick.richardson@comcast.net>
+ .br
+ ${URLZJS}/
+-'/"
+-'/"
+-'/"
+ .em pdf_outline
+--- foo2zjs-20090908dfsg.orig/foo2hiperc.1in
++++ foo2zjs-20090908dfsg/foo2hiperc.1in
+@@ -173,7 +173,4 @@
+ Rick Richardson <rick.richardson@comcast.com>
+ .br
+ ${URLHC}/
+-'/"
+-'/"
+-'/"
+ .em pdf_outline
+--- foo2zjs-20090908dfsg.orig/oakdecode.1in
++++ foo2zjs-20090908dfsg/oakdecode.1in
+@@ -92,7 +92,4 @@
+ Rick Richardson <rick.richardson@comcast.net>
+ .br
+ ${URLOAK}/
+-'/"
+-'/"
+-'/"
+ .em pdf_outline
+--- foo2zjs-20090908dfsg.orig/foo2oak.1in
++++ foo2zjs-20090908dfsg/foo2oak.1in
+@@ -182,7 +182,4 @@
+ Rick Richardson <rick.richardson@comcast.net>
+ .br
+ ${URLOAK}/
+-'/"
+-'/"
+-'/"
+ .em pdf_outline
+--- foo2zjs-20090908dfsg.orig/zjsdecode.1in
++++ foo2zjs-20090908dfsg/zjsdecode.1in
+@@ -99,7 +99,4 @@
+ Rick Richardson <rick.richardson@comcast.net>
+ .br
+ ${URLZJS}/
+-'/"
+-'/"
+-'/"
+ .em pdf_outline
+--- foo2zjs-20090908dfsg.orig/foo2zjs-pstops.1in
++++ foo2zjs-20090908dfsg/foo2zjs-pstops.1in
+@@ -45,7 +45,4 @@
+ Rick Richardson <rick.richardson@comcast.net>
+ .br
+ ${URLZJS}/
+-'/"
+-'/"
+-'/"
+ .em pdf_outline
+--- foo2zjs-20090908dfsg.orig/foo2zjs.1in
++++ foo2zjs-20090908dfsg/foo2zjs.1in
+@@ -186,7 +186,4 @@
+ Rick Richardson <rick.richardson@comcast.net>
+ .br
+ ${URLZJS}/
+-'/"
+-'/"
+-'/"
+ .em pdf_outline
+--- foo2zjs-20090908dfsg.orig/foo2qpdl.1in
++++ foo2zjs-20090908dfsg/foo2qpdl.1in
+@@ -191,7 +191,4 @@
+ Rick Richardson <rick.richardson@comcast.com>
+ .br
+ ${URLQPDL}/
+-'/"
+-'/"
+-'/"
+ .em pdf_outline
+--- foo2zjs-20090908dfsg.orig/foo2oak-wrapper.1in
++++ foo2zjs-20090908dfsg/foo2oak-wrapper.1in
+@@ -214,7 +214,4 @@
+ Rick Richardson <rick.richardson@comcast.net>
+ .br
+ ${URLOAK}/
+-'/"
+-'/"
+-'/"
+ .em pdf_outline
+--- foo2zjs-20090908dfsg.orig/foo2zjs-wrapper.1in
++++ foo2zjs-20090908dfsg/foo2zjs-wrapper.1in
+@@ -224,7 +224,4 @@
+ Rick Richardson <rick.richardson@comcast.net>
+ .br
+ ${URLZJS}/
+-'/"
+-'/"
+-'/"
+ .em pdf_outline
+--- foo2zjs-20090908dfsg.orig/xqxdecode.1in
++++ foo2zjs-20090908dfsg/xqxdecode.1in
+@@ -105,7 +105,4 @@
+ Rick Richardson <rick.richardson@comcast.net>
+ .br
+ ${URLXQX}/
+-'/"
+-'/"
+-'/"
+ .em pdf_outline
+--- foo2zjs-20090908dfsg.orig/foo2slx-wrapper.1in
++++ foo2zjs-20090908dfsg/foo2slx-wrapper.1in
+@@ -190,7 +190,4 @@
+ Rick Richardson <rick.richardson@comcast.net>
+ .br
+ ${URLSLX}/
+-'/"
+-'/"
+-'/"
+ .em pdf_outline
+--- foo2zjs-20090908dfsg.orig/foo2xqx-wrapper.1in
++++ foo2zjs-20090908dfsg/foo2xqx-wrapper.1in
+@@ -153,7 +153,4 @@
+ Rick Richardson <rick.richardson@comcast.net>
+ .br
+ ${URLXQX}/
+-'/"
+-'/"
+-'/"
+ .em pdf_outline
+--- foo2zjs-20090908dfsg.orig/foo2lava-wrapper.1in
++++ foo2zjs-20090908dfsg/foo2lava-wrapper.1in
+@@ -216,7 +216,4 @@
+ Rick Richardson <rick.richardson@comcast.net>
+ .br
+ ${URLZJS}/
+-'/"
+-'/"
+-'/"
+ .em pdf_outline
+--- foo2zjs-20090908dfsg.orig/foo2slx.1in
++++ foo2zjs-20090908dfsg/foo2slx.1in
+@@ -157,7 +157,4 @@
+ Rick Richardson <rick.richardson@comcast.net>
+ .br
+ ${URLSLX}/
+-'/"
+-'/"
+-'/"
+ .em pdf_outline
+--- foo2zjs-20090908dfsg.orig/foo2lava.1in
++++ foo2zjs-20090908dfsg/foo2lava.1in
+@@ -177,7 +177,4 @@
+ Rick Richardson <rick.richardson@comcast.com>
+ .br
+ ${URLZJS}/
+-'/"
+-'/"
+-'/"
+ .em pdf_outline
+--- foo2zjs-20090908dfsg.orig/slxdecode.1in
++++ foo2zjs-20090908dfsg/slxdecode.1in
+@@ -103,7 +103,4 @@
+ Rick Richardson <rick.richardson@comcast.net>
+ .br
+ ${URLSLX}/
+-'/"
+-'/"
+-'/"
+ .em pdf_outline
+--- foo2zjs-20090908dfsg.orig/lavadecode.1in
++++ foo2zjs-20090908dfsg/lavadecode.1in
+@@ -96,7 +96,4 @@
+ Rick Richardson <rick.richardson@comcast.net>
+ .br
+ ${URLLAVA}/
+-'/"
+-'/"
+-'/"
+ .em pdf_outline
+--- foo2zjs-20090908dfsg.orig/opldecode.1in
++++ foo2zjs-20090908dfsg/opldecode.1in
+@@ -115,7 +115,4 @@
+ Rick Richardson <rick.richardson@comcast.net>
+ .br
+ ${URLRO}/
+-'/"
+-'/"
+-'/"
+ .em pdf_outline
+--- foo2zjs-20090908dfsg.orig/printer-profile.1in
++++ foo2zjs-20090908dfsg/printer-profile.1in
+@@ -50,7 +50,4 @@
+ Rick Richardson <rick.richardson@comcast.net>
+ .br
+ ${URLZJS}/
+-'/"
+-'/"
+-'/"
+ .em pdf_outline
--- foo2zjs-20090908dfsg.orig/debian/patches/40-desktop-encoding-correction.patch
+++ foo2zjs-20090908dfsg/debian/patches/40-desktop-encoding-correction.patch
@@ -0,0 +1,9 @@
+Remove the now useless Encoding key
+--- foo2zjs-20090908dfsg.orig/hplj1020.desktop
++++ foo2zjs-20090908dfsg/hplj1020.desktop
+@@ -1,5 +1,4 @@
+ [Desktop Entry]
+-Encoding=UTF-8
+ Name=HPLJ 10xx Replaced Paper
+ Comment=HP LaserJet 1018, 1020
+ zExec=usb_printerid /dev/usb/lp0
--- foo2zjs-20090908dfsg.orig/debian/patches/92-udev-firmware-script-fixes.patch
+++ foo2zjs-20090908dfsg/debian/patches/92-udev-firmware-script-fixes.patch
@@ -0,0 +1,19 @@
+Delay firmware transfer for UDEV automatic printer setup
+--- foo2zjs_20100728dfsg.orig/hplj1000
++++ foo2zjs_20100728dfsg/hplj1000
+@@ -26,6 +26,15 @@
+ PROGNAME="$0"
+ 
+ #
++# Wait some time before installing the firmware so that probing for
++# automatic printer setup which happens immediately after turning on
++# the printer does not interfere with the firmware transfer to the
++# printer
++# https://bugs.launchpad.net/ubuntu/+source/foo2zjs/+bug/543177
++#
++sleep 3
++
++#
+ # Set $DEV to, e.g. /dev/usb/lp0, to force the device you want
+ # Else, leave it null to automatically detect the device
+ #
--- foo2zjs-20090908dfsg.orig/debian/patches/60-getweb.in.patch
+++ foo2zjs-20090908dfsg/debian/patches/60-getweb.in.patch
@@ -0,0 +1,215 @@
+Improve getweb also for installing the firmware
+--- a/getweb.in
++++ b/getweb.in
+@@ -2,7 +2,9 @@
+ 
+ #
+ # (c) Copyright Rick Richardson 2008
+-#
++# This version has been modified by Debian
++
++set -e
+ 
+ #
+ # PLEASE don't remove the copyright statements.  They should 
+@@ -12,6 +14,13 @@
+ VERSION='$Id: getweb.in,v 1.89 2009/06/23 18:31:20 rick Exp $'
+ 
+ WGETOPTS="--passive-ftp -q"
++ARM2HPDL="/usr/bin/arm2hpdl"
++
++if [ $(id -ru) -ne 0 ]; then
++    echo "You need to be root"
++    exit 1
++fi
++
+ 
+ usage() {
+ cat <<EOF
+@@ -94,7 +103,7 @@
+ }
+ 
+ SYSTEM=`uname -s`
+-WGET=`type wget 2>/dev/null`
++WGET=`which wget`
+ if [ "$SYSTEM" = Darwin -a "$WGET" = "" ]
+ then
+     WGETOPTS=
+@@ -104,6 +113,17 @@
+     }
+ fi
+ 
++putfw() {
++    inputname=$1
++    outputname=$2
++    $ARM2HPDL $inputname > /usr/share/foo2zjs/firmware/$outputname
++    rm $inputname
++}
++
++puticm() {
++    mv *.icm /usr/share/foo2zjs/icm/
++}
++
+ #
+ #	Download a .EXE file from the web, unzip it, and extract the
+ #	files we want
+@@ -150,6 +170,7 @@
+ 	    #lj1488en.exe \
+ 	    #sihp1000.img
+ 	copyright "(c) Copyright Hewlett-Packard 2001"
++	putfw sihp1000.img sihp1000.dl
+ 	;;
+     lj1005|1005)
+ 	gettgz \
+@@ -161,36 +182,42 @@
+ 	    #lj1005hostbased-en.exe \
+ 	    #sihp1005.img
+ 	copyright "(c) Copyright Hewlett-Packard 2002"
++	putfw sihp1005.img sihp1005.dl
+ 	;;
+     lj1018|1018)
+ 	gettgz \
+ 	    http://foo2zjs.rkkda.com/firmware sihp1018.tar.gz \
+ 	    ""
+ 	copyright "(c) Copyright Hewlett-Packard 2005"
++	putfw sihp1018.img sihp1018.dl
+ 	;;
+     lj1020|1020)
+ 	gettgz \
+ 	    http://foo2zjs.rkkda.com/firmware sihp1020.tar.gz \
+ 	    ""
+ 	copyright "(c) Copyright Hewlett-Packard 2005"
++	putfw sihp1020.img sihp1020.dl
+ 	;;
+     [pP]100[57])
+ 	gettgz \
+ 	    http://foo2zjs.rkkda.com/firmware sihpP1005.tar.gz \
+ 	    ""
+ 	copyright "(c) Copyright Hewlett-Packard 2008"
++	putfw sihpP1005.img sihpP1005.dl
+ 	;;
+     [pP]100[68])
+ 	gettgz \
+ 	    http://foo2zjs.rkkda.com/firmware sihpP1006.tar.gz \
+ 	    ""
+ 	copyright "(c) Copyright Hewlett-Packard 2008"
++	putfw sihpP1006.img sihpP1006.dl
+ 	;;
+     [pP]1505)
+ 	gettgz \
+ 	    http://foo2zjs.rkkda.com/firmware sihpP1505.tar.gz \
+ 	    ""
+ 	copyright "(c) Copyright Hewlett-Packard 2008"
++	putfw sihpP1505.img sihpP1505.dl
+ 	;;
+     2200dl|2200)
+ 	if false; then
+@@ -203,6 +230,7 @@
+ 		"*.icm"
+ 	fi
+ 	copyright "(c) Copyright Minolta-QMS 1999"
++	puticm
+ 	;;
+     2300dl|2300)
+ 	if false; then
+@@ -218,6 +246,7 @@
+ 	    http://foo2zjs.rkkda.com/icm km2430.tar.gz \
+ 	    ""
+ 	copyright "(c) Copyright Minolta-QMS 2001"
++	puticm
+ 	;;
+     2300dl_fw)
+ 	# 2300DL firmware upgrade to v2.55
+@@ -246,12 +275,14 @@
+ 	    done
+ 	fi
+ 	copyright "(c) Copyright Minolta-QMS 1998"
++	puticm
+ 	;;
+     2430)
+ 	gettgz \
+ 	    http://foo2zjs.rkkda.com/icm km2430.tar.gz \
+ 	    ""
+ 	copyright "(c) Copyright Konica Minolta 2003"
++	puticm
+ 	;;
+     2530|2490|6115|2480|1600w|1680|1690|4690)
+ 	gettgz \
+@@ -263,6 +294,7 @@
+ 	    http://foo2lava.rkkda.com/icm km-1600.tar.gz \
+ 	    ""
+ 	copyright "(c) Copyright Rick Richardson 2009.  All Rights Reserved"
++	puticm
+ 	;;
+     1215|1500|1600|2600*)
+ 	gettgz \
+@@ -277,6 +309,7 @@
+ 	    http://foo2hp.rkkda.com/icm hp1215.tar.gz \
+ 	    ""
+ 	copyright "(c) Copyright Rick Richardson 2008.  All Rights Reserved"
++	puticm
+ 	;;
+     300|310|315|2160|3160|3175|6110)
+ 	gettgz \
+@@ -287,6 +320,7 @@
+ 	    http://foo2qpdl.rkkda.com/icm samclp315.tar.gz \
+ 	    ""
+ 	copyright "(c) Copyright Rick Richardson 2008.  All Rights Reserved"
++	puticm
+ 	;;
+     600|610)
+ 	;;
+@@ -296,6 +330,7 @@
+ 	    http://foo2slx.rkkda.com/icm lexc500.tar.gz \
+ 	    ""
+ 	copyright "(c) Copyright Lexmark 2006"
++	puticm
+ 	;;
+ 
+     oki)
+@@ -311,24 +346,28 @@
+ 	    mv "$base.ICM" "$base.icm"
+ 	done
+ 	copyright "(c) Copyright Okidata 2005, 2006"
++	puticm
+ 	;;
+     3100|3200|5100|5150|5200|5250)
+ 	gettgz \
+ 	    http://foo2hiperc.rkkda.com/icm okic3200.tar.gz \
+ 	    ""
+ 	copyright "(c) Copyright Okidata 2005"
++	puticm
+ 	;;
+     3300|3400|3530)
+ 	gettgz \
+ 	    http://foo2hiperc.rkkda.com/icm okic3400.tar.gz \
+ 	    ""
+ 	copyright "(c) Copyright Okidata 2006"
++	puticm
+ 	;;
+     5500|5600|5800)
+ 	gettgz \
+ 	    http://foo2hiperc.rkkda.com/icm okic5600.tar.gz \
+ 	    ""
+ 	copyright "(c) Copyright Okidata 2006"
++	puticm
+ 	;;
+ 
+     xPPD)
+@@ -413,6 +452,10 @@
+     usage
+ fi
+ 
++OLDPWD=`pwd`
++NEWPWD=`mktemp --tmpdir --directory foo2zjs.XXXXXX`
++cd "$NEWPWD"
++
+ for i in $*
+ do
+     case "$1" in
+@@ -451,3 +494,5 @@
+ 	;;
+     esac
+ done
++
++cd "$OLDPWD"
--- foo2zjs-20090908dfsg.orig/debian/patches/80-getweb.in.patch
+++ foo2zjs-20090908dfsg/debian/patches/80-getweb.in.patch
@@ -0,0 +1,12 @@
+Fix bashism
+--- foo2zjs-20090908dfsg.orig/getweb.in
++++ foo2zjs-20090908dfsg/getweb.in
+@@ -419,7 +419,7 @@
+ 	tar zxf $HERE/$file
+ 	cd $HERE
+ 	echo "The tarball is extracted and the current directory is up to date."
+-	echo -e "Remove the tarball (y/n)? \c"
++	printf "Remove the tarball (y/n)? "
+ 	read ans
+ 	if [ "$ans" = y ]; then
+ 	    rm -f $file
--- foo2zjs-20090908dfsg.orig/debian/patches/70-printer-profile.patch
+++ foo2zjs-20090908dfsg/debian/patches/70-printer-profile.patch
@@ -0,0 +1,300 @@
+Don't delete printer-profile in clean target
+--- /dev/null
++++ foo2zjs-20090908dfsg/printer-profile.in
+@@ -0,0 +1,296 @@
++#!/bin/sh
++
++PROGNAME="$0"
++
++usage() {
++	cat <<EOF
++NAME
++    `basename $PROGNAME` - printer-profile using X-Rite ColorMunki and Argyll CMS
++
++SYNOPSIS
++    `basename $PROGNAME` [options] manuf model [rgb|cmyk] [patches] [ink-limit]
++
++DESCRIPTION
++    Prints a test chart, uses the ColorMunki instrument to scan it in, then
++    computes an ICM profile using the Argyll Color Management System.
++
++    Manuf is "sam".  Model is "clp-300" or "clp-315".
++    Manuf is "hp".  Model is "2600" or "cp1215".
++    Manuf is "km".  Model is "1600" or "2300" or "2530".
++
++    "rgb" is the usual setting.  "patches" is a multiple 196 per page.
++
++    Edit the script for additional models.
++
++OPTIONS
++    -b 1|2        Bits per pixel ($BPP)
++    -r XRESxYRES  Resolution. Default=''. ($RES)
++    -P rem-print  Remote print (64-bit) machine, or none ($REMPRINT)
++    -S rem-scan   Remote scan (ColorMunki) machine, or none ($REMSCAN)
++    -D lvl        Debug level
++
++EXAMPLE
++    $ printer-profile sam 315 rgb 196
++
++BUGS
++    gs 8.64 and before has problems with 32-bit machines and color profile
++    data.  Don't use!
++
++    You need two copies of Argyll: must be 1.0.3 and 1.1.0beta. Otherwise,
++    targen and colprof core dumps.
++
++SEE ALSO
++    http://www.xritephoto.com/html/colormunkisplash.htm
++	from Amazon, \$390 shipped
++    http://www.argyllcms.com/
++	free!
++EOF
++
++	exit 1
++}
++
++#
++#       Report an error and exit
++#
++error() {
++	echo "`basename $PROGNAME`: $1" >&2
++	exit 1
++}
++
++debug() {
++	if [ $DEBUG -ge $1 ]; then
++	    echo "`basename $PROGNAME`: $2" >&2
++	fi
++}
++
++#
++#	Execute a command as root
++#
++root() {
++    if [ -x /usr/bin/root ]; then
++        /usr/bin/root $@
++    else
++        su -c "$*"
++    fi
++}
++
++#
++#	trap on error
++#
++trap "exit 1" ERR
++
++#
++#       Process the options
++#
++REMPRINT=amd
++REMSCAN=mac
++REMSCAN=none
++RGB=rgb
++PATCHES=196	#Per page!
++BPP=1
++RES=
++DEBUG=0
++while getopts "b:r:P:S:D:h?" opt
++do
++	case $opt in
++	b)	BPP="$OPTARG";;
++	r)	RES="$OPTARG";;
++	P)	REMPRINT="$OPTARG";;
++	S)	REMSCAN="$OPTARG";;
++	D)	DEBUG="$OPTARG";;
++	h|\?)	usage;;
++	esac
++done
++shift `expr $OPTIND - 1`
++
++#
++#	Main Program
++#
++if [ $# -lt 2 ]; then
++    usage
++fi
++
++MANUF="$1"
++MODEL="$2"
++if [ $# -ge 3 ]; then
++    RGB="$3"
++fi
++if [ $# -ge 4 ]; then
++    PATCHES="$4"
++fi
++INK="$5"
++
++BPP_b="-b$BPP"
++RES_r=
++if [ "$RES" != "" ]; then
++    RES_r="-r$RES"
++fi
++
++case "$MANUF" in
++km)
++    MANUF=km
++    case "$MODEL" in
++    *1600*)
++	FOO=foo2lava
++	WRAPPER="foo2lava-wrapper $RES_r -z2 -c -C10 -Gnone.icm"
++	OUT="root cp xxx.prn /dev/usb/lp1"
++	;;
++    *2530*)
++	FOO=foo2lava
++	WRAPPER="foo2lava-wrapper $RES_r -z0 -c -C10 -Gnone.icm"
++	OUT="nc 192.168.1.13 9100 < xxx.prn"
++	;;
++    *2300*)
++	FOO=foo2zjs
++	WRAPPER="foo2zjs-wrapper $RES_r -c -C10 -Gnone.icm"
++	OUT="nc 192.168.1.10 9100 < xxx.prn"
++	;;
++    *)
++	usage
++	;;
++    esac
++    ;;
++sam*)
++    MANUF=sam
++    FOO=foo2qpdl
++    case "$MODEL" in
++    *300*)
++	WRAPPER="foo2qpdl-wrapper $RES_r -z0 -c -C10 -Gnone.icm"
++	OUT="nc 192.168.1.11 9100 < xxx.prn"
++	;;
++    *315*)
++	WRAPPER="foo2qpdl-wrapper $RES_r -z2 -c -C10 -Gnone.icm"
++	OUT="root cp xxx.prn /dev/usb/lp1"
++	;;
++    *)
++	usage
++	;;
++    esac
++    ;;
++hp*)
++    MANUF=hp
++    FOO=foo2hp
++    case "$MODEL" in
++    *2600*)
++	WRAPPER="foo2hp2600-wrapper $RES_r $BPP_b -z0 -c -C10 -Gnone.icm"
++	OUT="nc 192.168.1.12 9100 < xxx.prn"
++	;;
++    *cp1215*)
++	WRAPPER="foo2hp2600-wrapper $RES_r $BPP_b -z1 -c -C10 -Gnone.icm"
++	OUT="root cp xxx.prn /dev/usb/lp2"
++	;;
++    *)
++	usage
++	;;
++    esac
++    ;;
++*)
++    usage
++    ;;
++esac
++
++mrp="$MANUF-$MODEL-$RGB-$PATCHES"
++if [ "$INK" != "" ]; then
++    mrp="$mrp-ink$INK"
++fi
++if [ "$BPP" != "" ]; then
++    mrp="$mrp-bpp$BPP"
++fi
++if [ "$RES" != "" ]; then
++    mrp="$mrp-$RES"
++fi
++echo "$mrp"
++
++
++BETABIN=~/src/Argyll_V1.1.0_Beta/bin
++if [ ! -x $BETABIN/printtarg ]; then
++    error "No beta bin in $BETABIN!"
++fi
++
++targen_opts=
++case "$RGB" in
++rgb|RGB)	targen_opts="$targen_opts -d3";;
++cmyk|CMYK)	targen_opts="$targen_opts -d4";;
++*)		error "Parm2: Must be rgb or cmyk";;
++esac
++
++targen_opts="$targen_opts -f$PATCHES"
++
++if [ "$INK" != "" ]; then
++    targen_opts="$targen_opts -l$INK"
++fi
++
++echo
++echo "******************************** targen ********************************"
++echo "targen $targen_opts $mrp"
++if ! targen $targen_opts $mrp >$mrp.err1; then
++    cat $mrp.err1
++    exit 1
++fi
++
++echo
++echo "******************************* printtarg ******************************"
++echo "$BETABIN/printtarg -h -v -iCM -p Letter -R0 $mrp"
++$BETABIN/printtarg -h -v -iCM -p Letter -R0 $mrp
++
++evince $mrp.ps &
++
++echo
++echo "******************************* print it *******************************"
++echo "$WRAPPER"
++case "$REMPRINT" in
++''|none)
++    $WRAPPER <$mrp.ps >$mrp.prn
++    ;;
++*)
++    ssh $REMPRINT "$WRAPPER" <$mrp.ps >$mrp.prn
++    ;;
++esac
++ls -l $mrp.prn
++echo -n "Print it? [y|n]? "
++read yes
++case "$yes" in
++y|Y)
++    cp $mrp.prn xxx.prn
++    echo "	$OUT"
++    eval $OUT
++    rm -f xxx.prn
++esac
++
++echo
++echo "******************************* chartread ******************************"
++case "$REMSCAN" in
++''|none)
++    echo "$BETABIN/chartread $mrp"
++    $BETABIN/chartread $mrp
++    ;;
++*)
++    echo "scp $mrp.ti2 mac:"
++    scp $mrp.ti2 mac:
++    echo "$BETABIN/chartread $mrp"
++    echo  -n "Scanned on remote system $REMSCAN? [y/n]? "
++    read yes
++    case "$yes" in
++    y|Y)
++	scp $REMSCAN:$mrp.ti3 .
++	;;
++    esac
++    ;;
++esac
++
++echo
++echo "******************************** colprof *******************************"
++case $RGB in
++rgb)
++    echo "colprof -v -D\"$mrp\" -qm -cmt -dpp $mrp"
++    colprof -v -D"$mrp" -qm -cmt -dpp $mrp
++    ;;
++cymk)
++    echo "colprof -v -D\"$mrp\" -qm  -cmt -dpp -kr $mrp"
++    colprof -v -D"$mrp" -qm  -cmt -dpp -kr $mrp
++    ;;
++esac
++
++root cp $mrp.icc /usr/share/$FOO/icm/testing.icm
++echo "/usr/share/$FOO/icm/testing.icm created!"
++ls -l /usr/share/$FOO/icm/
--- foo2zjs-20090908dfsg.orig/debian/patches/30-udev-rules.patch
+++ foo2zjs-20090908dfsg/debian/patches/30-udev-rules.patch
@@ -0,0 +1,67 @@
+Correct the udev rules
+--- foo2zjs-20090908dfsg.orig/hplj10xx.rules
++++ foo2zjs-20090908dfsg/hplj10xx.rules
+@@ -1,36 +1,36 @@
+ #Own udev rule for HP Laserjet 1000
+-KERNEL=="lp*", BUS=="usb", SYSFS{idVendor}=="03f0", \
+-	SYSFS{product}=="hp LaserJet 1000", NAME="usb/%k", \
+-	SYMLINK+="hplj1000-%n", MODE="0666", RUN+="/etc/hotplug/usb/hplj1000" 
++KERNEL=="lp*", SUBSYSTEMS=="usb", ATTRS{idVendor}=="03f0", \
++	ATTRS{product}=="hp LaserJet 1000", \
++	SYMLINK+="hplj1000-%n", RUN+="/usr/sbin/hplj1000" 
+ #Own udev rule for HP Laserjet 1005
+-KERNEL=="lp*", BUS=="usb", SYSFS{idVendor}=="03f0", \
+-	SYSFS{product}=="hp LaserJet 1005 series", NAME="usb/%k", \
+-	SYMLINK+="hplj1005-%n", MODE="0666", RUN+="/etc/hotplug/usb/hplj1005" 
++KERNEL=="lp*", SUBSYSTEMS=="usb", ATTRS{idVendor}=="03f0", \
++	ATTRS{product}=="hp LaserJet 1005 series", \
++	SYMLINK+="hplj1005-%n", RUN+="/usr/sbin/hplj1005" 
+ #Own udev rule for HP Laserjet 1018
+-KERNEL=="lp*", BUS=="usb", SYSFS{idVendor}=="03f0", \
+-	SYSFS{product}=="HP LaserJet 1018", NAME="usb/%k", \
+-	SYMLINK+="hplj1018-%n", MODE="0666", RUN+="/etc/hotplug/usb/hplj1018" 
++KERNEL=="lp*", SUBSYSTEMS=="usb", ATTRS{idVendor}=="03f0", \
++	ATTRS{product}=="HP LaserJet 1018", \
++	SYMLINK+="hplj1018-%n", RUN+="/usr/sbin/hplj1018" 
+ #Own udev rule for HP Laserjet 1020
+-KERNEL=="lp*", BUS=="usb", SYSFS{idVendor}=="03f0", \
+-	SYSFS{product}=="HP LaserJet 1020", NAME="usb/%k", \
+-	SYMLINK+="hplj1020-%n", MODE="0666", RUN+="/etc/hotplug/usb/hplj1020" 
++KERNEL=="lp*", SUBSYSTEMS=="usb", ATTRS{idVendor}=="03f0", \
++	ATTRS{product}=="HP LaserJet 1020", \
++	SYMLINK+="hplj1020-%n", RUN+="/usr/sbin/hplj1020" 
+ #Own udev rule for HP Laserjet P1005
+-KERNEL=="lp*", BUS=="usb", SYSFS{idVendor}=="03f0", \
+-	SYSFS{product}=="HP LaserJet P1005", NAME="usb/%k", \
+-	SYMLINK+="hpljP1005-%n", MODE="0666", RUN+="/etc/hotplug/usb/hpljP1005" 
++KERNEL=="lp*", SUBSYSTEMS=="usb", ATTRS{idVendor}=="03f0", \
++	ATTRS{product}=="HP LaserJet P1005", \
++	SYMLINK+="hpljP1005-%n", RUN+="/usr/sbin/hpljP1005" 
+ #Own udev rule for HP Laserjet P1006
+-KERNEL=="lp*", BUS=="usb", SYSFS{idVendor}=="03f0", \
+-	SYSFS{product}=="HP LaserJet P1006", NAME="usb/%k", \
+-	SYMLINK+="hpljP1006-%n", MODE="0666", RUN+="/etc/hotplug/usb/hpljP1006" 
++KERNEL=="lp*", SUBSYSTEMS=="usb", ATTRS{idVendor}=="03f0", \
++	ATTRS{product}=="HP LaserJet P1006", \
++	SYMLINK+="hpljP1006-%n", RUN+="/usr/sbin/hpljP1006" 
+ #Own udev rule for HP Laserjet P1007
+-KERNEL=="lp*", BUS=="usb", SYSFS{idVendor}=="03f0", \
+-	SYSFS{product}=="HP LaserJet P1007", NAME="usb/%k", \
+-	SYMLINK+="hpljP1007-%n", MODE="0666", RUN+="/etc/hotplug/usb/hpljP1007" 
++KERNEL=="lp*", SUBSYSTEMS=="usb", ATTRS{idVendor}=="03f0", \
++	ATTRS{product}=="HP LaserJet P1007", \
++	SYMLINK+="hpljP1007-%n", RUN+="/usr/sbin/hpljP1007" 
+ #Own udev rule for HP Laserjet P1008
+-KERNEL=="lp*", BUS=="usb", SYSFS{idVendor}=="03f0", \
+-	SYSFS{product}=="HP LaserJet P1008", NAME="usb/%k", \
+-	SYMLINK+="hpljP1008-%n", MODE="0666", RUN+="/etc/hotplug/usb/hpljP1008" 
++KERNEL=="lp*", SUBSYSTEMS=="usb", ATTRS{idVendor}=="03f0", \
++	ATTRS{product}=="HP LaserJet P1008", \
++	SYMLINK+="hpljP1008-%n", RUN+="/usr/sbin/hpljP1008" 
+ #Own udev rule for HP Laserjet P1505
+-KERNEL=="lp*", BUS=="usb", SYSFS{idVendor}=="03f0", \
+-	SYSFS{product}=="HP LaserJet P1505", NAME="usb/%k", \
+-	SYMLINK+="hpljP1505-%n", MODE="0666", RUN+="/etc/hotplug/usb/hpljP1505" 
++KERNEL=="lp*", SUBSYSTEMS=="usb", ATTRS{idVendor}=="03f0", \
++	ATTRS{product}=="HP LaserJet P1505", \
++	SYMLINK+="hpljP1505-%n", RUN+="/usr/sbin/hpljP1505" 
--- foo2zjs-20090908dfsg.orig/debian/patches/20-honour-papersize.patch
+++ foo2zjs-20090908dfsg/debian/patches/20-honour-papersize.patch
@@ -0,0 +1,37 @@
+Support /etc/papersize
+--- foo2zjs-20090908dfsg.orig/foo2hp2600-wrapper.in
++++ foo2zjs-20090908dfsg/foo2hp2600-wrapper.in
+@@ -203,7 +203,8 @@
+ 
+ MEDIA=1
+ COPIES=1
+-PAPER=1
++test -r /etc/papersize && PAPER=$(cat /etc/papersize)
++test "$PAPER" || PAPER=1
+ RES=600x600
+ SOURCE=7
+ NUP=
+--- foo2zjs-20090908dfsg.orig/foo2oak-wrapper.in
++++ foo2zjs-20090908dfsg/foo2oak-wrapper.in
+@@ -157,7 +157,8 @@
+ QUALITY=wts
+ MEDIA=1
+ COPIES=1
+-PAPER=1
++test -r /etc/papersize && PAPER=$(cat /etc/papersize)
++test "$PAPER" || PAPER=1
+ RES=600x600
+ SOURCE=7
+ NUP=
+--- foo2zjs-20090908dfsg.orig/foo2zjs-wrapper.in
++++ foo2zjs-20090908dfsg/foo2zjs-wrapper.in
+@@ -168,7 +168,8 @@
+ QUALITY=wts
+ MEDIA=1
+ COPIES=1
+-PAPER=1
++test -r /etc/papersize && PAPER=$(cat /etc/papersize)
++test "$PAPER" || PAPER=1
+ RES=1200x600
+ SOURCE=7
+ NUP=
--- foo2zjs-20090908dfsg.orig/debian/patches/40-path-correction.patch
+++ foo2zjs-20090908dfsg/debian/patches/40-path-correction.patch
@@ -0,0 +1,12 @@
+Correct the path for the usb_printerid program
+--- foo2zjs-20090908dfsg.orig/hplj1000
++++ foo2zjs-20090908dfsg/hplj1000
+@@ -47,7 +47,7 @@
+ #    [snip]
+ #    # Mount all other filesystems (except for NFS and /proc, which is already
+ #
+-PRINTERID=/bin/usb_printerid
++PRINTERID=`which usb_printerid`
+ 
+ #
+ #	Figure out how to log our messages
--- foo2zjs-20090908dfsg.orig/debian/patches/60-hplj1000.patch
+++ foo2zjs-20090908dfsg/debian/patches/60-hplj1000.patch
@@ -0,0 +1,41 @@
+Use the same firmware folder for all HP LJ printers
+--- foo2zjs-20090908dfsg.orig/hplj1000
++++ foo2zjs-20090908dfsg/hplj1000
+@@ -77,37 +77,31 @@
+     MODEL=P1005; FWMODEL=$MODEL
+     USB1=0x03f0	#Vendor
+     USB2=0x3d17	#Model
+-    FWDIR=/usr/share/foo2xqx/firmware
+     ;;
+ *P1006)
+     MODEL=P1006; FWMODEL=$MODEL
+     USB1=0x03f0	#Vendor
+     USB2=0x3e17	#Model
+-    FWDIR=/usr/share/foo2xqx/firmware
+     ;;
+ *P1007)
+     MODEL=P1007; FWMODEL=P1005		# Alias
+     USB1=0x03f0	#Vendor
+     USB2=0x4817	#Model
+-    FWDIR=/usr/share/foo2xqx/firmware
+     ;;
+ *P1008)
+     MODEL=P1008; FWMODEL=P1006		# Alias
+     USB1=0x03f0	#Vendor
+     USB2=0x4917	#Model
+-    FWDIR=/usr/share/foo2xqx/firmware
+     ;;
+ *P1505)
+     MODEL=P1505; FWMODEL=$MODEL
+     USB1=0x03f0	#Vendor
+     USB2=0x3f17	#Model
+-    FWDIR=/usr/share/foo2xqx/firmware
+     ;;
+ *P1505n)
+     MODEL=P1505n; FWMODEL=$MODEL
+     USB1=0x03f0	#Vendor
+     USB2=0x4017	#Model
+-    FWDIR=/usr/share/foo2xqx/firmware
+     ;;
+ *1000)
+     MODEL=1000; FWMODEL=$MODEL
--- foo2zjs-20090908dfsg.orig/debian/source/format
+++ foo2zjs-20090908dfsg/debian/source/format
@@ -0,0 +1 @@
+1.0
