Codebase list pnm2ppa / df8fd31
Imported Debian patch 1.04-4 Chad C. Walstrom 21 years ago
24 changed file(s) with 2607 addition(s) and 0 deletion(s). Raw diff Collapse all Expand all
0 pnm2ppa for Debian
1 ----------------------
2
3 Using the pnm2ppa filter, it's possible to use printer with the PPA protocol.
4 PPA is a proprietary protocol by Hewlett Packard. Printers using PPA are
5 normally Windows-only. pnm2ppa supports color now.
6
7 The configuration files are in /etc/ppa/. The papersize is being autodetected
8 since this version.
9
10 This package is based on the pbm2ppa package. Thanks to Ionutz Borcoman
11 <borco@borco-ei.eng.hokudai.ac.jp>.
12
13 -- Roland Bauerschmidt <roland@copyleft.de>, Thu, 30 Mar 2000 20:51:28 +0100
14
15 Starting with pnm2ppa-1.0, pbm2ppa is completely replaced by pnm2ppa. pnm2ppa
16 will create symlinks for old filters, so your old printcap should work without
17 changes.
18
19 -- Ionutz Borcoman <borco@borco-ei.eng.hokudai.ac.jp>, Fri, 11 Aug 2000
20
21 As of Nov 2000, I don't use a PPA printer anymore. I'll continue to maintain
22 this package untill Roland can maintain it again, but I'll be unable to
23 test it myself.
24
25 -- Ionutz Borcoman <borco@borco-ei.eng.hokudai.ac.jp>, Thu, 09 Nov 2000
26
27 If you're using magicfilter or apsfilter, run magicfilterconfig or
28 apsfilterconfig and simply follow the instructions.
29
30 -- Matej Vela <vela@debian.org> Tue, 17 Apr 2001 17:48:24 +0200
31
0 .\" Hey, EMACS: -*- nroff -*-
1 .\" First parameter, NAME, should be all caps
2 .\" Second parameter, SECTION, should be 1-8, maybe w/ subsection
3 .\" other parameters are allowed: see man(7), man(1)
4 .TH calibrate_ppa 8 "November 05, 2000"
5 .\" Please adjust this date whenever revising the manpage.
6 .\"
7 .\" Some roff macros, for reference:
8 .\" .nh disable hyphenation
9 .\" .hy enable hyphenation
10 .\" .ad l left justify
11 .\" .ad b justify to both left and right margins
12 .\" .nf disable filling
13 .\" .fi enable filling
14 .\" .br insert line break
15 .\" .sp <n> insert n+1 empty lines
16 .\" for manpage-specific macros, see man(7)
17 .\" This file was created by Chad C. Walstrom <chewie@debian.org>
18 .\" for the pnm2ppa project.
19 .\"
20 .SH NAME
21 calibrate_ppa \- pnm2ppa calibration tool
22 .SH SYNOPSIS
23 .B calibrate_ppa
24 .RI [options]
25 .SH DESCRIPTION
26 Produces various PixMap (PPM) files used for calibrating pnm2ppa.
27 .TP
28 This manual page was written for the Debian GNU/Linux distribution because the original program does not have a manual page.
29 .SH NOTE
30 The size of a full-page PixMap is 100MB!!. These PixMaps should be piped directly to pnm2ppa, except in the case of the -g option, where the PixMap should be viewed or printed by other means.
31 .SH OPTIONS
32 .TP
33 .B \-g, \-\-gamma
34 produce gamma.ppm (10MB, used in color calibration).
35 .TP
36 .B \-h, \-\-help
37 displays this help text.
38 .TP
39 .B \-o <outfile>
40 output to file <outfile>, "-o -" means stdout (default)
41 .TP
42 .B \-p <n>
43 create test pattern number <n>
44 .TP
45 .B \-\-align
46 pattern 0: align print heads. (default)
47 .TP
48 .B \-\-test
49 pattern 1: test alignment.
50 .TP
51 .B \-\-clean
52 pattern 2: clean print head.
53 .TP
54 .B \-\-center
55 pattern 3: center paper.
56 .TP
57 .B \-s\fR <paper>
58 default papersize (a4, legal, letter = us (default))
59 .PD
60 .SH AUTHOR
61 This manual page was written by Chad C. Walstrom <chewie@debian.org>,
62 for the Debian GNU/Linux system (but may be used by others).
63 .SH SEE ALSO
64 .IR pnm2ppa (8),
65 .IR magicfilter (8),
66 .IR apsfilter (8)
0 pnm2ppa (1.04-4) unstable; urgency=low
1
2 * Long overdue adopted package. Closes: #88234
3 * Added a manpage for both pnm2ppa and calibrate_ppa.
4
5 -- Chad C. Walstrom <chewie@debian.org> Sat, 23 Jun 2001 00:26:02 -0500
6
7 pnm2ppa (1.04-3) unstable; urgency=low
8
9 * `Suggests: magicfilter | apsfilter' rather than `Depends:
10 magicfilter'. The postinst no longer calls magicfilterconfig.
11
12 -- Matej Vela <vela@debian.org> Tue, 17 Apr 2001 18:09:39 +0200
13
14 pnm2ppa (1.04-2) unstable; urgency=low
15
16 * debian/rules: Add `-DLANG_EN' to $(CFLAGS). (God, I'm stupid --
17 thanks to OHURA Makoto for the patch.) Closes: #93064.
18
19 -- Matej Vela <vela@debian.org> Fri, 6 Apr 2001 20:33:55 +0200
20
21 pnm2ppa (1.04-1) unstable; urgency=low
22
23 * New upstream version. Closes: #85224.
24 * Package is orphaned; maintainer set to Debian QA Group.
25 * Conforms to Standards version 3.5.2:
26 * Added build dependancies.
27 * Added support for the `debug' build option.
28 * Made lintian-clean.
29
30 -- Matej Vela <vela@debian.org> Mon, 19 Mar 2001 09:37:13 +0100
31
32 pnm2ppa (1.03-1) unstable; urgency=low
33
34 * New upstream release.
35
36 -- Ionutz Borcoman <borco@borco-ei.eng.hokudai.ac.jp> Thu, 9 Nov 2000 13:53:51 +0900
37
38 pnm2ppa (1.0-1) unstable; urgency=low
39
40 * New upstream release.
41 * New maintainer.
42 * Completly replaces pbm2ppa.
43
44 -- Ionutz Borcoman <borco@borco-ei.eng.hokudai.ac.jp> Fri, 11 Aug 2000 12:19:15 +0900
45
46 pnm2ppa (0.99-0.pre3) unstable; urgency=low
47
48 * New upsteam release
49 * Updated maintainer field to new @debian.org address ;)
50
51 -- Roland Bauerschmidt <rb@debian.org> Sun, 4 Jun 2000 13:26:45 +0200
52
53 pnm2ppa (0.99-0.pre2) unstable; urgency=low
54
55 * New upstream release
56 * Fixed problem with version numbers
57
58 -- Roland Bauerschmidt <roland@copyleft.de> Thu, 13 Apr 2000 21:41:04 +0200
59
60 pnm2ppa (0.99pre1-1) unstable; urgency=low
61
62 * New upstream release
63
64 -- Roland Bauerschmidt <roland@copyleft.de> Thu, 6 Apr 2000 20:46:30 +0200
65
66 pnm2ppa (0.20000326-1) unstable; urgency=low
67
68 * New upstream release
69
70 -- Roland Bauerschmidt <roland@copyleft.de> Wed, 29 Mar 2000 16:38:26 +0200
71
72 pnm2ppa (0.20000120-2) unstable; urgency=low
73
74 * Fixed Dependencies: gs is included in the Dependencies now.
75
76 -- Roland Bauerschmidt <roland@copyleft.de> Wed, 8 Mar 2000 17:26:29 +0100
77
78 pnm2ppa (0.20000120-1) unstable; urgency=low
79
80 * Initial Release.
81
82 -- Roland Bauerschmidt <roland@copyleft.de> Wed, 8 Mar 2000 17:25:05 +0100
83
84 Local variables:
85 mode: debian-changelog
86 End:
0 Source: pnm2ppa
1 Section: text
2 Priority: optional
3 Maintainer: Chad Walstrom <chewie@debian.org>
4 Standards-Version: 3.5.2
5 Build-Depends: debhelper (>= 3)
6
7 Package: pnm2ppa
8 Architecture: any
9 Depends: ${shlibs:Depends}, gs
10 Suggests: magicfilter | apsfilter
11 Replaces: pbm2ppa
12 Provides: pbm2ppa
13 Conflicts: pbm2ppa
14 Description: PPM to PPA converter
15 Using pnm2ppa it's possible to run HP-GDI printers on Linux. These printers
16 are normally "Windows-only" and use the PPA protocol which is proprietary.
17 pnm2ppa supports color and is supposed to work faster than pbm2ppa.
18 .
19 pnm2ppa supports the following printers: HP Deskjet 7XX Series, HP Deskjet
20 820 Series and HP Deskjet 1000 Series.
0 This package was debianized by Roland Bauerschmidt <roland@copyleft.de> on
1 Sat, 4 Mar 2000 20:51:28 +0100.
2
3 It was downloaded from http://sourceforge.net/projects/pnm2ppa/
4
5 Upstream Author(s): Tim Norman <tim@normsoft.com>
6
7 Copyright:
8
9 GPL (see /usr/share/common-licenses/GPL for details)
0 #!/usr/sbin/magicfilter
1 #
2 # Magic filter setup file for HP printers 720, 820 and 1000 series.
3
4 # pnm2ppa supports color and black/white printing. This file was
5 # tested on a HP Deskjet 720C printer, but is supposed to work on
6 # other printers using the HP PPA protocol, too. Supported pagesizes
7 # are a4, letter and legal. The pagesize has to be set in /etc/papersize
8 # and not in the configuration files in /etc/ppa/pnm2ppa.conf.hp*.
9
10 # Adapted from dj500-filter, cpsonly600-filter and pbm2ppa-filter
11 # by Roland Bauerschmidt <roland@copyleft.de>, 2000
12
13 # PostScript
14 0 %! fpipe /usr/bin/gs -q -dSAFER -dNOPAUSE -r600 -sDEVICE=ppmraw -sOutputFile=- - -c quit
15 0 \004%! fpipe /usr/bin/gs -q -dSAFER -dNOPAUSE -r600 -sDEVICE=ppmraw -sOutputFile=- - -c quit
16
17 # PDF
18 0 %PDF fpipe /usr/bin/gs -q -dSAFER -dNOPAUSE -r600 -sDEVICE=ppmraw -sOutputFile=- $FILE -c quit
19
20
21 # TeX DVI
22 0 \367\002 fpipe /usr/bin/dvips -D 600 -R -q -f
23
24 # compress'd data
25 0 \037\235 pipe /bin/gzip -cdq
26
27 # packed, gzipped, frozen and SCO LZH data
28 0 \037\036 pipe /bin/gzip -cdq
29 0 \037\213 pipe /bin/gzip -cdq
30 0 \037\236 pipe /bin/gzip -cdq
31 0 \037\240 pipe /bin/gzip -cdq
32
33 # troff documents
34 0 .\?\?\040 fpipe `/usr/bin/grog -Tps $FILE`
35 0 .\\\" fpipe `/usr/bin/grog -Tps $FILE`
36 0 '\\\" fpipe `/usr/bin/grog -Tps $FILE`
37 0 '.\\\" fpipe `/usr/bin/grog -Tps $FILE`
38 0 \\\" fpipe `/usr/bin/grog -Tps $FILE`
39
40 # ditroff
41 0 "x T ps" pipe /usr/bin/grops
42 0 "x T dvi" pipe /usr/bin/grodvi
43 0 "x T ascii" pipe /usr/bin/grotty
44 0 "x T latin1" pipe /usr/bin/grotty
45 0 "x T lj4" reject Cannot print LaserJet 4 ditroff files.
46
47 # Portable bit-, grey- and pixmaps
48 0 P1\n pipe /usr/bin/pnmtops -scale 1000 -dpi 600 2>/dev/null
49 0 P2\n pipe /usr/bin/pnmtops -scale 1000 -dpi 600 2>/dev/null
50 0 P3\n pipe /usr/bin/pnmtops -scale 1000 -dpi 600 2>/dev/null
51 0 P4\n pipe /usr/bin/pnmtops -scale 1000 -dpi 600 2>/dev/null
52 0 P5\n pipe /usr/bin/pnmtops -scale 1000 -dpi 600 2>/dev/null
53 0 P6\n filter /usr/bin/pnm2ppa --bw --eco -f /etc/ppa/pnm2ppa.conf.hp1000 -i - -o -
54
55 # HP Printer Control Language (PCL) -- assume start with reset code
56 0 \033E\033 reject Cannot print PCL files on this printer.
57
58 # HP Printer Job Language (PJL)
59 0 \033%-12345X reject Cannot print PJL files on this printer.
60 0 "@PJL " reject Cannot print PJL files on this printer.
61 0 @PJL\t reject Cannot print PJL files on this printer.
62 0 @PJL\r reject Cannot print PJL files on this printer.
63 0 @PJL\n reject Cannot print PJL files on this printer.
64
65 # GIF files
66 0 GIF87a pipe /usr/bin/giftopnm 2>/dev/null
67 0 GIF89a pipe /usr/bin/giftopnm 2>/dev/null
68
69 # JFIF (JPEG) files
70 0 \377\330\377\340\?\?JFIF\0 pipe /usr/bin/djpeg -pnm
71
72 # TIFF files (the last two bytes of the "magic" is really a version number;
73 # but the magic is really lame and as far as I have understood the version
74 # number has never changed and never will, so we include it.)
75 0 MM\0\x2a fpipe /usr/bin/tiff2ps $FILE
76 0 II\x2a\0 fpipe /usr/bin/tiff2ps $FILE
77
78 # BMP files (even lousier magic -- Microsoft strikes again!)
79 0 BM\?\?\?\?\?\?\?\?\?\?\?\?\x0c pipe \
80 /usr/bin/bmptoppm 2>/dev/null
81 0 BM\?\?\?\?\?\?\?\?\?\?\?\?\x40 pipe \
82 /usr/bin/bmptoppm 2>/dev/null
83 0 BM\?\?\?\?\?\?\?\?\?\?\?\?\x28 pipe \
84 /usr/bin/bmptoppm 2>/dev/null
85
86 # Garbage delivered from Windows via Samba
87 # (donated by Andree Leidenfrost <leidenfrost@dkrz.de>)
88 # 300 \033\052\157 cat
89 # later changed to
90 # (Bug report #22866: magicfilter: Incorrect magic for Win95/Samba print jobs)
91 0 \000\000\000\000\000 cat
92
93 # Sun rasterfiles
94 0 \x59\xa6\x6a\x95 pipe /usr/bin/rasttopnm 2>/dev/null
95
96 # SGI Imagelib (IRIS RGB) files
97 0 \x1\xda pipe /usr/bin/sgitopnm 2>/dev/null
98 0 \xda\x1 pipe /usr/bin/sgitopnm 2>/dev/null
99
100 # FIG files; reported by Steven P. Hill <sph@uscbu.ih.att.com>
101 0 #FIG pipe /usr/bin/X11/fig2dev -Lps -P -l dummy
102
103 #
104 # Standard rejects... things we don't want to print
105 #
106
107 # Various archive formats
108 257 ustar\0 reject Attempted to print a tar file.
109 257 "ustar \0" reject Attempted to print a tar file.
110 0 07070 reject Attempted to print a cpio file.
111 0 PK\3\4 reject Attempted to print a zip file.
112 20 \xdc\xa7\xc7\xfd reject Attempted to print a zoo file.
113
114 # Binaries (Linux): reject with email message
115 0 \013\1d\0 reject Attempted to print a compiled binary.
116 0 \100\1d\0 reject Attempted to print a compiled binary.
117 0 \007\1d\0 reject Attempted to print a compiled binary.
118 0 \314\0d\0 reject Attempted to print a compiled binary.
119 0 \177ELF reject Attempted to print an ELF object.
120 0 \007\001\0 reject Attempted to print an object file.
121 216 \021\001\0\0 reject Attempted to print a core dump file.
122 0 !<arch> reject Attempted to print an archive.
123 0 =<ar> reject Attempted to print an archive.
124
125 # Don't confuse this one with troff!
126 0 .snd reject Attempted to print Sun/NeXT audio data.
127
128 # wacko troff magic
129 0 ''' fpipe `/usr/bin/grog -Tps $FILE`
130
131 # wild guess: PCL control codes start with <ESC>
132 0 \033 reject Cannot print PCL files on this printer.
133
134 # Default entry -- for normal (text) files. MUST BE LAST.
135 # If you do not have djscript use the other default line or, better, install
136 # it. MM
137 #
138 default pipe /usr/bin/enscript -B -p-
0 #!/usr/sbin/magicfilter
1 #
2 # Magic filter setup file for HP printers 720, 820 and 1000 series.
3
4 # pnm2ppa supports color and black/white printing. This file was
5 # tested on a HP Deskjet 720C printer, but is supposed to work on
6 # other printers using the HP PPA protocol, too. Supported pagesizes
7 # are a4, letter and legal. The pagesize has to be set in /etc/papersize
8 # and not in the configuration files in /etc/ppa/pnm2ppa.conf.hp*.
9
10 # Adapted from dj500-filter, cpsonly600-filter and pbm2ppa-filter
11 # by Roland Bauerschmidt <roland@copyleft.de>, 2000
12
13 # PostScript
14 0 %! fpipe /usr/bin/gs -q -dSAFER -dNOPAUSE -r600 -sDEVICE=ppmraw -sOutputFile=- - -c quit
15 0 \004%! fpipe /usr/bin/gs -q -dSAFER -dNOPAUSE -r600 -sDEVICE=ppmraw -sOutputFile=- - -c quit
16
17 # PDF
18 0 %PDF fpipe /usr/bin/gs -q -dSAFER -dNOPAUSE -r600 -sDEVICE=ppmraw -sOutputFile=- $FILE -c quit
19
20
21 # TeX DVI
22 0 \367\002 fpipe /usr/bin/dvips -D 600 -R -q -f
23
24 # compress'd data
25 0 \037\235 pipe /bin/gzip -cdq
26
27 # packed, gzipped, frozen and SCO LZH data
28 0 \037\036 pipe /bin/gzip -cdq
29 0 \037\213 pipe /bin/gzip -cdq
30 0 \037\236 pipe /bin/gzip -cdq
31 0 \037\240 pipe /bin/gzip -cdq
32
33 # troff documents
34 0 .\?\?\040 fpipe `/usr/bin/grog -Tps $FILE`
35 0 .\\\" fpipe `/usr/bin/grog -Tps $FILE`
36 0 '\\\" fpipe `/usr/bin/grog -Tps $FILE`
37 0 '.\\\" fpipe `/usr/bin/grog -Tps $FILE`
38 0 \\\" fpipe `/usr/bin/grog -Tps $FILE`
39
40 # ditroff
41 0 "x T ps" pipe /usr/bin/grops
42 0 "x T dvi" pipe /usr/bin/grodvi
43 0 "x T ascii" pipe /usr/bin/grotty
44 0 "x T latin1" pipe /usr/bin/grotty
45 0 "x T lj4" reject Cannot print LaserJet 4 ditroff files.
46
47 # Portable bit-, grey- and pixmaps
48 0 P1\n pipe /usr/bin/pnmtops -scale 1000 -dpi 600 2>/dev/null
49 0 P2\n pipe /usr/bin/pnmtops -scale 1000 -dpi 600 2>/dev/null
50 0 P3\n pipe /usr/bin/pnmtops -scale 1000 -dpi 600 2>/dev/null
51 0 P4\n pipe /usr/bin/pnmtops -scale 1000 -dpi 600 2>/dev/null
52 0 P5\n pipe /usr/bin/pnmtops -scale 1000 -dpi 600 2>/dev/null
53 0 P6\n filter /usr/bin/pnm2ppa --bw -f /etc/ppa/pnm2ppa.conf.hp1000 -i - -o -
54
55 # HP Printer Control Language (PCL) -- assume start with reset code
56 0 \033E\033 reject Cannot print PCL files on this printer.
57
58 # HP Printer Job Language (PJL)
59 0 \033%-12345X reject Cannot print PJL files on this printer.
60 0 "@PJL " reject Cannot print PJL files on this printer.
61 0 @PJL\t reject Cannot print PJL files on this printer.
62 0 @PJL\r reject Cannot print PJL files on this printer.
63 0 @PJL\n reject Cannot print PJL files on this printer.
64
65 # GIF files
66 0 GIF87a pipe /usr/bin/giftopnm 2>/dev/null
67 0 GIF89a pipe /usr/bin/giftopnm 2>/dev/null
68
69 # JFIF (JPEG) files
70 0 \377\330\377\340\?\?JFIF\0 pipe /usr/bin/djpeg -pnm
71
72 # TIFF files (the last two bytes of the "magic" is really a version number;
73 # but the magic is really lame and as far as I have understood the version
74 # number has never changed and never will, so we include it.)
75 0 MM\0\x2a fpipe /usr/bin/tiff2ps $FILE
76 0 II\x2a\0 fpipe /usr/bin/tiff2ps $FILE
77
78 # BMP files (even lousier magic -- Microsoft strikes again!)
79 0 BM\?\?\?\?\?\?\?\?\?\?\?\?\x0c pipe \
80 /usr/bin/bmptoppm 2>/dev/null
81 0 BM\?\?\?\?\?\?\?\?\?\?\?\?\x40 pipe \
82 /usr/bin/bmptoppm 2>/dev/null
83 0 BM\?\?\?\?\?\?\?\?\?\?\?\?\x28 pipe \
84 /usr/bin/bmptoppm 2>/dev/null
85
86 # Garbage delivered from Windows via Samba
87 # (donated by Andree Leidenfrost <leidenfrost@dkrz.de>)
88 # 300 \033\052\157 cat
89 # later changed to
90 # (Bug report #22866: magicfilter: Incorrect magic for Win95/Samba print jobs)
91 0 \000\000\000\000\000 cat
92
93 # Sun rasterfiles
94 0 \x59\xa6\x6a\x95 pipe /usr/bin/rasttopnm 2>/dev/null
95
96 # SGI Imagelib (IRIS RGB) files
97 0 \x1\xda pipe /usr/bin/sgitopnm 2>/dev/null
98 0 \xda\x1 pipe /usr/bin/sgitopnm 2>/dev/null
99
100 # FIG files; reported by Steven P. Hill <sph@uscbu.ih.att.com>
101 0 #FIG pipe /usr/bin/X11/fig2dev -Lps -P -l dummy
102
103 #
104 # Standard rejects... things we don't want to print
105 #
106
107 # Various archive formats
108 257 ustar\0 reject Attempted to print a tar file.
109 257 "ustar \0" reject Attempted to print a tar file.
110 0 07070 reject Attempted to print a cpio file.
111 0 PK\3\4 reject Attempted to print a zip file.
112 20 \xdc\xa7\xc7\xfd reject Attempted to print a zoo file.
113
114 # Binaries (Linux): reject with email message
115 0 \013\1d\0 reject Attempted to print a compiled binary.
116 0 \100\1d\0 reject Attempted to print a compiled binary.
117 0 \007\1d\0 reject Attempted to print a compiled binary.
118 0 \314\0d\0 reject Attempted to print a compiled binary.
119 0 \177ELF reject Attempted to print an ELF object.
120 0 \007\001\0 reject Attempted to print an object file.
121 216 \021\001\0\0 reject Attempted to print a core dump file.
122 0 !<arch> reject Attempted to print an archive.
123 0 =<ar> reject Attempted to print an archive.
124
125 # Don't confuse this one with troff!
126 0 .snd reject Attempted to print Sun/NeXT audio data.
127
128 # wacko troff magic
129 0 ''' fpipe `/usr/bin/grog -Tps $FILE`
130
131 # wild guess: PCL control codes start with <ESC>
132 0 \033 reject Cannot print PCL files on this printer.
133
134 # Default entry -- for normal (text) files. MUST BE LAST.
135 # If you do not have djscript use the other default line or, better, install
136 # it. MM
137 #
138 default pipe /usr/bin/enscript -B -p-
0 #!/usr/sbin/magicfilter
1 #
2 # Magic filter setup file for HP printers 720, 820 and 1000 series.
3
4 # pnm2ppa supports color and black/white printing. This file was
5 # tested on a HP Deskjet 720C printer, but is supposed to work on
6 # other printers using the HP PPA protocol, too. Supported pagesizes
7 # are a4, letter and legal. The pagesize has to be set in /etc/papersize
8 # and not in the configuration files in /etc/ppa/pnm2ppa.conf.hp*.
9
10 # Adapted from dj500-filter, cpsonly600-filter and pbm2ppa-filter
11 # by Roland Bauerschmidt <roland@copyleft.de>, 2000
12
13 # PostScript
14 0 %! fpipe /usr/bin/gs -q -dSAFER -dNOPAUSE -r600 -sDEVICE=ppmraw -sOutputFile=- - -c quit
15 0 \004%! fpipe /usr/bin/gs -q -dSAFER -dNOPAUSE -r600 -sDEVICE=ppmraw -sOutputFile=- - -c quit
16
17 # PDF
18 0 %PDF fpipe /usr/bin/gs -q -dSAFER -dNOPAUSE -r600 -sDEVICE=ppmraw -sOutputFile=- $FILE -c quit
19
20
21 # TeX DVI
22 0 \367\002 fpipe /usr/bin/dvips -D 600 -R -q -f
23
24 # compress'd data
25 0 \037\235 pipe /bin/gzip -cdq
26
27 # packed, gzipped, frozen and SCO LZH data
28 0 \037\036 pipe /bin/gzip -cdq
29 0 \037\213 pipe /bin/gzip -cdq
30 0 \037\236 pipe /bin/gzip -cdq
31 0 \037\240 pipe /bin/gzip -cdq
32
33 # troff documents
34 0 .\?\?\040 fpipe `/usr/bin/grog -Tps $FILE`
35 0 .\\\" fpipe `/usr/bin/grog -Tps $FILE`
36 0 '\\\" fpipe `/usr/bin/grog -Tps $FILE`
37 0 '.\\\" fpipe `/usr/bin/grog -Tps $FILE`
38 0 \\\" fpipe `/usr/bin/grog -Tps $FILE`
39
40 # ditroff
41 0 "x T ps" pipe /usr/bin/grops
42 0 "x T dvi" pipe /usr/bin/grodvi
43 0 "x T ascii" pipe /usr/bin/grotty
44 0 "x T latin1" pipe /usr/bin/grotty
45 0 "x T lj4" reject Cannot print LaserJet 4 ditroff files.
46
47 # Portable bit-, grey- and pixmaps
48 0 P1\n pipe /usr/bin/pnmtops -scale 1000 -dpi 600 2>/dev/null
49 0 P2\n pipe /usr/bin/pnmtops -scale 1000 -dpi 600 2>/dev/null
50 0 P3\n pipe /usr/bin/pnmtops -scale 1000 -dpi 600 2>/dev/null
51 0 P4\n pipe /usr/bin/pnmtops -scale 1000 -dpi 600 2>/dev/null
52 0 P5\n pipe /usr/bin/pnmtops -scale 1000 -dpi 600 2>/dev/null
53 0 P6\n filter /usr/bin/pnm2ppa --eco -f /etc/ppa/pnm2ppa.conf.hp1000 -i - -o -
54
55 # HP Printer Control Language (PCL) -- assume start with reset code
56 0 \033E\033 reject Cannot print PCL files on this printer.
57
58 # HP Printer Job Language (PJL)
59 0 \033%-12345X reject Cannot print PJL files on this printer.
60 0 "@PJL " reject Cannot print PJL files on this printer.
61 0 @PJL\t reject Cannot print PJL files on this printer.
62 0 @PJL\r reject Cannot print PJL files on this printer.
63 0 @PJL\n reject Cannot print PJL files on this printer.
64
65 # GIF files
66 0 GIF87a pipe /usr/bin/giftopnm 2>/dev/null
67 0 GIF89a pipe /usr/bin/giftopnm 2>/dev/null
68
69 # JFIF (JPEG) files
70 0 \377\330\377\340\?\?JFIF\0 pipe /usr/bin/djpeg -pnm
71
72 # TIFF files (the last two bytes of the "magic" is really a version number;
73 # but the magic is really lame and as far as I have understood the version
74 # number has never changed and never will, so we include it.)
75 0 MM\0\x2a fpipe /usr/bin/tiff2ps $FILE
76 0 II\x2a\0 fpipe /usr/bin/tiff2ps $FILE
77
78 # BMP files (even lousier magic -- Microsoft strikes again!)
79 0 BM\?\?\?\?\?\?\?\?\?\?\?\?\x0c pipe \
80 /usr/bin/bmptoppm 2>/dev/null
81 0 BM\?\?\?\?\?\?\?\?\?\?\?\?\x40 pipe \
82 /usr/bin/bmptoppm 2>/dev/null
83 0 BM\?\?\?\?\?\?\?\?\?\?\?\?\x28 pipe \
84 /usr/bin/bmptoppm 2>/dev/null
85
86 # Garbage delivered from Windows via Samba
87 # (donated by Andree Leidenfrost <leidenfrost@dkrz.de>)
88 # 300 \033\052\157 cat
89 # later changed to
90 # (Bug report #22866: magicfilter: Incorrect magic for Win95/Samba print jobs)
91 0 \000\000\000\000\000 cat
92
93 # Sun rasterfiles
94 0 \x59\xa6\x6a\x95 pipe /usr/bin/rasttopnm 2>/dev/null
95
96 # SGI Imagelib (IRIS RGB) files
97 0 \x1\xda pipe /usr/bin/sgitopnm 2>/dev/null
98 0 \xda\x1 pipe /usr/bin/sgitopnm 2>/dev/null
99
100 # FIG files; reported by Steven P. Hill <sph@uscbu.ih.att.com>
101 0 #FIG pipe /usr/bin/X11/fig2dev -Lps -P -l dummy
102
103 #
104 # Standard rejects... things we don't want to print
105 #
106
107 # Various archive formats
108 257 ustar\0 reject Attempted to print a tar file.
109 257 "ustar \0" reject Attempted to print a tar file.
110 0 07070 reject Attempted to print a cpio file.
111 0 PK\3\4 reject Attempted to print a zip file.
112 20 \xdc\xa7\xc7\xfd reject Attempted to print a zoo file.
113
114 # Binaries (Linux): reject with email message
115 0 \013\1d\0 reject Attempted to print a compiled binary.
116 0 \100\1d\0 reject Attempted to print a compiled binary.
117 0 \007\1d\0 reject Attempted to print a compiled binary.
118 0 \314\0d\0 reject Attempted to print a compiled binary.
119 0 \177ELF reject Attempted to print an ELF object.
120 0 \007\001\0 reject Attempted to print an object file.
121 216 \021\001\0\0 reject Attempted to print a core dump file.
122 0 !<arch> reject Attempted to print an archive.
123 0 =<ar> reject Attempted to print an archive.
124
125 # Don't confuse this one with troff!
126 0 .snd reject Attempted to print Sun/NeXT audio data.
127
128 # wacko troff magic
129 0 ''' fpipe `/usr/bin/grog -Tps $FILE`
130
131 # wild guess: PCL control codes start with <ESC>
132 0 \033 reject Cannot print PCL files on this printer.
133
134 # Default entry -- for normal (text) files. MUST BE LAST.
135 # If you do not have djscript use the other default line or, better, install
136 # it. MM
137 #
138 default pipe /usr/bin/enscript -B -p-
0 #!/usr/sbin/magicfilter
1 #
2 # Magic filter setup file for HP printers 720, 820 and 1000 series.
3
4 # pnm2ppa supports color and black/white printing. This file was
5 # tested on a HP Deskjet 720C printer, but is supposed to work on
6 # other printers using the HP PPA protocol, too. Supported pagesizes
7 # are a4, letter and legal. The pagesize has to be set in /etc/papersize
8 # and not in the configuration files in /etc/ppa/pnm2ppa.conf.hp*.
9
10 # Adapted from dj500-filter, cpsonly600-filter and pbm2ppa-filter
11 # by Roland Bauerschmidt <roland@copyleft.de>, 2000
12
13 # PostScript
14 0 %! fpipe /usr/bin/gs -q -dSAFER -dNOPAUSE -r600 -sDEVICE=ppmraw -sOutputFile=- - -c quit
15 0 \004%! fpipe /usr/bin/gs -q -dSAFER -dNOPAUSE -r600 -sDEVICE=ppmraw -sOutputFile=- - -c quit
16
17 # PDF
18 0 %PDF fpipe /usr/bin/gs -q -dSAFER -dNOPAUSE -r600 -sDEVICE=ppmraw -sOutputFile=- $FILE -c quit
19
20
21 # TeX DVI
22 0 \367\002 fpipe /usr/bin/dvips -D 600 -R -q -f
23
24 # compress'd data
25 0 \037\235 pipe /bin/gzip -cdq
26
27 # packed, gzipped, frozen and SCO LZH data
28 0 \037\036 pipe /bin/gzip -cdq
29 0 \037\213 pipe /bin/gzip -cdq
30 0 \037\236 pipe /bin/gzip -cdq
31 0 \037\240 pipe /bin/gzip -cdq
32
33 # troff documents
34 0 .\?\?\040 fpipe `/usr/bin/grog -Tps $FILE`
35 0 .\\\" fpipe `/usr/bin/grog -Tps $FILE`
36 0 '\\\" fpipe `/usr/bin/grog -Tps $FILE`
37 0 '.\\\" fpipe `/usr/bin/grog -Tps $FILE`
38 0 \\\" fpipe `/usr/bin/grog -Tps $FILE`
39
40 # ditroff
41 0 "x T ps" pipe /usr/bin/grops
42 0 "x T dvi" pipe /usr/bin/grodvi
43 0 "x T ascii" pipe /usr/bin/grotty
44 0 "x T latin1" pipe /usr/bin/grotty
45 0 "x T lj4" reject Cannot print LaserJet 4 ditroff files.
46
47 # Portable bit-, grey- and pixmaps
48 0 P1\n pipe /usr/bin/pnmtops -scale 1000 -dpi 600 2>/dev/null
49 0 P2\n pipe /usr/bin/pnmtops -scale 1000 -dpi 600 2>/dev/null
50 0 P3\n pipe /usr/bin/pnmtops -scale 1000 -dpi 600 2>/dev/null
51 0 P4\n pipe /usr/bin/pnmtops -scale 1000 -dpi 600 2>/dev/null
52 0 P5\n pipe /usr/bin/pnmtops -scale 1000 -dpi 600 2>/dev/null
53 0 P6\n filter /usr/bin/pnm2ppa -f /etc/ppa/pnm2ppa.conf.hp1000 -i - -o -
54
55 # HP Printer Control Language (PCL) -- assume start with reset code
56 0 \033E\033 reject Cannot print PCL files on this printer.
57
58 # HP Printer Job Language (PJL)
59 0 \033%-12345X reject Cannot print PJL files on this printer.
60 0 "@PJL " reject Cannot print PJL files on this printer.
61 0 @PJL\t reject Cannot print PJL files on this printer.
62 0 @PJL\r reject Cannot print PJL files on this printer.
63 0 @PJL\n reject Cannot print PJL files on this printer.
64
65 # GIF files
66 0 GIF87a pipe /usr/bin/giftopnm 2>/dev/null
67 0 GIF89a pipe /usr/bin/giftopnm 2>/dev/null
68
69 # JFIF (JPEG) files
70 0 \377\330\377\340\?\?JFIF\0 pipe /usr/bin/djpeg -pnm
71
72 # TIFF files (the last two bytes of the "magic" is really a version number;
73 # but the magic is really lame and as far as I have understood the version
74 # number has never changed and never will, so we include it.)
75 0 MM\0\x2a fpipe /usr/bin/tiff2ps $FILE
76 0 II\x2a\0 fpipe /usr/bin/tiff2ps $FILE
77
78 # BMP files (even lousier magic -- Microsoft strikes again!)
79 0 BM\?\?\?\?\?\?\?\?\?\?\?\?\x0c pipe \
80 /usr/bin/bmptoppm 2>/dev/null
81 0 BM\?\?\?\?\?\?\?\?\?\?\?\?\x40 pipe \
82 /usr/bin/bmptoppm 2>/dev/null
83 0 BM\?\?\?\?\?\?\?\?\?\?\?\?\x28 pipe \
84 /usr/bin/bmptoppm 2>/dev/null
85
86 # Garbage delivered from Windows via Samba
87 # (donated by Andree Leidenfrost <leidenfrost@dkrz.de>)
88 # 300 \033\052\157 cat
89 # later changed to
90 # (Bug report #22866: magicfilter: Incorrect magic for Win95/Samba print jobs)
91 0 \000\000\000\000\000 cat
92
93 # Sun rasterfiles
94 0 \x59\xa6\x6a\x95 pipe /usr/bin/rasttopnm 2>/dev/null
95
96 # SGI Imagelib (IRIS RGB) files
97 0 \x1\xda pipe /usr/bin/sgitopnm 2>/dev/null
98 0 \xda\x1 pipe /usr/bin/sgitopnm 2>/dev/null
99
100 # FIG files; reported by Steven P. Hill <sph@uscbu.ih.att.com>
101 0 #FIG pipe /usr/bin/X11/fig2dev -Lps -P -l dummy
102
103 #
104 # Standard rejects... things we don't want to print
105 #
106
107 # Various archive formats
108 257 ustar\0 reject Attempted to print a tar file.
109 257 "ustar \0" reject Attempted to print a tar file.
110 0 07070 reject Attempted to print a cpio file.
111 0 PK\3\4 reject Attempted to print a zip file.
112 20 \xdc\xa7\xc7\xfd reject Attempted to print a zoo file.
113
114 # Binaries (Linux): reject with email message
115 0 \013\1d\0 reject Attempted to print a compiled binary.
116 0 \100\1d\0 reject Attempted to print a compiled binary.
117 0 \007\1d\0 reject Attempted to print a compiled binary.
118 0 \314\0d\0 reject Attempted to print a compiled binary.
119 0 \177ELF reject Attempted to print an ELF object.
120 0 \007\001\0 reject Attempted to print an object file.
121 216 \021\001\0\0 reject Attempted to print a core dump file.
122 0 !<arch> reject Attempted to print an archive.
123 0 =<ar> reject Attempted to print an archive.
124
125 # Don't confuse this one with troff!
126 0 .snd reject Attempted to print Sun/NeXT audio data.
127
128 # wacko troff magic
129 0 ''' fpipe `/usr/bin/grog -Tps $FILE`
130
131 # wild guess: PCL control codes start with <ESC>
132 0 \033 reject Cannot print PCL files on this printer.
133
134 # Default entry -- for normal (text) files. MUST BE LAST.
135 # If you do not have djscript use the other default line or, better, install
136 # it. MM
137 #
138 default pipe /usr/bin/enscript -B -p-
0 #!/usr/sbin/magicfilter
1 #
2 # Magic filter setup file for HP printers 720, 820 and 1000 series.
3
4 # pnm2ppa supports color and black/white printing. This file was
5 # tested on a HP Deskjet 720C printer, but is supposed to work on
6 # other printers using the HP PPA protocol, too. Supported pagesizes
7 # are a4, letter and legal. The pagesize has to be set in /etc/papersize
8 # and not in the configuration files in /etc/ppa/pnm2ppa.conf.hp*.
9
10 # Adapted from dj500-filter, cpsonly600-filter and pbm2ppa-filter
11 # by Roland Bauerschmidt <roland@copyleft.de>, 2000
12
13 # PostScript
14 0 %! fpipe /usr/bin/gs -q -dSAFER -dNOPAUSE -r600 -sDEVICE=ppmraw -sOutputFile=- - -c quit
15 0 \004%! fpipe /usr/bin/gs -q -dSAFER -dNOPAUSE -r600 -sDEVICE=ppmraw -sOutputFile=- - -c quit
16
17 # PDF
18 0 %PDF fpipe /usr/bin/gs -q -dSAFER -dNOPAUSE -r600 -sDEVICE=ppmraw -sOutputFile=- $FILE -c quit
19
20
21 # TeX DVI
22 0 \367\002 fpipe /usr/bin/dvips -D 600 -R -q -f
23
24 # compress'd data
25 0 \037\235 pipe /bin/gzip -cdq
26
27 # packed, gzipped, frozen and SCO LZH data
28 0 \037\036 pipe /bin/gzip -cdq
29 0 \037\213 pipe /bin/gzip -cdq
30 0 \037\236 pipe /bin/gzip -cdq
31 0 \037\240 pipe /bin/gzip -cdq
32
33 # troff documents
34 0 .\?\?\040 fpipe `/usr/bin/grog -Tps $FILE`
35 0 .\\\" fpipe `/usr/bin/grog -Tps $FILE`
36 0 '\\\" fpipe `/usr/bin/grog -Tps $FILE`
37 0 '.\\\" fpipe `/usr/bin/grog -Tps $FILE`
38 0 \\\" fpipe `/usr/bin/grog -Tps $FILE`
39
40 # ditroff
41 0 "x T ps" pipe /usr/bin/grops
42 0 "x T dvi" pipe /usr/bin/grodvi
43 0 "x T ascii" pipe /usr/bin/grotty
44 0 "x T latin1" pipe /usr/bin/grotty
45 0 "x T lj4" reject Cannot print LaserJet 4 ditroff files.
46
47 # Portable bit-, grey- and pixmaps
48 0 P1\n pipe /usr/bin/pnmtops -scale 1000 -dpi 600 2>/dev/null
49 0 P2\n pipe /usr/bin/pnmtops -scale 1000 -dpi 600 2>/dev/null
50 0 P3\n pipe /usr/bin/pnmtops -scale 1000 -dpi 600 2>/dev/null
51 0 P4\n pipe /usr/bin/pnmtops -scale 1000 -dpi 600 2>/dev/null
52 0 P5\n pipe /usr/bin/pnmtops -scale 1000 -dpi 600 2>/dev/null
53 0 P6\n filter /usr/bin/pnm2ppa --bw --eco -f /etc/ppa/pnm2ppa.conf.hp720 -i - -o -
54
55 # HP Printer Control Language (PCL) -- assume start with reset code
56 0 \033E\033 reject Cannot print PCL files on this printer.
57
58 # HP Printer Job Language (PJL)
59 0 \033%-12345X reject Cannot print PJL files on this printer.
60 0 "@PJL " reject Cannot print PJL files on this printer.
61 0 @PJL\t reject Cannot print PJL files on this printer.
62 0 @PJL\r reject Cannot print PJL files on this printer.
63 0 @PJL\n reject Cannot print PJL files on this printer.
64
65 # GIF files
66 0 GIF87a pipe /usr/bin/giftopnm 2>/dev/null
67 0 GIF89a pipe /usr/bin/giftopnm 2>/dev/null
68
69 # JFIF (JPEG) files
70 0 \377\330\377\340\?\?JFIF\0 pipe /usr/bin/djpeg -pnm
71
72 # TIFF files (the last two bytes of the "magic" is really a version number;
73 # but the magic is really lame and as far as I have understood the version
74 # number has never changed and never will, so we include it.)
75 0 MM\0\x2a fpipe /usr/bin/tiff2ps $FILE
76 0 II\x2a\0 fpipe /usr/bin/tiff2ps $FILE
77
78 # BMP files (even lousier magic -- Microsoft strikes again!)
79 0 BM\?\?\?\?\?\?\?\?\?\?\?\?\x0c pipe \
80 /usr/bin/bmptoppm 2>/dev/null
81 0 BM\?\?\?\?\?\?\?\?\?\?\?\?\x40 pipe \
82 /usr/bin/bmptoppm 2>/dev/null
83 0 BM\?\?\?\?\?\?\?\?\?\?\?\?\x28 pipe \
84 /usr/bin/bmptoppm 2>/dev/null
85
86 # Garbage delivered from Windows via Samba
87 # (donated by Andree Leidenfrost <leidenfrost@dkrz.de>)
88 # 300 \033\052\157 cat
89 # later changed to
90 # (Bug report #22866: magicfilter: Incorrect magic for Win95/Samba print jobs)
91 0 \000\000\000\000\000 cat
92
93 # Sun rasterfiles
94 0 \x59\xa6\x6a\x95 pipe /usr/bin/rasttopnm 2>/dev/null
95
96 # SGI Imagelib (IRIS RGB) files
97 0 \x1\xda pipe /usr/bin/sgitopnm 2>/dev/null
98 0 \xda\x1 pipe /usr/bin/sgitopnm 2>/dev/null
99
100 # FIG files; reported by Steven P. Hill <sph@uscbu.ih.att.com>
101 0 #FIG pipe /usr/bin/X11/fig2dev -Lps -P -l dummy
102
103 #
104 # Standard rejects... things we don't want to print
105 #
106
107 # Various archive formats
108 257 ustar\0 reject Attempted to print a tar file.
109 257 "ustar \0" reject Attempted to print a tar file.
110 0 07070 reject Attempted to print a cpio file.
111 0 PK\3\4 reject Attempted to print a zip file.
112 20 \xdc\xa7\xc7\xfd reject Attempted to print a zoo file.
113
114 # Binaries (Linux): reject with email message
115 0 \013\1d\0 reject Attempted to print a compiled binary.
116 0 \100\1d\0 reject Attempted to print a compiled binary.
117 0 \007\1d\0 reject Attempted to print a compiled binary.
118 0 \314\0d\0 reject Attempted to print a compiled binary.
119 0 \177ELF reject Attempted to print an ELF object.
120 0 \007\001\0 reject Attempted to print an object file.
121 216 \021\001\0\0 reject Attempted to print a core dump file.
122 0 !<arch> reject Attempted to print an archive.
123 0 =<ar> reject Attempted to print an archive.
124
125 # Don't confuse this one with troff!
126 0 .snd reject Attempted to print Sun/NeXT audio data.
127
128 # wacko troff magic
129 0 ''' fpipe `/usr/bin/grog -Tps $FILE`
130
131 # wild guess: PCL control codes start with <ESC>
132 0 \033 reject Cannot print PCL files on this printer.
133
134 # Default entry -- for normal (text) files. MUST BE LAST.
135 # If you do not have djscript use the other default line or, better, install
136 # it. MM
137 #
138 default pipe /usr/bin/enscript -B -p-
0 #!/usr/sbin/magicfilter
1 #
2 # Magic filter setup file for HP printers 720, 820 and 1000 series.
3
4 # pnm2ppa supports color and black/white printing. This file was
5 # tested on a HP Deskjet 720C printer, but is supposed to work on
6 # other printers using the HP PPA protocol, too. Supported pagesizes
7 # are a4, letter and legal. The pagesize has to be set in /etc/papersize
8 # and not in the configuration files in /etc/ppa/pnm2ppa.conf.hp*.
9
10 # Adapted from dj500-filter, cpsonly600-filter and pbm2ppa-filter
11 # by Roland Bauerschmidt <roland@copyleft.de>, 2000
12
13 # PostScript
14 0 %! fpipe /usr/bin/gs -q -dSAFER -dNOPAUSE -r600 -sDEVICE=ppmraw -sOutputFile=- - -c quit
15 0 \004%! fpipe /usr/bin/gs -q -dSAFER -dNOPAUSE -r600 -sDEVICE=ppmraw -sOutputFile=- - -c quit
16
17 # PDF
18 0 %PDF fpipe /usr/bin/gs -q -dSAFER -dNOPAUSE -r600 -sDEVICE=ppmraw -sOutputFile=- $FILE -c quit
19
20
21 # TeX DVI
22 0 \367\002 fpipe /usr/bin/dvips -D 600 -R -q -f
23
24 # compress'd data
25 0 \037\235 pipe /bin/gzip -cdq
26
27 # packed, gzipped, frozen and SCO LZH data
28 0 \037\036 pipe /bin/gzip -cdq
29 0 \037\213 pipe /bin/gzip -cdq
30 0 \037\236 pipe /bin/gzip -cdq
31 0 \037\240 pipe /bin/gzip -cdq
32
33 # troff documents
34 0 .\?\?\040 fpipe `/usr/bin/grog -Tps $FILE`
35 0 .\\\" fpipe `/usr/bin/grog -Tps $FILE`
36 0 '\\\" fpipe `/usr/bin/grog -Tps $FILE`
37 0 '.\\\" fpipe `/usr/bin/grog -Tps $FILE`
38 0 \\\" fpipe `/usr/bin/grog -Tps $FILE`
39
40 # ditroff
41 0 "x T ps" pipe /usr/bin/grops
42 0 "x T dvi" pipe /usr/bin/grodvi
43 0 "x T ascii" pipe /usr/bin/grotty
44 0 "x T latin1" pipe /usr/bin/grotty
45 0 "x T lj4" reject Cannot print LaserJet 4 ditroff files.
46
47 # Portable bit-, grey- and pixmaps
48 0 P1\n pipe /usr/bin/pnmtops -scale 1000 -dpi 600 2>/dev/null
49 0 P2\n pipe /usr/bin/pnmtops -scale 1000 -dpi 600 2>/dev/null
50 0 P3\n pipe /usr/bin/pnmtops -scale 1000 -dpi 600 2>/dev/null
51 0 P4\n pipe /usr/bin/pnmtops -scale 1000 -dpi 600 2>/dev/null
52 0 P5\n pipe /usr/bin/pnmtops -scale 1000 -dpi 600 2>/dev/null
53 0 P6\n filter /usr/bin/pnm2ppa --bw -f /etc/ppa/pnm2ppa.conf.hp720 -i - -o -
54
55 # HP Printer Control Language (PCL) -- assume start with reset code
56 0 \033E\033 reject Cannot print PCL files on this printer.
57
58 # HP Printer Job Language (PJL)
59 0 \033%-12345X reject Cannot print PJL files on this printer.
60 0 "@PJL " reject Cannot print PJL files on this printer.
61 0 @PJL\t reject Cannot print PJL files on this printer.
62 0 @PJL\r reject Cannot print PJL files on this printer.
63 0 @PJL\n reject Cannot print PJL files on this printer.
64
65 # GIF files
66 0 GIF87a pipe /usr/bin/giftopnm 2>/dev/null
67 0 GIF89a pipe /usr/bin/giftopnm 2>/dev/null
68
69 # JFIF (JPEG) files
70 0 \377\330\377\340\?\?JFIF\0 pipe /usr/bin/djpeg -pnm
71
72 # TIFF files (the last two bytes of the "magic" is really a version number;
73 # but the magic is really lame and as far as I have understood the version
74 # number has never changed and never will, so we include it.)
75 0 MM\0\x2a fpipe /usr/bin/tiff2ps $FILE
76 0 II\x2a\0 fpipe /usr/bin/tiff2ps $FILE
77
78 # BMP files (even lousier magic -- Microsoft strikes again!)
79 0 BM\?\?\?\?\?\?\?\?\?\?\?\?\x0c pipe \
80 /usr/bin/bmptoppm 2>/dev/null
81 0 BM\?\?\?\?\?\?\?\?\?\?\?\?\x40 pipe \
82 /usr/bin/bmptoppm 2>/dev/null
83 0 BM\?\?\?\?\?\?\?\?\?\?\?\?\x28 pipe \
84 /usr/bin/bmptoppm 2>/dev/null
85
86 # Garbage delivered from Windows via Samba
87 # (donated by Andree Leidenfrost <leidenfrost@dkrz.de>)
88 # 300 \033\052\157 cat
89 # later changed to
90 # (Bug report #22866: magicfilter: Incorrect magic for Win95/Samba print jobs)
91 0 \000\000\000\000\000 cat
92
93 # Sun rasterfiles
94 0 \x59\xa6\x6a\x95 pipe /usr/bin/rasttopnm 2>/dev/null
95
96 # SGI Imagelib (IRIS RGB) files
97 0 \x1\xda pipe /usr/bin/sgitopnm 2>/dev/null
98 0 \xda\x1 pipe /usr/bin/sgitopnm 2>/dev/null
99
100 # FIG files; reported by Steven P. Hill <sph@uscbu.ih.att.com>
101 0 #FIG pipe /usr/bin/X11/fig2dev -Lps -P -l dummy
102
103 #
104 # Standard rejects... things we don't want to print
105 #
106
107 # Various archive formats
108 257 ustar\0 reject Attempted to print a tar file.
109 257 "ustar \0" reject Attempted to print a tar file.
110 0 07070 reject Attempted to print a cpio file.
111 0 PK\3\4 reject Attempted to print a zip file.
112 20 \xdc\xa7\xc7\xfd reject Attempted to print a zoo file.
113
114 # Binaries (Linux): reject with email message
115 0 \013\1d\0 reject Attempted to print a compiled binary.
116 0 \100\1d\0 reject Attempted to print a compiled binary.
117 0 \007\1d\0 reject Attempted to print a compiled binary.
118 0 \314\0d\0 reject Attempted to print a compiled binary.
119 0 \177ELF reject Attempted to print an ELF object.
120 0 \007\001\0 reject Attempted to print an object file.
121 216 \021\001\0\0 reject Attempted to print a core dump file.
122 0 !<arch> reject Attempted to print an archive.
123 0 =<ar> reject Attempted to print an archive.
124
125 # Don't confuse this one with troff!
126 0 .snd reject Attempted to print Sun/NeXT audio data.
127
128 # wacko troff magic
129 0 ''' fpipe `/usr/bin/grog -Tps $FILE`
130
131 # wild guess: PCL control codes start with <ESC>
132 0 \033 reject Cannot print PCL files on this printer.
133
134 # Default entry -- for normal (text) files. MUST BE LAST.
135 # If you do not have djscript use the other default line or, better, install
136 # it. MM
137 #
138 default pipe /usr/bin/enscript -B -p-
0 #!/usr/sbin/magicfilter
1 #
2 # Magic filter setup file for HP printers 720, 820 and 1000 series.
3
4 # pnm2ppa supports color and black/white printing. This file was
5 # tested on a HP Deskjet 720C printer, but is supposed to work on
6 # other printers using the HP PPA protocol, too. Supported pagesizes
7 # are a4, letter and legal. The pagesize has to be set in /etc/papersize
8 # and not in the configuration files in /etc/ppa/pnm2ppa.conf.hp*.
9
10 # Adapted from dj500-filter, cpsonly600-filter and pbm2ppa-filter
11 # by Roland Bauerschmidt <roland@copyleft.de>, 2000
12
13 # PostScript
14 0 %! fpipe /usr/bin/gs -q -dSAFER -dNOPAUSE -r600 -sDEVICE=ppmraw -sOutputFile=- - -c quit
15 0 \004%! fpipe /usr/bin/gs -q -dSAFER -dNOPAUSE -r600 -sDEVICE=ppmraw -sOutputFile=- - -c quit
16
17 # PDF
18 0 %PDF fpipe /usr/bin/gs -q -dSAFER -dNOPAUSE -r600 -sDEVICE=ppmraw -sOutputFile=- $FILE -c quit
19
20
21 # TeX DVI
22 0 \367\002 fpipe /usr/bin/dvips -D 600 -R -q -f
23
24 # compress'd data
25 0 \037\235 pipe /bin/gzip -cdq
26
27 # packed, gzipped, frozen and SCO LZH data
28 0 \037\036 pipe /bin/gzip -cdq
29 0 \037\213 pipe /bin/gzip -cdq
30 0 \037\236 pipe /bin/gzip -cdq
31 0 \037\240 pipe /bin/gzip -cdq
32
33 # troff documents
34 0 .\?\?\040 fpipe `/usr/bin/grog -Tps $FILE`
35 0 .\\\" fpipe `/usr/bin/grog -Tps $FILE`
36 0 '\\\" fpipe `/usr/bin/grog -Tps $FILE`
37 0 '.\\\" fpipe `/usr/bin/grog -Tps $FILE`
38 0 \\\" fpipe `/usr/bin/grog -Tps $FILE`
39
40 # ditroff
41 0 "x T ps" pipe /usr/bin/grops
42 0 "x T dvi" pipe /usr/bin/grodvi
43 0 "x T ascii" pipe /usr/bin/grotty
44 0 "x T latin1" pipe /usr/bin/grotty
45 0 "x T lj4" reject Cannot print LaserJet 4 ditroff files.
46
47 # Portable bit-, grey- and pixmaps
48 0 P1\n pipe /usr/bin/pnmtops -scale 1000 -dpi 600 2>/dev/null
49 0 P2\n pipe /usr/bin/pnmtops -scale 1000 -dpi 600 2>/dev/null
50 0 P3\n pipe /usr/bin/pnmtops -scale 1000 -dpi 600 2>/dev/null
51 0 P4\n pipe /usr/bin/pnmtops -scale 1000 -dpi 600 2>/dev/null
52 0 P5\n pipe /usr/bin/pnmtops -scale 1000 -dpi 600 2>/dev/null
53 0 P6\n filter /usr/bin/pnm2ppa --eco -f /etc/ppa/pnm2ppa.conf.hp720 -i - -o -
54
55 # HP Printer Control Language (PCL) -- assume start with reset code
56 0 \033E\033 reject Cannot print PCL files on this printer.
57
58 # HP Printer Job Language (PJL)
59 0 \033%-12345X reject Cannot print PJL files on this printer.
60 0 "@PJL " reject Cannot print PJL files on this printer.
61 0 @PJL\t reject Cannot print PJL files on this printer.
62 0 @PJL\r reject Cannot print PJL files on this printer.
63 0 @PJL\n reject Cannot print PJL files on this printer.
64
65 # GIF files
66 0 GIF87a pipe /usr/bin/giftopnm 2>/dev/null
67 0 GIF89a pipe /usr/bin/giftopnm 2>/dev/null
68
69 # JFIF (JPEG) files
70 0 \377\330\377\340\?\?JFIF\0 pipe /usr/bin/djpeg -pnm
71
72 # TIFF files (the last two bytes of the "magic" is really a version number;
73 # but the magic is really lame and as far as I have understood the version
74 # number has never changed and never will, so we include it.)
75 0 MM\0\x2a fpipe /usr/bin/tiff2ps $FILE
76 0 II\x2a\0 fpipe /usr/bin/tiff2ps $FILE
77
78 # BMP files (even lousier magic -- Microsoft strikes again!)
79 0 BM\?\?\?\?\?\?\?\?\?\?\?\?\x0c pipe \
80 /usr/bin/bmptoppm 2>/dev/null
81 0 BM\?\?\?\?\?\?\?\?\?\?\?\?\x40 pipe \
82 /usr/bin/bmptoppm 2>/dev/null
83 0 BM\?\?\?\?\?\?\?\?\?\?\?\?\x28 pipe \
84 /usr/bin/bmptoppm 2>/dev/null
85
86 # Garbage delivered from Windows via Samba
87 # (donated by Andree Leidenfrost <leidenfrost@dkrz.de>)
88 # 300 \033\052\157 cat
89 # later changed to
90 # (Bug report #22866: magicfilter: Incorrect magic for Win95/Samba print jobs)
91 0 \000\000\000\000\000 cat
92
93 # Sun rasterfiles
94 0 \x59\xa6\x6a\x95 pipe /usr/bin/rasttopnm 2>/dev/null
95
96 # SGI Imagelib (IRIS RGB) files
97 0 \x1\xda pipe /usr/bin/sgitopnm 2>/dev/null
98 0 \xda\x1 pipe /usr/bin/sgitopnm 2>/dev/null
99
100 # FIG files; reported by Steven P. Hill <sph@uscbu.ih.att.com>
101 0 #FIG pipe /usr/bin/X11/fig2dev -Lps -P -l dummy
102
103 #
104 # Standard rejects... things we don't want to print
105 #
106
107 # Various archive formats
108 257 ustar\0 reject Attempted to print a tar file.
109 257 "ustar \0" reject Attempted to print a tar file.
110 0 07070 reject Attempted to print a cpio file.
111 0 PK\3\4 reject Attempted to print a zip file.
112 20 \xdc\xa7\xc7\xfd reject Attempted to print a zoo file.
113
114 # Binaries (Linux): reject with email message
115 0 \013\1d\0 reject Attempted to print a compiled binary.
116 0 \100\1d\0 reject Attempted to print a compiled binary.
117 0 \007\1d\0 reject Attempted to print a compiled binary.
118 0 \314\0d\0 reject Attempted to print a compiled binary.
119 0 \177ELF reject Attempted to print an ELF object.
120 0 \007\001\0 reject Attempted to print an object file.
121 216 \021\001\0\0 reject Attempted to print a core dump file.
122 0 !<arch> reject Attempted to print an archive.
123 0 =<ar> reject Attempted to print an archive.
124
125 # Don't confuse this one with troff!
126 0 .snd reject Attempted to print Sun/NeXT audio data.
127
128 # wacko troff magic
129 0 ''' fpipe `/usr/bin/grog -Tps $FILE`
130
131 # wild guess: PCL control codes start with <ESC>
132 0 \033 reject Cannot print PCL files on this printer.
133
134 # Default entry -- for normal (text) files. MUST BE LAST.
135 # If you do not have djscript use the other default line or, better, install
136 # it. MM
137 #
138 default pipe /usr/bin/enscript -B -p-
0 #!/usr/sbin/magicfilter
1 #
2 # Magic filter setup file for HP printers 720, 820 and 1000 series.
3
4 # pnm2ppa supports color and black/white printing. This file was
5 # tested on a HP Deskjet 720C printer, but is supposed to work on
6 # other printers using the HP PPA protocol, too. Supported pagesizes
7 # are a4, letter and legal. The pagesize has to be set in /etc/papersize
8 # and not in the configuration files in /etc/ppa/pnm2ppa.conf.hp*.
9
10 # Adapted from dj500-filter, cpsonly600-filter and pbm2ppa-filter
11 # by Roland Bauerschmidt <roland@copyleft.de>, 2000
12
13 # PostScript
14 0 %! fpipe /usr/bin/gs -q -dSAFER -dNOPAUSE -r600 -sDEVICE=ppmraw -sOutputFile=- - -c quit
15 0 \004%! fpipe /usr/bin/gs -q -dSAFER -dNOPAUSE -r600 -sDEVICE=ppmraw -sOutputFile=- - -c quit
16
17 # PDF
18 0 %PDF fpipe /usr/bin/gs -q -dSAFER -dNOPAUSE -r600 -sDEVICE=ppmraw -sOutputFile=- $FILE -c quit
19
20
21 # TeX DVI
22 0 \367\002 fpipe /usr/bin/dvips -D 600 -R -q -f
23
24 # compress'd data
25 0 \037\235 pipe /bin/gzip -cdq
26
27 # packed, gzipped, frozen and SCO LZH data
28 0 \037\036 pipe /bin/gzip -cdq
29 0 \037\213 pipe /bin/gzip -cdq
30 0 \037\236 pipe /bin/gzip -cdq
31 0 \037\240 pipe /bin/gzip -cdq
32
33 # troff documents
34 0 .\?\?\040 fpipe `/usr/bin/grog -Tps $FILE`
35 0 .\\\" fpipe `/usr/bin/grog -Tps $FILE`
36 0 '\\\" fpipe `/usr/bin/grog -Tps $FILE`
37 0 '.\\\" fpipe `/usr/bin/grog -Tps $FILE`
38 0 \\\" fpipe `/usr/bin/grog -Tps $FILE`
39
40 # ditroff
41 0 "x T ps" pipe /usr/bin/grops
42 0 "x T dvi" pipe /usr/bin/grodvi
43 0 "x T ascii" pipe /usr/bin/grotty
44 0 "x T latin1" pipe /usr/bin/grotty
45 0 "x T lj4" reject Cannot print LaserJet 4 ditroff files.
46
47 # Portable bit-, grey- and pixmaps
48 0 P1\n pipe /usr/bin/pnmtops -scale 1000 -dpi 600 2>/dev/null
49 0 P2\n pipe /usr/bin/pnmtops -scale 1000 -dpi 600 2>/dev/null
50 0 P3\n pipe /usr/bin/pnmtops -scale 1000 -dpi 600 2>/dev/null
51 0 P4\n pipe /usr/bin/pnmtops -scale 1000 -dpi 600 2>/dev/null
52 0 P5\n pipe /usr/bin/pnmtops -scale 1000 -dpi 600 2>/dev/null
53 0 P6\n filter /usr/bin/pnm2ppa -f /etc/ppa/pnm2ppa.conf.hp720 -i - -o -
54
55 # HP Printer Control Language (PCL) -- assume start with reset code
56 0 \033E\033 reject Cannot print PCL files on this printer.
57
58 # HP Printer Job Language (PJL)
59 0 \033%-12345X reject Cannot print PJL files on this printer.
60 0 "@PJL " reject Cannot print PJL files on this printer.
61 0 @PJL\t reject Cannot print PJL files on this printer.
62 0 @PJL\r reject Cannot print PJL files on this printer.
63 0 @PJL\n reject Cannot print PJL files on this printer.
64
65 # GIF files
66 0 GIF87a pipe /usr/bin/giftopnm 2>/dev/null
67 0 GIF89a pipe /usr/bin/giftopnm 2>/dev/null
68
69 # JFIF (JPEG) files
70 0 \377\330\377\340\?\?JFIF\0 pipe /usr/bin/djpeg -pnm
71
72 # TIFF files (the last two bytes of the "magic" is really a version number;
73 # but the magic is really lame and as far as I have understood the version
74 # number has never changed and never will, so we include it.)
75 0 MM\0\x2a fpipe /usr/bin/tiff2ps $FILE
76 0 II\x2a\0 fpipe /usr/bin/tiff2ps $FILE
77
78 # BMP files (even lousier magic -- Microsoft strikes again!)
79 0 BM\?\?\?\?\?\?\?\?\?\?\?\?\x0c pipe \
80 /usr/bin/bmptoppm 2>/dev/null
81 0 BM\?\?\?\?\?\?\?\?\?\?\?\?\x40 pipe \
82 /usr/bin/bmptoppm 2>/dev/null
83 0 BM\?\?\?\?\?\?\?\?\?\?\?\?\x28 pipe \
84 /usr/bin/bmptoppm 2>/dev/null
85
86 # Garbage delivered from Windows via Samba
87 # (donated by Andree Leidenfrost <leidenfrost@dkrz.de>)
88 # 300 \033\052\157 cat
89 # later changed to
90 # (Bug report #22866: magicfilter: Incorrect magic for Win95/Samba print jobs)
91 0 \000\000\000\000\000 cat
92
93 # Sun rasterfiles
94 0 \x59\xa6\x6a\x95 pipe /usr/bin/rasttopnm 2>/dev/null
95
96 # SGI Imagelib (IRIS RGB) files
97 0 \x1\xda pipe /usr/bin/sgitopnm 2>/dev/null
98 0 \xda\x1 pipe /usr/bin/sgitopnm 2>/dev/null
99
100 # FIG files; reported by Steven P. Hill <sph@uscbu.ih.att.com>
101 0 #FIG pipe /usr/bin/X11/fig2dev -Lps -P -l dummy
102
103 #
104 # Standard rejects... things we don't want to print
105 #
106
107 # Various archive formats
108 257 ustar\0 reject Attempted to print a tar file.
109 257 "ustar \0" reject Attempted to print a tar file.
110 0 07070 reject Attempted to print a cpio file.
111 0 PK\3\4 reject Attempted to print a zip file.
112 20 \xdc\xa7\xc7\xfd reject Attempted to print a zoo file.
113
114 # Binaries (Linux): reject with email message
115 0 \013\1d\0 reject Attempted to print a compiled binary.
116 0 \100\1d\0 reject Attempted to print a compiled binary.
117 0 \007\1d\0 reject Attempted to print a compiled binary.
118 0 \314\0d\0 reject Attempted to print a compiled binary.
119 0 \177ELF reject Attempted to print an ELF object.
120 0 \007\001\0 reject Attempted to print an object file.
121 216 \021\001\0\0 reject Attempted to print a core dump file.
122 0 !<arch> reject Attempted to print an archive.
123 0 =<ar> reject Attempted to print an archive.
124
125 # Don't confuse this one with troff!
126 0 .snd reject Attempted to print Sun/NeXT audio data.
127
128 # wacko troff magic
129 0 ''' fpipe `/usr/bin/grog -Tps $FILE`
130
131 # wild guess: PCL control codes start with <ESC>
132 0 \033 reject Cannot print PCL files on this printer.
133
134 # Default entry -- for normal (text) files. MUST BE LAST.
135 # If you do not have djscript use the other default line or, better, install
136 # it. MM
137 #
138 default pipe /usr/bin/enscript -B -p-
0 #!/usr/sbin/magicfilter
1 #
2 # Magic filter setup file for HP printers 720, 820 and 1000 series.
3
4 # pnm2ppa supports color and black/white printing. This file was
5 # tested on a HP Deskjet 720C printer, but is supposed to work on
6 # other printers using the HP PPA protocol, too. Supported pagesizes
7 # are a4, letter and legal. The pagesize has to be set in /etc/papersize
8 # and not in the configuration files in /etc/ppa/pnm2ppa.conf.hp*.
9
10 # Adapted from dj500-filter, cpsonly600-filter and pbm2ppa-filter
11 # by Roland Bauerschmidt <roland@copyleft.de>, 2000
12
13 # PostScript
14 0 %! fpipe /usr/bin/gs -q -dSAFER -dNOPAUSE -r600 -sDEVICE=ppmraw -sOutputFile=- - -c quit
15 0 \004%! fpipe /usr/bin/gs -q -dSAFER -dNOPAUSE -r600 -sDEVICE=ppmraw -sOutputFile=- - -c quit
16
17 # PDF
18 0 %PDF fpipe /usr/bin/gs -q -dSAFER -dNOPAUSE -r600 -sDEVICE=ppmraw -sOutputFile=- $FILE -c quit
19
20
21 # TeX DVI
22 0 \367\002 fpipe /usr/bin/dvips -D 600 -R -q -f
23
24 # compress'd data
25 0 \037\235 pipe /bin/gzip -cdq
26
27 # packed, gzipped, frozen and SCO LZH data
28 0 \037\036 pipe /bin/gzip -cdq
29 0 \037\213 pipe /bin/gzip -cdq
30 0 \037\236 pipe /bin/gzip -cdq
31 0 \037\240 pipe /bin/gzip -cdq
32
33 # troff documents
34 0 .\?\?\040 fpipe `/usr/bin/grog -Tps $FILE`
35 0 .\\\" fpipe `/usr/bin/grog -Tps $FILE`
36 0 '\\\" fpipe `/usr/bin/grog -Tps $FILE`
37 0 '.\\\" fpipe `/usr/bin/grog -Tps $FILE`
38 0 \\\" fpipe `/usr/bin/grog -Tps $FILE`
39
40 # ditroff
41 0 "x T ps" pipe /usr/bin/grops
42 0 "x T dvi" pipe /usr/bin/grodvi
43 0 "x T ascii" pipe /usr/bin/grotty
44 0 "x T latin1" pipe /usr/bin/grotty
45 0 "x T lj4" reject Cannot print LaserJet 4 ditroff files.
46
47 # Portable bit-, grey- and pixmaps
48 0 P1\n pipe /usr/bin/pnmtops -scale 1000 -dpi 600 2>/dev/null
49 0 P2\n pipe /usr/bin/pnmtops -scale 1000 -dpi 600 2>/dev/null
50 0 P3\n pipe /usr/bin/pnmtops -scale 1000 -dpi 600 2>/dev/null
51 0 P4\n pipe /usr/bin/pnmtops -scale 1000 -dpi 600 2>/dev/null
52 0 P5\n pipe /usr/bin/pnmtops -scale 1000 -dpi 600 2>/dev/null
53 0 P6\n filter /usr/bin/pnm2ppa --bw --eco -f /etc/ppa/pnm2ppa.conf.hp820 -i - -o -
54
55 # HP Printer Control Language (PCL) -- assume start with reset code
56 0 \033E\033 reject Cannot print PCL files on this printer.
57
58 # HP Printer Job Language (PJL)
59 0 \033%-12345X reject Cannot print PJL files on this printer.
60 0 "@PJL " reject Cannot print PJL files on this printer.
61 0 @PJL\t reject Cannot print PJL files on this printer.
62 0 @PJL\r reject Cannot print PJL files on this printer.
63 0 @PJL\n reject Cannot print PJL files on this printer.
64
65 # GIF files
66 0 GIF87a pipe /usr/bin/giftopnm 2>/dev/null
67 0 GIF89a pipe /usr/bin/giftopnm 2>/dev/null
68
69 # JFIF (JPEG) files
70 0 \377\330\377\340\?\?JFIF\0 pipe /usr/bin/djpeg -pnm
71
72 # TIFF files (the last two bytes of the "magic" is really a version number;
73 # but the magic is really lame and as far as I have understood the version
74 # number has never changed and never will, so we include it.)
75 0 MM\0\x2a fpipe /usr/bin/tiff2ps $FILE
76 0 II\x2a\0 fpipe /usr/bin/tiff2ps $FILE
77
78 # BMP files (even lousier magic -- Microsoft strikes again!)
79 0 BM\?\?\?\?\?\?\?\?\?\?\?\?\x0c pipe \
80 /usr/bin/bmptoppm 2>/dev/null
81 0 BM\?\?\?\?\?\?\?\?\?\?\?\?\x40 pipe \
82 /usr/bin/bmptoppm 2>/dev/null
83 0 BM\?\?\?\?\?\?\?\?\?\?\?\?\x28 pipe \
84 /usr/bin/bmptoppm 2>/dev/null
85
86 # Garbage delivered from Windows via Samba
87 # (donated by Andree Leidenfrost <leidenfrost@dkrz.de>)
88 # 300 \033\052\157 cat
89 # later changed to
90 # (Bug report #22866: magicfilter: Incorrect magic for Win95/Samba print jobs)
91 0 \000\000\000\000\000 cat
92
93 # Sun rasterfiles
94 0 \x59\xa6\x6a\x95 pipe /usr/bin/rasttopnm 2>/dev/null
95
96 # SGI Imagelib (IRIS RGB) files
97 0 \x1\xda pipe /usr/bin/sgitopnm 2>/dev/null
98 0 \xda\x1 pipe /usr/bin/sgitopnm 2>/dev/null
99
100 # FIG files; reported by Steven P. Hill <sph@uscbu.ih.att.com>
101 0 #FIG pipe /usr/bin/X11/fig2dev -Lps -P -l dummy
102
103 #
104 # Standard rejects... things we don't want to print
105 #
106
107 # Various archive formats
108 257 ustar\0 reject Attempted to print a tar file.
109 257 "ustar \0" reject Attempted to print a tar file.
110 0 07070 reject Attempted to print a cpio file.
111 0 PK\3\4 reject Attempted to print a zip file.
112 20 \xdc\xa7\xc7\xfd reject Attempted to print a zoo file.
113
114 # Binaries (Linux): reject with email message
115 0 \013\1d\0 reject Attempted to print a compiled binary.
116 0 \100\1d\0 reject Attempted to print a compiled binary.
117 0 \007\1d\0 reject Attempted to print a compiled binary.
118 0 \314\0d\0 reject Attempted to print a compiled binary.
119 0 \177ELF reject Attempted to print an ELF object.
120 0 \007\001\0 reject Attempted to print an object file.
121 216 \021\001\0\0 reject Attempted to print a core dump file.
122 0 !<arch> reject Attempted to print an archive.
123 0 =<ar> reject Attempted to print an archive.
124
125 # Don't confuse this one with troff!
126 0 .snd reject Attempted to print Sun/NeXT audio data.
127
128 # wacko troff magic
129 0 ''' fpipe `/usr/bin/grog -Tps $FILE`
130
131 # wild guess: PCL control codes start with <ESC>
132 0 \033 reject Cannot print PCL files on this printer.
133
134 # Default entry -- for normal (text) files. MUST BE LAST.
135 # If you do not have djscript use the other default line or, better, install
136 # it. MM
137 #
138 default pipe /usr/bin/enscript -B -p-
0 #!/usr/sbin/magicfilter
1 #
2 # Magic filter setup file for HP printers 720, 820 and 1000 series.
3
4 # pnm2ppa supports color and black/white printing. This file was
5 # tested on a HP Deskjet 720C printer, but is supposed to work on
6 # other printers using the HP PPA protocol, too. Supported pagesizes
7 # are a4, letter and legal. The pagesize has to be set in /etc/papersize
8 # and not in the configuration files in /etc/ppa/pnm2ppa.conf.hp*.
9
10 # Adapted from dj500-filter, cpsonly600-filter and pbm2ppa-filter
11 # by Roland Bauerschmidt <roland@copyleft.de>, 2000
12
13 # PostScript
14 0 %! fpipe /usr/bin/gs -q -dSAFER -dNOPAUSE -r600 -sDEVICE=ppmraw -sOutputFile=- - -c quit
15 0 \004%! fpipe /usr/bin/gs -q -dSAFER -dNOPAUSE -r600 -sDEVICE=ppmraw -sOutputFile=- - -c quit
16
17 # PDF
18 0 %PDF fpipe /usr/bin/gs -q -dSAFER -dNOPAUSE -r600 -sDEVICE=ppmraw -sOutputFile=- $FILE -c quit
19
20
21 # TeX DVI
22 0 \367\002 fpipe /usr/bin/dvips -D 600 -R -q -f
23
24 # compress'd data
25 0 \037\235 pipe /bin/gzip -cdq
26
27 # packed, gzipped, frozen and SCO LZH data
28 0 \037\036 pipe /bin/gzip -cdq
29 0 \037\213 pipe /bin/gzip -cdq
30 0 \037\236 pipe /bin/gzip -cdq
31 0 \037\240 pipe /bin/gzip -cdq
32
33 # troff documents
34 0 .\?\?\040 fpipe `/usr/bin/grog -Tps $FILE`
35 0 .\\\" fpipe `/usr/bin/grog -Tps $FILE`
36 0 '\\\" fpipe `/usr/bin/grog -Tps $FILE`
37 0 '.\\\" fpipe `/usr/bin/grog -Tps $FILE`
38 0 \\\" fpipe `/usr/bin/grog -Tps $FILE`
39
40 # ditroff
41 0 "x T ps" pipe /usr/bin/grops
42 0 "x T dvi" pipe /usr/bin/grodvi
43 0 "x T ascii" pipe /usr/bin/grotty
44 0 "x T latin1" pipe /usr/bin/grotty
45 0 "x T lj4" reject Cannot print LaserJet 4 ditroff files.
46
47 # Portable bit-, grey- and pixmaps
48 0 P1\n pipe /usr/bin/pnmtops -scale 1000 -dpi 600 2>/dev/null
49 0 P2\n pipe /usr/bin/pnmtops -scale 1000 -dpi 600 2>/dev/null
50 0 P3\n pipe /usr/bin/pnmtops -scale 1000 -dpi 600 2>/dev/null
51 0 P4\n pipe /usr/bin/pnmtops -scale 1000 -dpi 600 2>/dev/null
52 0 P5\n pipe /usr/bin/pnmtops -scale 1000 -dpi 600 2>/dev/null
53 0 P6\n filter /usr/bin/pnm2ppa --bw -f /etc/ppa/pnm2ppa.conf.hp820 -i - -o -
54
55 # HP Printer Control Language (PCL) -- assume start with reset code
56 0 \033E\033 reject Cannot print PCL files on this printer.
57
58 # HP Printer Job Language (PJL)
59 0 \033%-12345X reject Cannot print PJL files on this printer.
60 0 "@PJL " reject Cannot print PJL files on this printer.
61 0 @PJL\t reject Cannot print PJL files on this printer.
62 0 @PJL\r reject Cannot print PJL files on this printer.
63 0 @PJL\n reject Cannot print PJL files on this printer.
64
65 # GIF files
66 0 GIF87a pipe /usr/bin/giftopnm 2>/dev/null
67 0 GIF89a pipe /usr/bin/giftopnm 2>/dev/null
68
69 # JFIF (JPEG) files
70 0 \377\330\377\340\?\?JFIF\0 pipe /usr/bin/djpeg -pnm
71
72 # TIFF files (the last two bytes of the "magic" is really a version number;
73 # but the magic is really lame and as far as I have understood the version
74 # number has never changed and never will, so we include it.)
75 0 MM\0\x2a fpipe /usr/bin/tiff2ps $FILE
76 0 II\x2a\0 fpipe /usr/bin/tiff2ps $FILE
77
78 # BMP files (even lousier magic -- Microsoft strikes again!)
79 0 BM\?\?\?\?\?\?\?\?\?\?\?\?\x0c pipe \
80 /usr/bin/bmptoppm 2>/dev/null
81 0 BM\?\?\?\?\?\?\?\?\?\?\?\?\x40 pipe \
82 /usr/bin/bmptoppm 2>/dev/null
83 0 BM\?\?\?\?\?\?\?\?\?\?\?\?\x28 pipe \
84 /usr/bin/bmptoppm 2>/dev/null
85
86 # Garbage delivered from Windows via Samba
87 # (donated by Andree Leidenfrost <leidenfrost@dkrz.de>)
88 # 300 \033\052\157 cat
89 # later changed to
90 # (Bug report #22866: magicfilter: Incorrect magic for Win95/Samba print jobs)
91 0 \000\000\000\000\000 cat
92
93 # Sun rasterfiles
94 0 \x59\xa6\x6a\x95 pipe /usr/bin/rasttopnm 2>/dev/null
95
96 # SGI Imagelib (IRIS RGB) files
97 0 \x1\xda pipe /usr/bin/sgitopnm 2>/dev/null
98 0 \xda\x1 pipe /usr/bin/sgitopnm 2>/dev/null
99
100 # FIG files; reported by Steven P. Hill <sph@uscbu.ih.att.com>
101 0 #FIG pipe /usr/bin/X11/fig2dev -Lps -P -l dummy
102
103 #
104 # Standard rejects... things we don't want to print
105 #
106
107 # Various archive formats
108 257 ustar\0 reject Attempted to print a tar file.
109 257 "ustar \0" reject Attempted to print a tar file.
110 0 07070 reject Attempted to print a cpio file.
111 0 PK\3\4 reject Attempted to print a zip file.
112 20 \xdc\xa7\xc7\xfd reject Attempted to print a zoo file.
113
114 # Binaries (Linux): reject with email message
115 0 \013\1d\0 reject Attempted to print a compiled binary.
116 0 \100\1d\0 reject Attempted to print a compiled binary.
117 0 \007\1d\0 reject Attempted to print a compiled binary.
118 0 \314\0d\0 reject Attempted to print a compiled binary.
119 0 \177ELF reject Attempted to print an ELF object.
120 0 \007\001\0 reject Attempted to print an object file.
121 216 \021\001\0\0 reject Attempted to print a core dump file.
122 0 !<arch> reject Attempted to print an archive.
123 0 =<ar> reject Attempted to print an archive.
124
125 # Don't confuse this one with troff!
126 0 .snd reject Attempted to print Sun/NeXT audio data.
127
128 # wacko troff magic
129 0 ''' fpipe `/usr/bin/grog -Tps $FILE`
130
131 # wild guess: PCL control codes start with <ESC>
132 0 \033 reject Cannot print PCL files on this printer.
133
134 # Default entry -- for normal (text) files. MUST BE LAST.
135 # If you do not have djscript use the other default line or, better, install
136 # it. MM
137 #
138 default pipe /usr/bin/enscript -B -p-
0 #!/usr/sbin/magicfilter
1 #
2 # Magic filter setup file for HP printers 720, 820 and 1000 series.
3
4 # pnm2ppa supports color and black/white printing. This file was
5 # tested on a HP Deskjet 720C printer, but is supposed to work on
6 # other printers using the HP PPA protocol, too. Supported pagesizes
7 # are a4, letter and legal. The pagesize has to be set in /etc/papersize
8 # and not in the configuration files in /etc/ppa/pnm2ppa.conf.hp*.
9
10 # Adapted from dj500-filter, cpsonly600-filter and pbm2ppa-filter
11 # by Roland Bauerschmidt <roland@copyleft.de>, 2000
12
13 # PostScript
14 0 %! fpipe /usr/bin/gs -q -dSAFER -dNOPAUSE -r600 -sDEVICE=ppmraw -sOutputFile=- - -c quit
15 0 \004%! fpipe /usr/bin/gs -q -dSAFER -dNOPAUSE -r600 -sDEVICE=ppmraw -sOutputFile=- - -c quit
16
17 # PDF
18 0 %PDF fpipe /usr/bin/gs -q -dSAFER -dNOPAUSE -r600 -sDEVICE=ppmraw -sOutputFile=- $FILE -c quit
19
20
21 # TeX DVI
22 0 \367\002 fpipe /usr/bin/dvips -D 600 -R -q -f
23
24 # compress'd data
25 0 \037\235 pipe /bin/gzip -cdq
26
27 # packed, gzipped, frozen and SCO LZH data
28 0 \037\036 pipe /bin/gzip -cdq
29 0 \037\213 pipe /bin/gzip -cdq
30 0 \037\236 pipe /bin/gzip -cdq
31 0 \037\240 pipe /bin/gzip -cdq
32
33 # troff documents
34 0 .\?\?\040 fpipe `/usr/bin/grog -Tps $FILE`
35 0 .\\\" fpipe `/usr/bin/grog -Tps $FILE`
36 0 '\\\" fpipe `/usr/bin/grog -Tps $FILE`
37 0 '.\\\" fpipe `/usr/bin/grog -Tps $FILE`
38 0 \\\" fpipe `/usr/bin/grog -Tps $FILE`
39
40 # ditroff
41 0 "x T ps" pipe /usr/bin/grops
42 0 "x T dvi" pipe /usr/bin/grodvi
43 0 "x T ascii" pipe /usr/bin/grotty
44 0 "x T latin1" pipe /usr/bin/grotty
45 0 "x T lj4" reject Cannot print LaserJet 4 ditroff files.
46
47 # Portable bit-, grey- and pixmaps
48 0 P1\n pipe /usr/bin/pnmtops -scale 1000 -dpi 600 2>/dev/null
49 0 P2\n pipe /usr/bin/pnmtops -scale 1000 -dpi 600 2>/dev/null
50 0 P3\n pipe /usr/bin/pnmtops -scale 1000 -dpi 600 2>/dev/null
51 0 P4\n pipe /usr/bin/pnmtops -scale 1000 -dpi 600 2>/dev/null
52 0 P5\n pipe /usr/bin/pnmtops -scale 1000 -dpi 600 2>/dev/null
53 0 P6\n filter /usr/bin/pnm2ppa --eco -f /etc/ppa/pnm2ppa.conf.hp820 -i - -o -
54
55 # HP Printer Control Language (PCL) -- assume start with reset code
56 0 \033E\033 reject Cannot print PCL files on this printer.
57
58 # HP Printer Job Language (PJL)
59 0 \033%-12345X reject Cannot print PJL files on this printer.
60 0 "@PJL " reject Cannot print PJL files on this printer.
61 0 @PJL\t reject Cannot print PJL files on this printer.
62 0 @PJL\r reject Cannot print PJL files on this printer.
63 0 @PJL\n reject Cannot print PJL files on this printer.
64
65 # GIF files
66 0 GIF87a pipe /usr/bin/giftopnm 2>/dev/null
67 0 GIF89a pipe /usr/bin/giftopnm 2>/dev/null
68
69 # JFIF (JPEG) files
70 0 \377\330\377\340\?\?JFIF\0 pipe /usr/bin/djpeg -pnm
71
72 # TIFF files (the last two bytes of the "magic" is really a version number;
73 # but the magic is really lame and as far as I have understood the version
74 # number has never changed and never will, so we include it.)
75 0 MM\0\x2a fpipe /usr/bin/tiff2ps $FILE
76 0 II\x2a\0 fpipe /usr/bin/tiff2ps $FILE
77
78 # BMP files (even lousier magic -- Microsoft strikes again!)
79 0 BM\?\?\?\?\?\?\?\?\?\?\?\?\x0c pipe \
80 /usr/bin/bmptoppm 2>/dev/null
81 0 BM\?\?\?\?\?\?\?\?\?\?\?\?\x40 pipe \
82 /usr/bin/bmptoppm 2>/dev/null
83 0 BM\?\?\?\?\?\?\?\?\?\?\?\?\x28 pipe \
84 /usr/bin/bmptoppm 2>/dev/null
85
86 # Garbage delivered from Windows via Samba
87 # (donated by Andree Leidenfrost <leidenfrost@dkrz.de>)
88 # 300 \033\052\157 cat
89 # later changed to
90 # (Bug report #22866: magicfilter: Incorrect magic for Win95/Samba print jobs)
91 0 \000\000\000\000\000 cat
92
93 # Sun rasterfiles
94 0 \x59\xa6\x6a\x95 pipe /usr/bin/rasttopnm 2>/dev/null
95
96 # SGI Imagelib (IRIS RGB) files
97 0 \x1\xda pipe /usr/bin/sgitopnm 2>/dev/null
98 0 \xda\x1 pipe /usr/bin/sgitopnm 2>/dev/null
99
100 # FIG files; reported by Steven P. Hill <sph@uscbu.ih.att.com>
101 0 #FIG pipe /usr/bin/X11/fig2dev -Lps -P -l dummy
102
103 #
104 # Standard rejects... things we don't want to print
105 #
106
107 # Various archive formats
108 257 ustar\0 reject Attempted to print a tar file.
109 257 "ustar \0" reject Attempted to print a tar file.
110 0 07070 reject Attempted to print a cpio file.
111 0 PK\3\4 reject Attempted to print a zip file.
112 20 \xdc\xa7\xc7\xfd reject Attempted to print a zoo file.
113
114 # Binaries (Linux): reject with email message
115 0 \013\1d\0 reject Attempted to print a compiled binary.
116 0 \100\1d\0 reject Attempted to print a compiled binary.
117 0 \007\1d\0 reject Attempted to print a compiled binary.
118 0 \314\0d\0 reject Attempted to print a compiled binary.
119 0 \177ELF reject Attempted to print an ELF object.
120 0 \007\001\0 reject Attempted to print an object file.
121 216 \021\001\0\0 reject Attempted to print a core dump file.
122 0 !<arch> reject Attempted to print an archive.
123 0 =<ar> reject Attempted to print an archive.
124
125 # Don't confuse this one with troff!
126 0 .snd reject Attempted to print Sun/NeXT audio data.
127
128 # wacko troff magic
129 0 ''' fpipe `/usr/bin/grog -Tps $FILE`
130
131 # wild guess: PCL control codes start with <ESC>
132 0 \033 reject Cannot print PCL files on this printer.
133
134 # Default entry -- for normal (text) files. MUST BE LAST.
135 # If you do not have djscript use the other default line or, better, install
136 # it. MM
137 #
138 default pipe /usr/bin/enscript -B -p-
0 #!/usr/sbin/magicfilter
1 #
2 # Magic filter setup file for HP printers 720, 820 and 1000 series.
3
4 # pnm2ppa supports color and black/white printing. This file was
5 # tested on a HP Deskjet 720C printer, but is supposed to work on
6 # other printers using the HP PPA protocol, too. Supported pagesizes
7 # are a4, letter and legal. The pagesize has to be set in /etc/papersize
8 # and not in the configuration files in /etc/ppa/pnm2ppa.conf.hp*.
9
10 # Adapted from dj500-filter, cpsonly600-filter and pbm2ppa-filter
11 # by Roland Bauerschmidt <roland@copyleft.de>, 2000
12
13 # PostScript
14 0 %! fpipe /usr/bin/gs -q -dSAFER -dNOPAUSE -r600 -sDEVICE=ppmraw -sOutputFile=- - -c quit
15 0 \004%! fpipe /usr/bin/gs -q -dSAFER -dNOPAUSE -r600 -sDEVICE=ppmraw -sOutputFile=- - -c quit
16
17 # PDF
18 0 %PDF fpipe /usr/bin/gs -q -dSAFER -dNOPAUSE -r600 -sDEVICE=ppmraw -sOutputFile=- $FILE -c quit
19
20
21 # TeX DVI
22 0 \367\002 fpipe /usr/bin/dvips -D 600 -R -q -f
23
24 # compress'd data
25 0 \037\235 pipe /bin/gzip -cdq
26
27 # packed, gzipped, frozen and SCO LZH data
28 0 \037\036 pipe /bin/gzip -cdq
29 0 \037\213 pipe /bin/gzip -cdq
30 0 \037\236 pipe /bin/gzip -cdq
31 0 \037\240 pipe /bin/gzip -cdq
32
33 # troff documents
34 0 .\?\?\040 fpipe `/usr/bin/grog -Tps $FILE`
35 0 .\\\" fpipe `/usr/bin/grog -Tps $FILE`
36 0 '\\\" fpipe `/usr/bin/grog -Tps $FILE`
37 0 '.\\\" fpipe `/usr/bin/grog -Tps $FILE`
38 0 \\\" fpipe `/usr/bin/grog -Tps $FILE`
39
40 # ditroff
41 0 "x T ps" pipe /usr/bin/grops
42 0 "x T dvi" pipe /usr/bin/grodvi
43 0 "x T ascii" pipe /usr/bin/grotty
44 0 "x T latin1" pipe /usr/bin/grotty
45 0 "x T lj4" reject Cannot print LaserJet 4 ditroff files.
46
47 # Portable bit-, grey- and pixmaps
48 0 P1\n pipe /usr/bin/pnmtops -scale 1000 -dpi 600 2>/dev/null
49 0 P2\n pipe /usr/bin/pnmtops -scale 1000 -dpi 600 2>/dev/null
50 0 P3\n pipe /usr/bin/pnmtops -scale 1000 -dpi 600 2>/dev/null
51 0 P4\n pipe /usr/bin/pnmtops -scale 1000 -dpi 600 2>/dev/null
52 0 P5\n pipe /usr/bin/pnmtops -scale 1000 -dpi 600 2>/dev/null
53 0 P6\n filter /usr/bin/pnm2ppa -f /etc/ppa/pnm2ppa.conf.hp820 -i - -o -
54
55 # HP Printer Control Language (PCL) -- assume start with reset code
56 0 \033E\033 reject Cannot print PCL files on this printer.
57
58 # HP Printer Job Language (PJL)
59 0 \033%-12345X reject Cannot print PJL files on this printer.
60 0 "@PJL " reject Cannot print PJL files on this printer.
61 0 @PJL\t reject Cannot print PJL files on this printer.
62 0 @PJL\r reject Cannot print PJL files on this printer.
63 0 @PJL\n reject Cannot print PJL files on this printer.
64
65 # GIF files
66 0 GIF87a pipe /usr/bin/giftopnm 2>/dev/null
67 0 GIF89a pipe /usr/bin/giftopnm 2>/dev/null
68
69 # JFIF (JPEG) files
70 0 \377\330\377\340\?\?JFIF\0 pipe /usr/bin/djpeg -pnm
71
72 # TIFF files (the last two bytes of the "magic" is really a version number;
73 # but the magic is really lame and as far as I have understood the version
74 # number has never changed and never will, so we include it.)
75 0 MM\0\x2a fpipe /usr/bin/tiff2ps $FILE
76 0 II\x2a\0 fpipe /usr/bin/tiff2ps $FILE
77
78 # BMP files (even lousier magic -- Microsoft strikes again!)
79 0 BM\?\?\?\?\?\?\?\?\?\?\?\?\x0c pipe \
80 /usr/bin/bmptoppm 2>/dev/null
81 0 BM\?\?\?\?\?\?\?\?\?\?\?\?\x40 pipe \
82 /usr/bin/bmptoppm 2>/dev/null
83 0 BM\?\?\?\?\?\?\?\?\?\?\?\?\x28 pipe \
84 /usr/bin/bmptoppm 2>/dev/null
85
86 # Garbage delivered from Windows via Samba
87 # (donated by Andree Leidenfrost <leidenfrost@dkrz.de>)
88 # 300 \033\052\157 cat
89 # later changed to
90 # (Bug report #22866: magicfilter: Incorrect magic for Win95/Samba print jobs)
91 0 \000\000\000\000\000 cat
92
93 # Sun rasterfiles
94 0 \x59\xa6\x6a\x95 pipe /usr/bin/rasttopnm 2>/dev/null
95
96 # SGI Imagelib (IRIS RGB) files
97 0 \x1\xda pipe /usr/bin/sgitopnm 2>/dev/null
98 0 \xda\x1 pipe /usr/bin/sgitopnm 2>/dev/null
99
100 # FIG files; reported by Steven P. Hill <sph@uscbu.ih.att.com>
101 0 #FIG pipe /usr/bin/X11/fig2dev -Lps -P -l dummy
102
103 #
104 # Standard rejects... things we don't want to print
105 #
106
107 # Various archive formats
108 257 ustar\0 reject Attempted to print a tar file.
109 257 "ustar \0" reject Attempted to print a tar file.
110 0 07070 reject Attempted to print a cpio file.
111 0 PK\3\4 reject Attempted to print a zip file.
112 20 \xdc\xa7\xc7\xfd reject Attempted to print a zoo file.
113
114 # Binaries (Linux): reject with email message
115 0 \013\1d\0 reject Attempted to print a compiled binary.
116 0 \100\1d\0 reject Attempted to print a compiled binary.
117 0 \007\1d\0 reject Attempted to print a compiled binary.
118 0 \314\0d\0 reject Attempted to print a compiled binary.
119 0 \177ELF reject Attempted to print an ELF object.
120 0 \007\001\0 reject Attempted to print an object file.
121 216 \021\001\0\0 reject Attempted to print a core dump file.
122 0 !<arch> reject Attempted to print an archive.
123 0 =<ar> reject Attempted to print an archive.
124
125 # Don't confuse this one with troff!
126 0 .snd reject Attempted to print Sun/NeXT audio data.
127
128 # wacko troff magic
129 0 ''' fpipe `/usr/bin/grog -Tps $FILE`
130
131 # wild guess: PCL control codes start with <ESC>
132 0 \033 reject Cannot print PCL files on this printer.
133
134 # Default entry -- for normal (text) files. MUST BE LAST.
135 # If you do not have djscript use the other default line or, better, install
136 # it. MM
137 #
138 default pipe /usr/bin/enscript -B -p-
0 # Sample configuration file
1 #
2 # This file will be automatically read upon startup if it is placed in
3 # /etc/pnm2ppa.conf
4 #
5 # uncomment entries by removing "#" to activate them.
6 #
7 #-----------set the printer model---------------------------
8 # YOU MUST CHOOSE ONE OF THE FOLLOWING, EVEN IF YOU DO NOTHING ELSE!
9 #
10 # If there is more than one "version" entry activated, the last one
11 # will be used. The printer version can also be set with the command line
12 # option e.g., "-v 720".
13
14 #version ERROR # PNM2PPA WIIL *NOT* WORK UNTIUL THIS ENTRY IS REMOVED!!!!
15 #version 720 # 710, 712, 722 also acceptable
16 #version 820
17 version 1000
18
19
20 #--------control system log messages from pnm2ppa-------------------
21 # pnm2ppa issues progress and error messages to the system log (syslog).
22 # For security reasons, no input from the user is ever sent to the syslog.
23 # The setting "silent 1" suppresses messages to the syslog. The
24 # setting "verbose 1" sends messages to the standard error stream (stderr)
25 # in addition to the syslog. (Note: on BeOS, syslog messages are
26 # diverted to stderr; use "silent 1" to suppress them.)
27 # Note: the "silent 1" keyword is only accepted from the system
28 # configuration file (/etc/pnm2ppa.conf), and not from configuration files
29 # specified with the pnm2ppa option "-f".
30
31 #silent 1
32 #verbose 1
33
34 #---------set the margins of the printed page-------------------
35 # Margins: these are distances from the edges of the paper in
36 # "dots" ( 600 dots = 1 inch = 2.54 cm).
37 # Nothing outside these margins will be printed.
38 # Default values are give below; uncomment and change, if necessary.
39 # (Older versions of pnm2ppa required larger left and right margins to avoid
40 # printer failure with "flashing lights", but this problem is believed to
41 # be solved)
42
43 #topmargin 10
44 #bottommargin 150
45 #leftmargin 10
46 #rightmargin 10
47
48 #----------center the printer output on the paper-------------------
49 # Offsets: these are adjustments for centering the print correctly on the
50 # paper. Units are dots (1/600 inch). Add a positive number of dots to
51 # xoff to move the printed image to the right, relative to the paper.
52 # add to yoff to move it down. The helper program calibrate_ppa prints
53 # a test page to check the offsets (see CALIBRATON.txt):
54 # usage: "calibrate_ppa --center | pnm2ppa --bw - - | lpr -l
55 # Default values are:
56
57 #xoffset 160
58 #yoffset 50
59
60 #------------align the black and color ink cartridges--------
61 # Color Offsets: these control alignment between the black ink
62 # and color ink print cartridges. This changes a little whenever you
63 # replace an ink cartridge, so the default values are just approximate.
64 #
65 # Use "calibrate_ppa --align | pnm2ppa --fd - - | lpr -l "
66 # to print a test page to help you adjust the color offsets.
67 #
68 # The first line checks horizontal alignment ColOffsX,:
69 # The second line checks vertical alignment ColOffsY,:
70 # The alignment is correct if alignment patterns "0" is best.
71 # If a diffent alignment pattern is best, add or subtract the + or
72 # - value shown below it to ColOffsX or ColOffSy.
73 #
74 # See CALIBRATION.txt for more details.
75 # Use "calibrate_ppa --test | pnm2ppa --fd - - | lpr -l " to check your
76 # new settings.
77
78 #ColOffsX 0
79 #ColOffsY 0
80
81 #---------------"shearing" corrections-------------------------------------
82 # shearing correction (for bidirectional printing modes)
83 # if there is a horizontal offset between right-to-left and left-to-right
84 # sweeps of the print head, adjust these in units of 1"/600 (1 dot).
85 # There are separate corrections colorshear and blackshear for the
86 # color and black print heads. The third and fourth lines of the
87 # alignment test page (see above) tests these.
88 # The setting is correct when alignments "0" are correct.
89 # Add or subtract the + or - number shown under the best-aligned shearing
90 # alignment pattern.
91
92 #colorshear 0
93 #blackshear 0
94
95 #-------------blackness control-----------------------------
96 # this controls the density of black ink used.
97 # valid blackness choices are 1 2 3 4; controls the
98 # density of black ink used: 1 (least ink), 2 (default), 4 (most).
99 # 0 = no black ink. This affects black ink bordered by whitespace
100 # only (e.g. text, but not black in color images)
101
102 #blackness 2
103
104 #------------Color correct curve Gamma parameters-------------------------
105 # Gamma color correction values for Red, Green and Blue:
106 # (Note: a more effective method of color correction is to use
107 # a calibration file /etc/pnm2ppa.gamma, in which case these
108 # Gamma values will not be used. See COLOR.html or COLOR.txt)
109 # The pnm2ppa option --noGamma suppresses color correction.
110
111 # The standard Gamma enhancement curve is
112 # gEnh(i) = (int) ( pow ( (double) i / 256, Gamma ) * 256 )
113 # (i.e., 256 times ( i*(1.0/256)) to the power Gamma ),
114 # where (int) i is the ppm color intensity, in the range 0 - 255.
115 # positive values of Gamma enhance (increase the intensity of)
116 # the corresponding color. Gamma = 1.0 corresponds to no
117 # color correction, gEnh[i] = i.
118
119 # You can specify Gamma values as a decimal number for each primary color
120
121 #GammaR 1.0 # red enhancement
122 #GammaG 1.0 # green enhancement
123 #GammaB 1.0 # blue enhancement
124
125 # For use with the printed output of "pnm2ppa -g ",
126 # you can also specify Gamma values using the integer GammaIdx,
127 # which gives Gamma = 1.0 - 0.033 * GammaIdx :
128
129 #RedGammaIdx 0
130 #GreenGammaIdx 0
131 #BlueGammaIdx 0
132
133 # Default papersize (only used for printing the color calibration
134 # test page with pnm2ppa -g).
135 # Valid choices are: a4, letter, legal:
136
137 #papersize letter # this is the default
138 #papersize legal
139 #papersize a4
140
141 #-----------suppress bidirectional printing---------------------
142
143 # by default the printing sweeps are now bidirectional (unimode 0);
144 # to make unidirectional printing (left-to-right) the default behavior,
145 # (unimode 1) uncomment the next line . (The command line options --uni
146 # and --bi override the default behavior). You might wish to print
147 # unidirectionally to avoid shearing effects in high-quality
148 # color images, for example)
149
150 #unimode 1
151
152 #=====================================================================
153 # the following are switches for debugging purposes only:
154 # set their values to 0 to switch off the corresponding ink type:
155
156 #black_ink 1
157 #color_ink 1
158 #cyan_ink 1
159 #magenta_ink 1
160 #yellow_ink 1
0 # Sample configuration file
1 #
2 # This file will be automatically read upon startup if it is placed in
3 # /etc/pnm2ppa.conf
4 #
5 # uncomment entries by removing "#" to activate them.
6 #
7 #-----------set the printer model---------------------------
8 # YOU MUST CHOOSE ONE OF THE FOLLOWING, EVEN IF YOU DO NOTHING ELSE!
9 #
10 # If there is more than one "version" entry activated, the last one
11 # will be used. The printer version can also be set with the command line
12 # option e.g., "-v 720".
13
14 #version ERROR # PNM2PPA WIIL *NOT* WORK UNTIUL THIS ENTRY IS REMOVED!!!!
15 version 720 # 710, 712, 722 also acceptable
16 #version 820
17 #version 1000
18
19
20 #--------control system log messages from pnm2ppa-------------------
21 # pnm2ppa issues progress and error messages to the system log (syslog).
22 # For security reasons, no input from the user is ever sent to the syslog.
23 # The setting "silent 1" suppresses messages to the syslog. The
24 # setting "verbose 1" sends messages to the standard error stream (stderr)
25 # in addition to the syslog. (Note: on BeOS, syslog messages are
26 # diverted to stderr; use "silent 1" to suppress them.)
27 # Note: the "silent 1" keyword is only accepted from the system
28 # configuration file (/etc/pnm2ppa.conf), and not from configuration files
29 # specified with the pnm2ppa option "-f".
30
31 #silent 1
32 #verbose 1
33
34 #---------set the margins of the printed page-------------------
35 # Margins: these are distances from the edges of the paper in
36 # "dots" ( 600 dots = 1 inch = 2.54 cm).
37 # Nothing outside these margins will be printed.
38 # Default values are give below; uncomment and change, if necessary.
39 # (Older versions of pnm2ppa required larger left and right margins to avoid
40 # printer failure with "flashing lights", but this problem is believed to
41 # be solved)
42
43 #topmargin 10
44 #bottommargin 150
45 #leftmargin 10
46 #rightmargin 10
47
48 #----------center the printer output on the paper-------------------
49 # Offsets: these are adjustments for centering the print correctly on the
50 # paper. Units are dots (1/600 inch). Add a positive number of dots to
51 # xoff to move the printed image to the right, relative to the paper.
52 # add to yoff to move it down. The helper program calibrate_ppa prints
53 # a test page to check the offsets (see CALIBRATON.txt):
54 # usage: "calibrate_ppa --center | pnm2ppa --bw - - | lpr -l
55 # Default values are:
56
57 #xoffset 160
58 #yoffset 50
59
60 #------------align the black and color ink cartridges--------
61 # Color Offsets: these control alignment between the black ink
62 # and color ink print cartridges. This changes a little whenever you
63 # replace an ink cartridge, so the default values are just approximate.
64 #
65 # Use "calibrate_ppa --align | pnm2ppa --fd - - | lpr -l "
66 # to print a test page to help you adjust the color offsets.
67 #
68 # The first line checks horizontal alignment ColOffsX,:
69 # The second line checks vertical alignment ColOffsY,:
70 # The alignment is correct if alignment patterns "0" is best.
71 # If a diffent alignment pattern is best, add or subtract the + or
72 # - value shown below it to ColOffsX or ColOffSy.
73 #
74 # See CALIBRATION.txt for more details.
75 # Use "calibrate_ppa --test | pnm2ppa --fd - - | lpr -l " to check your
76 # new settings.
77
78 #ColOffsX 0
79 #ColOffsY 0
80
81 #---------------"shearing" corrections-------------------------------------
82 # shearing correction (for bidirectional printing modes)
83 # if there is a horizontal offset between right-to-left and left-to-right
84 # sweeps of the print head, adjust these in units of 1"/600 (1 dot).
85 # There are separate corrections colorshear and blackshear for the
86 # color and black print heads. The third and fourth lines of the
87 # alignment test page (see above) tests these.
88 # The setting is correct when alignments "0" are correct.
89 # Add or subtract the + or - number shown under the best-aligned shearing
90 # alignment pattern.
91
92 #colorshear 0
93 #blackshear 0
94
95 #-------------blackness control-----------------------------
96 # this controls the density of black ink used.
97 # valid blackness choices are 1 2 3 4; controls the
98 # density of black ink used: 1 (least ink), 2 (default), 4 (most).
99 # 0 = no black ink. This affects black ink bordered by whitespace
100 # only (e.g. text, but not black in color images)
101
102 #blackness 2
103
104 #------------Color correct curve Gamma parameters-------------------------
105 # Gamma color correction values for Red, Green and Blue:
106 # (Note: a more effective method of color correction is to use
107 # a calibration file /etc/pnm2ppa.gamma, in which case these
108 # Gamma values will not be used. See COLOR.html or COLOR.txt)
109 # The pnm2ppa option --noGamma suppresses color correction.
110
111 # The standard Gamma enhancement curve is
112 # gEnh(i) = (int) ( pow ( (double) i / 256, Gamma ) * 256 )
113 # (i.e., 256 times ( i*(1.0/256)) to the power Gamma ),
114 # where (int) i is the ppm color intensity, in the range 0 - 255.
115 # positive values of Gamma enhance (increase the intensity of)
116 # the corresponding color. Gamma = 1.0 corresponds to no
117 # color correction, gEnh[i] = i.
118
119 # You can specify Gamma values as a decimal number for each primary color
120
121 #GammaR 1.0 # red enhancement
122 #GammaG 1.0 # green enhancement
123 #GammaB 1.0 # blue enhancement
124
125 # For use with the printed output of "pnm2ppa -g ",
126 # you can also specify Gamma values using the integer GammaIdx,
127 # which gives Gamma = 1.0 - 0.033 * GammaIdx :
128
129 #RedGammaIdx 0
130 #GreenGammaIdx 0
131 #BlueGammaIdx 0
132
133 # Default papersize (only used for printing the color calibration
134 # test page with pnm2ppa -g).
135 # Valid choices are: a4, letter, legal:
136
137 #papersize letter # this is the default
138 #papersize legal
139 #papersize a4
140
141 #-----------suppress bidirectional printing---------------------
142
143 # by default the printing sweeps are now bidirectional (unimode 0);
144 # to make unidirectional printing (left-to-right) the default behavior,
145 # (unimode 1) uncomment the next line . (The command line options --uni
146 # and --bi override the default behavior). You might wish to print
147 # unidirectionally to avoid shearing effects in high-quality
148 # color images, for example)
149
150 #unimode 1
151
152 #=====================================================================
153 # the following are switches for debugging purposes only:
154 # set their values to 0 to switch off the corresponding ink type:
155
156 #black_ink 1
157 #color_ink 1
158 #cyan_ink 1
159 #magenta_ink 1
160 #yellow_ink 1
0 # Sample configuration file
1 #
2 # This file will be automatically read upon startup if it is placed in
3 # /etc/pnm2ppa.conf
4 #
5 # uncomment entries by removing "#" to activate them.
6 #
7 #-----------set the printer model---------------------------
8 # YOU MUST CHOOSE ONE OF THE FOLLOWING, EVEN IF YOU DO NOTHING ELSE!
9 #
10 # If there is more than one "version" entry activated, the last one
11 # will be used. The printer version can also be set with the command line
12 # option e.g., "-v 720".
13
14 #version ERROR # PNM2PPA WIIL *NOT* WORK UNTIUL THIS ENTRY IS REMOVED!!!!
15 #version 720 # 710, 712, 722 also acceptable
16 version 820
17 #version 1000
18
19
20 #--------control system log messages from pnm2ppa-------------------
21 # pnm2ppa issues progress and error messages to the system log (syslog).
22 # For security reasons, no input from the user is ever sent to the syslog.
23 # The setting "silent 1" suppresses messages to the syslog. The
24 # setting "verbose 1" sends messages to the standard error stream (stderr)
25 # in addition to the syslog. (Note: on BeOS, syslog messages are
26 # diverted to stderr; use "silent 1" to suppress them.)
27 # Note: the "silent 1" keyword is only accepted from the system
28 # configuration file (/etc/pnm2ppa.conf), and not from configuration files
29 # specified with the pnm2ppa option "-f".
30
31 #silent 1
32 #verbose 1
33
34 #---------set the margins of the printed page-------------------
35 # Margins: these are distances from the edges of the paper in
36 # "dots" ( 600 dots = 1 inch = 2.54 cm).
37 # Nothing outside these margins will be printed.
38 # Default values are give below; uncomment and change, if necessary.
39 # (Older versions of pnm2ppa required larger left and right margins to avoid
40 # printer failure with "flashing lights", but this problem is believed to
41 # be solved)
42
43 #topmargin 10
44 #bottommargin 150
45 #leftmargin 10
46 #rightmargin 10
47
48 #----------center the printer output on the paper-------------------
49 # Offsets: these are adjustments for centering the print correctly on the
50 # paper. Units are dots (1/600 inch). Add a positive number of dots to
51 # xoff to move the printed image to the right, relative to the paper.
52 # add to yoff to move it down. The helper program calibrate_ppa prints
53 # a test page to check the offsets (see CALIBRATON.txt):
54 # usage: "calibrate_ppa --center | pnm2ppa --bw - - | lpr -l
55 # Default values are:
56
57 #xoffset 160
58 #yoffset 50
59
60 #------------align the black and color ink cartridges--------
61 # Color Offsets: these control alignment between the black ink
62 # and color ink print cartridges. This changes a little whenever you
63 # replace an ink cartridge, so the default values are just approximate.
64 #
65 # Use "calibrate_ppa --align | pnm2ppa --fd - - | lpr -l "
66 # to print a test page to help you adjust the color offsets.
67 #
68 # The first line checks horizontal alignment ColOffsX,:
69 # The second line checks vertical alignment ColOffsY,:
70 # The alignment is correct if alignment patterns "0" is best.
71 # If a diffent alignment pattern is best, add or subtract the + or
72 # - value shown below it to ColOffsX or ColOffSy.
73 #
74 # See CALIBRATION.txt for more details.
75 # Use "calibrate_ppa --test | pnm2ppa --fd - - | lpr -l " to check your
76 # new settings.
77
78 #ColOffsX 0
79 #ColOffsY 0
80
81 #---------------"shearing" corrections-------------------------------------
82 # shearing correction (for bidirectional printing modes)
83 # if there is a horizontal offset between right-to-left and left-to-right
84 # sweeps of the print head, adjust these in units of 1"/600 (1 dot).
85 # There are separate corrections colorshear and blackshear for the
86 # color and black print heads. The third and fourth lines of the
87 # alignment test page (see above) tests these.
88 # The setting is correct when alignments "0" are correct.
89 # Add or subtract the + or - number shown under the best-aligned shearing
90 # alignment pattern.
91
92 #colorshear 0
93 #blackshear 0
94
95 #-------------blackness control-----------------------------
96 # this controls the density of black ink used.
97 # valid blackness choices are 1 2 3 4; controls the
98 # density of black ink used: 1 (least ink), 2 (default), 4 (most).
99 # 0 = no black ink. This affects black ink bordered by whitespace
100 # only (e.g. text, but not black in color images)
101
102 #blackness 2
103
104 #------------Color correct curve Gamma parameters-------------------------
105 # Gamma color correction values for Red, Green and Blue:
106 # (Note: a more effective method of color correction is to use
107 # a calibration file /etc/pnm2ppa.gamma, in which case these
108 # Gamma values will not be used. See COLOR.html or COLOR.txt)
109 # The pnm2ppa option --noGamma suppresses color correction.
110
111 # The standard Gamma enhancement curve is
112 # gEnh(i) = (int) ( pow ( (double) i / 256, Gamma ) * 256 )
113 # (i.e., 256 times ( i*(1.0/256)) to the power Gamma ),
114 # where (int) i is the ppm color intensity, in the range 0 - 255.
115 # positive values of Gamma enhance (increase the intensity of)
116 # the corresponding color. Gamma = 1.0 corresponds to no
117 # color correction, gEnh[i] = i.
118
119 # You can specify Gamma values as a decimal number for each primary color
120
121 #GammaR 1.0 # red enhancement
122 #GammaG 1.0 # green enhancement
123 #GammaB 1.0 # blue enhancement
124
125 # For use with the printed output of "pnm2ppa -g ",
126 # you can also specify Gamma values using the integer GammaIdx,
127 # which gives Gamma = 1.0 - 0.033 * GammaIdx :
128
129 #RedGammaIdx 0
130 #GreenGammaIdx 0
131 #BlueGammaIdx 0
132
133 # Default papersize (only used for printing the color calibration
134 # test page with pnm2ppa -g).
135 # Valid choices are: a4, letter, legal:
136
137 #papersize letter # this is the default
138 #papersize legal
139 #papersize a4
140
141 #-----------suppress bidirectional printing---------------------
142
143 # by default the printing sweeps are now bidirectional (unimode 0);
144 # to make unidirectional printing (left-to-right) the default behavior,
145 # (unimode 1) uncomment the next line . (The command line options --uni
146 # and --bi override the default behavior). You might wish to print
147 # unidirectionally to avoid shearing effects in high-quality
148 # color images, for example)
149
150 #unimode 1
151
152 #=====================================================================
153 # the following are switches for debugging purposes only:
154 # set their values to 0 to switch off the corresponding ink type:
155
156 #black_ink 1
157 #color_ink 1
158 #cyan_ink 1
159 #magenta_ink 1
160 #yellow_ink 1
0 debian/pnm2ppa.8
1 debian/calibrate_ppa.8
0 .\" Hey, EMACS: -*- nroff -*-
1 .\" First parameter, NAME, should be all caps
2 .\" Second parameter, SECTION, should be 1-8, maybe w/ subsection
3 .\" other parameters are allowed: see man(7), man(1)
4 .TH pnm2ppa 8 "November 2000"
5 .\" Please adjust this date whenever revising the manpage.
6 .\"
7 .\" Some roff macros, for reference:
8 .\" .nh disable hyphenation
9 .\" .hy enable hyphenation
10 .\" .ad l left justify
11 .\" .ad b justify to both left and right margins
12 .\" .nf disable filling
13 .\" .fi enable filling
14 .\" .br insert line break
15 .\" .sp <n> insert n+1 empty lines
16 .\" for manpage-specific macros, see man(7)
17 .\"
18 .SH NAME
19 pnm2ppa \- PPM to PPA converter
20 .SH SYNOPSIS
21 .B pnm2ppa
22 .RI [options]
23 .SH DESCRIPTION
24 Using pnm2ppa it's possible to run HP-GDI printers on Linux. These printers are normally "Windows-only" and use the PPA protocol which is proprietary. pnm2ppa supports color and is supposed to work faster than pbm2ppa. pnm2ppa supports the following printers: HP Deskjet 7XX Series, HP Deskjet 820 Series and HP Deskjet 1000 Series.
25 .SH OPTIONS
26 .TP
27 .B \-b <margin>
28 bottom margin in 1"/600 (default: 150 = 0.25")
29 .TP
30 .B \-\-bi
31 forces bidirectional print head sweeps
32 .TP
33 .B \-B <n>
34 density of black ink (n = 0,1,2,3 or 4)
35 .TP
36 .B \-\-bw
37 forces black/white output
38 .TP
39 .B \-d
40 dumps the configuration to stdout
41 .TP
42 .B \-\-eco
43 Econofast mode (uses less ink)
44 .TP
45 .B \-f <cfgfile>
46 read printer settings from configuration file <cfgfile>
47 .TP
48 .B \-F <gammaFile>
49 read color correction table from file <gammaFile>
50 .TP
51 .B \-\-fd
52 use fast dithering mode
53 .TP
54 .B \-g
55 print color calibration page. See CALIBRATION.txt
56 .TP
57 .B \-h, \-\-help displays this help text.
58 .TP
59 .B \-i <infile>
60 input from file <infile>, "-i -" means stdin
61 .TP
62 .B \-l <margin>
63 left margin in 1"/600 (default: 150 = 0.25")
64 .TP
65 .B \-\-noGamma
66 suppresses any color correction
67 .TP
68 .B \-o <outfile>
69 output to file <outfile>, "-o -" means stdout
70 .TP
71 .B \-p
72 disable black ink cartridge
73 .TP
74 .B \-r <margin>
75 right margin in 1"/600 (default: 150 = 0.25")
76 .TP
77 .B \-s <paper>
78 default papersize (a4, legal, letter = us (default))
79 .TP
80 .B \-t <margin>
81 top margin in 1"/600 (default: 150 = 0.25")
82 .TP
83 .B \-\-uni
84 forces unidirectional print head sweeps
85 .TP
86 .B \-v <model>
87 set the printer model (710, 712, 720, 722, 820, or 1000)
88 .TP
89 .B \-\-verbose
90 outputs syslog output to stderr as well
91 .TP
92 .B \-\-version
93 Display the version of pnm2ppa to the syslog
94 .TP
95 .B \-x <offset>
96 vertical offset adjustment in 1"/600
97 .TP
98 .B \-y <offset>
99 horizontal offset adjustment in 1"/600
100 .TP
101 The \fB\-v\fR option resets the margins and offset adjustments to the default values for that printer model. <infile> and <outfile> default to stdin and stdout. '-' is a synonym for stdin and stdout.
102 .SH CONFIGURATION FILES
103 The order in which parameters are specified is important: The file /etc/pnm2ppa.conf, if it exists, is processed as a configuration file before any command-line parameters are processed. If an alternate configuration file is specified on the command line with the '-f' parameter, its contents are processed at that point. If a parameter is specified more than once, only its last value is used. Configuration files specified with the '-f' parameter have the following format:
104 .IP
105 # Comment
106 .IP
107 <key1> <value1>
108 .IP
109 <key2> <value2>
110 .IP
111 [etc.]
112 .TP
113 Valid keys include:
114 .IP
115 version, xoffset, yoffset, topmargin, leftmargin, rightmargin, bottommargin, blackness, papersize
116 .TP
117 or any non-null truncated version of these words. Valid values are the same as with the corresponding command-line parameters.
118 .TP
119 Other keys that can be set in the configuration file include:
120 .IP
121 silent, verbose, unimode, blackshear, colorshear, RedGammaIdx, BlueGammaIdx, GreenGammaIdx, GammaR, GammaG, GammaB, ColOffsX, ColOffsY, black_ink, color_ink, cyan_ink, magenta_ink, yellow_ink
122 .TP
123 See documentation in the sample configuration file for their usage.
124 .SH FILES
125 .PD 0
126 .IR /etc/ppa/gamma.ppm
127 gamma correction file
128 .TP
129 \fI/etc/ppa/pnm2ppa.conf.hp1000\fP, \fI /etc/ppa/pnm2ppa.conf.hp820\fP, \fI /etc/ppa/pnm2ppa.conf.hp720\fP
130 .TP
131 Configuration files for the HP1000, HP820, and HP720 Series respectively.
132 .PD
133 .SH SEE ALSO
134 .IR calibrate_ppa (8),
135 .IR magicfilter (8),
136 .IR apsfilter(8)
0 #!/bin/sh -e
1
2 if [ "$1" = purge ]
3 then
4 rm -f /etc/magicfilter/pbm2ppa*
5 fi
6
7 #DEBHELPER#
0 #!/usr/bin/make -f
1 # This file is public domain software, originally written by Joey Hess.
2
3 # Uncomment this to turn on verbose mode.
4 #export DH_VERBOSE=1
5
6 # This is the debhelper compatibility version to use.
7 export DH_COMPAT=3
8
9 CFLAGS=-DLANG_EN -O2 -Wall
10 ifneq (,$(findstring debug,$(DEB_BUILD_OPTIONS)))
11 CFLAGS+=-g
12 endif
13
14 build: build-stamp
15 build-stamp:
16 dh_testdir
17
18 # Add here commands to compile the package.
19 $(MAKE) CFLAGS="$(CFLAGS)"
20
21 touch build-stamp
22
23 clean:
24 dh_testdir
25 dh_testroot
26 rm -f build-stamp
27
28 # Add here commands to clean up after the build process.
29 $(MAKE) clean
30
31 dh_clean
32
33 install: build
34 dh_testdir
35 dh_testroot
36 dh_clean -k
37 dh_installdirs usr/bin etc usr/share/man/man1
38
39 # Add here commands to install the package into debian/<packagename>
40 $(MAKE) install INSTALLDIR=`pwd`/debian/pnm2ppa/usr/bin \
41 CONFDIR=`pwd`/debian/pnm2ppa/etc \
42 MANDIR=`pwd`/debian/pnm2ppa/usr/share/man/man1
43 rm -r debian/pnm2ppa/etc
44 cp -a debian/etc debian/pnm2ppa
45 set -e; \
46 cd debian/pnm2ppa/etc/magicfilter; \
47 chmod 755 *; \
48 for m in 1000 720 820; do \
49 ln -s pnm2ppa-$$m-bw-filter pbm2ppa-$$m-filter; \
50 ln -s pnm2ppa-$$m-bw-eco-filter pbm2ppa-draft-$$m-filter; \
51 done
52
53 # Build architecture-independent files here.
54 binary-indep: build install
55 # We have nothing to do by default.
56
57 # Build architecture-dependent files here.
58 binary-arch: build install
59 dh_testdir
60 dh_testroot
61 # dh_installdebconf
62 dh_installdocs docs lpd pdq
63 cd debian/pnm2ppa/usr/share/doc/pnm2ppa/docs/en && rm LICENSE *.1
64 dh_installexamples sample_scripts/* *.ps
65 perl -pi -e 'print "#!/bin/sh -e\n" if $$. == 1; close ARGV if eof;' \
66 debian/pnm2ppa/usr/share/doc/pnm2ppa/examples/lpr*
67 dh_installmenu
68 # dh_installlogrotate
69 # dh_installemacsen
70 # dh_installpam
71 # dh_installmime
72 # dh_installinit
73 dh_installcron
74 dh_installman
75 dh_installinfo
76 # dh_undocumented calibrate_ppa.1
77 dh_installchangelogs Changelog
78 dh_link
79 dh_strip
80 dh_compress
81 dh_fixperms
82 # dh_makeshlibs
83 dh_installdeb
84 # dh_perl
85 dh_shlibdeps
86 dh_gencontrol
87 dh_md5sums
88 dh_builddeb
89
90 binary: binary-indep binary-arch
91 .PHONY: build clean binary-indep binary-arch binary install