Comparar commits

..

1 Commits

Autor SHA1 Mensagem Data
msweet bc3c4e76d7 Import cups.org releases
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/tags/release-1.1.7@4306 a1ca3aef-8c08-0410-bb20-df032aa958be
2013-05-10 18:56:23 +00:00
145 arquivos alterados com 10773 adições e 13614 exclusões
+1 -225
Ver Arquivo
@@ -1,230 +1,6 @@
CHANGES.txt - 06/28/2001
CHANGES.txt - 05/01/2001
------------------------
CHANGES IN CUPS V1.1.9
- Revamped the configure script to use a modular
approach for the various tests.
- Added --with-openssl-* options to properly reference
the OpenSSL libraries in DSOs.
- Added --with-cups-user and --with-cups-group
options to specify the default user and group for
CUPS.
- Added AIX shared library support.
- Added AIX device discovery for the serial and
parallel ports.
- Now use install program or script to install
directories, files, and symlinks.
- Updated pstops filter to use strict handling of EPS
files embedded in a PostScript document. The %%EOF
handling in 1.1.8 caused some dvips files not to
print.
- Fixed yet another memory allocation bug in pstoraster
that would cause it to crash. This fix also ensures
that all memory allocations are done on (at least) a
64-bit boundary.
- Fixed Digest authentication - httpGetSubField() didn't
skip the Digest keyword.
- The scheduler did not properly handle Digest
authentication with the new multiple-group support.
- The scheduler did not allow usernames that were
not in the UNIX password file to be used for Digest
authentication from passwd.md5.
- The scheduler could not scan PPD files that only used
a carriage return (i.e. MacOS PPD files); the new code
is also about 40% faster, so servers with thousands of
PPD files should start much faster now.
- The scheduler now stores the PPD file size and
modification times in the ppds.dat file, so it can now
incrementally update the PPD database from the model
directory, resulting in significantly faster startup
times.
- The lpinfo command did not return a non-zero status
code if an error occurred.
- Fixed a bug in the scheduler's UpdateJob() function.
Basically, all jobs shared the same status buffer, and
the "buffer start" pointer could point to 1 byte
before the beginning of the buffer. The new
implementation uses a separate buffer for each job and
eliminates the buffer start bug.
- The IPP backend would send N copies of a document if
the receiving device didn't support the copies
attribute, even if the upstream driver already added
the necessary commands to generate the copies. This
was most noticeable with HP printers where N * N
copies would come out instead of N.
- The PostScript filter (pstops) did not properly handle
duplex printing on inkjet printers that provide this
option. Copies would be put on the front and back
sides of the duplexed page, and the filter did not
output an even number of pages.
- The backends always caught SIGTERM after they
connected to the printer. This prevented raw jobs
from being cancelled early.
- The cupsSetDests() function now removes any printers,
instances, and options that are not defined by the
user or server. This should prevent old system-wide
options from being used in individual user accounts.
- Updated the EPSON printer driver and added PPDs for
the newer EPSON Stylus printers that only support the
"ESC i" graphics command.
- The lpadmin command didn't allow you to add remote
printers to a local class.
- The lpadmin command didn't allow you to set the
options (quotas, etc.) for a class.
- The scheduler did not load or save the
job-sheets-default attribute for classes.
- The scheduler did not automatically recreate remote
printers that were part of a class.
- It was possible for a printer class to list the same
printer more than once.
- The scheduler now makes a backup copy of classes.conf
and printers.conf before writing the new file.
- The lppasswd program incorrectly asked for a new
password when deleting an existing MD5 password
account.
- The scheduler did not match "/printers/name.ppd"
against a location of "/printers/name".
- The client code did not always handle HTTP encryption
upgrades properly.
- The client code now caches the last Digest password so
it can retry using a new resource path or nonce value,
which are included in the MD5 sum sent to the server.
This should eliminate unnecessary password prompts
when using Digest authentication.
- The lppasswd command didn't have a man page.
- Updated the PJL detection rules to allow the universal
escape to occur anywhere in the first 128 bytes of the
file.
- The cups-polld program would poll servers continuously
with no delay if there was an error contacting the
server.
- The IPP backend would send an empty job-name or
requesting-user-name attribute if the corresponding
job attribute was an empty string. While this is
allowed by the IPP specification, some HP JetDirect
implementations return a client-error-bad-request
error if an empty name attribute value is received.
The new code only sends these attributes if they are
not the empty string.
- At least some versions of the HP JetDirect firmware
do not correctly implement IPP. Added additional
checks to the IPP backend to eliminate extra,
unsupported attributes which should normally be
ignored by a compliant IPP device.
- The scheduler did not copy the complete list of
supported file types into the
document-format-supported attribute. This caused
clients to not send the local file type (such as
application/vnd.cups-raw for raw print files) and the
corresponding bad output in some cases.
- The scheduler did not fully copy attributes from a
set-job-attributes request - string attributes were
only referenced, which could cause cupsd to crash
or behave irratically.
- The lp command didn't send the right value for the
job-hold-until attribute when "-H resume" was
specified.
- The IPP backend now returns as soon as a job is
completed or reported as "pending-held".
- Added new ImplicitAnyClasses and HideImplicitMembers
directives to the cupsd.conf file to make implicit
classes more usable/transparent to the user.
- Clients can now (with the appropriate authentication)
retrieve and update the server configuration files
using HTTP GET and PUT requests.
- The web interface didn't allow you to modify the
location or description of the printer.
- The pdftops filter now uses its own temporary file
function to work with PDF files using LZW compression
(which use the uncompress program or gunzip)
- The SystemGroup directive now supports specification of
multiple groups.
- Added new Include directive to cupsd.conf, a la
Apache.
- Added new pseudo-driver/PPD called "raw" that can be
used to create/convert a raw queue. This also allows
raw queues to be created in the web interface.
- The pdftops filter didn't handle image objects that
used JPEG and Flate compression together.
- The pstops filter counted pages wrong when using the
N-up and even/odd printing options. This prevented
the page-ranges option from working properly.
- Added another fix to pstoraster for a bus error
condition caused by a lack of parenthesis in the
Ghostscript code.
- Added new "natural-scaling" option which scales the
natural size of the image (percent of natural image
size instead of percent of page size.)
- The lppasswd program is now setuid to the CUPS user
instead of root.
- The PPD functions did not allow for PPD files that
defined the page sizes and margins before the page
size options.
- The mime.types file now checks for the PJL "LANGUAGE =
Postscript" command for PostScript files.
- The scheduler did not truncate file: output files.
- The PPD file reading code did not handle options with
raw quotes (") in the human-readable names.
- The pdftops filter now remaps the space character when
(bad) PDF files contain a .notdef glyph for the space
character.
CHANGES IN CUPS V1.1.8
- Updated configure script to check for /etc/pam.d and
to only set PAMDIR if it exists.
- Updated spec file to generate separate cups-pstoraster
package for pstoraster.
- The spec file wasn't setting LOGDIR in the install.
- The scheduler might restart a stopped printer after
stopping a print job. Thanks to Florent
Guiliani for finding this bug!
- The init script showed run level 0 for the Red Hat
chkconfig program. This is incorrect because Red Hat
doesn't use run level 0 for shutdown scripts.
- The IPP backend did not handle the
client-error-not-found error when checking the status
of the job that was sent. This caused remote queues
to stop on client machines when the server had job
history disabled.
- Added httpConnectEncrypt() function to avoid
performance penalty for setting up encrypted
connections initially.
- Use httpConnectEncrypt() in all client apps and in the
CUPS API to ensure consistent usage of encryption
throughout.
- Jobs weren't queued to remote classes (fix from
Richard Begg.)
- AIX changes from Richard Begg.
- Fixed the pstops fix for GNOME output - no longer use
the page numbers in the %%Page: comment since GNOME
puts a filename instead (!?@!#?!). There is still an
issue with N-up printing since GNOME defines its fonts
in the first page instead of the document setup section
(pages must be independent according to the DSC spec)
People with GNOME printing problems should consult bug
#54489...
- The imagetops filter produced PAGE: messages when
generating PostScript for a non-PostScript printer
(only affects page-label and Classification
options.)
- The updated pdftops filter was looking for an options
file called xpdf.conf instead of pdftops.conf.
- The scheduler would not force the default job sheets
for printers to the current classification setting.
- Added a new ippFindNextAttribute() function to the
CUPS API.
- ppdEmitJCL() now strips any leading path info from
the title string. This is only an issue for non-CUPS
clients that don't do this already...
- Other pstops fixed from Helge Blischke for printing
non-conforming documents.
- The MaxJobs parameter was not reset when loading the
cupsd.conf file.
CHANGES IN CUPS V1.1.7
- Configuration script changes, including new
+5 -16
Ver Arquivo
@@ -1,4 +1,4 @@
INSTALL - CUPS v1.1.9 - 07/06/2001
INSTALL - CUPS v1.1.7 - 05/01/2001
----------------------------------
This file describes how to compile and install CUPS from source
@@ -72,14 +72,6 @@ SSL and TLS support require the OpenSSL library, available at:
http://www.openssl.org
If the OpenSSL header files and libraries are not in a standard
location, specify the locations of these files using the
--with-openssl-includes and --with-openssl-libs directives:
./configure --enable-ssl \
--with-openssl-includes=/foo/bar/include \
--with-openssl-libs=/foo/bar/lib
See the file "ENCRYPTION.txt" for information on using the
encryption support in CUPS.
@@ -87,7 +79,7 @@ Once you have configured things, just type:
make ENTER
or if you have FreeBSD, NetBSD, or OpenBSD type:
or if you have FreeBSD:
gmake ENTER
@@ -102,7 +94,7 @@ your local system:
make install ENTER
or for FreeBSD, NetBSD, or OpenBSD:
or for FreeBSD:
gmake install ENTER
@@ -132,19 +124,16 @@ or
gmake <format> ENTER
for FreeBSD, NetBSD, and OpenBSD. The <format> target is one of
the following:
for FreeBSD, where <format> is one of the following:
epm - Builds a portable shell script and tar file based
distribution. This format will also backup your
existing printing system if you decide to remove
CUPS at some future time.
aix - Builds an AIX binary distribution.
bsd - Builds a *BSD binary distribution.
rpm - Builds a RPM binary distribution.
deb - Builds a Debian binary distribution.
depot - Builds a HP-UX binary distribution.
pkg - Builds a Solaris binary distribution.
rpm - Builds a RPM binary distribution.
tardist - Builds an IRIX binary distribution.
+2 -2
Ver Arquivo
@@ -29,7 +29,7 @@ subdirectory of the CUPS source distribution and in the
<P>The GNU GPL applies to the remainder of the CUPS distribution,
including the "pstoraster" filter which is based upon GNU Ghostscript
5.50 and the "pdftops" filter which is based upon Xpdf 0.92.
5.50 and the "pdftops" filter which is based upon Xpdf 0.90.
<P>For those not familiar with the GNU GPL, the license basically
allows you to:
@@ -93,7 +93,7 @@ Fax: +1.415.492.9862<BR>
EMail: <A HREF="mailto:info@arsoft.com">info@arsoft.com</A>
</BLOCKQUOTE>
<P>The "pdftops" filter is based on the Xpdf 0.92 software. For binary
<P>The "pdftops" filter is based on the Xpdf 0.90 software. For binary
distribution licensing of this software, please contact:
<BLOCKQUOTE>
+9 -16
Ver Arquivo
@@ -29,12 +29,14 @@
AR = @AR@
AWK = @AWK@
CC = @LIBTOOL@ @CC@
CHMOD = @CHMOD@
CP = @CP@
CXX = @LIBTOOL@ @CXX@
DSO = @DSO@
HTMLDOC = @HTMLDOC@
INSTALL = @INSTALL@
LIBTOOL = @LIBTOOL@
LN = /bin/ln -sf
MKDIR = @MKDIR@ -p
MV = @MV@
NROFF = @NROFF@
RANLIB = @RANLIB@
@@ -46,19 +48,12 @@ SHELL = /bin/sh
# Installation programs...
#
INSTALL_BIN = $(LIBTOOL) $(INSTALL) -m 755 -s
INSTALL_DATA = $(INSTALL) -m 644
INSTALL_DIR = $(INSTALL) -d
INSTALL_LIB = $(LIBTOOL) $(INSTALL) -m 755
INSTALL_MAN = $(INSTALL) -m 644
INSTALL_SCRIPT = $(INSTALL) -m 755
#
# Default user and group for the scheduler...
#
CUPS_USER = @CUPS_USER@
CUPS_GROUP = @CUPS_GROUP@
INSTALL_BIN = $(LIBTOOL) $(CP)
INSTALL_DATA = $(CP)
INSTALL_LIB = $(LIBTOOL) $(CP)
INSTALL_MAN = $(CP)
INSTALL_SCRIPT = $(CP)
INSTALL_SYSV = @INSTALL_SYSV@
#
# Libraries...
@@ -93,7 +88,6 @@ LIBS = $(LINKCUPS) $(NETLIBS) @LIBS@
NETLIBS = @NETLIBS@
OPTIM = @OPTIM@
OPTIONS =
PAMLIBS = @PAMLIBS@
SSLLIBS = @SSLLIBS@
#
@@ -146,7 +140,6 @@ CAT1EXT = @CAT1EXT@
CAT5EXT = @CAT5EXT@
CAT8EXT = @CAT8EXT@
MAN8EXT = @MAN8EXT@
MAN8DIR = @MAN8DIR@
#
# Rules...
+28 -18
Ver Arquivo
@@ -75,21 +75,29 @@ install:
echo Installing in templates...
(cd templates; $(MAKE) $(MFLAGS) install)
echo Installing startup script...
if test "x$INITDIR" != "x"; then \
$(INSTALL_DIR) $(prefix)/$(INITDIR)/init.d; \
if test "x$(INITDIR)" != "x"; then \
$(MKDIR) $(prefix)/$(INITDIR)/init.d; \
$(RM) $(prefix)/$(INITDIR)/init.d/cups; \
$(INSTALL_SCRIPT) cups.sh $(prefix)/$(INITDIR)/init.d/cups; \
$(INSTALL_DIR) $(prefix)/$(INITDIR)/rc0.d; \
$(INSTALL_SCRIPT) cups.sh $(prefix)/$(INITDIR)/rc0.d/K00cups; \
$(INSTALL_DIR) $(prefix)/$(INITDIR)/rc2.d; \
$(INSTALL_SCRIPT) cups.sh $(prefix)/$(INITDIR)/rc2.d/S99cups; \
$(INSTALL_DIR) $(prefix)/$(INITDIR)/rc3.d; \
$(INSTALL_SCRIPT) cups.sh $(prefix)/$(INITDIR)/rc3.d/S99cups; \
$(INSTALL_DIR) $(prefix)/$(INITDIR)/rc5.d; \
$(INSTALL_SCRIPT) cups.sh $(prefix)/$(INITDIR)/rc5.d/S99cups; \
$(CHMOD) ugo+rx $(prefix)/$(INITDIR)/init.d/cups; \
$(MKDIR) $(prefix)/$(INITDIR)/rc0.d; \
$(RM) $(prefix)/$(INITDIR)/rc0.d/K00cups; \
ln -s $(INITDDIR)/cups $(prefix)/$(INITDIR)/rc0.d/K00cups; \
$(MKDIR) $(prefix)/$(INITDIR)/rc2.d; \
$(RM) $(prefix)/$(INITDIR)/rc2.d/S99cups; \
ln -s $(INITDDIR)/cups $(prefix)/$(INITDIR)/rc2.d/S99cups; \
$(MKDIR) $(prefix)/$(INITDIR)/rc3.d; \
$(RM) $(prefix)/$(INITDIR)/rc3.d/S99cups; \
ln -s $(INITDDIR)/cups $(prefix)/$(INITDIR)/rc3.d/S99cups; \
$(MKDIR) $(prefix)/$(INITDIR)/rc5.d; \
$(RM) $(prefix)/$(INITDIR)/rc5.d/S99cups; \
ln -s $(INITDDIR)/cups $(prefix)/$(INITDIR)/rc5.d/S99cups; \
fi
if test "x$(INITDIR)" = "x" -a "x$(INITDDIR)" != "x"; then \
$(INSTALL_DIR) $(prefix)/$(INITDDIR); \
$(MKDIR) $(prefix)/$(INITDDIR); \
$(RM) $(prefix)/$(INITDDIR)/cups; \
$(INSTALL_SCRIPT) cups.sh $(prefix)/$(INITDDIR)/cups; \
$(CHMOD) ugo+rx $(prefix)/$(INITDDIR)/cups; \
fi
@@ -106,13 +114,15 @@ test: all
# Make software distributions using EPM (http://www.easysw.com/epm)...
#
EPMFLAGS = -v
aix:
epm $(EPMFLAGS) -f aix cups
bsd:
epm $(EPMFLAGS) -f bsd cups
EPMFLAGS = -v \
AMANDIR=$(AMANDIR) \
BINDIR=$(BINDIR) DATADIR=$(DATADIR) \
DOCDIR=$(DOCDIR) INCLUDEDIR=$(INCLUDEDIR) \
LIBDIR=$(LIBDIR) LOCALEDIR=$(LOCALEDIR) \
LOGDIR=$(LOGDIR) MANDIR=$(MANDIR) \
PAMDIR=$(PAMDIR) REQUESTS=$(REQUESTS) \
SBINDIR=$(SBINDIR) SERVERBIN=$(SERVERBIN) \
SERVERROOT=$(SERVERROOT)
epm:
epm $(EPMFLAGS) cups
+12 -16
Ver Arquivo
@@ -1,4 +1,4 @@
README - CUPS v1.1.9 - 07/06/2001
README - CUPS v1.1.7 - 05/01/2001
---------------------------------
Looking for compile instructions? Read the file "INSTALL.txt"
@@ -55,8 +55,7 @@ SOFTWARE REQUIREMENTS
The following operating system software is required to install
one of the binary distributions from Easy Software Products:
- AIX 4.3 or higher
- Compaq Tru64 UNIX (aka OSF1 aka Digital UNIX) 4.0 or higher
- Digital UNIX (aka OSF1 aka Compaq Tru64 UNIX) 4.0 or higher
- HP-UX 10.20 or higher
- IRIX 5.3 or higher
- Linux 2.0 with glibc2 or higher
@@ -189,17 +188,14 @@ the following commands:
Similarly, for the other sample drivers you can use:
Driver PPD File
----------------------------- ------------
HP DeskJet Series deskjet.ppd
HP New DeskJet Series deskjet2.ppd
HP LaserJet Series laserjet.ppd
EPSON Stylus Color Series stcolor.ppd
EPSON Stylus Photo Series stphoto.ppd
EPSON Stylus New Color Series stcolor2.ppd
EPSON Stylus New Photo Series stphoto2.ppd
EPSON 9-pin Series epson9.ppd
EPSON 24-pin Series epson24.ppd
Driver PPD File
-------------------------- ------------
HP DeskJet Series deskjet.ppd
HP LaserJet Series laserjet.ppd
EPSON Stylus Color Series stcolor.ppd
EPSON Stylus Photo Series stphoto.ppd
EPSON 9-pin Series epson9.ppd
EPSON 24-pin Series epson24.ppd
These sample drivers provide basic printing capabilities, but
generally do not exercise the full potential of the printers or
@@ -250,8 +246,8 @@ The PostScript RIP software (pstoraster) is based on the GNU
Ghostscript 5.50 core, Copyright 1986-1998 by Aladdin
Enterprises.
The PDF filter (pdftops) is based on the Xpdf 0.92 software,
Copyright 1996-2001 by Derek B. Noonburg.
The PDF filter (pdftops) is based on the Xpdf 0.90 software,
Copyright 1996-1999 by Derek B. Noonburg.
This software is based in part on the work of the Independent
JPEG Group.
+6 -2
Ver Arquivo
@@ -49,8 +49,12 @@ clean:
#
install:
$(INSTALL_DIR) $(SERVERBIN)/backend
$(INSTALL_BIN) $(BACKENDS) http $(SERVERBIN)/backend
-$(MKDIR) $(SERVERBIN)/backend
$(CHMOD) ugo+rx $(SERVERBIN)
$(CHMOD) ugo+rx $(SERVERBIN)/backend
$(INSTALL_BIN) $(BACKENDS) $(SERVERBIN)/backend
$(RM) $(SERVERBIN)/backend/http
$(LN) ipp $(SERVERBIN)/backend/http
#
+20 -49
Ver Arquivo
@@ -320,30 +320,26 @@ main(int argc, /* I - Number of command-line arguments (6 or 7) */
/*
* Now that we are "connected" to the port, ignore SIGTERM so that we
* can finish out any page data the driver sends (e.g. to eject the
* current page... Only ignore SIGTERM if we are printing data from
* stdin (otherwise you can't cancel raw jobs...)
* current page...
*/
if (argc < 7)
{
#ifdef HAVE_SIGSET /* Use System V signals over POSIX to avoid bugs */
sigset(SIGTERM, SIG_IGN);
sigset(SIGTERM, SIG_IGN);
#elif defined(HAVE_SIGACTION)
memset(&action, 0, sizeof(action));
memset(&action, 0, sizeof(action));
sigemptyset(&action.sa_mask);
action.sa_handler = SIG_IGN;
sigaction(SIGTERM, &action, NULL);
sigemptyset(&action.sa_mask);
action.sa_handler = SIG_IGN;
sigaction(SIGTERM, &action, NULL);
#else
signal(SIGTERM, SIG_IGN);
signal(SIGTERM, SIG_IGN);
#endif /* HAVE_SIGSET */
}
/*
* See if the printer supports multiple copies...
*/
if (copies_sup || argc < 7)
if (copies_sup)
copies = 1;
else
copies = atoi(argv[4]);
@@ -412,15 +408,13 @@ main(int argc, /* I - Number of command-line arguments (6 or 7) */
fprintf(stderr, "DEBUG: printer-uri = \"%s\"\n", uri);
if (argv[2][0])
ippAddString(request, IPP_TAG_OPERATION, IPP_TAG_NAME, "requesting-user-name",
NULL, argv[2]);
ippAddString(request, IPP_TAG_OPERATION, IPP_TAG_NAME, "requesting-user-name",
NULL, argv[2]);
fprintf(stderr, "DEBUG: requesting-user-name = \"%s\"\n", argv[2]);
if (argv[3][0])
ippAddString(request, IPP_TAG_OPERATION, IPP_TAG_NAME, "job-name", NULL,
argv[3]);
ippAddString(request, IPP_TAG_OPERATION, IPP_TAG_NAME, "job-name", NULL,
argv[3]);
fprintf(stderr, "DEBUG: job-name = \"%s\"\n", argv[3]);
@@ -442,24 +436,11 @@ main(int argc, /* I - Number of command-line arguments (6 or 7) */
num_options, &options);
}
if (copies_sup)
{
/*
* Only send options if the destination printer supports the copies
* attribute. This is a hack for the HP JetDirect implementation of
* IPP, which does not accept extension attributes and incorrectly
* reports a client-error-bad-request error instead of the
* successful-ok-unsupported-attributes status. In short, at least
* some HP implementations of IPP are non-compliant.
*/
cupsEncodeOptions(request, num_options, options);
ippAddInteger(request, IPP_TAG_JOB, IPP_TAG_INTEGER, "copies",
atoi(argv[4]));
}
cupsEncodeOptions(request, num_options, options);
cupsFreeOptions(num_options, options);
if (copies_sup)
ippAddInteger(request, IPP_TAG_JOB, IPP_TAG_INTEGER, "copies", atoi(argv[4]));
/*
* Do the request...
@@ -551,18 +532,6 @@ main(int argc, /* I - Number of command-line arguments (6 or 7) */
else
ipp_status = response->request.status.status_code;
if (ipp_status == IPP_NOT_FOUND)
{
/*
* Job has gone away and/or the server has no job history...
*/
ippDelete(response);
ipp_status = IPP_OK;
break;
}
if (ipp_status > IPP_OK_CONFLICT)
{
if (ipp_status != IPP_SERVICE_UNAVAILABLE &&
@@ -579,11 +548,10 @@ main(int argc, /* I - Number of command-line arguments (6 or 7) */
else if ((job_state = ippFindAttribute(response, "job-state", IPP_TAG_ENUM)) != NULL)
{
/*
* Stop polling if the job is finished or pending-held...
* Stop polling if the job is finished...
*/
if (job_state->values[0].integer > IPP_JOB_PROCESSING ||
job_state->values[0].integer == IPP_JOB_HELD)
if (job_state->values[0].integer > IPP_JOB_PROCESSING)
{
ippDelete(response);
break;
@@ -621,6 +589,9 @@ main(int argc, /* I - Number of command-line arguments (6 or 7) */
* Return the queue status...
*/
if (ipp_status <= IPP_OK_CONFLICT)
fputs("INFO: " CUPS_SVERSION " is ready to print.\n", stderr);
return (ipp_status > IPP_OK_CONFLICT);
}
+11 -16
Ver Arquivo
@@ -75,8 +75,8 @@ extern int rresvport(int *port);
static int lpd_command(int lpd_fd, char *format, ...);
static int lpd_queue(char *hostname, char *printer, char *filename,
int fromstdin, char *user, char *title, int copies,
int banner, int format, int order);
char *user, char *title, int copies, int banner,
int format, int order);
static int lpd_write(int lpd_fd, char *buffer, int length);
@@ -285,7 +285,7 @@ main(int argc, /* I - Number of command-line arguments (6 or 7) */
if (argc > 6)
{
status = lpd_queue(hostname, resource + 1, filename, 0,
status = lpd_queue(hostname, resource + 1, filename,
argv[2] /* user */, title, atoi(argv[4]) /* copies */,
banner, format, order);
@@ -293,7 +293,7 @@ main(int argc, /* I - Number of command-line arguments (6 or 7) */
fprintf(stderr, "PAGE: 1 %d\n", atoi(argv[4]));
}
else
status = lpd_queue(hostname, resource + 1, filename, 1,
status = lpd_queue(hostname, resource + 1, filename,
argv[2] /* user */, title, 1, banner, format, order);
/*
@@ -368,7 +368,6 @@ static int /* O - Zero on success, non-zero on failure */
lpd_queue(char *hostname, /* I - Host to connect to */
char *printer, /* I - Printer/queue name */
char *filename, /* I - File to print */
int fromstdin, /* I - Printing from stdin? */
char *user, /* I - Requesting user */
char *title, /* I - Job title */
int copies, /* I - Number of copies */
@@ -476,24 +475,20 @@ lpd_queue(char *hostname, /* I - Host to connect to */
/*
* Now that we are "connected" to the port, ignore SIGTERM so that we
* can finish out any page data the driver sends (e.g. to eject the
* current page... Only ignore SIGTERM if we are printing data from
* stdin (otherwise you can't cancel raw jobs...)
* current page...
*/
if (fromstdin)
{
#ifdef HAVE_SIGSET /* Use System V signals over POSIX to avoid bugs */
sigset(SIGTERM, SIG_IGN);
sigset(SIGTERM, SIG_IGN);
#elif defined(HAVE_SIGACTION)
memset(&action, 0, sizeof(action));
memset(&action, 0, sizeof(action));
sigemptyset(&action.sa_mask);
action.sa_handler = SIG_IGN;
sigaction(SIGTERM, &action, NULL);
sigemptyset(&action.sa_mask);
action.sa_handler = SIG_IGN;
sigaction(SIGTERM, &action, NULL);
#else
signal(SIGTERM, SIG_IGN);
signal(SIGTERM, SIG_IGN);
#endif /* HAVE_SIGSET */
}
/*
* Next, open the print file and figure out its size...
+7 -26
Ver Arquivo
@@ -200,24 +200,20 @@ main(int argc, /* I - Number of command-line arguments (6 or 7) */
/*
* Now that we are "connected" to the port, ignore SIGTERM so that we
* can finish out any page data the driver sends (e.g. to eject the
* current page... Only ignore SIGTERM if we are printing data from
* stdin (otherwise you can't cancel raw jobs...)
* current page...
*/
if (argc < 7)
{
#ifdef HAVE_SIGSET /* Use System V signals over POSIX to avoid bugs */
sigset(SIGTERM, SIG_IGN);
sigset(SIGTERM, SIG_IGN);
#elif defined(HAVE_SIGACTION)
memset(&action, 0, sizeof(action));
memset(&action, 0, sizeof(action));
sigemptyset(&action.sa_mask);
action.sa_handler = SIG_IGN;
sigaction(SIGTERM, &action, NULL);
sigemptyset(&action.sa_mask);
action.sa_handler = SIG_IGN;
sigaction(SIGTERM, &action, NULL);
#else
signal(SIGTERM, SIG_IGN);
signal(SIGTERM, SIG_IGN);
#endif /* HAVE_SIGSET */
}
/*
* Finally, send the print file...
@@ -618,21 +614,6 @@ list_devices(void)
printf("direct parallel:%s \"Unknown\" \"Parallel Port #%d\"\n", device, i + 1);
}
}
#elif defined(_AIX)
int i; /* Looping var */
int fd; /* File descriptor */
char device[255]; /* Device filename */
for (i = 0; i < 8; i ++)
{
sprintf(device, "/dev/lp%d", i);
if ((fd = open(device, O_WRONLY)) >= 0)
{
close(fd);
printf("direct parallel:%s \"Unknown\" \"Parallel Port #%d\"\n", device, i + 1);
}
}
#endif
}
+7 -11
Ver Arquivo
@@ -382,24 +382,20 @@ main(int argc, /* I - Number of command-line arguments (6 or 7) */
/*
* Now that we are "connected" to the port, ignore SIGTERM so that we
* can finish out any page data the driver sends (e.g. to eject the
* current page... Only ignore SIGTERM if we are printing data from
* stdin (otherwise you can't cancel raw jobs...)
* current page...
*/
if (argc < 7)
{
#ifdef HAVE_SIGSET /* Use System V signals over POSIX to avoid bugs */
sigset(SIGTERM, SIG_IGN);
sigset(SIGTERM, SIG_IGN);
#elif defined(HAVE_SIGACTION)
memset(&action, 0, sizeof(action));
memset(&action, 0, sizeof(action));
sigemptyset(&action.sa_mask);
action.sa_handler = SIG_IGN;
sigaction(SIGTERM, &action, NULL);
sigemptyset(&action.sa_mask);
action.sa_handler = SIG_IGN;
sigaction(SIGTERM, &action, NULL);
#else
signal(SIGTERM, SIG_IGN);
signal(SIGTERM, SIG_IGN);
#endif /* HAVE_SIGSET */
}
/*
* Finally, send the print file...
+9 -11
Ver Arquivo
@@ -199,24 +199,20 @@ main(int argc, /* I - Number of command-line arguments (6 or 7) */
/*
* Now that we are "connected" to the port, ignore SIGTERM so that we
* can finish out any page data the driver sends (e.g. to eject the
* current page... Only ignore SIGTERM if we are printing data from
* stdin (otherwise you can't cancel raw jobs...)
* current page...
*/
if (argc < 7)
{
#ifdef HAVE_SIGSET /* Use System V signals over POSIX to avoid bugs */
sigset(SIGTERM, SIG_IGN);
sigset(SIGTERM, SIG_IGN);
#elif defined(HAVE_SIGACTION)
memset(&action, 0, sizeof(action));
memset(&action, 0, sizeof(action));
sigemptyset(&action.sa_mask);
action.sa_handler = SIG_IGN;
sigaction(SIGTERM, &action, NULL);
sigemptyset(&action.sa_mask);
action.sa_handler = SIG_IGN;
sigaction(SIGTERM, &action, NULL);
#else
signal(SIGTERM, SIG_IGN);
signal(SIGTERM, SIG_IGN);
#endif /* HAVE_SIGSET */
}
/*
* Finally, send the print file...
@@ -336,6 +332,8 @@ main(int argc, /* I - Number of command-line arguments (6 or 7) */
if (fp != stdin)
fclose(fp);
fputs("INFO: " CUPS_SVERSION " is ready to print.\n", stderr);
return (0);
}
+7 -11
Ver Arquivo
@@ -189,24 +189,20 @@ main(int argc, /* I - Number of command-line arguments (6 or 7) */
/*
* Now that we are "connected" to the port, ignore SIGTERM so that we
* can finish out any page data the driver sends (e.g. to eject the
* current page... Only ignore SIGTERM if we are printing data from
* stdin (otherwise you can't cancel raw jobs...)
* current page...
*/
if (argc < 7)
{
#ifdef HAVE_SIGSET /* Use System V signals over POSIX to avoid bugs */
sigset(SIGTERM, SIG_IGN);
sigset(SIGTERM, SIG_IGN);
#elif defined(HAVE_SIGACTION)
memset(&action, 0, sizeof(action));
memset(&action, 0, sizeof(action));
sigemptyset(&action.sa_mask);
action.sa_handler = SIG_IGN;
sigaction(SIGTERM, &action, NULL);
sigemptyset(&action.sa_mask);
action.sa_handler = SIG_IGN;
sigaction(SIGTERM, &action, NULL);
#else
signal(SIGTERM, SIG_IGN);
signal(SIGTERM, SIG_IGN);
#endif /* HAVE_SIGSET */
}
/*
* Finally, send the print file...
+4 -2
Ver Arquivo
@@ -48,9 +48,11 @@ clean:
#
install:
$(INSTALL_DIR) $(BINDIR)
-$(MKDIR) $(BINDIR)
$(CHMOD) ugo+rx $(BINDIR)
$(INSTALL_BIN) lpq lpr lprm $(BINDIR)
$(INSTALL_DIR) $(SBINDIR)
-$(MKDIR) $(SBINDIR)
$(CHMOD) ugo+rx $(SBINDIR)
$(INSTALL_BIN) lpc $(SBINDIR)
+1 -1
Ver Arquivo
@@ -69,7 +69,7 @@ main(int argc, /* I - Number of command-line arguments */
* Connect to the scheduler...
*/
http = httpConnectEncrypt(cupsServer(), ippPort(), cupsEncryption());
http = httpConnect(cupsServer(), ippPort());
if (argc > 1)
{
+1 -2
Ver Arquivo
@@ -79,8 +79,7 @@ main(int argc, /* I - Number of command-line arguments */
* Connect to the scheduler...
*/
if ((http = httpConnectEncrypt(cupsServer(), ippPort(),
cupsEncryption())) == NULL)
if ((http = httpConnect(cupsServer(), ippPort())) == NULL)
{
fputs("lpq: Unable to contact server!\n", stderr);
return (1);
+3 -1
Ver Arquivo
@@ -82,13 +82,15 @@ main(int argc, /* I - Number of command-line arguments */
* Open a connection to the server...
*/
if ((http = httpConnectEncrypt(cupsServer(), ippPort(), encryption)) == NULL)
if ((http = httpConnect(cupsServer(), ippPort())) == NULL)
{
fputs("lprm: Unable to contact server!\n", stderr);
cupsFreeDests(num_dests, dests);
return (1);
}
httpEncryption(http, encryption);
/*
* Process command-line arguments...
*/
+3 -1
Ver Arquivo
@@ -50,7 +50,9 @@ clean:
#
install:
$(INSTALL_DIR) $(SERVERBIN)/cgi-bin
-$(MKDIR) $(SERVERBIN)/cgi-bin
$(CHMOD) ugo+rx $(SERVERBIN)
$(CHMOD) ugo+rx $(SERVERBIN)/cgi-bin
$(INSTALL_BIN) $(CGIS) $(SERVERBIN)/cgi-bin
+2 -3
Ver Arquivo
@@ -105,7 +105,7 @@ main(int argc, /* I - Number of command-line arguments */
* Connect to the HTTP server...
*/
http = httpConnectEncrypt("localhost", ippPort(), cupsEncryption());
http = httpConnect("localhost", ippPort());
/*
* Do the operation...
@@ -549,8 +549,7 @@ do_am_printer(http_t *http, /* I - HTTP connection */
else
oldinfo = NULL;
if ((name = cgiGetVariable("PRINTER_NAME")) == NULL ||
cgiGetVariable("PRINTER_LOCATION") == NULL)
if ((name = cgiGetVariable("PRINTER_NAME")) == NULL)
{
if (modify)
{
+1 -1
Ver Arquivo
@@ -71,7 +71,7 @@ main(int argc, /* I - Number of command-line arguments */
* Connect to the HTTP server...
*/
http = httpConnectEncrypt("localhost", ippPort(), cupsEncryption());
http = httpConnect("localhost", ippPort());
/*
* Tell the client to expect HTML...
+1 -1
Ver Arquivo
@@ -64,7 +64,7 @@ main(int argc, /* I - Number of command-line arguments */
* Connect to the HTTP server...
*/
http = httpConnectEncrypt("localhost", ippPort(), cupsEncryption());
http = httpConnect("localhost", ippPort());
/*
* Tell the client to expect HTML...
+1 -1
Ver Arquivo
@@ -71,7 +71,7 @@ main(int argc, /* I - Number of command-line arguments */
* Connect to the HTTP server...
*/
http = httpConnectEncrypt("localhost", ippPort(), cupsEncryption());
http = httpConnect("localhost", ippPort());
/*
* Tell the client to expect HTML...
+2 -1
Ver Arquivo
@@ -51,7 +51,8 @@ clean:
#
install:
$(INSTALL_DIR) $(SERVERROOT)
-$(MKDIR) $(SERVERROOT)
$(CHMOD) ugo+rx $(SERVERROOT)
for file in $(KEEP); do \
if test -r $(SERVERROOT)/$$file ; then \
$(INSTALL_DATA) $$file $(SERVERROOT)/$$file.N ; \
+2 -32
Ver Arquivo
@@ -1,5 +1,5 @@
#
# "$Id: cupsd.conf 1779 2001-06-22 15:50:53Z mike $"
# "$Id: cupsd.conf 1631 2001-03-14 13:45:35Z mike $"
#
# Sample configuration file for the Common UNIX Printing System (CUPS)
# scheduler.
@@ -494,36 +494,6 @@ Port 631
#ImplicitClasses On
#
# ImplicitAnyClasses: whether or not to create "AnyPrinter" implicit
# classes.
#
# When ImplicitAnyClasses is On and a local queue of the same name
# exists, e.g. "printer", "printer@server1", "printer@server1", then
# an implicit class called "Anyprinter" is created instead.
#
# When ImplicitAnyClasses is Off, implicit classes are not created
# when there is a local queue of the same name.
#
# Disabled by default.
#
#ImplicitAnyCLasses Off
#
# HideImplicitMembers: whether or not to show the members of an
# implicit class.
#
# When HideImplicitMembers is On, any remote printers that are
# part of an implicit class are hidden from the user, who will
# then only see a single queue even though many queues will be
# supporting the implicit class.
#
# Enabled by default.
#
#HideImplicitMembers On
########
######## Security Options
@@ -665,5 +635,5 @@ Allow From 127.0.0.1
</Location>
#
# End of "$Id: cupsd.conf 1779 2001-06-22 15:50:53Z mike $".
# End of "$Id: cupsd.conf 1631 2001-03-14 13:45:35Z mike $".
#
+5 -6
Ver Arquivo
@@ -1,5 +1,5 @@
#
# "$Id: mime.types 1806 2001-06-28 18:01:17Z mike $"
# "$Id: mime.types 1681 2001-04-19 15:42:39Z mike $"
#
# MIME types file for the Common UNIX Printing System (CUPS).
#
@@ -75,7 +75,7 @@ application/vnd.hp-HPGL hpgl string(0,<1B>&)\
string(0,<1B>E<1B>%0B) string(0,<201B>)\
string(0,BP;) string(0,IN;) string(0,DF;) \
string(0,BPINPS;) \
(contains(0,128,<1B>%-12345X) + \
(string(0,<1B>%-12345X) + \
(contains(9,512,"LANGUAGE=HPGL") \
contains(9,512,"LANGUAGE = HPGL")))
@@ -129,14 +129,13 @@ text/plain txt printable(0,1024)
#
application/vnd.cups-form string(0,"<CUPSFORM>")
application/vnd.cups-postscript contains(0,128,<1B>%-12345X) + \
application/vnd.cups-postscript string(0,<1B>%-12345X) + \
(contains(9,512,"LANGUAGE=POSTSCRIPT") \
contains(9,512,"LANGUAGE = Postscript") \
contains(9,512,"LANGUAGE = POSTSCRIPT"))
application/vnd.cups-raster string(0,"RaSt") string(0,"tSaR")
application/vnd.cups-raw (string(0,<1B>E) + !string(2,<1B>%0B)) \
string(0,<1B>@) \
(contains(0,128,<1B>%-12345X) + \
(string(0,<1B>%-12345X) + \
(contains(9,512,"LANGUAGE=PCL") \
contains(9,512,"LANGUAGE = PCL")))
@@ -152,5 +151,5 @@ application/vnd.cups-raw (string(0,<1B>E) + !string(2,<1B>%0B)) \
#application/octet-stream
#
# End of "$Id: mime.types 1806 2001-06-28 18:01:17Z mike $".
# End of "$Id: mime.types 1681 2001-04-19 15:42:39Z mike $".
#
-132
Ver Arquivo
@@ -1,132 +0,0 @@
dnl
dnl "$Id: cups-common.m4 1811 2001-06-29 14:19:09Z mike $"
dnl
dnl Common configuration stuff for the Common UNIX Printing System (CUPS).
dnl
dnl Copyright 1997-2001 by Easy Software Products, all rights reserved.
dnl
dnl These coded instructions, statements, and computer programs are the
dnl property of Easy Software Products and are protected by Federal
dnl copyright law. Distribution and use rights are outlined in the file
dnl "LICENSE.txt" which should have been included with this file. If this
dnl file is missing or damaged please contact Easy Software Products
dnl at:
dnl
dnl Attn: CUPS Licensing Information
dnl Easy Software Products
dnl 44141 Airport View Drive, Suite 204
dnl Hollywood, Maryland 20636-3111 USA
dnl
dnl Voice: (301) 373-9603
dnl EMail: cups-info@cups.org
dnl WWW: http://www.cups.org
dnl
AC_CONFIG_HEADER(config.h)
dnl Default compiler flags...
CFLAGS="${CFLAGS:=}"
CXXFLAGS="${CXXFLAGS:=}"
LDFLAGS="${LDFLAGS:=}"
dnl Checks for programs...
AC_PROG_AWK
AC_PROG_CC
AC_PROG_CXX
AC_PROG_CPP
AC_PROG_INSTALL
AC_PROG_RANLIB
AC_PATH_PROG(AR,ar)
AC_PATH_PROG(HTMLDOC,htmldoc)
AC_PATH_PROG(MV,mv)
AC_PATH_PROG(NROFF,nroff)
if test "$NROFF" = ""; then
AC_PATH_PROG(GROFF,groff)
if test "$GROFF" = ""; then
NROFF="echo"
else
NROFF="$GROFF -T ascii"
fi
fi
AC_PATH_PROG(RM,rm)
AC_PATH_PROG(SED,sed)
dnl Architecture checks...
AC_C_BIGENDIAN
dnl Check for libraries...
AC_CHECK_LIB(c,crypt,LIBS="$LIBS")
if test "$ac_cv_lib_c_crypt" = "no"; then
AC_CHECK_LIB(crypt,crypt)
fi
AC_CHECK_LIB(sec,getspent)
AC_CHECK_LIB(gen,getspent)
LIBMALLOC=""
AC_CHECK_LIB(c,mallinfo,LIBS="$LIBS"; AC_DEFINE(HAVE_MALLINFO),LIBS="$LIBS")
if test "$ac_cv_lib_c_mallinfo" = "no"; then
AC_CHECK_LIB(malloc,mallinfo,
LIBS="$LIBS"
LIBMALLOC="-lmalloc"
AC_DEFINE(HAVE_MALLINFO),
LIBS="$LIBS")
fi
AC_SUBST(LIBMALLOC)
dnl Checks for header files.
AC_HEADER_STDC
AC_HEADER_DIRENT
AC_CHECK_HEADER(crypt.h,AC_DEFINE(HAVE_CRYPT_H))
AC_CHECK_HEADER(malloc.h,AC_DEFINE(HAVE_MALLOC_H))
AC_CHECK_HEADER(shadow.h,AC_DEFINE(HAVE_SHADOW_H))
AC_CHECK_HEADER(stddef.h,AC_DEFINE(HAVE_STDDEF_H))
AC_CHECK_HEADER(stdlib.h,AC_DEFINE(HAVE_STDLIB_H))
AC_CHECK_HEADER(string.h,AC_DEFINE(HAVE_STRING_H))
AC_CHECK_HEADER(strings.h,AC_DEFINE(HAVE_STRINGS_H))
AC_CHECK_HEADER(usersec.h,AC_DEFINE(HAVE_USERSEC_H))
AC_CHECK_HEADER(sys/ioctl.h,AC_DEFINE(HAVE_SYS_IOCTL_H))
dnl Checks for string functions.
AC_CHECK_FUNCS(strdup strcasecmp strncasecmp)
if test "$uname" = "HP-UX" -a "$uversion" = "1020"; then
echo Forcing snprintf emulation for HP-UX.
else
AC_CHECK_FUNCS(snprintf vsnprintf)
fi
dnl Check OS version and use appropriate format string for strftime...
AC_MSG_CHECKING(for correct format string to use with strftime)
case "$uname" in
IRIX* | SunOS*)
# IRIX and SunOS
AC_MSG_RESULT(NULL)
AC_DEFINE(CUPS_STRFTIME_FORMAT, NULL)
;;
*)
# All others
AC_MSG_RESULT("%c")
AC_DEFINE(CUPS_STRFTIME_FORMAT, "%c")
;;
esac
dnl Checks for mkstemp function.
AC_CHECK_FUNCS(mkstemp)
dnl Checks for vsyslog function.
AC_CHECK_FUNCS(vsyslog)
dnl Checks for signal functions.
if test "$uname" != "Linux"; then
AC_CHECK_FUNCS(sigset)
fi
AC_CHECK_FUNCS(sigaction)
dnl Checks for wait functions.
AC_CHECK_FUNCS(waitpid)
AC_CHECK_FUNCS(wait3)
dnl
dnl End of "$Id: cups-common.m4 1811 2001-06-29 14:19:09Z mike $".
dnl
-118
Ver Arquivo
@@ -1,118 +0,0 @@
dnl
dnl "$Id: cups-compiler.m4 1823 2001-07-03 17:07:29Z mike $"
dnl
dnl Common configuration stuff for the Common UNIX Printing System (CUPS).
dnl
dnl Copyright 1997-2001 by Easy Software Products, all rights reserved.
dnl
dnl These coded instructions, statements, and computer programs are the
dnl property of Easy Software Products and are protected by Federal
dnl copyright law. Distribution and use rights are outlined in the file
dnl "LICENSE.txt" which should have been included with this file. If this
dnl file is missing or damaged please contact Easy Software Products
dnl at:
dnl
dnl Attn: CUPS Licensing Information
dnl Easy Software Products
dnl 44141 Airport View Drive, Suite 204
dnl Hollywood, Maryland 20636-3111 USA
dnl
dnl Voice: (301) 373-9603
dnl EMail: cups-info@cups.org
dnl WWW: http://www.cups.org
dnl
dnl Clear the debugging and non-shared library options unless the user asks
dnl for them...
OPTIM=""
AC_SUBST(OPTIM)
AC_ARG_ENABLE(debug, [ --enable-debug turn on debugging [default=no]],
[if test x$enable_debug = xyes; then
OPTIM="-g"
fi])
dnl Update compiler options...
if test -n "$GCC"; then
CXX="$CC"
if test -z "$OPTIM"; then
if test $uname = HP-UX; then
# GCC under HP-UX has bugs with -O2
OPTIM="-O1"
else
OPTIM="-O2"
fi
fi
if test $PICFLAG = 1 -a $uname != AIX; then
OPTIM="-fPIC $OPTIM"
fi
OPTIM="-Wall $OPTIM"
else
case $uname in
AIX*)
if test -z "$OPTIM"; then
OPTIM="-O2 -qmaxmem=6000"
fi
;;
HP-UX*)
if test -z "$OPTIM"; then
OPTIM="+O2"
fi
CFLAGS="-Ae $CFLAGS"
OPTIM="+DAportable $OPTIM"
if test $PICFLAG = 1; then
OPTIM="+z $OPTIM"
fi
;;
IRIX*)
if test -z "$OPTIM"; then
OPTIM="-O2"
fi
if test $uversion -ge 62; then
OPTIM="$OPTIM -n32 -mips3"
fi
OPTIM="-fullwarn $OPTIM"
;;
SunOS*)
# Solaris
if test -z "$OPTIM"; then
OPTIM="-xO4"
fi
OPTIM="$OPTIM -xarch=generic"
if test $PICFLAG = 1; then
OPTIM="-KPIC $OPTIM"
fi
;;
UNIX_SVR*)
# UnixWare
if test -z "$OPTIM"; then
OPTIM="-O"
fi
if test $PICFLAG = 1; then
OPTIM="-KPIC $OPTIM"
fi
;;
*)
# Running some other operating system; inform the user they
# should contribute the necessary options to
# cups-support@cups.org...
echo "Building CUPS with default compiler optimizations; contact"
echo "cups-bugs@cups.org with uname and compiler options needed"
echo "for your platform, or set the CFLAGS and CXXFLAGS"
echo "environment variable before running configure."
;;
esac
fi
dnl
dnl End of "$Id: cups-compiler.m4 1823 2001-07-03 17:07:29Z mike $".
dnl
-230
Ver Arquivo
@@ -1,230 +0,0 @@
dnl
dnl "$Id: cups-directories.m4 1794 2001-06-27 19:06:46Z mike $"
dnl
dnl Directory stuff for the Common UNIX Printing System (CUPS).
dnl
dnl Copyright 1997-2001 by Easy Software Products, all rights reserved.
dnl
dnl These coded instructions, statements, and computer programs are the
dnl property of Easy Software Products and are protected by Federal
dnl copyright law. Distribution and use rights are outlined in the file
dnl "LICENSE.txt" which should have been included with this file. If this
dnl file is missing or damaged please contact Easy Software Products
dnl at:
dnl
dnl Attn: CUPS Licensing Information
dnl Easy Software Products
dnl 44141 Airport View Drive, Suite 204
dnl Hollywood, Maryland 20636-3111 USA
dnl
dnl Voice: (301) 373-9603
dnl EMail: cups-info@cups.org
dnl WWW: http://www.cups.org
dnl
AC_PREFIX_DEFAULT(/)
AC_ARG_WITH(fontpath, [ --with-fontpath set font path for pstoraster],fontpath="$withval",fontpath="")
AC_ARG_WITH(docdir, [ --with-docdir set path for documentation],docdir="$withval",docdir="")
AC_ARG_WITH(logdir, [ --with-logdir set path for log files],logdir="$withval",logdir="")
AC_ARG_WITH(rcdir, [ --with-rcdir set path for rc scripts],rcdir="$withval",rcdir="")
dnl Fix "prefix" variable if it hasn't been specified...
if test "$prefix" = "NONE"; then
prefix="/"
fi
dnl Fix "exec_prefix" variable if it hasn't been specified...
if test "$exec_prefix" = "NONE"; then
if test "$prefix" = "/"; then
exec_prefix="/usr"
else
exec_prefix="$prefix"
fi
fi
dnl Fix "sharedstatedir" variable if it hasn't been specified...
if test "$sharedstatedir" = "\${prefix}/com" -a "$prefix" = "/"; then
sharedstatedir="/usr/com"
fi
dnl Fix "datadir" variable if it hasn't been specified...
if test "$datadir" = "\${prefix}/share"; then
if test "$prefix" = "/"; then
datadir="/usr/share"
else
datadir="$prefix/share"
fi
fi
dnl Fix "includedir" variable if it hasn't been specified...
if test "$includedir" = "\${prefix}/include" -a "$prefix" = "/"; then
includedir="/usr/include"
fi
dnl Fix "localstatedir" variable if it hasn't been specified...
if test "$localstatedir" = "\${prefix}/var"; then
if test "$prefix" = "/"; then
localstatedir="/var"
else
localstatedir="$prefix/var"
fi
fi
dnl Fix "sysconfdir" variable if it hasn't been specified...
if test "$sysconfdir" = "\${prefix}/etc"; then
if test "$prefix" = "/"; then
sysconfdir="/etc"
else
sysconfdir="$prefix/etc"
fi
fi
dnl Fix "libdir" variable for IRIX 6.x...
if test "$uname" = "IRIX" -a $uversion -ge 62; then
libdir="$exec_prefix/lib32"
fi
dnl Fix "fontpath" variable...
if test "x$fontpath" = "x"; then
fontpath="$datadir/cups/fonts"
fi
dnl Setup init.d locations...
if test x$rcdir = x; then
case "$uname" in
FreeBSD* | OpenBSD*)
# FreeBSD and OpenBSD
INITDIR=""
INITDDIR=""
;;
NetBSD*)
# NetBSD
INITDIR=""
INITDDIR="/etc/rc.d"
;;
Linux*)
# Linux seems to choose an init.d directory at random...
if test -d /sbin/init.d; then
# SuSE
INITDIR="/sbin/init.d"
INITDDIR=".."
else
if test -d /etc/rc.d; then
# RedHat
INITDIR="/etc/rc.d"
INITDDIR="../init.d"
else
# Others
INITDIR="/etc"
INITDDIR="../init.d"
fi
fi
;;
OSF1* | HP-UX*)
INITDIR="/sbin"
INITDDIR="../init.d"
;;
AIX*)
INITDIR="/etc/rc.d"
INITDDIR=".."
;;
*)
INITDIR="/etc"
INITDDIR="../init.d"
;;
esac
else
INITDIR=""
INITDDIR="$rcdir"
fi
AC_SUBST(INITDIR)
AC_SUBST(INITDDIR)
dnl Setup default locations...
CUPS_SERVERROOT='${sysconfdir}/cups'
CUPS_REQUESTS='${localstatedir}/spool/cups'
AC_DEFINE_UNQUOTED(CUPS_SERVERROOT, "$sysconfdir/cups")
AC_DEFINE_UNQUOTED(CUPS_REQUESTS, "$localstatedir/spool/cups")
if test x$logdir = x; then
CUPS_LOGDIR='${localstatedir}/log/cups'
AC_DEFINE_UNQUOTED(CUPS_LOGDIR, "$localstatedir/log/cups")
else
CUPS_LOGDIR="$logdir"
AC_DEFINE_UNQUOTED(CUPS_LOGDIR, "$logdir")
fi
dnl See what directory to put server executables...
case "$uname" in
FreeBSD* | NetBSD* | OpenBSD*)
# *BSD
INSTALL_SYSV=""
CUPS_SERVERBIN='${exec_prefix}/libexec/cups'
AC_DEFINE_UNQUOTED(CUPS_SERVERBIN, "$exec_prefix/libexec/cups")
;;
*)
# All others
INSTALL_SYSV="install-sysv"
CUPS_SERVERBIN='${exec_prefix}/lib/cups'
AC_DEFINE_UNQUOTED(CUPS_SERVERBIN, "$exec_prefix/lib/cups")
;;
esac
AC_SUBST(INSTALL_SYSV)
AC_SUBST(CUPS_SERVERROOT)
AC_SUBST(CUPS_SERVERBIN)
AC_SUBST(CUPS_LOGDIR)
AC_SUBST(CUPS_REQUESTS)
dnl Set the CUPS_LOCALE directory...
case "$uname" in
Linux* | FreeBSD* | NetBSD* | OpenBSD*)
CUPS_LOCALEDIR='${datadir}/locale'
AC_DEFINE_UNQUOTED(CUPS_LOCALEDIR, "$datadir/locale")
;;
OSF1* | AIX*)
CUPS_LOCALEDIR='${exec_prefix}/lib/nls/msg'
AC_DEFINE_UNQUOTED(CUPS_LOCALEDIR, "$exec_prefix/lib/nls/msg")
;;
*)
# This is the standard System V location...
CUPS_LOCALEDIR='${exec_prefix}/lib/locale'
AC_DEFINE_UNQUOTED(CUPS_LOCALEDIR, "$exec_prefix/lib/locale")
;;
esac
AC_SUBST(CUPS_LOCALEDIR)
dnl Set the CUPS_DATADIR directory...
CUPS_DATADIR='${datadir}/cups'
AC_DEFINE_UNQUOTED(CUPS_DATADIR, "$datadir/cups")
AC_SUBST(CUPS_DATADIR)
dnl Set the CUPS_DOCROOT directory...
if test x$docdir = x; then
CUPS_DOCROOT='${datadir}/doc/cups'
docdir="$datadir/doc/cups"
else
CUPS_DOCROOT="$docdir"
fi
AC_DEFINE_UNQUOTED(CUPS_DOCROOT, "$docdir")
AC_SUBST(CUPS_DOCROOT)
dnl Set the CUPS_FONTPATH directory...
AC_DEFINE_UNQUOTED(CUPS_FONTPATH, "$fontpath")
dnl
dnl End of "$Id: cups-directories.m4 1794 2001-06-27 19:06:46Z mike $".
dnl
-70
Ver Arquivo
@@ -1,70 +0,0 @@
dnl
dnl "$Id: cups-image.m4 1794 2001-06-27 19:06:46Z mike $"
dnl
dnl Image library stuff for the Common UNIX Printing System (CUPS).
dnl
dnl Copyright 1997-2001 by Easy Software Products, all rights reserved.
dnl
dnl These coded instructions, statements, and computer programs are the
dnl property of Easy Software Products and are protected by Federal
dnl copyright law. Distribution and use rights are outlined in the file
dnl "LICENSE.txt" which should have been included with this file. If this
dnl file is missing or damaged please contact Easy Software Products
dnl at:
dnl
dnl Attn: CUPS Licensing Information
dnl Easy Software Products
dnl 44141 Airport View Drive, Suite 204
dnl Hollywood, Maryland 20636-3111 USA
dnl
dnl Voice: (301) 373-9603
dnl EMail: cups-info@cups.org
dnl WWW: http://www.cups.org
dnl
dnl Save the current libraries since we don't want the image libraries
dnl included with every program...
SAVELIBS="$LIBS"
dnl Check for image libraries...
LIBJPEG=""
LIBPNG=""
LIBTIFF=""
LIBZ=""
AC_SUBST(LIBJPEG)
AC_SUBST(LIBPNG)
AC_SUBST(LIBTIFF)
AC_SUBST(LIBZ)
AC_CHECK_HEADER(jpeglib.h,
AC_CHECK_LIB(jpeg, jpeg_destroy_decompress,
AC_DEFINE(HAVE_LIBJPEG)
LIBJPEG="-ljpeg"
LIBS="$LIBS -ljpeg"))
AC_CHECK_HEADER(zlib.h,
AC_CHECK_LIB(z, gzgets,
AC_DEFINE(HAVE_LIBZ)
LIBZ="-lz"
LIBS="$LIBS -lz"))
dnl PNG library uses math library functions...
AC_CHECK_LIB(m, pow)
AC_CHECK_HEADER(png.h,
AC_CHECK_LIB(png, png_set_tRNS_to_alpha,
AC_DEFINE(HAVE_LIBPNG)
LIBPNG="-lpng -lm"))
AC_CHECK_HEADER(tiff.h,
AC_CHECK_LIB(tiff, TIFFReadScanline,
AC_DEFINE(HAVE_LIBTIFF)
LIBTIFF="-ltiff"))
dnl Restore original LIBS settings...
LIBS="$SAVELIBS"
dnl
dnl End of "$Id: cups-image.m4 1794 2001-06-27 19:06:46Z mike $".
dnl
-50
Ver Arquivo
@@ -1,50 +0,0 @@
dnl
dnl "$Id: cups-libtool.m4 1794 2001-06-27 19:06:46Z mike $"
dnl
dnl Libtool stuff for the Common UNIX Printing System (CUPS).
dnl
dnl Copyright 1997-2001 by Easy Software Products, all rights reserved.
dnl
dnl These coded instructions, statements, and computer programs are the
dnl property of Easy Software Products and are protected by Federal
dnl copyright law. Distribution and use rights are outlined in the file
dnl "LICENSE.txt" which should have been included with this file. If this
dnl file is missing or damaged please contact Easy Software Products
dnl at:
dnl
dnl Attn: CUPS Licensing Information
dnl Easy Software Products
dnl 44141 Airport View Drive, Suite 204
dnl Hollywood, Maryland 20636-3111 USA
dnl
dnl Voice: (301) 373-9603
dnl EMail: cups-info@cups.org
dnl WWW: http://www.cups.org
dnl
AC_ARG_ENABLE(libtool_unsupported, [ --enable-libtool-unsupported=LIBTOOL_PATH
turn on building with libtool (UNSUPPORTED!) [default=no]],
[if test x$enable_libtool != xno; then
LIBTOOL="$enable_libtool"
enable_shared=no
echo "WARNING: libtool is not supported or endorsed by Easy Software Products."
echo " WE DO NOT PROVIDE TECHNICAL SUPPORT FOR LIBTOOL PROBLEMS."
echo " (even if you have a support contract)"
else
LIBTOOL=""
fi])
AC_SUBST(LIBTOOL)
if test x$LIBTOOL != x; then
LIBCUPS="libcups.la"
LIBCUPSIMAGE="libcupsimage.la"
LINKCUPS="../cups/\$(LIBCUPS)"
LINKCUPSIMAGE="../filter/\$(LIBCUPSIMAGE)"
DSO=":"
DSOFLAGS=""
fi
dnl
dnl End of "$Id: cups-libtool.m4 1794 2001-06-27 19:06:46Z mike $".
dnl
-94
Ver Arquivo
@@ -1,94 +0,0 @@
dnl
dnl "$Id: cups-manpages.m4 1813 2001-06-29 19:14:56Z mike $"
dnl
dnl Manpage stuff for the Common UNIX Printing System (CUPS).
dnl
dnl Copyright 1997-2001 by Easy Software Products, all rights reserved.
dnl
dnl These coded instructions, statements, and computer programs are the
dnl property of Easy Software Products and are protected by Federal
dnl copyright law. Distribution and use rights are outlined in the file
dnl "LICENSE.txt" which should have been included with this file. If this
dnl file is missing or damaged please contact Easy Software Products
dnl at:
dnl
dnl Attn: CUPS Licensing Information
dnl Easy Software Products
dnl 44141 Airport View Drive, Suite 204
dnl Hollywood, Maryland 20636-3111 USA
dnl
dnl Voice: (301) 373-9603
dnl EMail: cups-info@cups.org
dnl WWW: http://www.cups.org
dnl
dnl Fix "mandir" variable...
if test "$mandir" = "\${prefix}/man" -a "$prefix" = "/"; then
case "$uname" in
FreeBSD* | NetBSD* | OpenBSD* | AIX*)
# *BSD + AIX
mandir="/usr/share/man"
AMANDIR="/usr/share/man"
;;
IRIX*)
# SGI IRIX
mandir="/usr/share/catman/u_man"
AMANDIR="/usr/share/catman/a_man"
;;
*)
# All others
mandir="/usr/man"
AMANDIR="/usr/man"
;;
esac
else
AMANDIR="$mandir"
fi
AC_SUBST(AMANDIR)
dnl Setup manpage extensions...
case "$uname" in
FreeBSD* | NetBSD* | OpenBSD*)
# *BSD
CAT1EXT=0
CAT5EXT=0
CAT8EXT=0
MAN8EXT=8
MAN8DIR=8
;;
IRIX*)
# SGI IRIX
CAT1EXT=z
CAT5EXT=z
CAT8EXT=z
MAN8EXT=1m
MAN8DIR=1
;;
SunOS* | HP-UX*)
# Solaris and HP-UX
CAT1EXT=1
CAT5EXT=5
CAT8EXT=1m
MAN8EXT=1m
MAN8DIR=1m
;;
*)
# All others
CAT1EXT=1
CAT5EXT=5
CAT8EXT=8
MAN8EXT=8
MAN8DIR=8
;;
esac
AC_SUBST(CAT1EXT)
AC_SUBST(CAT5EXT)
AC_SUBST(CAT8EXT)
AC_SUBST(MAN8EXT)
AC_SUBST(MAN8DIR)
dnl
dnl End of "$Id: cups-manpages.m4 1813 2001-06-29 19:14:56Z mike $".
dnl
-36
Ver Arquivo
@@ -1,36 +0,0 @@
dnl
dnl "$Id: cups-network.m4 1794 2001-06-27 19:06:46Z mike $"
dnl
dnl Networking stuff for the Common UNIX Printing System (CUPS).
dnl
dnl Copyright 1997-2001 by Easy Software Products, all rights reserved.
dnl
dnl These coded instructions, statements, and computer programs are the
dnl property of Easy Software Products and are protected by Federal
dnl copyright law. Distribution and use rights are outlined in the file
dnl "LICENSE.txt" which should have been included with this file. If this
dnl file is missing or damaged please contact Easy Software Products
dnl at:
dnl
dnl Attn: CUPS Licensing Information
dnl Easy Software Products
dnl 44141 Airport View Drive, Suite 204
dnl Hollywood, Maryland 20636-3111 USA
dnl
dnl Voice: (301) 373-9603
dnl EMail: cups-info@cups.org
dnl WWW: http://www.cups.org
dnl
NETLIBS=""
if test "$uname" != "IRIX"; then
AC_CHECK_LIB(socket,socket,NETLIBS="-lsocket")
AC_CHECK_LIB(nsl,gethostbyaddr,NETLIBS="$NETLIBS -lnsl")
fi
AC_SUBST(NETLIBS)
dnl
dnl End of "$Id: cups-network.m4 1794 2001-06-27 19:06:46Z mike $".
dnl
-66
Ver Arquivo
@@ -1,66 +0,0 @@
dnl
dnl "$Id: cups-openssl.m4 1794 2001-06-27 19:06:46Z mike $"
dnl
dnl OpenSSL stuff for the Common UNIX Printing System (CUPS).
dnl
dnl Copyright 1997-2001 by Easy Software Products, all rights reserved.
dnl
dnl These coded instructions, statements, and computer programs are the
dnl property of Easy Software Products and are protected by Federal
dnl copyright law. Distribution and use rights are outlined in the file
dnl "LICENSE.txt" which should have been included with this file. If this
dnl file is missing or damaged please contact Easy Software Products
dnl at:
dnl
dnl Attn: CUPS Licensing Information
dnl Easy Software Products
dnl 44141 Airport View Drive, Suite 204
dnl Hollywood, Maryland 20636-3111 USA
dnl
dnl Voice: (301) 373-9603
dnl EMail: cups-info@cups.org
dnl WWW: http://www.cups.org
dnl
AC_ARG_ENABLE(ssl, [ --enable-ssl turn on SSL/TLS support [default=yes]])
AC_ARG_WITH(openssl-libs, [ --with-openssl-libs set directory for OpenSSL library],
LDFLAGS="-L$withval $LDFLAGS"
DSOFLAGS="-L$withval $DSOFLAGS",)
AC_ARG_WITH(openssl-includes, [ --with-openssl-includes set directory for OpenSSL includes],
CFLAGS="-I$withval $CFLAGS"
CXXFLAGS="-I$withval $CXXFLAGS",)
dnl Save the current libraries so the crypto stuff isn't always
dnl included...
SAVELIBS="$LIBS"
dnl Some ELF systems can't resolve all the symbols in libcrypto
dnl if libcrypto was linked against RSAREF, and fail to link the
dnl test program correctly, even though a correct installation
dnl of OpenSSL exists. So we test the linking three times in
dnl case the RSAREF libraries are needed.
SSLLIBS=""
for libcrypto in \
"-lcrypto" \
"-lcrypto -lrsaref" \
"-lcrypto -lRSAglue -lrsaref"
do
AC_CHECK_LIB(ssl,SSL_new,
[SSLLIBS="-lssl $libcrypto"
AC_DEFINE(HAVE_LIBSSL)],,
$libcrypto)
if test "x${SSLLIBS}" != "x"; then
break
fi
done
LIBS="$SAVELIBS"
AC_SUBST(SSLLIBS)
dnl
dnl End of "$Id: cups-openssl.m4 1794 2001-06-27 19:06:46Z mike $".
dnl
-85
Ver Arquivo
@@ -1,85 +0,0 @@
dnl
dnl "$Id: cups-opsys.m4 1823 2001-07-03 17:07:29Z mike $"
dnl
dnl Operating system stuff for the Common UNIX Printing System (CUPS).
dnl
dnl Copyright 1997-2001 by Easy Software Products, all rights reserved.
dnl
dnl These coded instructions, statements, and computer programs are the
dnl property of Easy Software Products and are protected by Federal
dnl copyright law. Distribution and use rights are outlined in the file
dnl "LICENSE.txt" which should have been included with this file. If this
dnl file is missing or damaged please contact Easy Software Products
dnl at:
dnl
dnl Attn: CUPS Licensing Information
dnl Easy Software Products
dnl 44141 Airport View Drive, Suite 204
dnl Hollywood, Maryland 20636-3111 USA
dnl
dnl Voice: (301) 373-9603
dnl EMail: cups-info@cups.org
dnl WWW: http://www.cups.org
dnl
dnl Get the operating system and version number...
uname=`uname`
uversion=`uname -r | sed -e '1,$s/[[^0-9]]//g'`
if test x$uname = xIRIX64; then
uname="IRIX"
fi
dnl Determine the correct username and group for this OS...
AC_ARG_WITH(cups-user, [ --with-cups-user set default user for CUPS],
CUPS_USER="$withval",
AC_MSG_CHECKING(for default print user)
if test -f /etc/passwd; then
CUPS_USER=""
for user in lp lpd guest daemon nobody; do
if test "`grep \^${user}: /etc/passwd`" != ""; then
CUPS_USER="$user"
AC_MSG_RESULT($user)
break;
fi
done
if test x$CUPS_USER = x; then
CUPS_USER="${USER:=nobody}"
AC_MSG_RESULT(not found, using "$CUPS_USER")
fi
else
CUPS_USER="${USER:=nobody}"
AC_MSG_RESULT(no password file, using "$CUPS_USER")
fi)
AC_ARG_WITH(cups-group, [ --with-cups-group set default group for CUPS],
CUPS_GROUP="$withval",
AC_MSG_CHECKING(for default print group)
if test -f /etc/group; then
CUPS_GROUP=""
for group in sys system root; do
if test "`grep \^${group}: /etc/group`" != ""; then
CUPS_GROUP="$group"
AC_MSG_RESULT($group)
break;
fi
done
if test x$CUPS_GROUP = x; then
CUPS_GROUP="${GROUP:=nobody}"
AC_MSG_RESULT(not found, using "$CUPS_GROUP")
fi
else
CUPS_GROUP="${GROUP:=nobody}"
AC_MSG_RESULT(no group file, using "$CUPS_GROUP")
fi)
AC_SUBST(CUPS_USER)
AC_SUBST(CUPS_GROUP)
AC_DEFINE(CUPS_DEFAULT_USER, "$CUPS_USER")
AC_DEFINE(CUPS_DEFAULT_GROUP, "$CUPS_GROUP")
dnl
dnl "$Id: cups-opsys.m4 1823 2001-07-03 17:07:29Z mike $"
dnl
-59
Ver Arquivo
@@ -1,59 +0,0 @@
dnl
dnl "$Id: cups-pam.m4 1794 2001-06-27 19:06:46Z mike $"
dnl
dnl PAM stuff for the Common UNIX Printing System (CUPS).
dnl
dnl Copyright 1997-2001 by Easy Software Products, all rights reserved.
dnl
dnl These coded instructions, statements, and computer programs are the
dnl property of Easy Software Products and are protected by Federal
dnl copyright law. Distribution and use rights are outlined in the file
dnl "LICENSE.txt" which should have been included with this file. If this
dnl file is missing or damaged please contact Easy Software Products
dnl at:
dnl
dnl Attn: CUPS Licensing Information
dnl Easy Software Products
dnl 44141 Airport View Drive, Suite 204
dnl Hollywood, Maryland 20636-3111 USA
dnl
dnl Voice: (301) 373-9603
dnl EMail: cups-info@cups.org
dnl WWW: http://www.cups.org
dnl
AC_ARG_ENABLE(pam, [ --enable-pam turn on PAM support [default=yes]])
dnl Don't use PAM with AIX...
if test $uname = AIX; then
enable_pam=no
fi
PAMDIR=""
PAMLIBS=""
if test x$enable_pam != xno; then
SAVELIBS="$LIBS"
AC_CHECK_LIB(dl,dlopen)
AC_CHECK_LIB(pam,pam_start)
if test x$ac_cv_lib_pam_pam_start != xno; then
if test x$ac_cv_lib_dl_dlopen != xno; then
PAMLIBS="-lpam -ldl"
else
PAMLIBS="-lpam"
fi
if test -d /etc/pam.d; then
PAMDIR="/etc/pam.d"
fi
fi
LIBS="$SAVELIBS"
fi
AC_SUBST(PAMDIR)
AC_SUBST(PAMLIBS)
dnl
dnl End of "$Id: cups-pam.m4 1794 2001-06-27 19:06:46Z mike $".
dnl
-136
Ver Arquivo
@@ -1,136 +0,0 @@
dnl
dnl "$Id: cups-sharedlibs.m4 1810 2001-06-29 14:01:15Z mike $"
dnl
dnl Shared library support for the Common UNIX Printing System (CUPS).
dnl
dnl Copyright 1997-2001 by Easy Software Products, all rights reserved.
dnl
dnl These coded instructions, statements, and computer programs are the
dnl property of Easy Software Products and are protected by Federal
dnl copyright law. Distribution and use rights are outlined in the file
dnl "LICENSE.txt" which should have been included with this file. If this
dnl file is missing or damaged please contact Easy Software Products
dnl at:
dnl
dnl Attn: CUPS Licensing Information
dnl Easy Software Products
dnl 44141 Airport View Drive, Suite 204
dnl Hollywood, Maryland 20636-3111 USA
dnl
dnl Voice: (301) 373-9603
dnl EMail: cups-info@cups.org
dnl WWW: http://www.cups.org
dnl
PICFLAG=1
DSOFLAGS="${DSOFLAGS:=}"
AC_ARG_ENABLE(shared, [ --enable-shared turn on shared libraries [default=yes]])
if test x$enable_shared != xno; then
case "$uname" in
SunOS* | UNIX_S*)
LIBCUPS="libcups.so.2"
LIBCUPSIMAGE="libcupsimage.so.2"
DSO="\$(CC)"
DSOFLAGS="$DSOFLAGS -Wl,-h,\$@ -G \$(OPTIM)"
;;
HP-UX*)
LIBCUPS="libcups.sl.2"
LIBCUPSIMAGE="libcupsimage.sl.2"
DSO="ld"
DSOFLAGS="$DSOFLAGS -b -z +h \$@"
;;
OSF1* | Linux* | IRIX* | FreeBSD* | NetBSD* | OpenBSD*)
LIBCUPS="libcups.so.2"
LIBCUPSIMAGE="libcupsimage.so.2"
DSO="\$(CC)"
DSOFLAGS="$DSOFLAGS -Wl,-soname,\$@ -shared \$(OPTIM)"
;;
AIX*)
LIBCUPS="libcups_s.a"
LIBCUPSIMAGE="libcupsimage_s.a"
DSO="\$(CC)"
DSOFLAGS="$DSOFLAGS -Wl,-bexpall,-bM:SRE,-bnoentry"
;;
*)
echo "Warning: shared libraries may not be supported. Trying -shared"
echo " option with compiler."
LIBCUPS="libcups.so.2"
LIBCUPSIMAGE="libcupsimage.so.2"
DSO="\$(CC)"
DSOFLAGS="$DSOFLAGS -Wl,-soname,\$@ -shared \$(OPTIM)"
;;
esac
else
PICFLAG=0
LIBCUPS="libcups.a"
LIBCUPSIMAGE="libcupsimage.a"
DSO=":"
fi
AC_SUBST(DSO)
AC_SUBST(DSOFLAGS)
AC_SUBST(LIBCUPS)
AC_SUBST(LIBCUPSIMAGE)
LDFLAGS="-L../cups -L../filter $LDFLAGS"
if test x$enable_shared = xno; then
LINKCUPS="-lcups"
LINKCUPSIMAGE="-lcupsimage"
LINKCUPS="$LINKCUPS \$(SSLLIBS)"
else
if test $uname = AIX; then
LINKCUPS="-lcups_s"
LINKCUPSIMAGE="-lcupsimage_s"
else
LINKCUPS="-lcups"
LINKCUPSIMAGE="-lcupsimage"
fi
fi
AC_SUBST(LINKCUPS)
AC_SUBST(LINKCUPSIMAGE)
dnl Update libraries for DSOs...
if test "$DSO" != ":"; then
# When using DSOs the image libraries are linked to libcupsimage.so
# rather than to the executables. This makes things smaller if you
# are using any static libraries, and it also allows us to distribute
# a single DSO rather than a bunch...
DSOLIBS="\$(LIBPNG) \$(LIBTIFF) \$(LIBJPEG) \$(LIBZ)"
IMGLIBS=""
# The *BSD, HP-UX, and Solaris run-time linkers need help when
# deciding where to find a DSO. Add linker options to tell them
# where to find the DSO (usually in /usr/lib... duh!)
case $uname in
HP-UX*)
# HP-UX
DSOFLAGS="+b $libdir +fb $DSOFLAGS"
LDFLAGS="$LDFLAGS -Wl,+b,$libdir,+fb"
;;
SunOS*)
# Solaris
DSOFLAGS="-R$libdir $DSOFLAGS"
LDFLAGS="$LDFLAGS -R$libdir"
;;
FreeBSD* | NetBSD* | OpenBSD*)
# *BSD
DSOFLAGS="-Wl,-R$libdir $DSOFLAGS"
LDFLAGS="$LDFLAGS -Wl,-R$libdir"
;;
esac
else
DSOLIBS=""
IMGLIBS="\$(LIBPNG) \$(LIBTIFF) \$(LIBJPEG) \$(LIBZ)"
fi
AC_SUBST(DSOLIBS)
AC_SUBST(IMGLIBS)
dnl
dnl End of "$Id: cups-sharedlibs.m4 1810 2001-06-29 14:01:15Z mike $".
dnl
+1 -41
Ver Arquivo
@@ -28,16 +28,7 @@
* Version of software...
*/
#define CUPS_SVERSION "CUPS v1.1.9"
/*
* Default user and group...
*/
#define CUPS_DEFAULT_USER "lp"
#define CUPS_DEFAULT_GROUP "sys"
#define CUPS_SVERSION "CUPS v1.1.7"
/*
* Where are files stored?
@@ -52,14 +43,12 @@
#define CUPS_DATADIR "/usr/share/cups"
#define CUPS_FONTPATH "/usr/share/cups/fonts"
/*
* What is the format string for strftime?
*/
#define CUPS_STRFTIME_FORMAT NULL
/*
* Do we have various image libraries?
*/
@@ -69,14 +58,12 @@
#undef HAVE_LIBJPEG
#undef HAVE_LIBTIFF
/*
* Does this machine store words in big-endian (MSB-first) order?
*/
#undef WORDS_BIGENDIAN
/*
* Which directory functions and headers do we use?
*/
@@ -86,7 +73,6 @@
#undef HAVE_SYS_NDIR_H
#undef HAVE_NDIR_H
/*
* Do we have PAM stuff?
*/
@@ -95,29 +81,18 @@
#define HAVE_LIBPAM 0
#endif /* !HAVE_LIBPAM */
/*
* Do we have <shadow.h>?
*/
#undef HAVE_SHADOW_H
/*
* Do we have <crypt.h>?
*/
#undef HAVE_CRYPT_H
/*
* Use <string.h>, <strings.h>, or both?
*/
#undef HAVE_STRING_H
#undef HAVE_STRINGS_H
/*
* Do we have the strXXX() functions?
*/
@@ -126,14 +101,12 @@
#undef HAVE_STRCASECMP
#undef HAVE_STRNCASECMP
/*
* Do we have the vsyslog() function?
*/
#undef HAVE_VSYSLOG
/*
* Do we have the (v)snprintf() functions?
*/
@@ -141,7 +114,6 @@
#undef HAVE_SNPRINTF
#undef HAVE_VSNPRINTF
/*
* What signal functions to use?
*/
@@ -149,7 +121,6 @@
#undef HAVE_SIGSET
#undef HAVE_SIGACTION
/*
* What wait functions to use?
*/
@@ -157,7 +128,6 @@
#undef HAVE_WAITPID
#undef HAVE_WAIT3
/*
* Do we have the mallinfo function and malloc.h?
*/
@@ -165,28 +135,18 @@
#undef HAVE_MALLINFO
#undef HAVE_MALLOC_H
/*
* Do we have the OpenSSL library?
*/
#undef HAVE_LIBSSL
/*
* Do we have <sys/ioctl.h>?
*/
#undef HAVE_SYS_IOCTL_H
/*
* Do we have mkstemp()?
*/
#undef HAVE_MKSTEMP
/*
* End of "$Id$".
*/
+637 -12
Ver Arquivo
@@ -23,22 +23,647 @@ dnl WWW: http://www.cups.org
dnl
AC_INIT(cups/cups.h)
AC_CONFIG_HEADER(config.h)
AC_PREFIX_DEFAULT(/)
sinclude(config-scripts/cups-opsys.m4)
sinclude(config-scripts/cups-common.m4)
sinclude(config-scripts/cups-directories.m4)
sinclude(config-scripts/cups-manpages.m4)
dnl Get the operating system and version number...
sinclude(config-scripts/cups-sharedlibs.m4)
sinclude(config-scripts/cups-libtool.m4)
sinclude(config-scripts/cups-compiler.m4)
uname=`uname`
uversion=`uname -r | sed -e '1,$s/[[^0-9]]//g'`
if test "$uname" = "IRIX64"; then
uname="IRIX"
fi
sinclude(config-scripts/cups-image.m4)
sinclude(config-scripts/cups-network.m4)
sinclude(config-scripts/cups-openssl.m4)
sinclude(config-scripts/cups-pam.m4)
dnl Clear the debugging and non-shared library options unless the user asks
dnl for them...
AC_OUTPUT(Makedefs cups.list cups.sh)
OPTIM=""
AC_SUBST(OPTIM)
PICFLAG=1
CFLAGS="${CFLAGS:=}"
CXXFLAGS="${CXXFLAGS:=}"
DSOFLAGS="${DSOFLAGS:=}"
AC_SUBST(DSOFLAGS)
AC_ARG_ENABLE(debug, [ --enable-debug turn on debugging [default=no]],[if eval "test x$enable_debug = xyes"; then
OPTIM="-g"
fi])
AC_ARG_ENABLE(shared, [ --enable-shared turn on shared libraries [default=yes]])
AC_ARG_ENABLE(ssl, [ --enable-ssl turn on SSL/TLS support [default=no]])
AC_ARG_ENABLE(libtool_unsupported, [ --enable-libtool-unsupported=LIBTOOL_PATH
turn on building with libtool (UNSUPPORTED!) [default=no]],[if eval "test x$enable_libtool_unsupported != xno"; then
LIBTOOL="$enable_libtool_unsupported"
enable_shared=no
echo "WARNING: libtool is not supported or endorsed by Easy Software Products."
echo " WE DO NOT PROVIDE TECHNICAL SUPPORT FOR LIBTOOL PROBLEMS."
echo " (even if you have a support contract)"
else
LIBTOOL=""
fi])
if test "$enable_shared" != "no"; then
case "$uname" in
SunOS* | UNIX_S*)
LIBCUPS="libcups.so.2"
LIBCUPSIMAGE="libcupsimage.so.2"
DSO="\$(CC)"
DSOFLAGS="$DSOFLAGS -Wl,-h,\$@ -G \$(OPTIM)"
;;
HP-UX*)
LIBCUPS="libcups.sl.2"
LIBCUPSIMAGE="libcupsimage.sl.2"
DSO="ld"
DSOFLAGS="$DSOFLAGS -b -z +h \$@"
;;
FreeBSD* | NetBSD* | OpenBSD*)
LIBCUPS="libcups.so.2"
LIBCUPSIMAGE="libcupsimage.so.2"
DSO="\$(CC)"
DSOFLAGS="$DSOFLAGS -Wl,-soname,\$@ -shared \$(OPTIM)"
;;
OSF1* | Linux*)
LIBCUPS="libcups.so.2"
LIBCUPSIMAGE="libcupsimage.so.2"
DSO="\$(CC)"
DSOFLAGS="$DSOFLAGS -Wl,-soname,\$@ -shared \$(OPTIM)"
;;
IRIX*)
LIBCUPS="libcups.so.2"
LIBCUPSIMAGE="libcupsimage.so.2"
DSO="\$(CC)"
DSOFLAGS="$DSOFLAGS -soname \$@ -shared \$(OPTIM)"
;;
*)
echo "Warning: shared libraries may not be supported. Trying -shared"
echo " option with compiler."
LIBCUPS="libcups.so.2"
LIBCUPSIMAGE="libcupsimage.so.2"
DSO="\$(CC)"
DSOFLAGS="$DSOFLAGS -Wl,-soname,\$@ -shared \$(OPTIM)"
;;
esac
else
PICFLAG=0
LIBCUPS="libcups.a"
LIBCUPSIMAGE="libcupsimage.a"
DSO=":"
fi
if test "$LIBTOOL" != ""; then
LIBCUPS="libcups.la"
LIBCUPSIMAGE="libcupsimage.la"
LINKCUPS="../cups/\$(LIBCUPS)"
LINKCUPSIMAGE="../filter/\$(LIBCUPSIMAGE)"
DSO=":"
DSOFLAGS=""
else
LINKCUPS="-L../cups -lcups"
LINKCUPSIMAGE="-L../filter -lcupsimage"
fi
AC_ARG_ENABLE(pam, [ --enable-pam turn on PAM support [default=yes]])
AC_ARG_WITH(fontpath, [ --with-fontpath set font path for pstoraster],fontpath="$withval",fontpath="")
AC_ARG_WITH(docdir, [ --with-docdir set path for documentation],docdir="$withval",docdir="")
dnl Checks for programs...
AC_PROG_AWK
AC_PROG_CC
AC_PROG_CXX
AC_PROG_CPP
AC_PROG_RANLIB
AC_PATH_PROG(AR,ar)
AC_PATH_PROG(CHMOD,chmod)
AC_PATH_PROG(CHOWN,chown)
AC_PATH_PROG(CP,cp)
AC_PATH_PROG(MV,mv)
AC_PATH_PROG(NROFF,nroff)
if test "$NROFF" = ""; then
AC_PATH_PROG(GROFF,groff)
if test "$GROFF" = ""; then
NROFF="echo"
else
NROFF="$GROFF -T ascii"
fi
fi
AC_PATH_PROG(HTMLDOC,htmldoc)
AC_PATH_PROG(MKDIR,mkdir)
AC_PATH_PROG(RM,rm)
AC_PATH_PROG(SED,sed)
dnl Architecture checks...
AC_C_BIGENDIAN
dnl Check for libraries...
AC_CHECK_LIB(c,crypt,LIBS="$LIBS")
if test "$ac_cv_lib_c_crypt" = "no"; then
AC_CHECK_LIB(crypt,crypt)
fi
AC_CHECK_LIB(sec,getspent)
LIBMALLOC=""
AC_CHECK_LIB(c,mallinfo,LIBS="$LIBS"; AC_DEFINE(HAVE_MALLINFO),LIBS="$LIBS")
if test "$ac_cv_lib_c_mallinfo" = "no"; then
AC_CHECK_LIB(malloc,mallinfo,
LIBS="$LIBS"
LIBMALLOC="-lmalloc"
AC_DEFINE(HAVE_MALLINFO),
LIBS="$LIBS")
fi
AC_SUBST(LIBMALLOC)
if test "$enable_pam" != "no"; then
OLDLIBS="$LIBS"
AC_CHECK_LIB(dl,dlopen)
AC_CHECK_LIB(pam,pam_start)
if test "$ac_cv_lib_pam_pam_start" != "no"; then
PAMDIR="/etc/pam.d"
else
PAMDIR=""
LIBS="$OLDLIBS"
fi
AC_SUBST(PAMDIR)
fi
NETLIBS=""
AC_SUBST(NETLIBS)
AC_CHECK_LIB(socket,socket,
if test "$uname" != "IRIX"; then
NETLIBS="-lsocket"
else
echo "Not using -lsocket since you are running IRIX."
fi)
AC_CHECK_LIB(nsl,gethostbyaddr,
if test "$uname" != "IRIX"; then
NETLIBS="$NETLIBS -lnsl"
else
echo "Not using -lnsl since you are running IRIX."
fi)
dnl Encryption support...
SSLLIBS=""
AC_SUBST(SSLLIBS)
if test "$enable_ssl" = "yes"; then
dnl Save the current libraries so the crypto stuff isn't always
dnl included...
SAVELIBS="$LIBS"
dnl Some ELF systems can't resolve all the symbols in libcrypto
dnl if libcrypto was linked against RSAREF, and fail to link the
dnl test program correctly, even though a correct installation
dnl of OpenSSL exists. So we test the linking three times in
dnl case the RSAREF libraries are needed.
for libcrypto in \
"-lcrypto" \
"-lcrypto -lrsaref" \
"-lcrypto -lRSAglue -lrsaref"
do
AC_CHECK_LIB(ssl,SSL_new,
[SSLLIBS="-lssl $libcrypto"
AC_DEFINE(HAVE_LIBSSL)],,
$libcrypto
)
if test "x${SSLLIBS}" != "x"; then
break
fi
done
LIBS="$SAVELIBS"
fi
dnl Save the current libraries since we don't want the image libraries
dnl included with every program...
SAVELIBS="$LIBS"
dnl Check for image libraries...
LIBJPEG=""
LIBPNG=""
LIBTIFF=""
LIBZ=""
AC_SUBST(LIBJPEG)
AC_SUBST(LIBPNG)
AC_SUBST(LIBTIFF)
AC_SUBST(LIBZ)
AC_CHECK_LIB(jpeg, jpeg_destroy_decompress,
AC_DEFINE(HAVE_LIBJPEG)
LIBJPEG="-ljpeg"
LIBS="$LIBS -ljpeg")
AC_CHECK_LIB(z, gzgets,
AC_DEFINE(HAVE_LIBZ)
LIBZ="-lz"
LIBS="$LIBS -lz")
dnl PNG library uses math library functions...
AC_CHECK_LIB(m, pow)
AC_CHECK_LIB(png, png_set_tRNS_to_alpha,
AC_DEFINE(HAVE_LIBPNG)
LIBPNG="-lpng")
AC_CHECK_LIB(tiff, TIFFReadScanline,
AC_DEFINE(HAVE_LIBTIFF)
LIBTIFF="-ltiff")
dnl Restore original LIBS settings...
LIBS="$SAVELIBS"
dnl Checks for header files.
AC_HEADER_STDC
AC_HEADER_DIRENT
AC_CHECK_HEADER(crypt.h,AC_DEFINE(HAVE_CRYPT_H))
AC_CHECK_HEADER(malloc.h,AC_DEFINE(HAVE_MALLOC_H))
AC_CHECK_HEADER(shadow.h,AC_DEFINE(HAVE_SHADOW_H))
AC_CHECK_HEADER(stddef.h,AC_DEFINE(HAVE_STDDEF_H))
AC_CHECK_HEADER(stdlib.h,AC_DEFINE(HAVE_STDLIB_H))
AC_CHECK_HEADER(sys/ioctl.h,AC_DEFINE(HAVE_SYS_IOCTL_H))
dnl Checks for string functions.
AC_CHECK_FUNCS(strdup)
AC_CHECK_FUNCS(strcasecmp)
AC_CHECK_FUNCS(strncasecmp)
if test "$uname" = "HP-UX" -a "$uversion" = "1020"; then
echo Forcing snprintf emulation for HP-UX.
else
AC_CHECK_FUNCS(snprintf)
AC_CHECK_FUNCS(vsnprintf)
fi
dnl Check OS version and use appropriate format string for strftime...
AC_MSG_CHECKING(for correct format string to use with strftime)
case "$uname" in
IRIX* | SunOS*)
# IRIX and SunOS
AC_MSG_RESULT(NULL)
AC_DEFINE(CUPS_STRFTIME_FORMAT, NULL)
;;
*)
# All others
AC_MSG_RESULT("%c")
AC_DEFINE(CUPS_STRFTIME_FORMAT, "%c")
;;
esac
dnl Checks for vsyslog function.
AC_CHECK_FUNCS(vsyslog)
dnl Checks for signal functions.
if test "$uname" != "Linux"; then
AC_CHECK_FUNCS(sigset)
fi
AC_CHECK_FUNCS(sigaction)
dnl Checks for wait functions.
AC_CHECK_FUNCS(waitpid)
AC_CHECK_FUNCS(wait3)
dnl Update compiler options...
if test -n "$GCC"; then
CXX="$CC"
if test -z "$OPTIM"; then
OPTIM="-O2"
fi
if test $PICFLAG = 1; then
OPTIM="-fPIC $OPTIM"
fi
OPTIM="-Wall $OPTIM"
else
case $uname in
IRIX*)
if test -z "$OPTIM"; then
OPTIM="-O2"
fi
if test $uversion -ge 62; then
OPTIM="$OPTIM -n32 -mips3"
fi
OPTIM="-fullwarn $OPTIM"
;;
HP-UX*)
if test -z "$OPTIM"; then
OPTIM="+O2"
fi
CFLAGS="-Ae $CFLAGS"
OPTIM="+DAportable $OPTIM"
if test $PICFLAG = 1; then
OPTIM="+z $OPTIM"
fi
;;
SunOS*)
# Solaris
if test -z "$OPTIM"; then
OPTIM="-xO4"
fi
OPTIM="$OPTIM -xarch=generic"
if test $PICFLAG = 1; then
OPTIM="-KPIC $OPTIM"
fi
;;
*)
# Running some other operating system; inform the user they
# should contribute the necessary options to
# cups-support@cups.org...
echo "Building CUPS with default compiler optimizations; contact"
echo "cups-support@cups.org with uname and compiler options needed"
echo "for your platform, or set the CFLAGS environment variable"
echo "before running configure."
;;
esac
fi
if test "$DSO" != ":"; then
# When using DSOs the image libraries are linked to libcupsimage.so
# rather than to the executables. This makes things smaller if you
# are using any static libraries, and it also allows us to distribute
# a single DSO rather than a bunch...
DSOLIBS="\$(LIBPNG) \$(LIBTIFF) \$(LIBJPEG) \$(LIBZ)"
IMGLIBS=""
# The *BSD, HP-UX, and Solaris run-time linkers need help when
# deciding where to find a DSO. Add linker options to tell them
# where to find the DSO (usually in /usr/lib... duh!)
case $uname in
HP-UX*)
# HP-UX
DSOFLAGS="+b $libdir +fb $DSOFLAGS"
LDFLAGS="$LDFLAGS -Wl,+b,$libdir,+fb"
;;
SunOS*)
# Solaris
DSOFLAGS="-R$libdir $DSOFLAGS"
LDFLAGS="$LDFLAGS -R$libdir"
;;
FreeBSD* | NetBSD* | OpenBSD*)
# *BSD
DSOFLAGS="-Wl,-R$libdir $DSOFLAGS"
LDFLAGS="$LDFLAGS -Wl,-R$libdir"
;;
esac
else
DSOLIBS=""
IMGLIBS="\$(LIBPNG) \$(LIBTIFF) \$(LIBJPEG) \$(LIBZ)"
fi
AC_SUBST(DSO)
AC_SUBST(DSOLIBS)
AC_SUBST(IMGLIBS)
AC_SUBST(LIBCUPS)
AC_SUBST(LIBCUPSIMAGE)
AC_SUBST(LIBTOOL)
AC_SUBST(LINKCUPS)
AC_SUBST(LINKCUPSIMAGE)
dnl Fix "prefix" variable if it hasn't been specified...
if test "$prefix" = "NONE"; then
prefix="/"
fi
dnl Fix "exec_prefix" variable if it hasn't been specified...
if test "$exec_prefix" = "NONE"; then
if test "$prefix" = "/"; then
exec_prefix="/usr"
else
exec_prefix="$prefix"
fi
fi
dnl Fix "sharedstatedir" variable if it hasn't been specified...
if test "$sharedstatedir" = "\${prefix}/com" -a "$prefix" = "/"; then
sharedstatedir="/usr/com"
fi
dnl Fix "datadir" variable if it hasn't been specified...
if test "$datadir" = "\${prefix}/share"; then
if test "$prefix" = "/"; then
datadir="/usr/share"
else
datadir="$prefix/share"
fi
fi
dnl Fix "includedir" variable if it hasn't been specified...
if test "$includedir" = "\${prefix}/include" -a "$prefix" = "/"; then
includedir="/usr/include"
fi
dnl Fix "localstatedir" variable if it hasn't been specified...
if test "$localstatedir" = "\${prefix}/var"; then
if test "$prefix" = "/"; then
localstatedir="/var"
else
localstatedir="$prefix/var"
fi
fi
dnl Fix "sysconfdir" variable if it hasn't been specified...
if test "$sysconfdir" = "\${prefix}/etc"; then
if test "$prefix" = "/"; then
sysconfdir="/etc"
else
sysconfdir="$prefix/etc"
fi
fi
dnl Fix "libdir" variable for IRIX 6.x...
if test "$uname" = "IRIX" -a $uversion -ge 62; then
libdir="$exec_prefix/lib32"
fi
dnl Fix "mandir" variable...
if test "$mandir" = "\${prefix}/man" -a "$prefix" = "/"; then
case "$uname" in
FreeBSD* | NetBSD* | OpenBSD*)
# *BSD
mandir="/usr/share/man"
AMANDIR="/usr/share/man"
;;
IRIX*)
# SGI IRIX
mandir="/usr/share/catman/u_man"
AMANDIR="/usr/share/catman/a_man"
;;
*)
# All others
mandir="/usr/man"
AMANDIR="/usr/man"
;;
esac
else
AMANDIR="$mandir"
fi
AC_SUBST(AMANDIR)
dnl Fix "fontpath" variable...
if test "x$fontpath" = "x"; then
fontpath="$datadir/cups/fonts"
fi
dnl Setup manpage extensions...
case "$uname" in
FreeBSD* | NetBSD* | OpenBSD*)
# *BSD
CAT1EXT=0
CAT5EXT=0
CAT8EXT=0
MAN8EXT=8
;;
IRIX*)
# SGI IRIX
CAT1EXT=z
CAT5EXT=z
CAT8EXT=z
MAN8EXT=1m
;;
SunOS* | HP-UX*)
# Solaris and HP-UX
CAT1EXT=1
CAT5EXT=5
CAT8EXT=1m
MAN8EXT=1m
;;
*)
# All others
CAT1EXT=1
CAT5EXT=5
CAT8EXT=8
MAN8EXT=8
;;
esac
AC_SUBST(CAT1EXT)
AC_SUBST(CAT5EXT)
AC_SUBST(CAT8EXT)
AC_SUBST(MAN8EXT)
dnl Setup init.d locations...
case "$uname" in
FreeBSD* | OpenBSD*)
# FreeBSD and OpenBSD
INITDIR=""
INITDDIR=""
;;
NetBSD*)
# NetBSD
INITDIR=""
INITDDIR="/etc/rc.d"
;;
Linux*)
# Linux seems to choose an init.d directory at random...
if test -d /sbin/init.d; then
# SuSE
INITDIR="/sbin/init.d"
INITDDIR=".."
else
if test -d /etc/rc.d; then
# RedHat
INITDIR="/etc/rc.d"
INITDDIR="../init.d"
else
# Others
INITDIR="/etc"
INITDDIR="../init.d"
fi
fi
;;
OSF1* | HP-UX*)
INITDIR="/sbin"
INITDDIR="../init.d"
;;
*)
INITDIR="/etc"
INITDDIR="../init.d"
;;
esac
AC_SUBST(INITDIR)
AC_SUBST(INITDDIR)
dnl Setup default locations...
CUPS_SERVERROOT='${sysconfdir}/cups'
CUPS_LOGDIR='${localstatedir}/log/cups'
CUPS_REQUESTS='${localstatedir}/spool/cups'
AC_DEFINE_UNQUOTED(CUPS_SERVERROOT, "$sysconfdir/cups")
AC_DEFINE_UNQUOTED(CUPS_LOGDIR, "$localstatedir/log/cups")
AC_DEFINE_UNQUOTED(CUPS_REQUESTS, "$localstatedir/spool/cups")
dnl See what directory to put server executables...
case "$uname" in
FreeBSD* | NetBSD* | OpenBSD*)
# *BSD
INSTALL_SYSV=""
CUPS_SERVERBIN='${exec_prefix}/libexec/cups'
AC_DEFINE_UNQUOTED(CUPS_SERVERBIN, "$exec_prefix/libexec/cups")
;;
*)
# All others
INSTALL_SYSV="install-sysv"
CUPS_SERVERBIN='${exec_prefix}/lib/cups'
AC_DEFINE_UNQUOTED(CUPS_SERVERBIN, "$exec_prefix/lib/cups")
;;
esac
AC_SUBST(INSTALL_SYSV)
AC_SUBST(CUPS_SERVERROOT)
AC_SUBST(CUPS_SERVERBIN)
AC_SUBST(CUPS_LOGDIR)
AC_SUBST(CUPS_REQUESTS)
dnl Set the CUPS_LOCALE directory...
case "$uname" in
Linux* | FreeBSD* | NetBSD* | OpenBSD*)
CUPS_LOCALEDIR='${datadir}/locale'
AC_DEFINE_UNQUOTED(CUPS_LOCALEDIR, "$datadir/locale")
;;
OSF1*)
CUPS_LOCALEDIR='${exec_prefix}/lib/nls/msg'
AC_DEFINE_UNQUOTED(CUPS_LOCALEDIR, "$exec_prefix/lib/nls/msg")
;;
*)
# This is the standard System V location...
CUPS_LOCALEDIR='${exec_prefix}/lib/locale'
AC_DEFINE_UNQUOTED(CUPS_LOCALEDIR, "$exec_prefix/lib/locale")
;;
esac
AC_SUBST(CUPS_LOCALEDIR)
dnl Set the CUPS_DATADIR directory...
CUPS_DATADIR='${datadir}/cups'
AC_DEFINE_UNQUOTED(CUPS_DATADIR, "$datadir/cups")
AC_SUBST(CUPS_DATADIR)
dnl Set the CUPS_DOCROOT directory...
if test x$docdir = x; then
CUPS_DOCROOT='${datadir}/doc/cups'
docdir="$datadir/doc/cups"
else
CUPS_DOCROOT="$docdir"
fi
AC_DEFINE_UNQUOTED(CUPS_DOCROOT, "$docdir")
AC_SUBST(CUPS_DOCROOT)
dnl Set the CUPS_FONTPATH directory...
AC_DEFINE_UNQUOTED(CUPS_FONTPATH, "$fontpath")
AC_OUTPUT(Makedefs cups.sh)
dnl
dnl End of "$Id$".
+320
Ver Arquivo
@@ -0,0 +1,320 @@
#
# "$Id: cups.list 1682 2001-04-19 16:35:35Z mike $"
#
# ESP Package Manager (EPM) file list for the Common UNIX Printing
# System (CUPS).
#
# Copyright 1997-2001 by Easy Software Products, all rights reserved.
#
# These coded instructions, statements, and computer programs are the
# property of Easy Software Products and are protected by Federal
# copyright law. Distribution and use rights are outlined in the file
# "LICENSE.txt" which should have been included with this file. If this
# file is missing or damaged please contact Easy Software Products
# at:
#
# Attn: CUPS Licensing Information
# Easy Software Products
# 44141 Airport View Drive, Suite 204
# Hollywood, Maryland 20636-3111 USA
#
# Voice: (301) 373-9603
# EMail: cups-info@cups.org
# WWW: http://www.cups.org
#
# Product information
%product Common UNIX Printing System
%copyright 1993-2001 by Easy Software Products, All Rights Reserved.
%vendor Easy Software Products
%license LICENSE.txt
%readme README.txt
%version 1.1.7
%incompat printpro
# Server programs
%system all
# Server files
f 0555 root sys $SBINDIR/cupsd scheduler/cupsd
d 0555 root sys $SERVERBIN -
d 0555 root sys $SERVERBIN/backend -
f 0555 root sys $SERVERBIN/backend/ipp backend/ipp
l 0555 root sys $SERVERBIN/backend/http ipp
f 0555 root sys $SERVERBIN/backend/lpd backend/lpd
f 0555 root sys $SERVERBIN/backend/parallel backend/parallel
f 0555 root sys $SERVERBIN/backend/serial backend/serial
f 0555 root sys $SERVERBIN/backend/socket backend/socket
f 0555 root sys $SERVERBIN/backend/usb backend/usb
d 0555 root sys $SERVERBIN/cgi-bin -
f 0555 root sys $SERVERBIN/cgi-bin/admin.cgi cgi-bin/admin.cgi
f 0555 root sys $SERVERBIN/cgi-bin/classes.cgi cgi-bin/classes.cgi
f 0555 root sys $SERVERBIN/cgi-bin/jobs.cgi cgi-bin/jobs.cgi
f 0555 root sys $SERVERBIN/cgi-bin/printers.cgi cgi-bin/printers.cgi
d 0555 root sys $SERVERBIN/daemon -
f 0555 root sys $SERVERBIN/daemon/cups-lpd scheduler/cups-lpd
f 0555 root sys $SERVERBIN/daemon/cups-polld scheduler/cups-polld
d 0555 root sys $SERVERBIN/filter -
f 0555 root sys $SERVERBIN/filter/pstoraster pstoraster/pstoraster
f 0555 root sys $SERVERBIN/filter/pdftops pdftops/pdftops
f 0555 root sys $SERVERBIN/filter/imagetops filter/imagetops
f 0555 root sys $SERVERBIN/filter/pstops filter/pstops
f 0555 root sys $SERVERBIN/filter/texttops filter/texttops
f 0555 root sys $SERVERBIN/filter/rastertoepson filter/rastertoepson
f 0555 root sys $SERVERBIN/filter/rastertohp filter/rastertohp
f 0555 root sys $SERVERBIN/filter/hpgltops filter/hpgltops
f 0555 root sys $SERVERBIN/filter/imagetoraster filter/imagetoraster
# Admin commands
l 0555 root sys $BINDIR/disable $SBINDIR/accept
l 0555 root sys $BINDIR/enable $SBINDIR/accept
l 0555 root sys $LIBDIR/accept $SBINDIR/accept
l 0555 root sys $LIBDIR/lpadmin $SBINDIR/lpadmin
l 0555 root sys $LIBDIR/reject accept
f 0555 root sys $SBINDIR/accept systemv/accept
f 0555 root sys $SBINDIR/lpadmin systemv/lpadmin
f 0555 root sys $SBINDIR/lpc berkeley/lpc
f 0555 root sys $SBINDIR/lpinfo systemv/lpinfo
f 0555 root sys $SBINDIR/lpmove systemv/lpmove
l 0555 root sys $SBINDIR/reject accept
%system irix
l 0555 root sys /usr/etc/lpc $SBINDIR/lpc
%system all
# User commands
f 0555 root sys $BINDIR/cancel systemv/cancel
f 0555 root sys $BINDIR/lp systemv/lp
f 0555 root sys $BINDIR/lpoptions systemv/lpoptions
f 4555 root sys $BINDIR/lppasswd systemv/lppasswd
f 0555 root sys $BINDIR/lpq berkeley/lpq
f 0555 root sys $BINDIR/lpr berkeley/lpr
f 0555 root sys $BINDIR/lprm berkeley/lprm
f 0555 root sys $BINDIR/lpstat systemv/lpstat
%system irix
l 0555 root sys /usr/bsd/lpq $BINDIR/lpq
l 0555 root sys /usr/bsd/lpr $BINDIR/lpr
l 0555 root sys /usr/bsd/lprm $BINDIR/lprm
%system all
# DSOs
%system hpux
f 0555 root sys $LIBDIR/libcups.sl.2 cups/libcups.sl.2
l 0555 root sys $LIBDIR/libcups.sl libcups.sl.2
f 0555 root sys $LIBDIR/libcupsimage.sl.2 filter/libcupsimage.sl.2
l 0555 root sys $LIBDIR/libcupsimage.sl libcupsimage.sl.2
%system !hpux
f 0555 root sys $LIBDIR/libcups.so.2 cups/libcups.so.2
l 0555 root sys $LIBDIR/libcups.so libcups.so.2
f 0555 root sys $LIBDIR/libcupsimage.so.2 filter/libcupsimage.so.2
l 0555 root sys $LIBDIR/libcupsimage.so libcupsimage.so.2
%system all
# Directories
d 0755 root sys $LOGDIR -
d 0700 lp sys $REQUESTS -
d 1700 lp sys $REQUESTS/tmp -
# Data files
f 0444 root sys $LOCALEDIR/C/cups_C locale/C/cups_C
f 0444 root sys $LOCALEDIR/de/cups_de locale/de/cups_de
f 0444 root sys $LOCALEDIR/en/cups_en locale/en/cups_en
f 0444 root sys $LOCALEDIR/es/cups_es locale/es/cups_es
f 0444 root sys $LOCALEDIR/fr/cups_fr locale/fr/cups_fr
f 0444 root sys $LOCALEDIR/it/cups_it locale/it/cups_it
d 0555 root sys $DATADIR -
d 0555 root sys $DATADIR/banners -
f 0444 root sys $DATADIR/banners/classified data/classified
f 0444 root sys $DATADIR/banners/confidential data/confidential
f 0444 root sys $DATADIR/banners/secret data/secret
f 0444 root sys $DATADIR/banners/standard data/standard
f 0444 root sys $DATADIR/banners/topsecret data/topsecret
f 0444 root sys $DATADIR/banners/unclassified data/unclassified
d 0555 root sys $DATADIR/charsets -
f 0444 root sys $DATADIR/charsets/windows-874 data/windows-874
f 0444 root sys $DATADIR/charsets/windows-1250 data/windows-1250
f 0444 root sys $DATADIR/charsets/windows-1251 data/windows-1251
f 0444 root sys $DATADIR/charsets/windows-1252 data/windows-1252
f 0444 root sys $DATADIR/charsets/windows-1253 data/windows-1253
f 0444 root sys $DATADIR/charsets/windows-1254 data/windows-1254
f 0444 root sys $DATADIR/charsets/windows-1255 data/windows-1255
f 0444 root sys $DATADIR/charsets/windows-1256 data/windows-1256
f 0444 root sys $DATADIR/charsets/windows-1257 data/windows-1257
f 0444 root sys $DATADIR/charsets/windows-1258 data/windows-1258
f 0444 root sys $DATADIR/charsets/iso-8859-1 data/iso-8859-1
f 0444 root sys $DATADIR/charsets/iso-8859-14 data/iso-8859-14
f 0444 root sys $DATADIR/charsets/iso-8859-15 data/iso-8859-15
f 0444 root sys $DATADIR/charsets/iso-8859-2 data/iso-8859-2
f 0444 root sys $DATADIR/charsets/iso-8859-3 data/iso-8859-3
f 0444 root sys $DATADIR/charsets/iso-8859-4 data/iso-8859-4
f 0444 root sys $DATADIR/charsets/iso-8859-5 data/iso-8859-5
f 0444 root sys $DATADIR/charsets/iso-8859-6 data/iso-8859-6
f 0444 root sys $DATADIR/charsets/iso-8859-7 data/iso-8859-7
f 0444 root sys $DATADIR/charsets/iso-8859-8 data/iso-8859-8
f 0444 root sys $DATADIR/charsets/iso-8859-9 data/iso-8859-9
f 0444 root sys $DATADIR/charsets/utf-8 data/utf-8
d 0555 root sys $DATADIR/data -
f 0444 root sys $DATADIR/data/HPGLprolog data/HPGLprolog
f 0444 root sys $DATADIR/data/psglyphs data/psglyphs
f 0444 root sys $DATADIR/data/testprint.ps data/testprint.ps
d 0555 root sys $DATADIR/fonts -
f 0444 root sys $DATADIR/fonts fonts/*
d 0555 root sys $DATADIR/pstoraster -
f 0444 root sys $DATADIR/pstoraster/Fontmap pstoraster/Fontmap
f 0444 root sys $DATADIR/pstoraster pstoraster/gs*.ps
d 0555 root sys $DATADIR/model -
f 0444 root sys $DATADIR/model ppd/*.ppd
d 0555 root sys $DATADIR/templates -
f 0444 root sys $DATADIR/templates templates/*.tmpl
# Config files
d 0555 root sys $SERVERROOT -
d 0711 root sys $SERVERROOT/certs -
d 0755 root sys $SERVERROOT/interfaces -
d 0755 root sys $SERVERROOT/ppd -
c 0644 root sys $SERVERROOT conf/*.conf
f 0644 root sys $SERVERROOT/mime.convs conf/mime.convs
f 0644 root sys $SERVERROOT/mime.types conf/mime.types
%system linux
d 0555 root sys $PAMDIR -
c 0644 root sys $PAMDIR/cups data/cups.pam
c 0644 root sys $PAMDIR/cups.suse data/cups.suse
%install if test -f /lib/security/pam_unix.so; then
%install mv $PAMDIR/cups.suse $PAMDIR/cups
%install fi
%system all
# Developer files
d 0555 root sys $INCLUDEDIR/cups -
f 0444 root sys $INCLUDEDIR/cups/cups.h cups/cups.h
f 0444 root sys $INCLUDEDIR/cups/http.h cups/http.h
f 0444 root sys $INCLUDEDIR/cups/image.h filter/image.h
f 0444 root sys $INCLUDEDIR/cups/ipp.h cups/ipp.h
f 0444 root sys $INCLUDEDIR/cups/language.h cups/language.h
f 0444 root sys $INCLUDEDIR/cups/md5.h cups/md5.h
f 0444 root sys $INCLUDEDIR/cups/ppd.h cups/ppd.h
f 0444 root sys $INCLUDEDIR/cups/raster.h filter/raster.h
f 0444 root sys $LIBDIR/libcups.a cups/libcups.a
# Documentation files
d 0555 root sys $DOCDIR -
f 0444 root sys $DOCDIR/cups.css doc/cups.css
f 0444 root sys $DOCDIR doc/*.html
f 0444 root sys $DOCDIR doc/*.pdf
d 0555 root sys $DOCDIR/images -
f 0444 root sys $DOCDIR/images doc/images/*.gif
# Man pages
%system irix
d 0555 root sys $AMANDIR -
d 0555 root sys $AMANDIR/cat1 -
d 0555 root sys $MANDIR -
d 0555 root sys $MANDIR/cat1 -
d 0555 root sys $MANDIR/cat5 -
f 0444 root sys $AMANDIR/cat1/accept.z man/accept.z
l 0444 root sys $AMANDIR/cat1/reject.z accept.z
f 0444 root sys $MANDIR/cat1/backend.z man/backend.z
f 0444 root sys $MANDIR/cat5/classes.conf.z man/classes.conf.z
f 0444 root sys $AMANDIR/cat1/cups-lpd.z man/cups-lpd.z
f 0444 root sys $AMANDIR/cat1/cups-polld.z man/cups-polld.z
f 0444 root sys $MANDIR/cat5/cupsd.conf.z man/cupsd.conf.z
f 0444 root sys $AMANDIR/cat1/cupsd.z man/cupsd.z
f 0444 root sys $AMANDIR/cat1/enable.z man/enable.z
l 0444 root sys $AMANDIR/cat1/disable.z enable.z
f 0444 root sys $MANDIR/cat1/filter.z man/filter.z
f 0444 root sys $AMANDIR/cat1/lpadmin.z man/lpadmin.z
f 0444 root sys $AMANDIR/cat1/lpc.z man/lpc.z
f 0444 root sys $AMANDIR/cat1/lpinfo.z man/lpinfo.z
f 0444 root sys $AMANDIR/cat1/lpmove.z man/lpmove.z
f 0444 root sys $MANDIR/cat1/lpoptions.z man/lpoptions.z
f 0444 root sys $MANDIR/cat1/lpq.z man/lpq.z
f 0444 root sys $MANDIR/cat1/lprm.z man/lprm.z
f 0444 root sys $MANDIR/cat1/lpr.z man/lpr.z
f 0444 root sys $MANDIR/cat1/lpstat.z man/lpstat.z
f 0444 root sys $MANDIR/cat1/lp.z man/lp.z
l 0444 root sys $MANDIR/cat1/cancel.z lp.z
f 0444 root sys $MANDIR/cat5/mime.convs.z man/mime.convs.z
f 0444 root sys $MANDIR/cat5/mime.types.z man/mime.types.z
f 0444 root sys $MANDIR/cat5/printers.conf.z man/printers.conf.z
%system solaris hpux
d 0555 root sys $MANDIR/man1 -
d 0555 root sys $MANDIR/man5 -
d 0555 root sys $MANDIR/man1m -
f 0444 root sys $MANDIR/man1m/accept.1m man/accept.man
l 0444 root sys $MANDIR/man1m/reject.1m accept.1m
f 0444 root sys $MANDIR/man1/backend.1 man/backend.man
f 0444 root sys $MANDIR/man1/classes.conf.5 man/classes.conf.man
f 0444 root sys $MANDIR/man1m/cups-lpd.1m man/cups-lpd.man
f 0444 root sys $MANDIR/man1m/cups-polld.1m man/cups-polld.man
f 0444 root sys $MANDIR/man1m/cupsd.1m man/cupsd.man
f 0444 root sys $MANDIR/man5/cupsd.conf.5 man/cupsd.conf.man
f 0444 root sys $MANDIR/man1m/enable.1m man/enable.man
l 0444 root sys $MANDIR/man1m/disable.1m enable.1m
f 0444 root sys $MANDIR/man1/filter.1 man/filter.man
f 0444 root sys $MANDIR/man1m/lpadmin.1m man/lpadmin.man
f 0444 root sys $MANDIR/man1m/lpc.1m man/lpc.man
f 0444 root sys $MANDIR/man1m/lpinfo.1m man/lpinfo.man
f 0444 root sys $MANDIR/man1m/lpmove.1m man/lpmove.man
f 0444 root sys $MANDIR/man1/lpoptions.1 man/lpoptions.man
f 0444 root sys $MANDIR/man1/lpq.1 man/lpq.man
f 0444 root sys $MANDIR/man1/lprm.1 man/lprm.man
f 0444 root sys $MANDIR/man1/lpr.1 man/lpr.man
f 0444 root sys $MANDIR/man1/lpstat.1 man/lpstat.man
f 0444 root sys $MANDIR/man1/lp.1 man/lp.man
l 0444 root sys $MANDIR/man1/cancel.1 lp.1
f 0444 root sys $MANDIR/man5/mime.convs.5 man/mime.convs.man
f 0444 root sys $MANDIR/man5/mime.types.5 man/mime.types.man
f 0444 root sys $MANDIR/man5/printers.conf.5 man/printers.conf.man
%system !irix !solaris !hpux
d 0555 root sys $MANDIR/man1 -
d 0555 root sys $MANDIR/man5 -
d 0555 root sys $MANDIR/man8 -
f 0444 root sys $MANDIR/man8/accept.8 man/accept.man
l 0444 root sys $MANDIR/man8/reject.8 accept.8
f 0444 root sys $MANDIR/man1/backend.1 man/backend.man
f 0444 root sys $MANDIR/man1/classes.conf.5 man/classes.conf.man
f 0444 root sys $MANDIR/man8/cups-lpd.8 man/cups-lpd.man
f 0444 root sys $MANDIR/man8/cups-polld.8 man/cups-polld.man
f 0444 root sys $MANDIR/man8/cupsd.8 man/cupsd.man
f 0444 root sys $MANDIR/man5/cupsd.conf.5 man/cupsd.conf.man
f 0444 root sys $MANDIR/man8/enable.8 man/enable.man
l 0444 root sys $MANDIR/man8/disable.8 enable.8
f 0444 root sys $MANDIR/man1/filter.1 man/filter.man
f 0444 root sys $MANDIR/man8/lpadmin.8 man/lpadmin.man
f 0444 root sys $MANDIR/man8/lpc.8 man/lpc.man
f 0444 root sys $MANDIR/man8/lpinfo.8 man/lpinfo.man
f 0444 root sys $MANDIR/man8/lpmove.8 man/lpmove.man
f 0444 root sys $MANDIR/man1/lpoptions.1 man/lpoptions.man
f 0444 root sys $MANDIR/man1/lpq.1 man/lpq.man
f 0444 root sys $MANDIR/man1/lprm.1 man/lprm.man
f 0444 root sys $MANDIR/man1/lpr.1 man/lpr.man
f 0444 root sys $MANDIR/man1/lpstat.1 man/lpstat.man
f 0444 root sys $MANDIR/man1/lp.1 man/lp.man
l 0444 root sys $MANDIR/man1/cancel.1 lp.1
f 0444 root sys $MANDIR/man5/mime.convs.5 man/mime.convs.man
f 0444 root sys $MANDIR/man5/mime.types.5 man/mime.types.man
f 0444 root sys $MANDIR/man5/printers.conf.5 man/printers.conf.man
# Startup script
%system all
i 0555 root sys cups cups.sh
#
# End of "$Id: cups.list 1682 2001-04-19 16:35:35Z mike $".
#
+2 -6
Ver Arquivo
@@ -28,7 +28,7 @@
#
# Linux chkconfig stuff:
#
# chkconfig: 235 99 00
# chkconfig: 0235 99 00
# description: Startup/shutdown script for the Common UNIX \
# Printing System (CUPS).
#
@@ -76,13 +76,9 @@ fi
#
case "`uname`" in
IRIX* | HP-UX* | SunOS* | AIX* | SINIX*)
IRIX* | HP-UX* | SunOS*)
pid=`ps -e | awk '{print $1,$4}' | grep cupsd | awk '{print $1}'`
;;
UnixWare*)
pid=`ps -e | awk '{print $1,$6}' | grep cupsd | awk '{print $1}'`
. /etc/TIMEZONE
;;
OSF1*)
pid=`ps -e | awk '{print $1,$5}' | grep cupsd | awk '{print $1}'`
;;
+12 -52
Ver Arquivo
@@ -1,5 +1,5 @@
#
# "$Id: cups.spec 1824 2001-07-05 15:34:47Z mike $"
# "$Id: cups.spec 1615 2001-03-06 18:37:49Z mike $"
#
# RPM "spec" file for the Common UNIX Printing System (CUPS).
#
@@ -26,8 +26,8 @@
Summary: Common Unix Printing System
Name: cups
Version: 1.1.9
Release: 1
Version: 1.1.7
Release: 0
Copyright: GPL
Group: System Environment/Daemons
Source: ftp://ftp.easysw.com/pub/cups/%{version}/cups-%{version}-source.tar.gz
@@ -37,19 +37,11 @@ Vendor: Easy Software Products
# use buildroot so as not to disturb the version already installed
BuildRoot: /var/tmp/%{name}-root
Conflicts: lpr, LPRng
Provides: libcups.so.2
Provides: libcupsimage.so.2
Provides: cups
%package devel
Summary: Common Unix Printing System - development environment
Group: Development/Libraries
%package pstoraster
Summary: Common Unix Printing System - PostScript RIP
Group: System Environment/Daemons
Provides: pstoraster
%description
The Common UNIX Printing System provides a portable printing layer for
UNIX® operating systems. It has been developed by Easy Software Products
@@ -61,11 +53,6 @@ The Common UNIX Printing System provides a portable printing layer for
UNIX® operating systems. This is the development package for creating
additional printer drivers, and other CUPS services.
%description pstoraster
The Common UNIX Printing System provides a portable printing layer for
UNIX® operating systems. This is the PostScript RIP package for
supporting non-PostScript printer drivers.
%prep
%setup
@@ -76,8 +63,13 @@ supporting non-PostScript printer drivers.
make
%install
# Make sure the RPM_BUILD_ROOT directory exists.
# these lines just make sure the directory structure in the
# RPM_BUILD_ROOT exists
rm -rf $RPM_BUILD_ROOT
mkdir -p $RPM_BUILD_ROOT/etc/rc.d/init.d
mkdir -p $RPM_BUILD_ROOT/etc/rc.d/rc0.d
mkdir -p $RPM_BUILD_ROOT/etc/rc.d/rc3.d
mkdir -p $RPM_BUILD_ROOT/etc/rc.d/rc5.d
make prefix=$RPM_BUILD_ROOT \
exec_prefix=$RPM_BUILD_ROOT/usr \
@@ -87,7 +79,6 @@ make prefix=$RPM_BUILD_ROOT \
DOCDIR=$RPM_BUILD_ROOT/usr/share/doc/cups \
INCLUDEDIR=$RPM_BUILD_ROOT/usr/include \
LIBDIR=$RPM_BUILD_ROOT/usr/lib \
LOGDIR=$RPM_BUILD_ROOT/var/log/cups \
LOCALEDIR=$RPM_BUILD_ROOT/usr/share/locale \
MANDIR=$RPM_BUILD_ROOT/usr/man \
PAMDIR=$RPM_BUILD_ROOT/etc/pam.d \
@@ -166,34 +157,11 @@ rm -rf $RPM_BUILD_ROOT
/usr/bin/*
/usr/lib/*.so*
%dir /usr/lib/cups
%dir /usr/lib/cups/backend
/usr/lib/cups/backend/*
%dir /usr/lib/cups/cgi-bin
/usr/lib/cups/cgi-bin/*
%dir /usr/lib/cups/daemon
/usr/lib/cups/daemon/*
%dir /usr/lib/cups/filter
/usr/lib/cups/filter/hpgltops
/usr/lib/cups/filter/imagetops
/usr/lib/cups/filter/imagetoraster
/usr/lib/cups/filter/pdftops
/usr/lib/cups/filter/pstops
/usr/lib/cups/filter/rastertoepson
/usr/lib/cups/filter/rastertohp
/usr/lib/cups/filter/texttops
/usr/lib/cups/*
/usr/man/*
/usr/sbin/*
%dir /usr/share/cups
%dir /usr/share/cups/banners
/usr/share/cups/banners/*
%dir /usr/share/cups/charsets
/usr/share/cups/charsets/*
%dir /usr/share/cups/data
/usr/share/cups/data/*
%dir /usr/share/cups/model
/usr/share/cups/model/*
%dir /usr/share/cups/templates
/usr/share/cups/templates/*
/usr/share/cups/*
%dir /usr/share/doc/cups
/usr/share/doc/cups/*
%dir /usr/share/locale
@@ -206,14 +174,6 @@ rm -rf $RPM_BUILD_ROOT
/usr/include/cups/*
/usr/lib/*.a
%files pstoraster
%dir /usr/lib/cups/filter
/usr/lib/cups/filter/pstoraster
%dir /usr/share/cups/fonts
/usr/share/cups/fonts/*
%dir /usr/share/cups/pstoraster
/usr/share/cups/pstoraster/*
#
# End of "$Id: cups.spec 1824 2001-07-05 15:34:47Z mike $".
# End of "$Id: cups.spec 1615 2001-03-06 18:37:49Z mike $".
#
+14 -25
Ver Arquivo
@@ -31,7 +31,7 @@ include ../Makedefs
LIBOBJS = dest.o emit.o encode.o http.o ipp.o language.o mark.o md5.o \
md5passwd.o options.o page.o ppd.o snprintf.o string.o \
tempfile.o usersys.o util.o
OBJS = $(LIBOBJS) testhttp.o testppd.o ppd-debug.o
OBJS = $(LIBOBJS) testhttp.o testppd.o
#
@@ -68,17 +68,22 @@ clean:
#
install: all
$(INSTALL_DIR) $(INCLUDEDIR)/cups
-$(MKDIR) $(INCLUDEDIR)/cups
$(CHMOD) ugo+rx $(INCLUDEDIR)
$(CHMOD) ugo+rx $(INCLUDEDIR)/cups
$(INSTALL_DATA) $(HEADERS) $(INCLUDEDIR)/cups
$(INSTALL_DIR) $(LIBDIR)
-$(MKDIR) $(LIBDIR)
$(CHMOD) ugo+rx $(LIBDIR)
$(INSTALL_LIB) $(LIBCUPS) $(LIBDIR)
if test $(LIBCUPS) = "libcups.so.2" -o $(LIBCUPS) = "libcups.sl.2"; then \
$(INSTALL_LIB) libcups.a `basename $(LIBCUPS) .2` $(LIBDIR); \
if test $(LIBCUPS) != "libcups.a" -a $(LIBCUPS) != "libcups.la"; then \
$(INSTALL_LIB) libcups.a $(LIBDIR); \
$(RM) $(LIBDIR)/`basename $(LIBCUPS) .2`; \
$(LN) $(LIBCUPS) $(LIBDIR)/`basename $(LIBCUPS) .2`; \
fi
#
# libcups.so.2, libcups.sl.2
# libcups.so.2, libcups.sl.1
#
libcups.so.2 libcups.sl.2: $(LIBOBJS) ../Makedefs
@@ -88,19 +93,6 @@ libcups.so.2 libcups.sl.2: $(LIBOBJS) ../Makedefs
$(LN) $@ `basename $@ .2`
#
# libcups_s.a
#
libcups_s.a: $(LIBOBJS) ../Makedefs
echo Creating $@...
$(RM) libcups_s.exp
(echo _ipp_add_attr; echo _ipp_free_attr) >libcups_s.exp
$(DSO) $(DSOFLAGS) -Wl,-bexport:libcups_s.exp -o libcups_s.o $(LIBOBJS) $(SSLLIBS) -lm
$(RM) $@
$(AR) $(ARFLAGS) $@ libcups_s.o
#
# libcups.la
#
@@ -161,17 +153,14 @@ testhttp.o: http.h
#
# testppd
# testppd (dependency on static CUPS library is intentional)
#
testppd: testppd.o ppd-debug.o language.o mark.o page.o
testppd: testppd.o libcups.a
echo Linking $@...
$(CC) $(LDFLAGS) -o $@ testppd.o ppd-debug.o language.o mark.o page.o
$(CC) $(LDFLAGS) -o $@ testppd.o libcups.a $(NETLIBS)
testppd.o: ppd.h
ppd-debug.o: ppd.c language.h ppd.h
echo Compiling $< with debugging...
$(CC) $(OPTIM) $(CFLAGS) -DDEBUG -c -o $@ $<
$(OBJS): ../Makedefs ../config.h
+1 -1
Ver Arquivo
@@ -46,7 +46,7 @@ extern "C" {
* Constants...
*/
# define CUPS_VERSION 1.0109
# define CUPS_VERSION 1.0103
# define CUPS_DATE_ANY -1
+54 -234
Ver Arquivo
@@ -24,13 +24,12 @@
*
* Contents:
*
* cupsAddDest() - Add a destination to the list of destinations.
* cupsFreeDests() - Free the memory used by the list of destinations.
* cupsGetDest() - Get the named destination from the list.
* cupsGetDests() - Get the list of destinations.
* cupsSetDests() - Set the list of destinations.
* cups_get_dests() - Get destinations from a file.
* cups_get_sdests() - Get destinations from a server.
* cupsAddDest() - Add a destination to the list of destinations.
* cupsFreeDests() - Free the memory used by the list of destinations.
* cupsGetDest() - Get the named destination from the list.
* cupsGetDests() - Get the list of destinations.
* cupsSetDests() - Set the list of destinations.
* cups_get_dests() - Get destinations from a file.
*/
/*
@@ -38,7 +37,6 @@
*/
#include "cups.h"
#include "language.h"
#include "string.h"
#include <stdlib.h>
#include <ctype.h>
@@ -50,8 +48,6 @@
static int cups_get_dests(const char *filename, int num_dests,
cups_dest_t **dests);
static int cups_get_sdests(ipp_op_t op, int num_dests,
cups_dest_t **dests);
/*
@@ -207,7 +203,10 @@ cupsGetDest(const char *name, /* I - Name of destination */
int /* O - Number of destinations */
cupsGetDests(cups_dest_t **dests) /* O - Destinations */
{
int i; /* Looping var */
int num_dests; /* Number of destinations */
int count; /* Number of printers/classes */
char **names; /* Printer/class names */
cups_dest_t *dest; /* Destination pointer */
const char *home; /* HOME environment variable */
char filename[1024]; /* Local ~/.lpoptions file */
@@ -224,11 +223,34 @@ cupsGetDests(cups_dest_t **dests) /* O - Destinations */
*dests = (cups_dest_t *)0;
/*
* Grab the printers and classes...
* Grab all available printers...
*/
num_dests = cups_get_sdests(CUPS_GET_PRINTERS, num_dests, dests);
num_dests = cups_get_sdests(CUPS_GET_CLASSES, num_dests, dests);
if ((count = cupsGetPrinters(&names)) > 0)
{
for (i = 0; i < count; i ++)
{
num_dests = cupsAddDest(names[i], NULL, num_dests, dests);
free(names[i]);
}
free(names);
}
/*
* Grab all available classes...
*/
if ((count = cupsGetClasses(&names)) > 0)
{
for (i = 0; i < count; i ++)
{
num_dests = cupsAddDest(names[i], NULL, num_dests, dests);
free(names[i]);
}
free(names);
}
/*
* Grab the default destination...
@@ -289,61 +311,42 @@ cupsSetDests(int num_dests, /* I - Number of destinations */
cups_dest_t *dests) /* I - Destinations */
{
int i, j; /* Looping vars */
int wrote; /* Wrote definition? */
cups_dest_t *dest; /* Current destination */
cups_option_t *option; /* Current option */
FILE *fp; /* File pointer */
const char *home; /* HOME environment variable */
char filename[1024]; /* lpoptions file */
int num_temps; /* Number of temporary destinations */
cups_dest_t *temps, /* Temporary destinations */
*temp; /* Current temporary dest */
const char *val; /* Value of temporary option */
/*
* Get the server destinations...
*/
num_temps = cups_get_sdests(CUPS_GET_PRINTERS, 0, &temps);
num_temps = cups_get_sdests(CUPS_GET_CLASSES, num_temps, &temps);
/*
* Figure out which file to write to...
*/
if ((home = getenv("CUPS_SERVERROOT")) != NULL)
snprintf(filename, sizeof(filename), "%s/lpoptions", home);
else
strcpy(filename, CUPS_SERVERROOT "/lpoptions");
#ifdef WIN32
if ((home = getenv("CUPS_SERVERROOT")) == NULL)
home = CUPS_SERVERROOT;
#ifndef WIN32
if (getuid())
snprintf(filename, sizeof(filename), "%s/lpoptions", home);
#else
if (getuid() == 0)
{
/*
* Merge in server defaults...
*/
if ((home = getenv("CUPS_SERVERROOT")) == NULL)
home = CUPS_SERVERROOT;
num_temps = cups_get_dests(filename, num_temps, &temps);
/*
* Point to user defaults...
*/
if ((home = getenv("HOME")) != NULL)
snprintf(filename, sizeof(filename), "%s/.lpoptions", home);
snprintf(filename, sizeof(filename), "%s/lpoptions", home);
}
#endif /* !WIN32 */
else if ((home = getenv("HOME")) != NULL)
snprintf(filename, sizeof(filename), "%s/.lpoptions", home);
else
return;
#endif /* WIN32 */
/*
* Try to open the file...
*/
if ((fp = fopen(filename, "w")) == NULL)
{
cupsFreeDests(num_temps, temps);
return;
}
/*
* Write each printer; each line looks like:
@@ -355,46 +358,12 @@ cupsSetDests(int num_dests, /* I - Number of destinations */
for (i = num_dests, dest = dests; i > 0; i --, dest ++)
if (dest->instance != NULL || dest->num_options != 0 || dest->is_default)
{
if (dest->is_default)
{
fprintf(fp, "Default %s", dest->name);
if (dest->instance)
fprintf(fp, "/%s", dest->instance);
wrote = 1;
}
else
wrote = 0;
if ((temp = cupsGetDest(dest->name, dest->instance, num_temps, temps)) == NULL)
temp = cupsGetDest(dest->name, NULL, num_temps, temps);
fprintf(fp, "%s %s", dest->is_default ? "Default" : "Dest",
dest->name);
if (dest->instance)
fprintf(fp, "/%s", dest->instance);
for (j = dest->num_options, option = dest->options; j > 0; j --, option ++)
{
/*
* See if the server/global options match these; if so, don't
* write 'em.
*/
if (temp && (val = cupsGetOption(option->name, temp->num_options,
temp->options)) != NULL)
{
if (strcasecmp(val, option->value) == 0)
continue;
}
/*
* Options don't match, write to the file...
*/
if (!wrote)
{
fprintf(fp, "Dest %s", dest->name);
if (dest->instance)
fprintf(fp, "/%s", dest->instance);
wrote = 1;
}
if (option->value[0])
{
if (strchr(option->value, ' ') != NULL)
@@ -404,18 +373,10 @@ cupsSetDests(int num_dests, /* I - Number of destinations */
}
else
fprintf(fp, " %s", option->name);
}
if (wrote)
fputs("\n", fp);
fputs("\n", fp);
}
/*
* Free the temporary destinations...
*/
cupsFreeDests(num_temps, temps);
/*
* Close the file and return...
*/
@@ -580,147 +541,6 @@ cups_get_dests(const char *filename, /* I - File to read from */
}
/*
* 'cups_get_sdests()' - Get destinations from a server.
*/
static int /* O - Number of destinations */
cups_get_sdests(ipp_op_t op, /* I - get-printers or get-classes */
int num_dests, /* I - Number of destinations */
cups_dest_t **dests) /* IO - Destinations */
{
cups_dest_t *dest; /* Current destination */
http_t *http; /* HTTP connection */
ipp_t *request, /* IPP Request */
*response; /* IPP Response */
ipp_attribute_t *attr; /* Current attribute */
cups_lang_t *language; /* Default language */
const char *name; /* printer-name attribute */
char job_sheets[1024]; /* job-sheets option */
static const char *pattrs[] = /* Attributes we're interested in */
{
"printer-name",
"job-sheets-default"
};
/*
* Connect to the CUPS server...
*/
if ((http = httpConnect(cupsServer(), ippPort())) == NULL)
return (num_dests);
/*
* Build a CUPS_GET_PRINTERS or CUPS_GET_CLASSES request, which require
* the following attributes:
*
* attributes-charset
* attributes-natural-language
*/
request = ippNew();
request->request.op.operation_id = op;
request->request.op.request_id = 1;
language = cupsLangDefault();
ippAddString(request, IPP_TAG_OPERATION, IPP_TAG_CHARSET,
"attributes-charset", NULL, cupsLangEncoding(language));
ippAddString(request, IPP_TAG_OPERATION, IPP_TAG_LANGUAGE,
"attributes-natural-language", NULL, language->language);
ippAddStrings(request, IPP_TAG_OPERATION, IPP_TAG_NAME,
"requested-attributes", sizeof(pattrs) / sizeof(pattrs[0]),
NULL, pattrs);
/*
* Do the request and get back a response...
*/
if ((response = cupsDoRequest(http, request, "/")) != NULL)
{
for (attr = response->attrs; attr != NULL; attr = attr->next)
{
/*
* Skip leading attributes until we hit a printer...
*/
while (attr != NULL && attr->group_tag != IPP_TAG_PRINTER)
attr = attr->next;
if (attr == NULL)
break;
/*
* Pull the needed attributes from this job...
*/
name = NULL;
strcpy(job_sheets, "none,none");
while (attr != NULL && attr->group_tag == IPP_TAG_PRINTER)
{
if (strcmp(attr->name, "printer-name") == 0 &&
attr->value_tag == IPP_TAG_NAME)
name = attr->values[0].string.text;
if (strcmp(attr->name, "job-sheets-default") == 0 &&
(attr->value_tag == IPP_TAG_KEYWORD ||
attr->value_tag == IPP_TAG_NAME))
{
if (attr->num_values == 2)
snprintf(job_sheets, sizeof(job_sheets), "%s,%s",
attr->values[0].string.text, attr->values[1].string.text);
else
strcpy(job_sheets, attr->values[0].string.text);
}
attr = attr->next;
}
/*
* See if we have everything needed...
*/
if (!name)
{
if (attr == NULL)
break;
else
continue;
}
num_dests = cupsAddDest(name, NULL, num_dests, dests);
if ((dest = cupsGetDest(name, NULL, num_dests, *dests)) != NULL)
dest->num_options = cupsAddOption("job-sheets", job_sheets, 0,
&(dest->options));
if (attr == NULL)
break;
}
ippDelete(response);
}
/*
* Close the server connection...
*/
httpClose(http);
/*
* Return the count...
*/
return (num_dests);
}
/*
* End of "$Id$".
*/
-15
Ver Arquivo
@@ -329,17 +329,9 @@ ppdEmitJCL(ppd_file_t *ppd, /* I - PPD file record */
const char *ptr; /* Pointer into JCL string */
/*
* Range check the input...
*/
if (ppd == NULL || ppd->jcl_begin == NULL || ppd->jcl_ps == NULL)
return (0);
/*
* See if the printer supports HP PJL...
*/
if (strncmp(ppd->jcl_begin, "\033%-12345X@", 10) == 0)
{
/*
@@ -379,13 +371,6 @@ ppdEmitJCL(ppd_file_t *ppd, /* I - PPD file record */
ptr ++;
}
/*
* Eliminate any path info from the job title...
*/
if ((ptr = strrchr(title, '/')) != NULL)
title = ptr + 1;
/*
* Send PJL JOB command before we enter PostScript mode...
*/
+42 -76
Ver Arquivo
@@ -23,43 +23,41 @@
*
* Contents:
*
* httpInitialize() - Initialize the HTTP interface library and set the
* default HTTP proxy (if any).
* httpCheck() - Check to see if there is a pending response from
* the server.
* httpClose() - Close an HTTP connection...
* httpConnect() - Connect to a HTTP server.
* httpConnectEncrypt() - Connect to a HTTP server using encryption.
* httpEncryption() - Set the required encryption on the link.
* httpReconnect() - Reconnect to a HTTP server...
* httpSeparate() - Separate a Universal Resource Identifier into its
* components.
* httpGetSubField() - Get a sub-field value.
* httpSetField() - Set the value of an HTTP header.
* httpDelete() - Send a DELETE request to the server.
* httpGet() - Send a GET request to the server.
* httpHead() - Send a HEAD request to the server.
* httpOptions() - Send an OPTIONS request to the server.
* httpPost() - Send a POST request to the server.
* httpPut() - Send a PUT request to the server.
* httpTrace() - Send an TRACE request to the server.
* httpFlush() - Flush data from a HTTP connection.
* httpRead() - Read data from a HTTP connection.
* httpWrite() - Write data to a HTTP connection.
* httpGets() - Get a line of text from a HTTP connection.
* httpPrintf() - Print a formatted string to a HTTP connection.
* httpStatus() - Return a short string describing a HTTP status code.
* httpGetDateString() - Get a formatted date/time string from a time value.
* httpGetDateTime() - Get a time value from a formatted date/time string.
* httpUpdate() - Update the current HTTP state for incoming data.
* httpDecode64() - Base64-decode a string.
* httpEncode64() - Base64-encode a string.
* httpGetLength() - Get the amount of data remaining from the
* content-length or transfer-encoding fields.
* http_field() - Return the field index for a field name.
* http_send() - Send a request with all fields and the trailing
* blank line.
* http_upgrade() - Force upgrade to TLS encryption.
* httpInitialize() - Initialize the HTTP interface library and set the
* default HTTP proxy (if any).
* httpCheck() - Check to see if there is a pending response from
* the server.
* httpClose() - Close an HTTP connection...
* httpConnect() - Connect to a HTTP server.
* httpEncryption() - Set the required encryption on the link.
* httpReconnect() - Reconnect to a HTTP server...
* httpSeparate() - Separate a Universal Resource Identifier into its
* components.
* httpSetField() - Set the value of an HTTP header.
* httpDelete() - Send a DELETE request to the server.
* httpGet() - Send a GET request to the server.
* httpHead() - Send a HEAD request to the server.
* httpOptions() - Send an OPTIONS request to the server.
* httpPost() - Send a POST request to the server.
* httpPut() - Send a PUT request to the server.
* httpTrace() - Send an TRACE request to the server.
* httpFlush() - Flush data from a HTTP connection.
* httpRead() - Read data from a HTTP connection.
* httpWrite() - Write data to a HTTP connection.
* httpGets() - Get a line of text from a HTTP connection.
* httpPrintf() - Print a formatted string to a HTTP connection.
* httpStatus() - Return a short string describing a HTTP status code.
* httpGetDateString() - Get a formatted date/time string from a time value.
* httpGetDateTime() - Get a time value from a formatted date/time string.
* httpUpdate() - Update the current HTTP state for incoming data.
* httpDecode64() - Base64-decode a string.
* httpEncode64() - Base64-encode a string.
* httpGetLength() - Get the amount of data remaining from the
* content-length or transfer-encoding fields.
* http_field() - Return the field index for a field name.
* http_send() - Send a request with all fields and the trailing
* blank line.
* http_upgrade() - Force upgrade to TLS encryption.
*/
/*
@@ -312,32 +310,6 @@ httpClose(http_t *http) /* I - Connection to close */
http_t * /* O - New HTTP connection */
httpConnect(const char *host, /* I - Host to connect to */
int port) /* I - Port number */
{
http_encryption_t encrypt;/* Type of encryption to use */
/*
* Set the default encryption status...
*/
if (port == 443)
encrypt = HTTP_ENCRYPT_ALWAYS;
else
encrypt = HTTP_ENCRYPT_IF_REQUESTED;
return (httpConnectEncrypt(host, port, encrypt));
}
/*
* 'httpConnectEncrypt()' - Connect to a HTTP server using encryption.
*/
http_t * /* O - New HTTP connection */
httpConnectEncrypt(const char *host, /* I - Host to connect to */
int port, /* I - Port number */
http_encryption_t encrypt)
/* I - Type of encryption to use */
{
http_t *http; /* New HTTP connection */
struct hostent *hostaddr; /* Host address data */
@@ -399,10 +371,11 @@ httpConnectEncrypt(const char *host, /* I - Host to connect to */
#endif /* WIN32 */
/*
* Set the encryption status...
* Set the default encryption status...
*/
http->encryption = encrypt;
if (port == 443)
http->encryption = HTTP_ENCRYPT_ALWAYS;
/*
* Connect to the remote system...
@@ -811,9 +784,6 @@ httpGetSubField(http_t *http, /* I - HTTP data */
name == NULL || value == NULL)
return (NULL);
DEBUG_printf(("httpGetSubField(%p, %d, \"%s\", %p)\n",
http, field, name, value));
for (fptr = http->fields[field]; *fptr;)
{
/*
@@ -839,21 +809,16 @@ httpGetSubField(http_t *http, /* I - HTTP data */
*ptr = '\0';
DEBUG_printf(("name = \"%s\"\n", temp));
/*
* Skip trailing chars up to the '='...
*/
while (isspace(*fptr))
while (*fptr && *fptr != '=')
fptr ++;
if (!*fptr)
break;
if (*fptr != '=')
continue;
/*
* Skip = and leading whitespace...
*/
@@ -897,8 +862,6 @@ httpGetSubField(http_t *http, /* I - HTTP data */
fptr ++;
}
DEBUG_printf(("value = \"%s\"\n", value));
/*
* See if this is the one...
*/
@@ -1607,6 +1570,9 @@ httpUpdate(http_t *http) /* I - HTTP data */
return (HTTP_CONTINUE);
}
else if (http->status == HTTP_UPGRADE_REQUIRED &&
http->encryption != HTTP_ENCRYPT_NEVER)
http->encryption = HTTP_ENCRYPT_REQUIRED;
#endif /* HAVE_LIBSSL */
httpGetLength(http);
-2
Ver Arquivo
@@ -290,8 +290,6 @@ extern int httpCheck(http_t *http);
httpSetField((http), HTTP_FIELD_HOST, (http)->hostname)
extern void httpClose(http_t *http);
extern http_t *httpConnect(const char *host, int port);
extern http_t *httpConnectEncrypt(const char *host, int port,
http_encryption_t encrypt);
extern int httpDelete(http_t *http, const char *uri);
extern int httpEncryption(http_t *http, http_encryption_t e);
# define httpError(http) ((http)->error)
+43 -89
Ver Arquivo
@@ -24,35 +24,32 @@
*
* Contents:
*
* ippAddBoolean() - Add a boolean attribute to an IPP request.
* ippAddBooleans() - Add an array of boolean values.
* ippAddDate() - Add a date attribute to an IPP request.
* ippAddInteger() - Add a integer attribute to an IPP request.
* ippAddIntegers() - Add an array of integer values.
* ippAddString() - Add a language-encoded string to an IPP request.
* ippAddStrings() - Add language-encoded strings to an IPP request.
* ippAddRange() - Add a range of values to an IPP request.
* ippAddRanges() - Add ranges of values to an IPP request.
* ippAddResolution() - Add a resolution value to an IPP request.
* ippAddResolutions() - Add resolution values to an IPP request.
* ippAddSeparator() - Add a group separator to an IPP request.
* ippDateToTime() - Convert from RFC 1903 Date/Time format to UNIX
* time in seconds.
* ippDelete() - Delete an IPP request.
* ippErrorString() - Return a textual message for the given error
* message.
* ippFindAttribute() - Find a named attribute in a request...
* ippFindNextAttribute() - Find the next named attribute in a request...
* ippLength() - Compute the length of an IPP request.
* ippNew() - Allocate a new IPP request.
* ippPort() - Return the default IPP port number.
* ippRead() - Read data for an IPP request.
* ippSetPort() - Set the default port number.
* ippTimeToDate() - Convert from UNIX time to RFC 1903 format.
* ippWrite() - Write data for an IPP request.
* _ipp_add_attr() - Add a new attribute to the request.
* _ipp_free_attr() - Free an attribute.
* ipp_read() - Semi-blocking read on a HTTP connection...
* ippAddBoolean() - Add a boolean attribute to an IPP request.
* ippAddBooleans() - Add an array of boolean values.
* ippAddDate() - Add a date attribute to an IPP request.
* ippAddInteger() - Add a integer attribute to an IPP request.
* ippAddIntegers() - Add an array of integer values.
* ippAddString() - Add a language-encoded string to an IPP request.
* ippAddStrings() - Add language-encoded strings to an IPP request.
* ippAddRange() - Add a range of values to an IPP request.
* ippAddRanges() - Add ranges of values to an IPP request.
* ippAddResolution() - Add a resolution value to an IPP request.
* ippAddResolutions() - Add resolution values to an IPP request.
* ippAddSeparator() - Add a group separator to an IPP request.
* ippDateToTime() - Convert from RFC 1903 Date/Time format to UNIX time
* ippDelete() - Delete an IPP request.
* ippErrorString() - Return a textual message for the given error message.
* ippFindAttribute() - Find a named attribute in a request...
* ippLength() - Compute the length of an IPP request.
* ippNew() - Allocate a new IPP request.
* ippPort() - Return the default IPP port number.
* ippRead() - Read data for an IPP request.
* ippSetPort() - Set the default port number.
* ippTimeToDate() - Convert from UNIX time to RFC 1903 format.
* ippWrite() - Write data for an IPP request.
* _ipp_add_attr() - Add a new attribute to the request.
* _ipp_free_attr() - Free an attribute.
* ipp_read() - Semi-blocking read on a HTTP connection...
*/
/*
@@ -270,10 +267,8 @@ ippAddString(ipp_t *ipp, /* I - IPP request */
attr->name = strdup(name);
attr->group_tag = group;
attr->value_tag = type;
attr->values[0].string.charset = ((int)type & IPP_TAG_COPY) ? (char *)charset :
charset ? strdup(charset) : NULL;
attr->values[0].string.text = ((int)type & IPP_TAG_COPY) ? (char *)value :
value ? strdup(value) : NULL;
attr->values[0].string.charset = charset ? strdup(charset) : NULL;
attr->values[0].string.text = value ? strdup(value) : NULL;
if ((type == IPP_TAG_LANGUAGE || type == IPP_TAG_CHARSET) &&
attr->values[0].string.text)
@@ -323,18 +318,16 @@ ippAddStrings(ipp_t *ipp, /* I - IPP request */
attr->group_tag = group;
attr->value_tag = type;
for (i = 0; i < num_values; i ++)
{
if (i == 0)
attr->values[0].string.charset = ((int)type & IPP_TAG_COPY) ? (char *)charset :
charset ? strdup(charset) : NULL;
else
attr->values[i].string.charset = attr->values[0].string.charset;
if (values != NULL)
for (i = 0; i < num_values; i ++)
{
if (i == 0)
attr->values[0].string.charset = charset ? strdup(charset) : NULL;
else
attr->values[i].string.charset = attr->values[0].string.charset;
if (values != NULL)
attr->values[i].string.text = ((int)type & IPP_TAG_COPY) ? (char *)values[i] :
strdup(values[i]);
}
attr->values[i].string.text = strdup(values[i]);
}
return (attr);
}
@@ -505,7 +498,7 @@ ippAddSeparator(ipp_t *ipp) /* I - IPP request */
/*
* 'ippDateToTime()' - Convert from RFC 1903 Date/Time format to UNIX time
* in seconds.
* in seconds.
*/
time_t /* O - UNIX time value */
@@ -671,49 +664,16 @@ ippFindAttribute(ipp_t *ipp, /* I - IPP request */
const char *name, /* I - Name of attribute */
ipp_tag_t type) /* I - Type of attribute */
{
ipp_attribute_t *attr; /* Current atttribute */
ipp_tag_t value_tag; /* Value tag */
DEBUG_printf(("ippFindAttribute(%p, \'%s\')\n", ipp, name));
if (ipp == NULL || name == NULL)
return (NULL);
/*
* Reset the current pointer...
*/
ipp->current = NULL;
/*
* Search for the attribute...
*/
return (ippFindNextAttribute(ipp, name, type));
}
/*
* 'ippFindNextAttribute()' - Find the next named attribute in a request...
*/
ipp_attribute_t * /* O - Matching attribute */
ippFindNextAttribute(ipp_t *ipp, /* I - IPP request */
const char *name, /* I - Name of attribute */
ipp_tag_t type) /* I - Type of attribute */
{
ipp_attribute_t *attr; /* Current atttribute */
ipp_tag_t value_tag; /* Value tag */
DEBUG_printf(("ippFindNextAttribute(%p, \'%s\')\n", ipp, name));
if (ipp == NULL || name == NULL)
return (NULL);
if (ipp->current)
attr = ipp->current->next;
else
attr = ipp->attrs;
for (; attr != NULL; attr = attr->next)
for (attr = ipp->attrs; attr != NULL; attr = attr->next)
{
DEBUG_printf(("ippFindAttribute: attr = %p, name = \'%s\'\n", attr,
attr->name));
@@ -724,15 +684,9 @@ ippFindNextAttribute(ipp_t *ipp, /* I - IPP request */
(value_tag == type || type == IPP_TAG_ZERO ||
(value_tag == IPP_TAG_TEXTLANG && type == IPP_TAG_TEXT) ||
(value_tag == IPP_TAG_NAMELANG && type == IPP_TAG_NAME)))
{
ipp->current = attr;
return (attr);
}
}
ipp->current = NULL;
return (NULL);
}
+2 -5
Ver Arquivo
@@ -106,7 +106,7 @@ typedef enum /**** Format tags for attribute formats... ****/
IPP_TAG_MIMETYPE,
IPP_TAG_MEMBERNAME,
IPP_TAG_MASK = 0x7fffffff, /* Mask for copied attribute values */
IPP_TAG_COPY = -0x7fffffff-1 /* Bitflag for copied attribute values */
IPP_TAG_COPY = 0x80000000 /* Bitflag for copied attribute values */
} ipp_tag_t;
typedef enum /**** Resolution units... ****/
@@ -403,10 +403,7 @@ extern ipp_attribute_t *ippAddStrings(ipp_t *ipp, ipp_tag_t group, ipp_tag_t typ
extern time_t ippDateToTime(const ipp_uchar_t *date);
extern void ippDelete(ipp_t *ipp);
extern const char *ippErrorString(ipp_status_t error);
extern ipp_attribute_t *ippFindAttribute(ipp_t *ipp, const char *name,
ipp_tag_t type);
extern ipp_attribute_t *ippFindNextAttribute(ipp_t *ipp, const char *name,
ipp_tag_t type);
extern ipp_attribute_t *ippFindAttribute(ipp_t *ipp, const char *name, ipp_tag_t type);
extern size_t ippLength(ipp_t *ipp);
extern ipp_t *ippNew(void);
extern ipp_state_t ippRead(http_t *http, ipp_t *ipp);
+16 -72
Ver Arquivo
@@ -525,21 +525,6 @@ ppdOpen(FILE *fp) /* I - File to read from */
puts("");
#endif /* DEBUG */
if (strcmp(keyword, "CloseUI") != 0 &&
strcmp(keyword, "JCLCloseUI") != 0 &&
strcmp(keyword, "CloseGroup") != 0 &&
strcmp(keyword, "CloseSubGroup") != 0 &&
strncmp(keyword, "Default", 7) != 0 &&
string == NULL)
{
/*
* Need a string value!
*/
ppdClose(ppd);
return (NULL);
}
if (strcmp(keyword, "LanguageLevel") == 0)
ppd->language_level = atoi(string);
else if (strcmp(keyword, "LanguageEncoding") == 0)
@@ -928,6 +913,12 @@ ppdOpen(FILE *fp) /* I - File to read from */
if (name[0] == '*')
strcpy(name, name + 1);
if (string == NULL)
{
ppdClose(ppd);
return (NULL);
}
if (subgroup != NULL)
option = ppd_get_option(subgroup, name);
else if (group == NULL)
@@ -1249,40 +1240,14 @@ ppdOpen(FILE *fp) /* I - File to read from */
}
else if (strcmp(keyword, "PaperDimension") == 0)
{
if ((size = ppdPageSize(ppd, name)) == NULL)
size = ppd_add_size(ppd, name);
if (size == NULL)
{
/*
* Unable to add or find size!
*/
ppdClose(ppd);
safe_free(string);
return (NULL);
}
sscanf(string, "%f%f", &(size->width), &(size->length));
if ((size = ppdPageSize(ppd, name)) != NULL)
sscanf(string, "%f%f", &(size->width), &(size->length));
}
else if (strcmp(keyword, "ImageableArea") == 0)
{
if ((size = ppdPageSize(ppd, name)) == NULL)
size = ppd_add_size(ppd, name);
if (size == NULL)
{
/*
* Unable to add or find size!
*/
ppdClose(ppd);
safe_free(string);
return (NULL);
}
sscanf(string, "%f%f%f%f", &(size->left), &(size->bottom),
&(size->right), &(size->top));
if ((size = ppdPageSize(ppd, name)) != NULL)
sscanf(string, "%f%f%f%f", &(size->left), &(size->bottom),
&(size->right), &(size->top));
}
else if (option != NULL &&
(mask & (PPD_KEYWORD | PPD_OPTION | PPD_STRING)) ==
@@ -1296,8 +1261,7 @@ ppdOpen(FILE *fp) /* I - File to read from */
* Add a page size...
*/
if (ppdPageSize(ppd, name) == NULL)
ppd_add_size(ppd, name);
ppd_add_size(ppd, name);
}
/*
@@ -1615,7 +1579,6 @@ ppd_read(FILE *fp, /* I - File to read from */
char **string) /* O - Code/string data */
{
int ch, /* Character from file */
colon, /* Colon seen? */
endquote, /* Waiting for an end quote */
mask; /* Mask to be returned */
char *keyptr, /* Keyword pointer */
@@ -1648,7 +1611,6 @@ ppd_read(FILE *fp, /* I - File to read from */
lineptr = line;
endquote = 0;
colon = 0;
while ((ch = getc(fp)) != EOF &&
(lineptr - line) < (sizeof(line) - 1))
@@ -1689,10 +1651,7 @@ ppd_read(FILE *fp, /* I - File to read from */
*lineptr++ = ch;
if (ch == ':')
colon = 1;
if (ch == '\"' && colon)
if (ch == '\"')
{
endquote = !endquote;
@@ -1764,8 +1723,6 @@ ppd_read(FILE *fp, /* I - File to read from */
*lineptr = '\0';
DEBUG_printf(("LINE = \"%s\"\n", line));
if (ch == EOF && lineptr == line)
return (0);
@@ -1784,8 +1741,7 @@ ppd_read(FILE *fp, /* I - File to read from */
if (line[0] != '*') /* All lines start with an asterisk */
continue;
if (strcmp(line, "*") == 0 || /* (Bad) comment line */
strncmp(line, "*%", 2) == 0 || /* Comment line */
if (strncmp(line, "*%", 2) == 0 || /* Comment line */
strncmp(line, "*?", 2) == 0 || /* Query line */
strcmp(line, "*End") == 0) /* End of multi-line string */
continue;
@@ -1801,21 +1757,15 @@ ppd_read(FILE *fp, /* I - File to read from */
*keyptr++ = *lineptr++;
*keyptr = '\0';
if (strcmp(keyword, "End") == 0)
continue;
mask |= PPD_KEYWORD;
DEBUG_printf(("keyword = \"%s\", lineptr = \"%s\"\n", keyword, lineptr));
if (isspace(*lineptr))
if (*lineptr == ' ' || *lineptr == '\t')
{
/*
* Get an option name...
*/
while (isspace(*lineptr))
while (*lineptr == ' ' || *lineptr == '\t')
lineptr ++;
optptr = option;
@@ -1827,8 +1777,6 @@ ppd_read(FILE *fp, /* I - File to read from */
*optptr = '\0';
mask |= PPD_OPTION;
DEBUG_printf(("option = \"%s\", lineptr = \"%s\"\n", option, lineptr));
if (*lineptr == '/')
{
/*
@@ -1848,8 +1796,6 @@ ppd_read(FILE *fp, /* I - File to read from */
mask |= PPD_TEXT;
}
DEBUG_printf(("text = \"%s\", lineptr = \"%s\"\n", text, lineptr));
}
if (*lineptr == ':')
@@ -1875,8 +1821,6 @@ ppd_read(FILE *fp, /* I - File to read from */
*strptr = '\0';
DEBUG_printf(("string = \"%s\", lineptr = \"%s\"\n", *string, lineptr));
mask |= PPD_STRING;
}
}
+1 -8
Ver Arquivo
@@ -32,14 +32,7 @@
# include <stdio.h>
# include <stdarg.h>
# include <config.h>
# ifdef HAVE_STRING_H
# include <string.h>
# endif /* HAVE_STRING_H */
# ifdef HAVE_STRINGS_H
# include <strings.h>
# endif /* HAVE_STRINGS_H */
# include <string.h>
/*
+7 -4
Ver Arquivo
@@ -56,8 +56,6 @@ main(int argc, /* I - Number of command-line arguments */
"JCL", "PAGE", "PROLOG" };
setbuf(stdout, NULL);
/*
* Display PPD files for each file listed on the command-line...
*/
@@ -70,9 +68,14 @@ main(int argc, /* I - Number of command-line arguments */
for (i = 1; i < argc; i ++)
{
if ((ppd = ppdOpenFile(argv[i])) == NULL)
if (strstr(argv[i], ".ppd"))
filename = argv[i];
else
filename = cupsGetPPD(argv[i]);
if ((ppd = ppdOpenFile(filename)) == NULL)
{
fprintf(stderr, "Unable to open \'%s\' as a PPD file!\n", argv[i]);
fprintf(stderr, "Unable to open \'%s\' as a PPD file!\n", filename);
continue;
}
+74 -134
Ver Arquivo
@@ -66,9 +66,7 @@
static http_t *cups_server = NULL; /* Current server connection */
static ipp_status_t last_error = IPP_OK; /* Last IPP error */
static char authstring[HTTP_MAX_VALUE] = "";
/* Authorization string */
static char pwdstring[33] = ""; /* Last password string */
static char authstring[1024] = ""; /* Authorization string */
/*
@@ -181,7 +179,6 @@ cupsDoFileRequest(http_t *http, /* I - HTTP connection to server */
plain[255], /* Plaintext username:password */
encode[512]; /* Encoded username:password */
char prompt[1024]; /* Prompt string */
int digest_tries; /* Number of tries with Digest */
if (http == NULL || request == NULL || resource == NULL)
@@ -231,9 +228,8 @@ cupsDoFileRequest(http_t *http, /* I - HTTP connection to server */
* Loop until we can send the request without authorization problems.
*/
response = NULL;
status = HTTP_ERROR;
digest_tries = 0;
response = NULL;
status = HTTP_ERROR;
while (response == NULL)
{
@@ -319,63 +315,50 @@ cupsDoFileRequest(http_t *http, /* I - HTTP connection to server */
continue;
/*
* See if we should retry the current digest password...
* Nope - get a password from the user...
*/
if (strncmp(http->fields[HTTP_FIELD_WWW_AUTHENTICATE], "Basic", 5) == 0 ||
digest_tries > 1 || !pwdstring[0])
snprintf(prompt, sizeof(prompt), "Password for %s on %s? ", cupsUser(),
http->hostname);
if ((password = cupsGetPassword(prompt)) != NULL)
{
/*
* Nope - get a password from the user...
* Got a password; send it to the server...
*/
snprintf(prompt, sizeof(prompt), "Password for %s on %s? ", cupsUser(),
http->hostname);
if (!password[0])
break;
if ((password = cupsGetPassword(prompt)) == NULL)
break;
if (!password[0])
break;
if (strncmp(http->fields[HTTP_FIELD_WWW_AUTHENTICATE], "Basic", 5) == 0)
{
/*
* Basic authentication...
*/
strncpy(pwdstring, password, sizeof(pwdstring) - 1);
pwdstring[sizeof(pwdstring) - 1] = '\0';
snprintf(plain, sizeof(plain), "%s:%s", cupsUser(), password);
httpEncode64(encode, plain);
snprintf(authstring, sizeof(authstring), "Basic %s", encode);
}
else
{
/*
* Digest authentication...
*/
digest_tries = 0;
httpGetSubField(http, HTTP_FIELD_WWW_AUTHENTICATE, "realm", realm);
httpGetSubField(http, HTTP_FIELD_WWW_AUTHENTICATE, "nonce", nonce);
httpMD5(cupsUser(), realm, password, encode);
httpMD5Final(nonce, "POST", resource, encode);
snprintf(authstring, sizeof(authstring),
"Digest username=\"%s\", realm=\"%s\", nonce=\"%s\", "
"response=\"%s\"", cupsUser(), realm, nonce, encode);
}
continue;
}
else
digest_tries ++;
/*
* Got a password; encode it for the server...
*/
if (strncmp(http->fields[HTTP_FIELD_WWW_AUTHENTICATE], "Basic", 5) == 0)
{
/*
* Basic authentication...
*/
snprintf(plain, sizeof(plain), "%s:%s", cupsUser(), pwdstring);
httpEncode64(encode, plain);
snprintf(authstring, sizeof(authstring), "Basic %s", encode);
}
else
{
/*
* Digest authentication...
*/
httpGetSubField(http, HTTP_FIELD_WWW_AUTHENTICATE, "realm", realm);
httpGetSubField(http, HTTP_FIELD_WWW_AUTHENTICATE, "nonce", nonce);
httpMD5(cupsUser(), realm, pwdstring, encode);
httpMD5Final(nonce, "POST", resource, encode);
snprintf(authstring, sizeof(authstring),
"Digest username=\"%s\", realm=\"%s\", nonce=\"%s\", "
"response=\"%s\"", cupsUser(), realm, nonce, encode);
}
continue;
break;
}
else if (status == HTTP_ERROR)
{
@@ -397,12 +380,6 @@ cupsDoFileRequest(http_t *http, /* I - HTTP connection to server */
httpFlush(http);
/*
* Upgrade with encryption...
*/
httpEncryption(http, HTTP_ENCRYPT_REQUIRED);
/*
* Try again, this time with encryption enabled...
*/
@@ -977,7 +954,6 @@ cupsGetPPD(const char *name) /* I - Printer name */
encode[512]; /* Encoded username:password */
http_status_t status; /* HTTP status from server */
char prompt[1024]; /* Prompt string */
int digest_tries; /* Number of tries with Digest */
static char filename[HTTP_MAX_URI]; /* Local filename */
static const char *requested_attrs[] =/* Requested attributes */
{
@@ -1105,8 +1081,7 @@ cupsGetPPD(const char *name) /* I - Printer name */
{
httpClose(cups_server);
if ((cups_server = httpConnectEncrypt(hostname, ippPort(),
cupsEncryption())) == NULL)
if ((cups_server = httpConnect(hostname, ippPort())) == NULL)
{
last_error = IPP_SERVICE_UNAVAILABLE;
return (NULL);
@@ -1135,8 +1110,6 @@ cupsGetPPD(const char *name) /* I - Printer name */
snprintf(resource, sizeof(resource), "/printers/%s.ppd", printer);
digest_tries = 0;
do
{
httpClearFields(cups_server);
@@ -1177,86 +1150,51 @@ cupsGetPPD(const char *name) /* I - Printer name */
continue;
/*
* See if we should retry the current digest password...
* Nope, get a password from the user...
*/
if (strncmp(cups_server->fields[HTTP_FIELD_WWW_AUTHENTICATE], "Basic", 5) == 0 ||
digest_tries > 1 || !pwdstring[0])
snprintf(prompt, sizeof(prompt), "Password for %s on %s? ", cupsUser(),
cups_server->hostname);
if ((password = cupsGetPassword(prompt)) != NULL)
{
/*
* Nope - get a password from the user...
* Got a password; send it to the server...
*/
snprintf(prompt, sizeof(prompt), "Password for %s on %s? ", cupsUser(),
cups_server->hostname);
if (!password[0])
break;
if ((password = cupsGetPassword(prompt)) == NULL)
break;
if (!password[0])
break;
if (strncmp(cups_server->fields[HTTP_FIELD_WWW_AUTHENTICATE], "Basic", 5) == 0)
{
/*
* Basic authentication...
*/
strncpy(pwdstring, password, sizeof(pwdstring) - 1);
pwdstring[sizeof(pwdstring) - 1] = '\0';
snprintf(plain, sizeof(plain), "%s:%s", cupsUser(), password);
httpEncode64(encode, plain);
snprintf(authstring, sizeof(authstring), "Basic %s", encode);
}
else
{
/*
* Digest authentication...
*/
digest_tries = 0;
httpGetSubField(cups_server, HTTP_FIELD_WWW_AUTHENTICATE, "realm", realm);
httpGetSubField(cups_server, HTTP_FIELD_WWW_AUTHENTICATE, "nonce", nonce);
httpMD5(cupsUser(), realm, password, encode);
httpMD5Final(nonce, "GET", resource, encode);
snprintf(authstring, sizeof(authstring),
"Digest username=\"%s\", realm=\"%s\", nonce=\"%s\", "
"response=\"%s\"", cupsUser(), realm, nonce, encode);
}
continue;
}
else
digest_tries ++;
/*
* Got a password; encode it for the server...
*/
if (strncmp(cups_server->fields[HTTP_FIELD_WWW_AUTHENTICATE], "Basic", 5) == 0)
{
/*
* Basic authentication...
*/
snprintf(plain, sizeof(plain), "%s:%s", cupsUser(), pwdstring);
httpEncode64(encode, plain);
snprintf(authstring, sizeof(authstring), "Basic %s", encode);
}
else
{
/*
* Digest authentication...
*/
httpGetSubField(cups_server, HTTP_FIELD_WWW_AUTHENTICATE, "realm", realm);
httpGetSubField(cups_server, HTTP_FIELD_WWW_AUTHENTICATE, "nonce", nonce);
httpMD5(cupsUser(), realm, pwdstring, encode);
httpMD5Final(nonce, "GET", resource, encode);
snprintf(authstring, sizeof(authstring),
"Digest username=\"%s\", realm=\"%s\", nonce=\"%s\", "
"response=\"%s\"", cupsUser(), realm, nonce, encode);
}
continue;
break;
}
#ifdef HAVE_LIBSSL
else if (status == HTTP_UPGRADE_REQUIRED)
{
/*
* Flush any error message...
*/
httpFlush(cups_server);
/*
* Upgrade with encryption...
*/
httpEncryption(cups_server, HTTP_ENCRYPT_REQUIRED);
/*
* Try again, this time with encryption enabled...
*/
continue;
}
#endif /* HAVE_LIBSSL */
}
while (status == HTTP_UNAUTHORIZED || status == HTTP_UPGRADE_REQUIRED);
@@ -1657,14 +1595,16 @@ cups_connect(const char *name, /* I - Destination (printer[@host]) */
DEBUG_printf(("connecting to %s on port %d...\n", hostname, ippPort()));
if ((cups_server = httpConnectEncrypt(hostname, ippPort(),
cupsEncryption())) == NULL)
if ((cups_server = httpConnect(hostname, ippPort())) == NULL)
{
last_error = IPP_SERVICE_UNAVAILABLE;
return (NULL);
}
else
{
httpEncryption(cups_server, cupsEncryption());
return (printer);
}
}
+10 -5
Ver Arquivo
@@ -81,14 +81,19 @@ clean:
#
install:
$(INSTALL_DIR) $(DATADIR)/banners
-$(MKDIR) $(DATADIR)/banners
$(CHMOD) ugo+rx $(DATADIR)
$(CHMOD) ugo+rx $(DATADIR)/banners
$(INSTALL_DATA) $(BANNERS) $(DATADIR)/banners
$(INSTALL_DIR) $(DATADIR)/charsets
-$(MKDIR) $(DATADIR)/charsets
$(CHMOD) ugo+rx $(DATADIR)/charsets
$(INSTALL_DATA) $(CHARSETS) $(DATADIR)/charsets
$(INSTALL_DIR) $(DATADIR)/data
-$(MKDIR) $(DATADIR)/data
$(CHMOD) ugo+rx $(DATADIR)/data
$(INSTALL_DATA) $(DATAFILES) $(DATADIR)/data
-if test x$(PAMDIR) != x; then \
$(INSTALL_DIR) $(PAMDIR); \
-if test "$(PAMDIR)" != ""; then \
$(MKDIR) $(PAMDIR); \
$(CHMOD) ugo+rx $(PAMDIR); \
if test -f /lib/security/pam_unix.so; then \
$(INSTALL_DATA) cups.suse $(PAMDIR)/cups; \
else \
+4 -2
Ver Arquivo
@@ -118,12 +118,14 @@ clean:
#
install:
$(INSTALL_DIR) $(DOCDIR)
-$(MKDIR) $(DOCDIR)
$(CHMOD) ugo+rx $(DOCDIR)
$(INSTALL_MAN) $(WEBPAGES) $(DOCDIR)
$(INSTALL_MAN) overview.html overview.pdf $(DOCDIR)
$(INSTALL_MAN) $(DOCUMENTS:.shtml=.html) $(DOCDIR)
$(INSTALL_MAN) $(DOCUMENTS:.shtml=.pdf) $(DOCDIR)
$(INSTALL_DIR) $(DOCDIR)/images
-$(MKDIR) $(DOCDIR)/images
$(CHMOD) ugo+rx $(DOCDIR)/images
$(INSTALL_MAN) $(WEBIMAGES) $(DOCDIR)/images
$(INSTALL_MAN) $(DOCIMAGES) $(DOCDIR)/images
+253 -252
Ver Arquivo
@@ -1,27 +1,27 @@
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" "http://www.w3.org/TR/REC-html40/loose.dtd">
<HTML>
<HEAD>
<TITLE>CUPS Configuration Management Plan</TITLE>
<TITLE> CUPS Configuration Management Plan</TITLE>
<META NAME="author" CONTENT="Easy Software Products">
<META NAME="copyright" CONTENT="Copyright 1997-2001, All Rights Reserved">
<META NAME="docnumber" CONTENT="CUPS-CMP-1.1">
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; CHARSET=iso-8859-1">
<STYLE TYPE="text/css"><!--
BODY { font-family: serif }
H1 { font-family: sans-serif }
H2 { font-family: sans-serif }
H3 { font-family: sans-serif }
H4 { font-family: sans-serif }
H5 { font-family: sans-serif }
H6 { font-family: sans-serif }
SUB { font-size: smaller }
SUP { font-size: smaller }
PRE { font-family: monospace }
BODY { font-family: serif; font-size: 11.0pt }
H1 { font-family: sans-serif; font-size: 20.0pt }
H2 { font-family: sans-serif; font-size: 17.0pt }
H3 { font-family: sans-serif; font-size: 14.0pt }
H4 { font-family: sans-serif; font-size: 11.0pt }
H5 { font-family: sans-serif; font-size: 9.0pt }
H6 { font-family: sans-serif; font-size: 8.0pt }
SUB { font-size: 8.0pt }
SUP { font-size: 8.0pt }
PRE { font-size: 9.0pt }
--></STYLE>
</HEAD>
<BODY>
<CENTER><A HREF="#CONTENTS"><IMG SRC="images/cups-large.gif" BORDER="0" WIDTH="431" HEIGHT="511"><BR>
<H1>CUPS Configuration Management Plan</H1></A><BR>
<CENTER><A HREF="#CONTENTS"><IMG SRC="images/cups-large.gif" BORDER="0" WIDTH="100%"><BR>
<H1> CUPS Configuration Management Plan</H1></A><BR>
CUPS-CMP-1.1<BR>
Easy Software Products<BR>
Copyright 1997-2001, All Rights Reserved<BR>
@@ -116,28 +116,28 @@ Copyright 1997-2001, All Rights Reserved<BR>
<B><A HREF="#8">C Software Trouble Report Form</A></B><HR>
<H1><A NAME="1">1 Scope</A></H1>
<H2><A NAME="1_1">1.1 Identification</A></H2>
This configuration management plan document provides the guidelines for
development and maintenance of the Common UNIX Printing System (&quot;CUPS&quot;)
Version 1.1 software.
This configuration management plan document provides the guidelines
for development and maintenance of the Common UNIX Printing System
(&quot;CUPS&quot;) Version 1.1 software.
<H2><A NAME="1_2">1.2 System Overview</A></H2>
<P>CUPS provides a portable printing layer for UNIX&reg;-based operating
systems. It has been developed by<A HREF="http://www.easysw.com"> Easy
Software Products</A> to promote a standard printing solution for all
UNIX vendors and users. CUPS provides the System V and Berkeley
command-line interfaces.</P>
<P>CUPS uses the Internet Printing Protocol (&quot;IPP&quot;) as the basis for
managing print jobs and queues. The Line Printer Daemon (&quot;LPD&quot;) Server
Message Block (&quot;SMB&quot;), and AppSocket (a.k.a. JetDirect) protocols are
also supported with reduced functionality. CUPS adds network printer
browsing and PostScript Printer Description (&quot;PPD&quot;) based printing
options to support real-world printing under UNIX.</P>
<P>CUPS also includes a customized version of GNU Ghostscript (currently
based off GNU Ghostscript 5.50) and an image file RIP that are used to
support non-PostScript printers. Sample drivers for HP and EPSON
printers are included that use these filters.</P>
<P>CUPS provides a portable printing layer for UNIX&reg;-based operating
systems. It has been developed by <A HREF="http://www.easysw.com">Easy
Software Products</A> to promote a standard printing solution for all
UNIX vendors and users. CUPS provides the System V and Berkeley
command-line interfaces. </P>
<P>CUPS uses the Internet Printing Protocol (&quot;IPP&quot;) as the basis for
managing print jobs and queues. The Line Printer Daemon (&quot;LPD&quot;) Server
Message Block (&quot;SMB&quot;), and AppSocket (a.k.a. JetDirect) protocols are
also supported with reduced functionality. CUPS adds network printer
browsing and PostScript Printer Description (&quot;PPD&quot;) based printing
options to support real-world printing under UNIX. </P>
<P>CUPS also includes a customized version of GNU Ghostscript
(currently based off GNU Ghostscript 5.50) and an image file RIP that
are used to support non-PostScript printers. Sample drivers for HP and
EPSON printers are included that use these filters. </P>
<H2><A NAME="1_3">1.3 Document Overview</A></H2>
This configuration management document is organized into the following
sections:
This configuration management document is organized into the following
sections:
<UL>
<LI>1 - Scope</LI>
<LI>2 - References</LI>
@@ -149,74 +149,74 @@ Copyright 1997-2001, All Rights Reserved<BR>
</UL>
<H1><A NAME="2">2 References</A></H1>
<H2><A NAME="2_1">2.1 CUPS Documentation</A></H2>
<P>The following CUPS documentation is referenced by this document:</P>
<P>The following CUPS documentation is referenced by this document: </P>
<UL>
<LI>CUPS-CMP-1.1: CUPS Configuration Management Plan</LI>
<LI>CUPS-IDD-1.1: CUPS System Interface Design Description</LI>
<LI>CUPS-IPP-1.1: CUPS Implementation of IPP</LI>
<LI>CUPS-SAM-1.1.x: CUPS Software Administrators Manual</LI>
<LI>CUPS-SDD-1.1: CUPS Software Design Description</LI>
<LI>CUPS-SPM-1.1.x: CUPS Software Programming Manual</LI>
<LI>CUPS-SSR-1.1: CUPS Software Security Report</LI>
<LI>CUPS-STP-1.1: CUPS Software Test Plan</LI>
<LI>CUPS-SUM-1.1.x: CUPS Software Users Manual</LI>
<LI>CUPS-SVD-1.1: CUPS Software Version Description</LI>
<LI>CUPS-CMP-1.1: CUPS Configuration Management Plan </LI>
<LI>CUPS-IDD-1.1: CUPS System Interface Design Description </LI>
<LI>CUPS-IPP-1.1: CUPS Implementation of IPP </LI>
<LI>CUPS-SAM-1.1.x: CUPS Software Administrators Manual </LI>
<LI>CUPS-SDD-1.1: CUPS Software Design Description </LI>
<LI>CUPS-SPM-1.1.x: CUPS Software Programming Manual </LI>
<LI>CUPS-SSR-1.1: CUPS Software Security Report </LI>
<LI>CUPS-STP-1.1: CUPS Software Test Plan </LI>
<LI>CUPS-SUM-1.1.x: CUPS Software Users Manual </LI>
<LI>CUPS-SVD-1.1: CUPS Software Version Description </LI>
</UL>
<H2><A NAME="2_2">2.2 Other Documents</A></H2>
<P>The following non-CUPS documents are referenced by this document:</P>
<P>The following non-CUPS documents are referenced by this document: </P>
<UL>
<LI><A HREF="http://partners.adobe.com/asn/developer/PDFS/TN/5003.PPD_Spec_v4.3.pdf">
Adobe PostScript Printer Description File Format Specification, Version
4.3.</A></LI>
Adobe PostScript Printer Description File Format Specification,
Version 4.3.</A></LI>
<LI><A HREF="http://partners.adobe.com/asn/developer/PDFS/TN/PLRM.pdf">
Adobe PostScript Language Reference, Third Edition.</A></LI>
<LI>IPP: Job and Printer Set Operations</LI>
<LI>IPP/1.1: Encoding and Transport</LI>
<LI>IPP/1.1: Implementers Guide</LI>
<LI>IPP/1.1: Model and Semantics</LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc1179.txt">RFC 1179, Line Printer
Daemon Protocol</A></LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc2567.txt">RFC 2567, Design Goals
for an Internet Printing Protocol</A></LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc2568.txt">RFC 2568, Rationale
for the Structure of the Model and Protocol</A> for the Internet
Printing Protocol</LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc2569.txt">RFC 2569, Mapping
between LPD and IPP Protocols</A></LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc2616.txt">RFC 2616, Hypertext
Transfer Protocol -- HTTP/1.1</A></LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc2617.txt">RFC 2617, HTTP
Authentication: Basic and Digest Access</A> Authentication</LI>
Adobe PostScript Language Reference, Third Edition.</A></LI>
<LI>IPP: Job and Printer Set Operations </LI>
<LI>IPP/1.1: Encoding and Transport </LI>
<LI>IPP/1.1: Implementers Guide </LI>
<LI>IPP/1.1: Model and Semantics </LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc1179.txt">RFC 1179, Line
Printer Daemon Protocol</A></LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc2567.txt">RFC 2567, Design
Goals for an Internet Printing Protocol</A></LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc2568.txt">RFC 2568, Rationale
for the Structure of the Model and Protocol</A> for the Internet
Printing Protocol</LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc2569.txt">RFC 2569, Mapping
between LPD and IPP Protocols</A></LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc2616.txt">RFC 2616, Hypertext
Transfer Protocol -- HTTP/1.1</A></LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc2617.txt">RFC 2617, HTTP
Authentication: Basic and Digest Access</A> Authentication </LI>
</UL>
<H1><A NAME="3">3 File Management</A></H1>
<H2><A NAME="3_1">3.1 Directory Structure</A></H2>
Each source file shall be placed a sub-directory corresponding to the
software sub-system it belongs to (&quot;scheduler&quot;, &quot;cups&quot;, etc.) To remain
compatible with older UNIX filesystems, directory names shall not
exceed 16 characters in length.
Each source file shall be placed a sub-directory corresponding to the
software sub-system it belongs to (&quot;scheduler&quot;, &quot;cups&quot;, etc.) To remain
compatible with older UNIX filesystems, directory names shall not
exceed 16 characters in length.
<H2><A NAME="3_2">3.2 Source Files</A></H2>
Source files shall be documented and formatted as described in Appendix
B, Coding Requirements.
Source files shall be documented and formatted as described in
Appendix B, Coding Requirements.
<H2><A NAME="3_3">3.3 Configuration Management</A></H2>
Source files shall be placed under the control of the Concurrent
Versions System (&quot;CVS&quot;) software. Source files shall be &quot;checked in&quot;
with each change so that modifications can be tracked.
<P>Documentation on the CVS software is included with the whitepaper,
&quot;CVS II: Parallelizing Software Development&quot;.</P>
Source files shall be placed under the control of the Concurrent
Versions System (&quot;CVS&quot;) software. Source files shall be &quot;checked in&quot;
with each change so that modifications can be tracked.
<P>Documentation on the CVS software is included with the whitepaper,
&quot;CVS II: Parallelizing Software Development&quot;. </P>
<H1><A NAME="4">4 Trouble Report Processing</A></H1>
A Software Trouble Report (&quot;STR&quot;) shall be submitted every time a user
or vendor experiences a problem with the CUPS software. Trouble reports
are maintained in a database with one of the following states:
A Software Trouble Report (&quot;STR&quot;) shall be submitted every time a user
or vendor experiences a problem with the CUPS software. Trouble reports
are maintained in a database with one of the following states:
<OL>
<LI>STR is closed with complete resolution</LI>
<LI>STR is closed without resolution</LI>
<LI>STR is active</LI>
<LI>STR is pending (new STR or additional information available)</LI>
</OL>
Trouble reports shall be processed using the following steps.
Trouble reports shall be processed using the following steps.
<H2><A NAME="4_1">4.1 Classification</A></H2>
When a trouble report is received it must be classified at one of the
following levels:
When a trouble report is received it must be classified at one of the
following levels:
<OL>
<LI>Request for enhancement</LI>
<LI>Documentation error</LI>
@@ -224,61 +224,61 @@ Adobe PostScript Language Reference, Third Edition.</A></LI>
<LI>Unable to print to a printer</LI>
<LI>Unable to print at all</LI>
</OL>
The scope of the problem should also be determined as:
The scope of the problem should also be determined as:
<OL>
<LI>Specific to a machine</LI>
<LI>Specific to an operating system</LI>
<LI>Applies to all machines and operating systems</LI>
</OL>
<H2><A NAME="4_2">4.2 Identification</A></H2>
Once the level and scope of the trouble report is determined the
software sub-system(s) involved with the problem are determined. This
may involve additional communication with the user or vendor to isolate
the problem to a specific cause.
<P>When the sub-system(s) involved have been identified, an engineer
will then determine the change(s) needed and estimate the time required
for the change(s).</P>
Once the level and scope of the trouble report is determined the
software sub-system(s) involved with the problem are determined. This
may involve additional communication with the user or vendor to isolate
the problem to a specific cause.
<P>When the sub-system(s) involved have been identified, an engineer
will then determine the change(s) needed and estimate the time required
for the change(s). </P>
<H2><A NAME="4_3">4.3 Correction</A></H2>
Corrections are scheduled based upon the severity and complexity of the
problem. Once all changes have been made, documented, and tested
successfully a new software release snapshot is generated. Additional
tests are added as necessary for proper testing of the changes.
Corrections are scheduled based upon the severity and complexity of
the problem. Once all changes have been made, documented, and tested
successfully a new software release snapshot is generated. Additional
tests are added as necessary for proper testing of the changes.
<H2><A NAME="4_4">4.4 Notification</A></H2>
The user or vendor is notified when the fix is available or if the
problem was caused by user error.
The user or vendor is notified when the fix is available or if the
problem was caused by user error.
<H1><A NAME="5">5 Software Releases</A></H1>
<H2><A NAME="5_1">5.1 Version Numbering</A></H2>
CUPS uses a three-part version number separated by periods to represent
the major, minor, and patch release numbers:
CUPS uses a three-part version number separated by periods to
represent the major, minor, and patch release numbers:
<UL>
<PRE>
major.minor.patch
1.1.0
</PRE>
</UL>
Beta-test releases are indentified by appending the letter B followed
by the build number:
Beta-test releases are indentified by appending the letter B followed
by the build number:
<UL>
<PRE>
major.minor.patchbbuild
1.1.0b1
</PRE>
</UL>
A CVS snapshot is generated for every beta and final release and uses
the version number preceded by the letter &quot;v&quot; and with the decimal
points replaced by underscores:
A CVS snapshot is generated for every beta and final release and uses
the version number preceded by the letter &quot;v&quot; and with the decimal
points replaced by underscores:
<UL>
<PRE>
v1_0_0b1
v1_0_0
</PRE>
</UL>
Each change that corrects a fault in a software sub-system increments
the patch release number. If a change affects the software design of
CUPS then the minor release number will be incremented and the patch
release number reset to 0. If CUPS is completely redesigned the major
release number will be incremented and the minor and patch release
numbers reset to 0:
Each change that corrects a fault in a software sub-system increments
the patch release number. If a change affects the software design of
CUPS then the minor release number will be incremented and the patch
release number reset to 0. If CUPS is completely redesigned the major
release number will be incremented and the minor and patch release
numbers reset to 0:
<UL>
<PRE>
1.1.0b1 First beta release
@@ -293,82 +293,82 @@ v1_0_0
</PRE>
</UL>
<H2><A NAME="5_2">5.2 Generation</A></H2>
Software releases shall be generated for each successfully completed
software trouble report. All object and executable files shall be
deleted prior to performing a full build to ensure that source files
are recompiled.
Software releases shall be generated for each successfully completed
software trouble report. All object and executable files shall be
deleted prior to performing a full build to ensure that source files
are recompiled.
<H2><A NAME="5_3">5.3 Testing</A></H2>
Software testing shall be conducted according to the CUPS Software Test
Plan, CUPS-STP-1.1. Failed tests cause STRs to be generated to correct
the problems found.
Software testing shall be conducted according to the CUPS Software
Test Plan, CUPS-STP-1.1. Failed tests cause STRs to be generated to
correct the problems found.
<H2><A NAME="5_4">5.4 Release</A></H2>
When testing has been completed successfully a new distribution image
is created from the current CVS code &quot;snapshot&quot;. No production release
shall contain software that has not passed the appropriate software
tests.
When testing has been completed successfully a new distribution image
is created from the current CVS code &quot;snapshot&quot;. No production release
shall contain software that has not passed the appropriate software
tests.
<H1 TYPE="A" VALUE="1"><A NAME="6">A Glossary</A></H1>
<H2><A NAME="6_1">A.1 Terms</A></H2>
<DL>
<DT>C</DT>
<DD>A computer language.</DD>
<DT>parallel</DT>
<DD>Sending or receiving data more than 1 bit at a time.</DD>
<DT>pipe</DT>
<DD>A one-way communications channel between two programs.</DD>
<DT>serial</DT>
<DD>Sending or receiving data 1 bit at a time.</DD>
<DT>socket</DT>
<DD>A two-way network communications channel.</DD>
<DT>C </DT>
<DD>A computer language. </DD>
<DT>parallel </DT>
<DD>Sending or receiving data more than 1 bit at a time. </DD>
<DT>pipe </DT>
<DD>A one-way communications channel between two programs. </DD>
<DT>serial </DT>
<DD>Sending or receiving data 1 bit at a time. </DD>
<DT>socket </DT>
<DD>A two-way network communications channel. </DD>
</DL>
<H2><A NAME="6_2">A.2 Acronyms</A></H2>
<DL>
<DT>ASCII</DT>
<DD>American Standard Code for Information Interchange</DD>
<DT>CUPS</DT>
<DD>Common UNIX Printing System</DD>
<DT>ESC/P</DT>
<DD>EPSON Standard Code for Printers</DD>
<DT>FTP</DT>
<DD>File Transfer Protocol</DD>
<DT>HP-GL</DT>
<DD>Hewlett-Packard Graphics Language</DD>
<DT>HP-PCL</DT>
<DD>Hewlett-Packard Page Control Language</DD>
<DT>HP-PJL</DT>
<DD>Hewlett-Packard Printer Job Language</DD>
<DT>IETF</DT>
<DD>Internet Engineering Task Force</DD>
<DT>IPP</DT>
<DD>Internet Printing Protocol</DD>
<DT>ISO</DT>
<DD>International Standards Organization</DD>
<DT>LPD</DT>
<DD>Line Printer Daemon</DD>
<DT>MIME</DT>
<DD>Multimedia Internet Mail Exchange</DD>
<DT>PPD</DT>
<DD>PostScript Printer Description</DD>
<DT>SMB</DT>
<DD>Server Message Block</DD>
<DT>TFTP</DT>
<DD>Trivial File Transfer Protocol</DD>
<DT>ASCII </DT>
<DD>American Standard Code for Information Interchange </DD>
<DT>CUPS </DT>
<DD>Common UNIX Printing System </DD>
<DT>ESC/P </DT>
<DD>EPSON Standard Code for Printers </DD>
<DT>FTP </DT>
<DD>File Transfer Protocol </DD>
<DT>HP-GL </DT>
<DD>Hewlett-Packard Graphics Language </DD>
<DT>HP-PCL </DT>
<DD>Hewlett-Packard Page Control Language </DD>
<DT>HP-PJL </DT>
<DD>Hewlett-Packard Printer Job Language </DD>
<DT>IETF </DT>
<DD>Internet Engineering Task Force </DD>
<DT>IPP </DT>
<DD>Internet Printing Protocol </DD>
<DT>ISO </DT>
<DD>International Standards Organization </DD>
<DT>LPD </DT>
<DD>Line Printer Daemon </DD>
<DT>MIME </DT>
<DD>Multimedia Internet Mail Exchange </DD>
<DT>PPD </DT>
<DD>PostScript Printer Description </DD>
<DT>SMB </DT>
<DD>Server Message Block </DD>
<DT>TFTP </DT>
<DD>Trivial File Transfer Protocol </DD>
</DL>
<H1><A NAME="7">B Coding Requirements</A></H1>
These coding requirements provide detailed information on source file
formatting and documentation content. These guidelines shall be applied
to all C and C++ source files provided with CUPS.
These coding requirements provide detailed information on source file
formatting and documentation content. These guidelines shall be applied
to all C and C++ source files provided with CUPS.
<H2><A NAME="7_1">B.1 Source Files</A></H2>
<H3><A NAME="7_1_1">B.1.1 Naming</A></H3>
All source files names shall be 16 characters or less in length to
ensure compatibility with older UNIX filesystems. Source files
containing functions shall have an extension of &quot;.c&quot; for ANSI C and
&quot;.cxx&quot; for C++ source files. All other &quot;include&quot; files shall have an
extension of &quot;.h&quot;.
All source files names shall be 16 characters or less in length to
ensure compatibility with older UNIX filesystems. Source files
containing functions shall have an extension of &quot;.c&quot; for ANSI C and
&quot;.cxx&quot; for C++ source files. All other &quot;include&quot; files shall have an
extension of &quot;.h&quot;.
<H3><A NAME="7_1_2">B.1.2 Documentation</A></H3>
The top of each source file shall contain a header giving the name of
the file, the purpose or nature of the source file, the copyright and
licensing notice, and the functions contained in the file. The file
name and revision information is provided by the CVS &quot;$Id$&quot; tag:
The top of each source file shall contain a header giving the name of
the file, the purpose or nature of the source file, the copyright and
licensing notice, and the functions contained in the file. The file
name and revision information is provided by the CVS &quot;$Id$&quot; tag:
<UL>
<PRE>
/*
@@ -403,10 +403,10 @@ v1_0_0
*/
</PRE>
</UL>
The bottom of each source file shall contain a trailer giving the name
of the file using the CVS &quot;$Id$&quot; tag. The primary purpose of this is to
mark the end of a source file; if the trailer is missing it is possible
that code has been lost near the end of the file:
The bottom of each source file shall contain a trailer giving the name
of the file using the CVS &quot;$Id$&quot; tag. The primary purpose of this is to
mark the end of a source file; if the trailer is missing it is possible
that code has been lost near the end of the file:
<UL>
<PRE>
/*
@@ -416,17 +416,17 @@ v1_0_0
</UL>
<H2><A NAME="7_2">B.2 Functions</A></H2>
<H3><A NAME="7_2_1">B.2.1 Naming</A></H3>
Functions with a global scope shall be capitalized (&quot;DoThis&quot;, &quot;DoThat&quot;,
&quot;DoSomethingElse&quot;, etc.) The only exception to this rule shall be the
CUPS interface library functions which may begin with a prefix word in
lowercase (&quot;cupsDoThis&quot;, &quot;cupsDoThat&quot;, etc.)
<P>Functions with a local scope shall be declared &quot;static&quot; and be
lowercase with underscores between words (&quot;do_this&quot;, &quot;do_that&quot;,
&quot;do_something_else&quot;, etc.)</P>
Functions with a global scope shall be capitalized (&quot;DoThis&quot;,
&quot;DoThat&quot;, &quot;DoSomethingElse&quot;, etc.) The only exception to this rule
shall be the CUPS interface library functions which may begin with a
prefix word in lowercase (&quot;cupsDoThis&quot;, &quot;cupsDoThat&quot;, etc.)
<P>Functions with a local scope shall be declared &quot;static&quot; and be
lowercase with underscores between words (&quot;do_this&quot;, &quot;do_that&quot;,
&quot;do_something_else&quot;, etc.) </P>
<H3><A NAME="7_2_2">B.2.2 Documentation</A></H3>
Each function shall begin with a comment header describing what the
function does, the possible input limits (if any), and the possible
output values (if any), and any special information needed:
Each function shall begin with a comment header describing what the
function does, the possible input limits (if any), and the possible
output values (if any), and any special information needed:
<UL>
<PRE>
/*
@@ -445,12 +445,12 @@ do_this(float x) /* I - Power value (0.0 &lt;= x &lt;= 1.1) */
</UL>
<H2><A NAME="7_3">B.3 Methods</A></H2>
<H3><A NAME="7_3_1">B.3.1 Naming</A></H3>
Methods shall be in lowercase with underscores between words
(&quot;do_this&quot;, &quot;do_that&quot;, &quot;do_something_else&quot;, etc.)
Methods shall be in lowercase with underscores between words
(&quot;do_this&quot;, &quot;do_that&quot;, &quot;do_something_else&quot;, etc.)
<H3><A NAME="7_3_2">B.3.2 Documentation</A></H3>
Each method shall begin with a comment header describing what the
method does, the possible input limits (if any), and the possible
output values (if any), and any special information needed:
Each method shall begin with a comment header describing what the
method does, the possible input limits (if any), and the possible
output values (if any), and any special information needed:
<UL>
<PRE>
/*
@@ -469,19 +469,19 @@ class::do_this(float x) /* I - Power value (0.0 &lt;= x &lt;= 1.0) */
</UL>
<H2><A NAME="7_4">B.4 Variables</A></H2>
<H3><A NAME="7_4_1">B.4.1 Naming</A></H3>
Variables with a global scope shall be capitalized (&quot;ThisVariable&quot;,
&quot;ThatVariable&quot;, &quot;ThisStateVariable&quot;, etc.) The only exception to this
rule shall be the CUPS interface library global variables which must
begin with the prefix &quot;cups&quot; (&quot;cupsThisVariable&quot;, &quot;cupsThatVariable&quot;,
etc.) Global variables shall be replaced by function arguments whenever
possible.
<P>Variables with a local scope shall be lowercase with underscores
between words (&quot;this_variable&quot;, &quot;that_variable&quot;, etc.) Any local
variables shared by functions within a source file shall be declared
&quot;static&quot;.</P>
Variables with a global scope shall be capitalized (&quot;ThisVariable&quot;,
&quot;ThatVariable&quot;, &quot;ThisStateVariable&quot;, etc.) The only exception to this
rule shall be the CUPS interface library global variables which must
begin with the prefix &quot;cups&quot; (&quot;cupsThisVariable&quot;, &quot;cupsThatVariable&quot;,
etc.) Global variables shall be replaced by function arguments whenever
possible.
<P>Variables with a local scope shall be lowercase with underscores
between words (&quot;this_variable&quot;, &quot;that_variable&quot;, etc.) Any local
variables shared by functions within a source file shall be declared
&quot;static&quot;. </P>
<H3><A NAME="7_4_2">B.4.2 Documentation</A></H3>
Each variable shall be declared on a separate line and shall be
immediately followed by a comment block describing the variable:
Each variable shall be declared on a separate line and shall be
immediately followed by a comment block describing the variable:
<UL>
<PRE>
int this_variable; /* The current state of this */
@@ -490,11 +490,11 @@ int that_variable; /* The current state of that */
</UL>
<H2><A NAME="7_5">B.5 Types</A></H2>
<H3><A NAME="7_5_1">B.5.1 Naming</A></H3>
All type names shall be lowercase with underscores between words and
&quot;_t&quot; appended to the end of the name (&quot;this_type_t&quot;, &quot;that_type_t&quot;,
etc.)
All type names shall be lowercase with underscores between words and
&quot;_t&quot; appended to the end of the name (&quot;this_type_t&quot;, &quot;that_type_t&quot;,
etc.)
<H3><A NAME="7_5_2">B.5.2 Documentation</A></H3>
Each type shall have a comment block immediately before the typedef:
Each type shall have a comment block immediately before the typedef:
<UL>
<PRE>
/*
@@ -505,13 +505,13 @@ typedef int cups_this_type_t;
</UL>
<H2><A NAME="7_6">B.6 Structures</A></H2>
<H3><A NAME="7_6_1">B.6.1 Naming</A></H3>
All structure names shall be lowercase with underscores between words
and &quot;_str&quot; appended to the end of the name (&quot;this_struct_str&quot;,
&quot;that_struct_str&quot;, etc.)
All structure names shall be lowercase with underscores between words
and &quot;_str&quot; appended to the end of the name (&quot;this_struct_str&quot;,
&quot;that_struct_str&quot;, etc.)
<H3><A NAME="7_6_2">B.6.2 Documentation</A></H3>
Each structure shall have a comment block immediately before the struct
and each member shall be documented in accordance with the variable
naming policy above:
Each structure shall have a comment block immediately before the
struct and each member shall be documented in accordance with the
variable naming policy above:
<UL>
<PRE>
/*
@@ -526,12 +526,12 @@ struct cups_this_struct_str
</UL>
<H2><A NAME="7_7">B.7 Classes</A></H2>
<H3><A NAME="7_7_1">B.7.1 Naming</A></H3>
All class names shall be lowercase with underscores between words
(&quot;this_class&quot;, &quot;that_class&quot;, etc.)
All class names shall be lowercase with underscores between words
(&quot;this_class&quot;, &quot;that_class&quot;, etc.)
<H3><A NAME="7_7_2">B.7.2 Documentation</A></H3>
Each class shall have a comment block immediately before the class and
each member shall be documented in accordance with the variable naming
policy above:
Each class shall have a comment block immediately before the class and
each member shall be documented in accordance with the variable naming
policy above:
<UL>
<PRE>
/*
@@ -546,14 +546,14 @@ class cups_this_class
</UL>
<H2><A NAME="7_8">B.8 Constants</A></H2>
<H3><A NAME="7_8_1">B.8.1 Naming</A></H3>
All constant names shall be uppercase with underscored between words
(&quot;THIS_CONSTANT&quot;, &quot;THAT_CONSTANT&quot;, etc.) Constants defined for the CUPS
interface library must begin with an uppercase prefix
(&quot;CUPS_THIS_CONSTANT&quot;, &quot;CUPS_THAT_CONSTANT&quot;, etc.)
<P>Typed enumerations shall be used whenever possible to allow for type
checking by the compiler.</P>
All constant names shall be uppercase with underscored between words
(&quot;THIS_CONSTANT&quot;, &quot;THAT_CONSTANT&quot;, etc.) Constants defined for the CUPS
interface library must begin with an uppercase prefix
(&quot;CUPS_THIS_CONSTANT&quot;, &quot;CUPS_THAT_CONSTANT&quot;, etc.)
<P>Typed enumerations shall be used whenever possible to allow for type
checking by the compiler. </P>
<H3><A NAME="7_8_2">B.8.2 Documentation</A></H3>
Comment blocks shall immediately follow each constant:
Comment blocks shall immediately follow each constant:
<UL>
<PRE>
enum
@@ -565,8 +565,8 @@ enum
</UL>
<H2><A NAME="7_9">B.9 Code</A></H2>
<H3><A NAME="7_9_1">B.9.1 Documentation</A></H3>
All source code shall utilize block comments within functions to
describe the operations being performed by a group of statements:
All source code shall utilize block comments within functions to
describe the operations being performed by a group of statements:
<UL>
<PRE>
/*
@@ -593,10 +593,10 @@ do
</UL>
<H3><A NAME="7_9_2">B.9.2 Style</A></H3>
<H4 TYPE="a">B.9.2.a Indentation</H4>
All code blocks enclosed by brackets shall begin with the opening brace
on a new line. The code then follows starting on a new line after the
brace and is indented 2 spaces. The closing brace is then placed on a
new line following the code at the original indentation:
All code blocks enclosed by brackets shall begin with the opening
brace on a new line. The code then follows starting on a new line after
the brace and is indented 2 spaces. The closing brace is then placed on
a new line following the code at the original indentation:
<UL>
<PRE>
{
@@ -614,9 +614,10 @@ do
}
</PRE>
</UL>
Single-line statements following &quot;do&quot;, &quot;else&quot;, &quot;for&quot;, &quot;if&quot;, and &quot;while&quot;
shall be indented 2 spaces as well. Blocks of code in a &quot;switch&quot; block
shall be indented 4 spaces after each &quot;case&quot; and &quot;default&quot; case:
Single-line statements following &quot;do&quot;, &quot;else&quot;, &quot;for&quot;, &quot;if&quot;, and
&quot;while&quot; shall be indented 2 spaces as well. Blocks of code in a
&quot;switch&quot; block shall be indented 4 spaces after each &quot;case&quot; and
&quot;default&quot; case:
<UL>
<PRE>
switch (array[i])
@@ -632,20 +633,20 @@ switch (array[i])
</PRE>
</UL>
<H4>B.9.2.b Spacing</H4>
A space shall follow each reserved word (&quot;if&quot;, &quot;while&quot;, etc.) Spaces
shall not be inserted between a function name and the arguments in
parenthesis.
A space shall follow each reserved word (&quot;if&quot;, &quot;while&quot;, etc.) Spaces
shall not be inserted between a function name and the arguments in
parenthesis.
<H4>B.9.2.c Return Values</H4>
Parenthesis shall surround values returned from a function using
&quot;return&quot;:
Parenthesis shall surround values returned from a function using
&quot;return&quot;:
<UL>
<PRE>
return (STATE_IDLE);
</PRE>
</UL>
<H4>B.9.2.d Loops</H4>
Whenever convenient loops should count downward to zero to improve
program performance:
Whenever convenient loops should count downward to zero to improve
program performance:
<UL>
<PRE>
for (i = sizeof(array) / sizeof(array[0]) - 1; i &gt;= 0; i --)
@@ -657,19 +658,19 @@ for (i = sizeof(array) / sizeof(array[0]) - 1; i &gt;= 0; i --)
<TABLE WIDTH="80%">
<TR><TH ALIGN="RIGHT">Summary of Problem:</TH><TD ALIGN="LEFT">
________________________________________</TD></TR>
<TR><TH ALIGN="RIGHT">Problem Severity:</TH><TD ALIGN="LEFT">__1=RFE
<BR> __2=Documentation-Error
<BR> __3=Unable-to-Print-a-File
<BR> __4=Unable-to-Print-to-a-Printer
<TR><TH ALIGN="RIGHT">Problem Severity:</TH><TD ALIGN="LEFT">__1=RFE
<BR> __2=Documentation-Error
<BR> __3=Unable-to-Print-a-File
<BR> __4=Unable-to-Print-to-a-Printer
<BR> __5=Unable-to-Print-at-All</TD></TR>
<TR><TH ALIGN="RIGHT">Problem Scope:</TH><TD ALIGN="LEFT">__1=Machine
__2=Operating-System __3=All</TD></TR>
<TR><TH ALIGN="RIGHT">Problem Scope:</TH><TD ALIGN="LEFT">__1=Machine
__2=Operating-System __3=All</TD></TR>
<TR><TH ALIGN="RIGHT" VALIGN="TOP">Detailed Description of Problem:</TH><TD
ALIGN="LEFT">________________________________________
<BR> ________________________________________
<BR> ________________________________________
<BR> ________________________________________
<BR> ________________________________________
ALIGN="LEFT">________________________________________
<BR> ________________________________________
<BR> ________________________________________
<BR> ________________________________________
<BR> ________________________________________
<BR> ________________________________________</TD></TR>
</TABLE>
</CENTER>
BIN
Ver Arquivo
Arquivo binário não exibido.
+549 -544
Ver Arquivo
Diferenças do arquivo suprimidas por serem muito extensas Carregar Diff
BIN
Ver Arquivo
Arquivo binário não exibido.
+933 -941
Ver Arquivo
Diferenças do arquivo suprimidas por serem muito extensas Carregar Diff
BIN
Ver Arquivo
Arquivo binário não exibido.
-12
Ver Arquivo
@@ -1633,18 +1633,6 @@ resolution is enabled. The localhost address (127.0.0.1) is
printing text files. Only the values 6 and 8 are currently supported.
The default value is 6.
<H3>natural-scaling (integer(1:1000))</H3>
<P><I>(CUPS 1.1.9 and higher)</I>
<P>The natural-scaling attribute specifies the scaling of image files with
respect to the natural image size. A value of 100 specifies that the image
file should exactly the natural size, while 50 is half the natural size
and 200 is twice the natural size. The default value is 100.
<P>The ppi option can be used to override the natural resolution of the
image, which controls the natural size.
<H3>page-bottom (integer(0:MAX))</H3>
<P>The page-bottom attribute specifies the bottom margin in points (72 points
Arquivo binário não exibido.
+2117 -2172
Ver Arquivo
Diferenças do arquivo suprimidas por serem muito extensas Carregar Diff
BIN
Ver Arquivo
Arquivo binário não exibido.
+5 -82
Ver Arquivo
@@ -1,7 +1,7 @@
<HTML>
<HEAD>
<META NAME="COPYRIGHT" CONTENT="Copyright 1997-2001, All Rights Reserved">
<META NAME="DOCNUMBER" CONTENT="CUPS-SAM-1.1.9">
<META NAME="DOCNUMBER" CONTENT="CUPS-SAM-1.1.7">
<META NAME="Author" CONTENT="Easy Software Products">
<TITLE>CUPS Software Administrators Manual</TITLE>
</HEAD>
@@ -11,7 +11,7 @@
<P>This software administrators manual provides printer administration
information for the Common UNIX Printing System<SUP>TM</SUP>
("CUPS<SUP>TM</SUP>"), version 1.1.9.
("CUPS<SUP>TM</SUP>"), version 1.1.7.
<EMBED SRC="system-overview.shtml">
@@ -177,11 +177,6 @@ make changes you can get the HTMLDOC software from:
<A HREF="http://www.easysw.com/htmldoc">http://www.easysw.com/htmldoc</A>
</PRE></UL>
<P>Finally, you'll need a <CODE>make</CODE> program that
understands the <CODE>include</CODE> directive - FreeBSD,
NetBSD, and OpenBSD developers should use the <CODE>gmake</CODE>
program.
<H3><A NAME="COMPILING">Compiling CUPS</A></H3>
<P>CUPS uses GNU autoconf to configure the makefiles and source code
@@ -239,16 +234,6 @@ prior to running configure:
<A HREF="http://www.openssl.org">http://www.openssl.org</A>
</PRE></UL>
<P>If the OpenSSL headers and libraries are not installed in the
standard directories, use the <CODE>--with-openssl-includes</CODE>
and <CODE>--with-openssl-libs</CODE> options:</P>
<UL><PRE>
./configure --enable-ssl \
--with-openssl-includes=/foo/bar/include \
--with-openssl-libs=/foo/bar/lib
</PRE></UL>
<P>Once you have configured things, just type:
<UL><PRE>
@@ -872,8 +857,6 @@ determine how the server operates:
<LI><A HREF="#DefaultLanguage"><CODE>DefaultLanguage</CODE></A>
<LI><A HREF="#Deny"><CODE>Deny</CODE></A>
<LI><A HREF="#DocumentRoot"><CODE>DocumentRoot</CODE></A>
<LI><A HREF="#Encryption"><CODE>Encryption</CODE></A>
<LI><A HREF="#ErrorLog"><CODE>ErrorLog</CODE></A>
</TD>
<TD VALIGN="TOP">
@@ -881,14 +864,13 @@ determine how the server operates:
</TD>
<TD VALIGN="TOP">
<LI><A HREF="#Encryption"><CODE>Encryption</CODE></A>
<LI><A HREF="#ErrorLog"><CODE>ErrorLog</CODE></A>
<LI><A HREF="#FilterLimit"><CODE>FilterLimit</CODE></A>
<LI><A HREF="#FontPath"><CODE>FontPath</CODE></A>
<LI><A HREF="#Group"><CODE>Group</CODE></A>
<LI><A HREF="#HideImplicitMembers"><CODE>HideImplicitMembers</CODE></A>
<LI><A HREF="#HostNameLookups"><CODE>HostNameLookups</CODE></A>
<LI><A HREF="#ImplicitClasses"><CODE>ImplicitClasses</CODE></A>
<LI><A HREF="#ImplicitAnyClasses"><CODE>ImplicitAnyClasses</CODE></A>
<LI><A HREF="#Include"><CODE>Include</CODE></A>
<LI><A HREF="#KeepAliveTimeout"><CODE>KeepAliveTimeout</CODE></A>
<LI><A HREF="#KeepAlive"><CODE>KeepAlive</CODE></A>
<LI><A HREF="#Limit"><CODE>Limit</CODE></A>
@@ -904,6 +886,7 @@ determine how the server operates:
<LI><A HREF="#MaxLogSize"><CODE>MaxLogSize</CODE></A>
<LI><A HREF="#MaxRequestSize"><CODE>MaxRequestSize</CODE></A>
<LI><A HREF="#Order"><CODE>Order</CODE></A>
<LI><A HREF="#PageLog"><CODE>PageLog</CODE></A>
</TD>
<TD VALIGN="TOP">
@@ -911,7 +894,6 @@ determine how the server operates:
</TD>
<TD VALIGN="TOP">
<LI><A HREF="#PageLog"><CODE>PageLog</CODE></A>
<LI><A HREF="#Port"><CODE>Port</CODE></A>
<LI><A HREF="#PreserveJobFiles"><CODE>PreserveJobFiles</CODE></A>
<LI><A HREF="#PreserveJobHistory"><CODE>PreserveJobHistory</CODE></A>
@@ -1711,26 +1693,6 @@ filter and CGI programs run as. The default group is <CODE>sys</CODE>,
<CODE>system</CODE>, or <CODE>root</CODE> depending on the operating
system.
<!-- NEED 3in -->
<H3><A NAME="HideImplicitMembers">HideImplicitMembers</A></H3>
<HR>
<H4>Examples</H4>
<UL><PRE>
HideImplicitMembers Yes
HideImplicitMembers No
</PRE></UL>
<H4>Description</H4>
<P>The <CODE>HideImplicitMembers</CODE> directive controls
whether the individual printers in an implicit class are shown
to the user. The default is <CODE>No</CODE>.</P>
<P><A HREF="#ImplicitClasses"><CODE>ImplicitClasses</CODE></A>
must be enabled for this directive to have any effect.</P>
<!-- NEED 3in -->
<H3><A NAME="HostNameLookups">HostNameLookups</A></H3>
<HR>
@@ -1777,45 +1739,6 @@ The default setting is <CODE>On</CODE> but is automatically turned
<CODE>Off</CODE> if <A HREF="#Browsing"><CODE>Browsing</CODE></A> is
turned <CODE>Off</CODE>.
<!-- NEED 3in -->
<H3><A NAME="ImplicitAnyClasses">ImplicitAnyClasses</A></H3>
<HR>
<H4>Examples</H4>
<UL><PRE>
ImplicitAnyClasses On
ImplicitAnyClasses Off
</PRE></UL>
<H4>Description</H4>
<P>The <CODE>ImplicitAnyClasses</CODE> directive controls
whether implicit classes for local and remote printers are
created with the name <CODE>AnyPrinter</CODE>. The default
setting is <CODE>Off</CODE>.</P>
<P><A HREF="#ImplicitClasses"><CODE>ImplicitClasses</CODE></A>
must be enabled for this directive to have any effect.</P>
<!-- NEED 3in -->
<H3><A NAME="Include">Include</A></H3>
<HR>
<H4>Examples</H4>
<UL><PRE>
Include filename
Include /foo/bar/filename
</PRE></UL>
<H4>Description</H4>
<P>The <CODE>Include</CODE> directive includes the named file in
the <CODE>cupsd.conf</CODE> file. If no leading path is
provided, the file is assumed to be relative to the
<A HREF="#ServerRoot"><CODE>ServerRoot</CODE></A> directory.</P>
<!-- NEED 3in -->
<H3><A NAME="KeepAlive">KeepAlive</A></H3>
<HR>
+347 -342
Ver Arquivo
@@ -1,27 +1,27 @@
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" "http://www.w3.org/TR/REC-html40/loose.dtd">
<HTML>
<HEAD>
<TITLE>CUPS Software Design Description</TITLE>
<TITLE> CUPS Software Design Description</TITLE>
<META NAME="author" CONTENT="Easy Software Products">
<META NAME="copyright" CONTENT="Copyright 1997-2001, All Rights Reserved">
<META NAME="docnumber" CONTENT="CUPS-SDD-1.1">
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; CHARSET=iso-8859-1">
<STYLE TYPE="text/css"><!--
BODY { font-family: serif }
H1 { font-family: sans-serif }
H2 { font-family: sans-serif }
H3 { font-family: sans-serif }
H4 { font-family: sans-serif }
H5 { font-family: sans-serif }
H6 { font-family: sans-serif }
SUB { font-size: smaller }
SUP { font-size: smaller }
PRE { font-family: monospace }
BODY { font-family: serif; font-size: 11.0pt }
H1 { font-family: sans-serif; font-size: 20.0pt }
H2 { font-family: sans-serif; font-size: 17.0pt }
H3 { font-family: sans-serif; font-size: 14.0pt }
H4 { font-family: sans-serif; font-size: 11.0pt }
H5 { font-family: sans-serif; font-size: 9.0pt }
H6 { font-family: sans-serif; font-size: 8.0pt }
SUB { font-size: 8.0pt }
SUP { font-size: 8.0pt }
PRE { font-size: 9.0pt }
--></STYLE>
</HEAD>
<BODY>
<CENTER><A HREF="#CONTENTS"><IMG SRC="images/cups-large.gif" BORDER="0" WIDTH="431" HEIGHT="511"><BR>
<H1>CUPS Software Design Description</H1></A><BR>
<CENTER><A HREF="#CONTENTS"><IMG SRC="images/cups-large.gif" BORDER="0" WIDTH="100%"><BR>
<H1> CUPS Software Design Description</H1></A><BR>
CUPS-SDD-1.1<BR>
Easy Software Products<BR>
Copyright 1997-2001, All Rights Reserved<BR>
@@ -138,454 +138,459 @@ Copyright 1997-2001, All Rights Reserved<BR>
<HR>
<H1><A NAME="1">1 Scope</A></H1>
<H2><A NAME="1_1">1.1 Identification</A></H2>
This software design description document provides general information
on the architecture and coding of the Common UNIX Printing System
(&quot;CUPS&quot;) Version 1.1.
This software design description document provides general information
on the architecture and coding of the Common UNIX Printing System
(&quot;CUPS&quot;) Version 1.1.
<H2><A NAME="1_2">1.2 System Overview</A></H2>
<P>CUPS provides a portable printing layer for UNIX&reg;-based operating
systems. It has been developed by<A HREF="http://www.easysw.com"> Easy
Software Products</A> to promote a standard printing solution for all
UNIX vendors and users. CUPS provides the System V and Berkeley
command-line interfaces.</P>
<P>CUPS uses the Internet Printing Protocol (&quot;IPP&quot;) as the basis for
managing print jobs and queues. The Line Printer Daemon (&quot;LPD&quot;) Server
Message Block (&quot;SMB&quot;), and AppSocket (a.k.a. JetDirect) protocols are
also supported with reduced functionality. CUPS adds network printer
browsing and PostScript Printer Description (&quot;PPD&quot;) based printing
options to support real-world printing under UNIX.</P>
<P>CUPS also includes a customized version of GNU Ghostscript (currently
based off GNU Ghostscript 5.50) and an image file RIP that are used to
support non-PostScript printers. Sample drivers for HP and EPSON
printers are included that use these filters.</P>
<P>CUPS provides a portable printing layer for UNIX&reg;-based operating
systems. It has been developed by <A HREF="http://www.easysw.com">Easy
Software Products</A> to promote a standard printing solution for all
UNIX vendors and users. CUPS provides the System V and Berkeley
command-line interfaces. </P>
<P>CUPS uses the Internet Printing Protocol (&quot;IPP&quot;) as the basis for
managing print jobs and queues. The Line Printer Daemon (&quot;LPD&quot;) Server
Message Block (&quot;SMB&quot;), and AppSocket (a.k.a. JetDirect) protocols are
also supported with reduced functionality. CUPS adds network printer
browsing and PostScript Printer Description (&quot;PPD&quot;) based printing
options to support real-world printing under UNIX. </P>
<P>CUPS also includes a customized version of GNU Ghostscript
(currently based off GNU Ghostscript 5.50) and an image file RIP that
are used to support non-PostScript printers. Sample drivers for HP and
EPSON printers are included that use these filters. </P>
<H2><A NAME="1_3">1.3 Document Overview</A></H2>
This software design description document is organized into the
following sections:
This software design description document is organized into the
following sections:
<UL>
<LI>1 - Scope</LI>
<LI>2 - References</LI>
<LI>3 - Design Overview</LI>
<LI>A - Glossary</LI>
<LI>1 - Scope </LI>
<LI>2 - References </LI>
<LI>3 - Design Overview </LI>
<LI>A - Glossary </LI>
</UL>
<H1><A NAME="2">2 References</A></H1>
<H2><A NAME="2_1">2.1 CUPS Documentation</A></H2>
<P>The following CUPS documentation is referenced by this document:</P>
<P>The following CUPS documentation is referenced by this document: </P>
<UL>
<LI>CUPS-CMP-1.1: CUPS Configuration Management Plan</LI>
<LI>CUPS-IDD-1.1: CUPS System Interface Design Description</LI>
<LI>CUPS-IPP-1.1: CUPS Implementation of IPP</LI>
<LI>CUPS-SAM-1.1.x: CUPS Software Administrators Manual</LI>
<LI>CUPS-SDD-1.1: CUPS Software Design Description</LI>
<LI>CUPS-SPM-1.1.x: CUPS Software Programming Manual</LI>
<LI>CUPS-SSR-1.1: CUPS Software Security Report</LI>
<LI>CUPS-STP-1.1: CUPS Software Test Plan</LI>
<LI>CUPS-SUM-1.1.x: CUPS Software Users Manual</LI>
<LI>CUPS-SVD-1.1: CUPS Software Version Description</LI>
<LI>CUPS-CMP-1.1: CUPS Configuration Management Plan </LI>
<LI>CUPS-IDD-1.1: CUPS System Interface Design Description </LI>
<LI>CUPS-IPP-1.1: CUPS Implementation of IPP </LI>
<LI>CUPS-SAM-1.1.x: CUPS Software Administrators Manual </LI>
<LI>CUPS-SDD-1.1: CUPS Software Design Description </LI>
<LI>CUPS-SPM-1.1.x: CUPS Software Programming Manual </LI>
<LI>CUPS-SSR-1.1: CUPS Software Security Report </LI>
<LI>CUPS-STP-1.1: CUPS Software Test Plan </LI>
<LI>CUPS-SUM-1.1.x: CUPS Software Users Manual </LI>
<LI>CUPS-SVD-1.1: CUPS Software Version Description </LI>
</UL>
<H2><A NAME="2_2">2.2 Other Documents</A></H2>
<P>The following non-CUPS documents are referenced by this document:</P>
<P>The following non-CUPS documents are referenced by this document: </P>
<UL>
<LI><A HREF="http://partners.adobe.com/asn/developer/PDFS/TN/5003.PPD_Spec_v4.3.pdf">
Adobe PostScript Printer Description File Format Specification, Version
4.3.</A></LI>
Adobe PostScript Printer Description File Format Specification,
Version 4.3.</A></LI>
<LI><A HREF="http://partners.adobe.com/asn/developer/PDFS/TN/PLRM.pdf">
Adobe PostScript Language Reference, Third Edition.</A></LI>
<LI>IPP: Job and Printer Set Operations</LI>
<LI>IPP/1.1: Encoding and Transport</LI>
<LI>IPP/1.1: Implementers Guide</LI>
<LI>IPP/1.1: Model and Semantics</LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc1179.txt">RFC 1179, Line Printer
Daemon Protocol</A></LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc2567.txt">RFC 2567, Design Goals
for an Internet Printing Protocol</A></LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc2568.txt">RFC 2568, Rationale
for the Structure of the Model and Protocol</A> for the Internet
Printing Protocol</LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc2569.txt">RFC 2569, Mapping
between LPD and IPP Protocols</A></LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc2616.txt">RFC 2616, Hypertext
Transfer Protocol -- HTTP/1.1</A></LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc2617.txt">RFC 2617, HTTP
Authentication: Basic and Digest Access</A> Authentication</LI>
Adobe PostScript Language Reference, Third Edition.</A></LI>
<LI>IPP: Job and Printer Set Operations </LI>
<LI>IPP/1.1: Encoding and Transport </LI>
<LI>IPP/1.1: Implementers Guide </LI>
<LI>IPP/1.1: Model and Semantics </LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc1179.txt">RFC 1179, Line
Printer Daemon Protocol</A></LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc2567.txt">RFC 2567, Design
Goals for an Internet Printing Protocol</A></LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc2568.txt">RFC 2568, Rationale
for the Structure of the Model and Protocol</A> for the Internet
Printing Protocol</LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc2569.txt">RFC 2569, Mapping
between LPD and IPP Protocols</A></LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc2616.txt">RFC 2616, Hypertext
Transfer Protocol -- HTTP/1.1</A></LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc2617.txt">RFC 2617, HTTP
Authentication: Basic and Digest Access</A> Authentication </LI>
</UL>
<H1><A NAME="3">3 Design Overview</A></H1>
CUPS is composed of 9 software sub-systems that operate together to
perform common printing tasks:
CUPS is composed of 9 software sub-systems that operate together to
perform common printing tasks:
<UL>
<LI>Backends</LI>
<LI>Berkeley Commands</LI>
<LI>CGI</LI>
<LI>CUPS Application Programmers Interface</LI>
<LI>CUPS Imaging Library</LI>
<LI>Daemons</LI>
<LI>Filters</LI>
<LI>Scheduler</LI>
<LI>System V Commands</LI>
<LI>Backends </LI>
<LI>Berkeley Commands </LI>
<LI>CGI </LI>
<LI>CUPS Application Programmers Interface </LI>
<LI>CUPS Imaging Library </LI>
<LI>Daemons </LI>
<LI>Filters </LI>
<LI>Scheduler </LI>
<LI>System V Commands </LI>
</UL>
<H2><A NAME="3_1">3.1 Backends</A></H2>
The backends implement communications over a number of different
interfaces. All backends are called with a common set of arguments:
The backends implement communications over a number of different
interfaces. All backends are called with a common set of arguments:
<UL>
<LI>Device URI - the Uniform Resource Identifier for the output device
(e.g. <CODE>parallel:/dev/plp</CODE>, <CODE>ipp://hostname/resource</CODE>
).</LI>
<LI>Job Identifier - the job identifier for this job (integer).</LI>
<LI>User Name - the user associated with this job (name string).</LI>
<LI>Title - the title/job-name associated with this job (name string).</LI>
<LI>Copies - the number of copies required (integer).</LI>
<LI>Options - the options associated with this job (space separated
option strings).</LI>
<LI>Filename (optional) - the file to print; if this option is not
specified, the backend must read the print file from the standard
input.</LI>
<LI>Device URI - the Uniform Resource Identifier for the output device
(e.g. <CODE>parallel:/dev/plp</CODE>, <CODE> ipp://hostname/resource</CODE>
). </LI>
<LI>Job Identifier - the job identifier for this job (integer). </LI>
<LI>User Name - the user associated with this job (name string). </LI>
<LI>Title - the title/job-name associated with this job (name string). </LI>
<LI>Copies - the number of copies required (integer). </LI>
<LI>Options - the options associated with this job (space separated
option strings). </LI>
<LI>Filename (optional) - the file to print; if this option is not
specified, the backend must read the print file from the standard
input. </LI>
</UL>
<P>Backends are named using the scheme of the URI, so a URI of
&quot;ipp://hostname/resource&quot; would be processed by the &quot;ipp&quot; backend.</P>
<P>Backends are named using the scheme of the URI, so a URI of
&quot;ipp://hostname/resource&quot; would be processed by the &quot;ipp&quot; backend. </P>
<H3><A NAME="3_1_1">3.1.1 ipp</A></H3>
<P>The ipp backend sends the specified job to a network printer or host
using the Internet Printing Protocol. The URI is as specified by the <CODE>
printer-uri-supported</CODE> attribute from the printer or host.</P>
<P>The ipp backend sends the specified job to a network printer or host
using the Internet Printing Protocol. The URI is as specified by the <CODE>
printer-uri-supported</CODE> attribute from the printer or host. </P>
<H3><A NAME="3_1_2">3.1.2 lpd</A></H3>
<P>The lpd backend sends the specified job to a network printer or host
using the Line Printer Daemon protocol. The URI is of the form:</P>
<P>The lpd backend sends the specified job to a network printer or host
using the Line Printer Daemon protocol. The URI is of the form: </P>
<UL>
<PRE>lpd://hostname/queue
</PRE>
</UL>
<H3><A NAME="3_1_3">3.1.3 parallel</A></H3>
<P>The parallel backend sends the specified job to a local printer
connected via the specified parallel port device. The URI is of the
form:</P>
<P>The parallel backend sends the specified job to a local printer
connected via the specified parallel port device. The URI is of the
form: </P>
<UL>
<PRE>parallel:/dev/file
</PRE>
</UL>
<H3><A NAME="3_1_4">3.1.4 serial</A></H3>
<P>The serial backend sends the specified job to a local printer
connected via the specified serial port device. The URI is of the form:</P>
<P>The serial backend sends the specified job to a local printer
connected via the specified serial port device. The URI is of the
form: </P>
<UL>
<PRE>serial:/dev/file?option[+option+...]
</PRE>
</UL>
The options can be any combination of the following:
The options can be any combination of the following:
<UL>
<LI><CODE>baud=<I>rate</I></CODE> - Sets the baud rate for the device.</LI>
<LI><CODE>bits=<I>7 or 8</I></CODE> - Sets the number of data bits.</LI>
<LI><CODE>parity=<I>even</I></CODE> - Sets even parity checking.</LI>
<LI><CODE>parity=<I>odd</I></CODE> - Sets odd parity checking.</LI>
<LI><CODE>parity=<I>none</I></CODE> - Turns parity checking off.</LI>
<LI><CODE>flow=dtrdsr<I></I></CODE> - Turns DTR/DSR (hardware) flow
control on.</LI>
<LI><CODE>flow=hard<I></I></CODE> - Turns RTS/CTS (hardware) flow
control on.</LI>
<LI><CODE>flow=none<I></I></CODE> - Turns flow control off.</LI>
<LI><CODE>flow=rtscts<I></I></CODE> - Turns RTS/CTS (hardware) flow
control on.</LI>
<LI><CODE>flow=xonxoff<I></I></CODE> - Turns XON/XOFF (software) flow
control on.</LI>
<LI><CODE>baud=<I>rate</I></CODE> - Sets the baud rate for the device. </LI>
<LI><CODE>bits=<I>7 or 8</I></CODE> - Sets the number of data bits. </LI>
<LI><CODE>parity=<I>even</I></CODE> - Sets even parity checking. </LI>
<LI><CODE>parity=<I>odd</I></CODE> - Sets odd parity checking. </LI>
<LI><CODE>parity=<I>none</I></CODE> - Turns parity checking off. </LI>
<LI><CODE>flow=dtrdsr<I></I></CODE> - Turns DTR/DSR (hardware) flow
control on. </LI>
<LI><CODE>flow=hard<I></I></CODE> - Turns RTS/CTS (hardware) flow
control on. </LI>
<LI><CODE>flow=none<I></I></CODE> - Turns flow control off. </LI>
<LI><CODE>flow=rtscts<I></I></CODE> - Turns RTS/CTS (hardware) flow
control on. </LI>
<LI><CODE>flow=xonxoff<I></I></CODE> - Turns XON/XOFF (software) flow
control on. </LI>
</UL>
<H3><A NAME="3_1_5">3.1.5 socket</A></H3>
<P>The socket backend sends the specified job to a network host using
the AppSocket protocol commonly used by Hewlett-Packard and Tektronix
printers. The URI is of the form:</P>
<P>The socket backend sends the specified job to a network host using
the AppSocket protocol commonly used by Hewlett-Packard and Tektronix
printers. The URI is of the form: </P>
<UL>
<PRE>socket://hostname[:port]
</PRE>
</UL>
The default port number is 9100.
The default port number is 9100.
<H3><A NAME="3_1_6">3.1.6 usb</A></H3>
<P>The usb backend sends the specified job to a local printer connected
via the specified usb port device. The URI is of the form:</P>
<P>The usb backend sends the specified job to a local printer connected
via the specified usb port device. The URI is of the form: </P>
<UL>
<PRE>usb:/dev/file
</PRE>
</UL>
<H2><A NAME="3_2">3.2 Berkeley Commands</A></H2>
<P>The Berkeley commands provide a simple command-line interface to CUPS
to submit and control print jobs. It is provided for compatibility with
existing software that is hardcoded to use the Berkeley commands.</P>
<P>The Berkeley commands provide a simple command-line interface to
CUPS to submit and control print jobs. It is provided for compatibility
with existing software that is hardcoded to use the Berkeley commands. </P>
<H3><A NAME="3_2_1">3.2.1 lpc</A></H3>
The lpc command allows users and administrators to check the status and
control print queues. The version provided with CUPS supports the
following commands:
The lpc command allows users and administrators to check the status
and control print queues. The version provided with CUPS supports the
following commands:
<UL>
<LI>quit - Quits the lpc command.</LI>
<LI>status - Shows the status of printers and jobs in the queue.</LI>
<LI>quit - Quits the lpc command. </LI>
<LI>status - Shows the status of printers and jobs in the queue. </LI>
</UL>
<H3><A NAME="3_2_2">3.2.2 lpq</A></H3>
<P>The lpq command shows the current queue status.</P>
<P>The lpq command shows the current queue status. </P>
<H3><A NAME="3_2_3">3.2.3 lpr</A></H3>
<P>The lpr command submits a job for printing. The CUPS version of lpr
silently ignores the &quot;i&quot;, &quot;t&quot;, &quot;m&quot;, &quot;h&quot;, and &quot;s&quot; options.</P>
<P>The lpr command submits a job for printing. The CUPS version of lpr
silently ignores the &quot;i&quot;, &quot;t&quot;, &quot;m&quot;, &quot;h&quot;, and &quot;s&quot; options. </P>
<H3><A NAME="3_2_4">3.2.4 lprm</A></H3>
<P>The lprm removes one or more print jobs.</P>
<P>The lprm removes one or more print jobs. </P>
<H2><A NAME="3_3">3.3 CGI</A></H2>
<P>The Common Gateway Interface (CGI) programs provide a web-based
status interface to monitor the status of printers, classes, and jobs.
Each of the CGIs utilize HTML template files that can be customized to
provide alternate appearances.</P>
<P>The Common Gateway Interface (CGI) programs provide a web-based
status interface to monitor the status of printers, classes, and jobs.
Each of the CGIs utilize HTML template files that can be customized to
provide alternate appearances. </P>
<H3><A NAME="3_3_1">3.3.1 admin.cgi</A></H3>
<P>The admin CGI provides administration interfaces for printers and
classes. The user can add, modify, delete, start, stop, and configure
printers and classes using &quot;wizard&quot; interfaces.</P>
<P>The admin CGI provides administration interfaces for printers and
classes. The user can add, modify, delete, start, stop, and configure
printers and classes using &quot;wizard&quot; interfaces. </P>
<H3><A NAME="3_3_2">3.3.2 classes.cgi</A></H3>
<P>The classes CGI lists the available printer classes and any pending
jobs for the class. The user can click on individual classes to limit
the display and click on jobs to see the job status.</P>
<P>The classes CGI lists the available printer classes and any pending
jobs for the class. The user can click on individual classes to limit
the display and click on jobs to see the job status. </P>
<H3><A NAME="3_3_3">3.3.3 jobs.cgi</A></H3>
<P>The jobs CGI lists the queued print jobs in order of priority. The
list can be limited by printer or job.</P>
<P>The jobs CGI lists the queued print jobs in order of priority. The
list can be limited by printer or job. </P>
<H3><A NAME="3_3_4">3.3.4 printers.cgi</A></H3>
<P>The printers CGI lists the available printer queues and any pending
jobs for the printer. The user can click on individual printers to
limit the display and click on jobs to see the job status.</P>
<P>The printers CGI lists the available printer queues and any pending
jobs for the printer. The user can click on individual printers to
limit the display and click on jobs to see the job status. </P>
<H2><A NAME="3_4">3.4 CUPS Application Programmers Interface</A></H2>
<P>The CUPS Application Programmers Interface (&quot;API&quot;) provides common
convenience, HTTP, IPP, language, and PPD functions used by the CUPS
software.</P>
<P>The CUPS Application Programmers Interface (&quot;API&quot;) provides common
convenience, HTTP, IPP, language, and PPD functions used by the CUPS
software. </P>
<H3><A NAME="3_4_1">3.4.1 Convenience Functions</A></H3>
<P>Convenience functions are provided to submit an IPP request, send a
print file, cancel a job, get a list of available printers, get a list
of available classes, get the default printer or class, get the default
server name, get the local username, and get a password string.</P>
<P>Convenience functions are provided to submit an IPP request, send a
print file, cancel a job, get a list of available printers, get a list
of available classes, get the default printer or class, get the default
server name, get the local username, and get a password string. </P>
<H3><A NAME="3_4_2">3.4.2 HTTP Functions</A></H3>
<P>The HTTP functions provide functions to connect to HTTP servers,
issue requests, read data from a server, and write data to a server.</P>
<P>The HTTP functions provide functions to connect to HTTP servers,
issue requests, read data from a server, and write data to a server. </P>
<H3><A NAME="3_4_3">3.4.3 IPP Functions</A></H3>
<P>The IPP function provide functions to manage IPP request data and
attributes, read IPP responses from a server, and write IPP requests to
a server.</P>
<P>The IPP function provide functions to manage IPP request data and
attributes, read IPP responses from a server, and write IPP requests to
a server. </P>
<H3><A NAME="3_4_4">3.4.4 Language Functions</A></H3>
<P>The language functions provide a standard interface for retrieving
common textual messages for a particular locale and determining the
correct encoding (e.g. US ASCII, UTF-8, ISO-8859-1, etc.)</P>
<P>The language functions provide a standard interface for retrieving
common textual messages for a particular locale and determining the
correct encoding (e.g. US ASCII, UTF-8, ISO-8859-1, etc.) </P>
<H3><A NAME="3_4_5">3.4.5 PPD Functions</A></H3>
<P>The PostScript Printer Description functions manage PPD files, select
options, check for option conflicts, and emit selected options in the
correct order.</P>
<P>The PostScript Printer Description functions manage PPD files,
select options, check for option conflicts, and emit selected options
in the correct order. </P>
<H2><A NAME="3_5">3.5 CUPS Imaging Library</A></H2>
<P>The CUPS imaging library provides colorspace conversion, color
management, image management, scaling, image file, and raster functions
used by the CUPS raster filters.</P>
<P>The CUPS imaging library provides colorspace conversion, color
management, image management, scaling, image file, and raster functions
used by the CUPS raster filters. </P>
<H3><A NAME="3_5_1">3.5.1 Colorspace Conversion Functions</A></H3>
<P>The colorspace conversion functions handle conversion of grayscale
and RGB colors to grayscale, RGB, K, CMY, CMYK, and CMYKcm colorspaces.</P>
<P>The colorspace conversion functions handle conversion of grayscale
and RGB colors to grayscale, RGB, K, CMY, CMYK, and CMYKcm colorspaces. </P>
<H3><A NAME="3_5_2">3.5.2 Color Management Functions</A></H3>
<P>The color management functions handle gamut mapping and density
correction. These are integrated with the colorspace conversion
functions so that colorspace conversion and color management are
processed in a single step.</P>
<P>The color management functions handle gamut mapping and density
correction. These are integrated with the colorspace conversion
functions so that colorspace conversion and color management are
processed in a single step. </P>
<H3><A NAME="3_5_3">3.5.3 Image Management Functions</A></H3>
<P>The image management functions manage a tiled image database that is
swapped to/from disk as needed.</P>
<P>The image management functions manage a tiled image database that is
swapped to/from disk as needed. </P>
<H3><A NAME="3_5_4">3.5.4 Scaling Functions</A></H3>
<P>The scaling functions provide image scaling services using
nearest-neighbor sampling and bilinear interpolation as appropriate.</P>
<P>The scaling functions provide image scaling services using
nearest-neighbor sampling and bilinear interpolation as appropriate. </P>
<H3><A NAME="3_5_5">3.5.5 Image File Functions</A></H3>
<P>The image file functions handle loading of all image file formats.</P>
<P>The image file functions handle loading of all image file formats. </P>
<H3><A NAME="3_5_6">3.5.6 Raster Functions</A></H3>
<P>The raster functions manage streams of CUPS raster data (described in
the Interface Design Document) used by non-PostScript printer drivers
and raster filters.</P>
<P>The raster functions manage streams of CUPS raster data (described
in the Interface Design Document) used by non-PostScript printer
drivers and raster filters. </P>
<H2><A NAME="3_6">3.6 Daemons</A></H2>
<P>The daemons provide additional network functions for the scheduler.
Currently only two daemons are provided with CUPS.</P>
<P>The daemons provide additional network functions for the scheduler.
Currently only two daemons are provided with CUPS. </P>
<H3><A NAME="3_6_1">3.6.1 Line Printer Daemon</A></H3>
<P>The line printer daemon provides remote LPD client support and is run
by the <CODE>inetd(8)</CODE> daemon as needed.</P>
<P>The line printer daemon provides remote LPD client support and is
run by the <CODE>inetd(8)</CODE> daemon as needed. </P>
<H3><A NAME="3_6_2">3.6.2 Polling Daemon</A></H3>
<P>The polling daemon is used to poll a remote server for a list of
available printers and provide it to the scheduler for addition. A
separate polling daemon is run by the scheduler for every remote system
listed for polling in the scheduler configuration file.</P>
<P>The polling daemon is used to poll a remote server for a list of
available printers and provide it to the scheduler for addition. A
separate polling daemon is run by the scheduler for every remote system
listed for polling in the scheduler configuration file. </P>
<H2><A NAME="3_7">3.7 Filters</A></H2>
<P>The filters implement file conversion services for CUPS. All filters
are called with a common set of arguments:</P>
<P>The filters implement file conversion services for CUPS. All filters
are called with a common set of arguments: </P>
<UL>
<LI>Printer name - the name of the destination printer (name string).</LI>
<LI>Job Identifier - the job identifier for this job (integer).</LI>
<LI>User Name - the user associated with this job (name string).</LI>
<LI>Title - the title/job-name associated with this job (name string).</LI>
<LI>Copies - the number of copies required (integer).</LI>
<LI>Options - the options associated with this job (space separated
option strings).</LI>
<LI>Filename (optional) - the file to print; if this option is not
specified, the filter must read the input file from the standard input.</LI>
<LI>Printer name - the name of the destination printer (name string). </LI>
<LI>Job Identifier - the job identifier for this job (integer). </LI>
<LI>User Name - the user associated with this job (name string). </LI>
<LI>Title - the title/job-name associated with this job (name string). </LI>
<LI>Copies - the number of copies required (integer). </LI>
<LI>Options - the options associated with this job (space separated
option strings). </LI>
<LI>Filename (optional) - the file to print; if this option is not
specified, the filter must read the input file from the standard
input. </LI>
</UL>
<P>Filters are added to the MIME conversion data file and implement all
necessary conversions from one file type to another.</P>
<P>Filters are added to the MIME conversion data file and implement all
necessary conversions from one file type to another. </P>
<H3><A NAME="3_7_1">3.7.1 hpgltops</A></H3>
<P>The hpgltops filter converts HP-GL/2 files into PostScript.</P>
<P>The hpgltops filter converts HP-GL/2 files into PostScript. </P>
<H3><A NAME="3_7_2">3.7.2 imagetops</A></H3>
<P>The imagetops filter converts image files into PostScript.</P>
<P>The imagetops filter converts image files into PostScript. </P>
<H3><A NAME="3_7_3">3.7.3 imagetoraster</A></H3>
<P>The imagetoraster filter converts image files into CUPS raster data.</P>
<P>The imagetoraster filter converts image files into CUPS raster data. </P>
<H3><A NAME="3_7_4">3.7.4 pdftops</A></H3>
<P>The pdftops filter converts PDF files into PostScript.</P>
<P>The pdftops filter converts PDF files into PostScript. </P>
<H3><A NAME="3_7_5">3.7.5 pstops</A></H3>
<P>The pstops filter inserts printer-specific commands from PPD files
and performs page filtering as requested by the user.</P>
<P>The pstops filter inserts printer-specific commands from PPD files
and performs page filtering as requested by the user. </P>
<H3><A NAME="3_7_6">3.7.6 pstoraster</A></H3>
<P>The pstoraster filter converts PostScript program data into CUPS
raster data.</P>
<P>The pstoraster filter converts PostScript program data into CUPS
raster data. </P>
<H3><A NAME="3_7_7">3.7.7 rastertoepson</A></H3>
<P>The rastertoepson filter handles converting CUPS raster data to ESC/P
and supports both color and black-and-white printers.</P>
<P>The rastertoepson filter handles converting CUPS raster data to
ESC/P and supports both color and black-and-white printers. </P>
<H3><A NAME="3_7_8">3.7.8 rastertohp</A></H3>
<P>The rastertohp filter handles converting CUPS raster data to HP-PCL
and supports both color and black-and-white printers.</P>
<P>The rastertohp filter handles converting CUPS raster data to HP-PCL
and supports both color and black-and-white printers. </P>
<H3><A NAME="3_7_9">3.7.9 texttops</A></H3>
<P>The texttops filter converts text files into PostScript.</P>
<P>The texttops filter converts text files into PostScript. </P>
<H2><A NAME="3_8">3.8 Scheduler</A></H2>
<P>The scheduler is a fully-functional HTTP/1.1 and IPP/1.1 server that
manages the printers, classes, and jobs in the system. It also handles
a simple broadcast-based directory service so that remote print queues
and classes can be accessed transparently from the local system.</P>
<P>The scheduler is a fully-functional HTTP/1.1 and IPP/1.1 server that
manages the printers, classes, and jobs in the system. It also handles
a simple broadcast-based directory service so that remote print queues
and classes can be accessed transparently from the local system. </P>
<H3><A NAME="3_8_1">3.8.1 Authorization</A></H3>
<P>The authorization module is responsible for performing access control
and authentication for all HTTP and IPP requests entering the system.</P>
<P>The authorization module is responsible for performing access
control and authentication for all HTTP and IPP requests entering the
system. </P>
<H3><A NAME="3_8_2">3.8.2 Classes</A></H3>
<P>The classes module is responsible for managing printer classes in the
system. Each class is a collection of local and/or remote printers. The
classes module also reads and writes the classes configuration file.</P>
<P>The classes module is responsible for managing printer classes in
the system. Each class is a collection of local and/or remote printers.
The classes module also reads and writes the classes configuration
file. </P>
<H3><A NAME="3_8_3">3.8.3 Client</A></H3>
<P>The client module is responsible for all HTTP client communications.
It handles listening on selected interfaces, accepting connections from
prospective clients, processing incoming HTTP requests, and sending
HTTP responses to those requests. The client module also is responsible
for executing the external CGI programs as needed to support web-based
printer, class, and job status monitoring and administration.</P>
<P>Once authorized, all IPP requests are sent to the IPP module.</P>
<P>The client module is responsible for all HTTP client communications.
It handles listening on selected interfaces, accepting connections
from prospective clients, processing incoming HTTP requests, and
sending HTTP responses to those requests. The client module also is
responsible for executing the external CGI programs as needed to
support web-based printer, class, and job status monitoring and
administration. </P>
<P>Once authorized, all IPP requests are sent to the IPP module. </P>
<H3><A NAME="3_8_4">3.8.4 Configuration</A></H3>
<P>The configuration module is responsible for reading the CUPS
configuration file and initializing the appropriate data structures and
values. The configuration module also stops CUPS services before
reading the configuration file and restarts them after the
configuration file has been read.</P>
<P>The configuration module is responsible for reading the CUPS
configuration file and initializing the appropriate data structures and
values. The configuration module also stops CUPS services before
reading the configuration file and restarts them after the
configuration file has been read. </P>
<H3><A NAME="3_8_5">3.8.5 Devices</A></H3>
<P>The devices module is responsible for managing the list of available
devices for the CUPS-Get-Devices operation.</P>
<P>The devices module is responsible for managing the list of available
devices for the CUPS-Get-Devices operation. </P>
<H3><A NAME="3_8_6">3.8.6 Directory Services</A></H3>
<P>The directory services module sends and recieves printer state
information over a broadcast socket. Remote printers and classes are
automatically added to or removed from the local printer and class
lists as needed.</P>
<P>The directory services module can only recieve printer state
information over a single UDP port, however it can broadcast to
multiple addresses and ports as needed.</P>
<P>The directory services module sends and recieves printer state
information over a broadcast socket. Remote printers and classes are
automatically added to or removed from the local printer and class
lists as needed. </P>
<P>The directory services module can only recieve printer state
information over a single UDP port, however it can broadcast to
multiple addresses and ports as needed. </P>
<H3><A NAME="3_8_7">3.8.7 IPP</A></H3>
<P>The IPP module handles IPP requests and acts accordingly. URI
validation is also performed here, as a client can post IPP data to any
URI on the server which might sidestep the access control or
authentication of the HTTP server.</P>
<P>The IPP module handles IPP requests and acts accordingly. URI
validation is also performed here, as a client can post IPP data to any
URI on the server which might sidestep the access control or
authentication of the HTTP server. </P>
<H3><A NAME="3_8_8">3.8.8 Jobs</A></H3>
<P>The jobs module manages print jobs, starts filter and backend
processes for jobs to be printed, and monitors status messages from
those filters and backends.</P>
<P>The jobs module manages print jobs, starts filter and backend
processes for jobs to be printed, and monitors status messages from
those filters and backends. </P>
<H3><A NAME="3_8_9">3.8.9 Logging</A></H3>
<P>The logging module manages the access, error, and page log files that
are generated by the scheduler.</P>
<P>The logging module manages the access, error, and page log files
that are generated by the scheduler. </P>
<H3><A NAME="3_8_10">3.8.10 Main</A></H3>
<P>The main module is responsible for timing out and dispatching input
and output for client connections. It also watches for incoming <CODE>
SIGHUP</CODE> and <CODE>SIGCHLD</CODE> signals, reloads the server
configuration files as needed, and handles child process errors and
exits.</P>
<P>The main module is responsible for timing out and dispatching input
and output for client connections. It also watches for incoming <CODE>
SIGHUP</CODE> and <CODE>SIGCHLD</CODE> signals, reloads the server
configuration files as needed, and handles child process errors and
exits. </P>
<H3><A NAME="3_8_11">3.8.11 MIME</A></H3>
<P>The Multimedia Internet Mail Exchange module manages a MIME type and
conversion database that supports file typing by extension and content
and least-cost file filtering from a source to a destination file type.</P>
<P>The Multimedia Internet Mail Exchange module manages a MIME type and
conversion database that supports file typing by extension and content
and least-cost file filtering from a source to a destination file type. </P>
<H3><A NAME="3_8_12">3.8.12 PPDs</A></H3>
<P>The PPDs module is responsible for managing the list of available PPD
files for the CUPS-Get-PPDs operation.</P>
<P>The PPDs module is responsible for managing the list of available
PPD files for the CUPS-Get-PPDs operation. </P>
<H3><A NAME="3_8_13">3.8.13 Printers</A></H3>
<P>The printers module is responsible for managing printers and PPD
files in the system. The printers module also reads and writes the
printers configuration file.</P>
<P>The printers module is responsible for managing printers and PPD
files in the system. The printers module also reads and writes the
printers configuration file. </P>
<H2><A NAME="3_9">3.9 System V Commands</A></H2>
<P>The System V commands provide a robust command-line interface to CUPS
to submit and control printers and jobs.</P>
<P>The System V commands provide a robust command-line interface to
CUPS to submit and control printers and jobs. </P>
<H3><A NAME="3_9_1">3.9.1 accept</A></H3>
<P>The accept command tells the scheduler to accept new jobs for
specific printers.</P>
<P>The accept command tells the scheduler to accept new jobs for
specific printers. </P>
<H3><A NAME="3_9_2">3.9.2 cancel</A></H3>
<P>The cancel command tells the scheduler to cancel one or more jobs
that are queued for printing.</P>
<P>The cancel command tells the scheduler to cancel one or more jobs
that are queued for printing. </P>
<H3><A NAME="3_9_3">3.9.3 disable</A></H3>
<P>The disable command tells the scheduler to stop printing jobs on the
specified printers.</P>
<P>The disable command tells the scheduler to stop printing jobs on the
specified printers. </P>
<H3><A NAME="3_9_4">3.9.4 enable</A></H3>
<P>The enable command tells the scheduler to start printing jobs on the
specified printers.</P>
<P>The enable command tells the scheduler to start printing jobs on the
specified printers. </P>
<H3><A NAME="3_9_5">3.9.5 lp</A></H3>
<P>The lp command submits submits files for printing. Unlike the
standard System V lp command, a single CUPS lp command will generate a
separate job ID for each file that is printed. Also, the Solaris &quot;f&quot;,
&quot;H&quot;, &quot;P&quot;, &quot;S&quot;, and &quot;y&quot; options are silently ignored.</P>
<P>The lp command submits submits files for printing. Unlike the
standard System V lp command, a single CUPS lp command will generate a
separate job ID for each file that is printed. Also, the Solaris &quot;f&quot;,
&quot;H&quot;, &quot;P&quot;, &quot;S&quot;, and &quot;y&quot; options are silently ignored. </P>
<H3><A NAME="3_9_6">3.9.6 lpadmin</A></H3>
<P>The lpadmin command manages printer queues and classes. The Solaris
&quot;A&quot;, &quot;F&quot;, &quot;I&quot;, &quot;M&quot;, &quot;P&quot;, &quot;Q&quot;, &quot;S&quot;, &quot;T&quot;, &quot;U&quot;, &quot;W&quot;, &quot;f&quot;, &quot;l&quot;, &quot;m&quot;, &quot;o&quot;,
&quot;s&quot;, &quot;t&quot;, and &quot;u&quot; options are not supported, and new options &quot;P&quot; (PPD
file) and &quot;E&quot; (enable and accept) are provided to configure
CUPS-specific features.</P>
<P>The lpadmin command manages printer queues and classes. The Solaris
&quot;A&quot;, &quot;F&quot;, &quot;I&quot;, &quot;M&quot;, &quot;P&quot;, &quot;Q&quot;, &quot;S&quot;, &quot;T&quot;, &quot;U&quot;, &quot;W&quot;, &quot;f&quot;, &quot;l&quot;, &quot;m&quot;, &quot;o&quot;,
&quot;s&quot;, &quot;t&quot;, and &quot;u&quot; options are not supported, and new options &quot;P&quot; (PPD
file) and &quot;E&quot; (enable and accept) are provided to configure
CUPS-specific features. </P>
<H3><A NAME="3_9_7">3.9.7 lpinfo</A></H3>
<P>The lpinfo command lists the available PPD files or devices as
selected by the user.</P>
<P>The lpinfo command lists the available PPD files or devices as
selected by the user. </P>
<H3><A NAME="3_9_8">3.9.8 lpmove</A></H3>
<P>The lpmove command moves a print job to a new destination.</P>
<P>The lpmove command moves a print job to a new destination. </P>
<H3><A NAME="3_9_9">3.9.9 lpoptions</A></H3>
<P>The lpoptions command manages user-defined printers and options.</P>
<P>The lpoptions command manages user-defined printers and options. </P>
<H3><A NAME="3_9_10">3.9.10 lpstat</A></H3>
<P>The lpstat command lists printers, classes, and jobs as requested by
the user.</P>
<P>The lpstat command lists printers, classes, and jobs as requested by
the user. </P>
<H3><A NAME="3_9_11">3.9.11 reject</A></H3>
<P>The reject command tells the scheduler not to accept new jobs for
specific printers.</P>
<P>The reject command tells the scheduler not to accept new jobs for
specific printers. </P>
<H1 TYPE="A" VALUE="1"><A NAME="4">A Glossary</A></H1>
<H2><A NAME="4_1">A.1 Terms</A></H2>
<DL>
<DT>C</DT>
<DD>A computer language.</DD>
<DT>parallel</DT>
<DD>Sending or receiving data more than 1 bit at a time.</DD>
<DT>pipe</DT>
<DD>A one-way communications channel between two programs.</DD>
<DT>serial</DT>
<DD>Sending or receiving data 1 bit at a time.</DD>
<DT>socket</DT>
<DD>A two-way network communications channel.</DD>
<DT>C </DT>
<DD>A computer language. </DD>
<DT>parallel </DT>
<DD>Sending or receiving data more than 1 bit at a time. </DD>
<DT>pipe </DT>
<DD>A one-way communications channel between two programs. </DD>
<DT>serial </DT>
<DD>Sending or receiving data 1 bit at a time. </DD>
<DT>socket </DT>
<DD>A two-way network communications channel. </DD>
</DL>
<H2><A NAME="4_2">A.2 Acronyms</A></H2>
<DL>
<DT>ASCII</DT>
<DD>American Standard Code for Information Interchange</DD>
<DT>CUPS</DT>
<DD>Common UNIX Printing System</DD>
<DT>ESC/P</DT>
<DD>EPSON Standard Code for Printers</DD>
<DT>FTP</DT>
<DD>File Transfer Protocol</DD>
<DT>HP-GL</DT>
<DD>Hewlett-Packard Graphics Language</DD>
<DT>HP-PCL</DT>
<DD>Hewlett-Packard Page Control Language</DD>
<DT>HP-PJL</DT>
<DD>Hewlett-Packard Printer Job Language</DD>
<DT>IETF</DT>
<DD>Internet Engineering Task Force</DD>
<DT>IPP</DT>
<DD>Internet Printing Protocol</DD>
<DT>ISO</DT>
<DD>International Standards Organization</DD>
<DT>LPD</DT>
<DD>Line Printer Daemon</DD>
<DT>MIME</DT>
<DD>Multimedia Internet Mail Exchange</DD>
<DT>PPD</DT>
<DD>PostScript Printer Description</DD>
<DT>SMB</DT>
<DD>Server Message Block</DD>
<DT>TFTP</DT>
<DD>Trivial File Transfer Protocol</DD>
<DT>ASCII </DT>
<DD>American Standard Code for Information Interchange </DD>
<DT>CUPS </DT>
<DD>Common UNIX Printing System </DD>
<DT>ESC/P </DT>
<DD>EPSON Standard Code for Printers </DD>
<DT>FTP </DT>
<DD>File Transfer Protocol </DD>
<DT>HP-GL </DT>
<DD>Hewlett-Packard Graphics Language </DD>
<DT>HP-PCL </DT>
<DD>Hewlett-Packard Page Control Language </DD>
<DT>HP-PJL </DT>
<DD>Hewlett-Packard Printer Job Language </DD>
<DT>IETF </DT>
<DD>Internet Engineering Task Force </DD>
<DT>IPP </DT>
<DD>Internet Printing Protocol </DD>
<DT>ISO </DT>
<DD>International Standards Organization </DD>
<DT>LPD </DT>
<DD>Line Printer Daemon </DD>
<DT>MIME </DT>
<DD>Multimedia Internet Mail Exchange </DD>
<DT>PPD </DT>
<DD>PostScript Printer Description </DD>
<DT>SMB </DT>
<DD>Server Message Block </DD>
<DT>TFTP </DT>
<DD>Trivial File Transfer Protocol </DD>
</DL>
</BODY>
</HTML>
BIN
Ver Arquivo
Arquivo binário não exibido.
+2482 -2456
Ver Arquivo
Diferenças do arquivo suprimidas por serem muito extensas Carregar Diff
BIN
Ver Arquivo
Arquivo binário não exibido.
+2 -2
Ver Arquivo
@@ -1,7 +1,7 @@
<HTML>
<HEAD>
<META NAME="COPYRIGHT" CONTENT="Copyright 1997-2001, All Rights Reserved">
<META NAME="DOCNUMBER" CONTENT="CUPS-SPM-1.1.9">
<META NAME="DOCNUMBER" CONTENT="CUPS-SPM-1.1.7">
<META NAME="Author" CONTENT="Easy Software Products">
<TITLE>CUPS Software Programmers Manual</TITLE>
</HEAD>
@@ -11,7 +11,7 @@
<P>This software programmers manual provides software
programming information for the Common UNIX Printing System
("CUPS") Version 1.1.9.
("CUPS") Version 1.1.7.
<EMBED SRC="system-overview.shtml">
+153 -153
Ver Arquivo
@@ -1,27 +1,27 @@
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" "http://www.w3.org/TR/REC-html40/loose.dtd">
<HTML>
<HEAD>
<TITLE>CUPS Software Performance Specification</TITLE>
<TITLE> CUPS Software Performance Specification</TITLE>
<META NAME="author" CONTENT="Easy Software Products">
<META NAME="copyright" CONTENT="Copyright 1997-2001, All Rights Reserved">
<META NAME="docnumber" CONTENT="CUPS-SPS-1.1">
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; CHARSET=iso-8859-1">
<STYLE TYPE="text/css"><!--
BODY { font-family: serif }
H1 { font-family: sans-serif }
H2 { font-family: sans-serif }
H3 { font-family: sans-serif }
H4 { font-family: sans-serif }
H5 { font-family: sans-serif }
H6 { font-family: sans-serif }
SUB { font-size: smaller }
SUP { font-size: smaller }
PRE { font-family: monospace }
BODY { font-family: serif; font-size: 11.0pt }
H1 { font-family: sans-serif; font-size: 20.0pt }
H2 { font-family: sans-serif; font-size: 17.0pt }
H3 { font-family: sans-serif; font-size: 14.0pt }
H4 { font-family: sans-serif; font-size: 11.0pt }
H5 { font-family: sans-serif; font-size: 9.0pt }
H6 { font-family: sans-serif; font-size: 8.0pt }
SUB { font-size: 8.0pt }
SUP { font-size: 8.0pt }
PRE { font-size: 9.0pt }
--></STYLE>
</HEAD>
<BODY>
<CENTER><A HREF="#CONTENTS"><IMG SRC="images/cups-large.gif" BORDER="0" WIDTH="431" HEIGHT="511"><BR>
<H1>CUPS Software Performance Specification</H1></A><BR>
<CENTER><A HREF="#CONTENTS"><IMG SRC="images/cups-large.gif" BORDER="0" WIDTH="100%"><BR>
<H1> CUPS Software Performance Specification</H1></A><BR>
CUPS-SPS-1.1<BR>
Easy Software Products<BR>
Copyright 1997-2001, All Rights Reserved<BR>
@@ -52,30 +52,30 @@ Copyright 1997-2001, All Rights Reserved<BR>
<HR>
<H1><A NAME="1">1 Scope</A></H1>
<H2><A NAME="1_1">1.1 Identification</A></H2>
<P>This software performance specification provides an analysis of the
memory, disk, and processor utilitization of each program in the Common
UNIX Printing System (&quot;CUPS&quot;) Version 1.1.</P>
<P>For the purposes of comparison, all figures are for the Linux Intel
platform. Memory utilization on other platforms should be similar.</P>
<P>This software performance specification provides an analysis of the
memory, disk, and processor utilitization of each program in the Common
UNIX Printing System (&quot;CUPS&quot;) Version 1.1.</P>
<P>For the purposes of comparison, all figures are for the Linux Intel
platform. Memory utilization on other platforms should be similar. </P>
<H2><A NAME="1_2">1.2 System Overview</A></H2>
<P>CUPS provides a portable printing layer for UNIX&reg;-based operating
systems. It has been developed by<A HREF="http://www.easysw.com"> Easy
Software Products</A> to promote a standard printing solution for all
UNIX vendors and users. CUPS provides the System V and Berkeley
command-line interfaces.</P>
<P>CUPS uses the Internet Printing Protocol (&quot;IPP&quot;) as the basis for
managing print jobs and queues. The Line Printer Daemon (&quot;LPD&quot;) Server
Message Block (&quot;SMB&quot;), and AppSocket (a.k.a. JetDirect) protocols are
also supported with reduced functionality. CUPS adds network printer
browsing and PostScript Printer Description (&quot;PPD&quot;) based printing
options to support real-world printing under UNIX.</P>
<P>CUPS also includes a customized version of GNU Ghostscript (currently
based off GNU Ghostscript 5.50) and an image file RIP that are used to
support non-PostScript printers. Sample drivers for HP and EPSON
printers are included that use these filters.</P>
<P>CUPS provides a portable printing layer for UNIX&reg;-based operating
systems. It has been developed by <A HREF="http://www.easysw.com">Easy
Software Products</A> to promote a standard printing solution for all
UNIX vendors and users. CUPS provides the System V and Berkeley
command-line interfaces. </P>
<P>CUPS uses the Internet Printing Protocol (&quot;IPP&quot;) as the basis for
managing print jobs and queues. The Line Printer Daemon (&quot;LPD&quot;) Server
Message Block (&quot;SMB&quot;), and AppSocket (a.k.a. JetDirect) protocols are
also supported with reduced functionality. CUPS adds network printer
browsing and PostScript Printer Description (&quot;PPD&quot;) based printing
options to support real-world printing under UNIX. </P>
<P>CUPS also includes a customized version of GNU Ghostscript
(currently based off GNU Ghostscript 5.50) and an image file RIP that
are used to support non-PostScript printers. Sample drivers for HP and
EPSON printers are included that use these filters. </P>
<H2><A NAME="1_3">1.3 Document Overview</A></H2>
<P>This software performance specification is organized into the
following sections:</P>
<P>This software performance specification is organized into the
following sections:</P>
<UL>
<LI>1 - Scope</LI>
<LI>2 - References</LI>
@@ -85,72 +85,72 @@ Copyright 1997-2001, All Rights Reserved<BR>
</UL>
<H1><A NAME="2">2 References</A></H1>
<H2><A NAME="2_1">2.1 CUPS Documentation</A></H2>
<P>The following CUPS documentation is referenced by this document:</P>
<P>The following CUPS documentation is referenced by this document: </P>
<UL>
<LI>CUPS-CMP-1.1: CUPS Configuration Management Plan</LI>
<LI>CUPS-IDD-1.1: CUPS System Interface Design Description</LI>
<LI>CUPS-IPP-1.1: CUPS Implementation of IPP</LI>
<LI>CUPS-SAM-1.1.x: CUPS Software Administrators Manual</LI>
<LI>CUPS-SDD-1.1: CUPS Software Design Description</LI>
<LI>CUPS-SPM-1.1.x: CUPS Software Programming Manual</LI>
<LI>CUPS-SSR-1.1: CUPS Software Security Report</LI>
<LI>CUPS-STP-1.1: CUPS Software Test Plan</LI>
<LI>CUPS-SUM-1.1.x: CUPS Software Users Manual</LI>
<LI>CUPS-SVD-1.1: CUPS Software Version Description</LI>
<LI>CUPS-CMP-1.1: CUPS Configuration Management Plan </LI>
<LI>CUPS-IDD-1.1: CUPS System Interface Design Description </LI>
<LI>CUPS-IPP-1.1: CUPS Implementation of IPP </LI>
<LI>CUPS-SAM-1.1.x: CUPS Software Administrators Manual </LI>
<LI>CUPS-SDD-1.1: CUPS Software Design Description </LI>
<LI>CUPS-SPM-1.1.x: CUPS Software Programming Manual </LI>
<LI>CUPS-SSR-1.1: CUPS Software Security Report </LI>
<LI>CUPS-STP-1.1: CUPS Software Test Plan </LI>
<LI>CUPS-SUM-1.1.x: CUPS Software Users Manual </LI>
<LI>CUPS-SVD-1.1: CUPS Software Version Description </LI>
</UL>
<H2><A NAME="2_2">2.2 Other Documents</A></H2>
<P>The following non-CUPS documents are referenced by this document:</P>
<P>The following non-CUPS documents are referenced by this document: </P>
<UL>
<LI><A HREF="http://partners.adobe.com/asn/developer/PDFS/TN/5003.PPD_Spec_v4.3.pdf">
Adobe PostScript Printer Description File Format Specification, Version
4.3.</A></LI>
Adobe PostScript Printer Description File Format Specification,
Version 4.3.</A></LI>
<LI><A HREF="http://partners.adobe.com/asn/developer/PDFS/TN/PLRM.pdf">
Adobe PostScript Language Reference, Third Edition.</A></LI>
<LI>IPP: Job and Printer Set Operations</LI>
<LI>IPP/1.1: Encoding and Transport</LI>
<LI>IPP/1.1: Implementers Guide</LI>
<LI>IPP/1.1: Model and Semantics</LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc1179.txt">RFC 1179, Line Printer
Daemon Protocol</A></LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc2567.txt">RFC 2567, Design Goals
for an Internet Printing Protocol</A></LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc2568.txt">RFC 2568, Rationale
for the Structure of the Model and Protocol</A> for the Internet
Printing Protocol</LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc2569.txt">RFC 2569, Mapping
between LPD and IPP Protocols</A></LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc2616.txt">RFC 2616, Hypertext
Transfer Protocol -- HTTP/1.1</A></LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc2617.txt">RFC 2617, HTTP
Authentication: Basic and Digest Access</A> Authentication</LI>
Adobe PostScript Language Reference, Third Edition.</A></LI>
<LI>IPP: Job and Printer Set Operations </LI>
<LI>IPP/1.1: Encoding and Transport </LI>
<LI>IPP/1.1: Implementers Guide </LI>
<LI>IPP/1.1: Model and Semantics </LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc1179.txt">RFC 1179, Line
Printer Daemon Protocol</A></LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc2567.txt">RFC 2567, Design
Goals for an Internet Printing Protocol</A></LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc2568.txt">RFC 2568, Rationale
for the Structure of the Model and Protocol</A> for the Internet
Printing Protocol</LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc2569.txt">RFC 2569, Mapping
between LPD and IPP Protocols</A></LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc2616.txt">RFC 2616, Hypertext
Transfer Protocol -- HTTP/1.1</A></LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc2617.txt">RFC 2617, HTTP
Authentication: Basic and Digest Access</A> Authentication </LI>
</UL>
<H1><A NAME="3">3 Programs</A></H1>
<P>The following table describes the average memory, disk, and CPU usage
of each program in CUPS.</P>
<P>The base memory column shows the initial memory requirements for each
program, including any shared libraries that are provided by CUPS.</P>
<P>The max memory column shows the maximum amount of memory that will be
used by the program based upon the default configuration settings
supplied with CUPS.</P>
<P>The temp files column indicates whether any temporary files are
created.</P>
<P>The CPU usage column specifies a relative CPU usage by the program
under normal conditions, either low, medium, or high. Low usage
indicates that the program will never use more than 33% of the
available CPU time. Medium usage indicates the program will use as much
as 66% of the available CPU time. High usage indicates the program uses
66% or more of the available CPU time.
<P>The following table describes the average memory, disk, and CPU
usage of each program in CUPS. </P>
<P>The base memory column shows the initial memory requirements for
each program, including any shared libraries that are provided by CUPS. </P>
<P>The max memory column shows the maximum amount of memory that will
be used by the program based upon the default configuration settings
supplied with CUPS. </P>
<P>The temp files column indicates whether any temporary files are
created. </P>
<P>The CPU usage column specifies a relative CPU usage by the program
under normal conditions, either low, medium, or high. Low usage
indicates that the program will never use more than 33% of the
available CPU time. Medium usage indicates the program will use as much
as 66% of the available CPU time. High usage indicates the program uses
66% or more of the available CPU time.
<CENTER>
<TABLE BORDER="1" WIDTH="80%">
<TR><TH COLSPAN="3">Backends</TH></TR>
<TR><TH>Program</TH><TH>Base Memory</TH><TH>Max Memory</TH><TH>Temp
Files</TH><TH>CPU Usage</TH></TR>
<TR><TH>Program</TH><TH>Base Memory</TH><TH>Max Memory</TH><TH>Temp
Files</TH><TH>CPU Usage</TH></TR>
<TR><TD>ipp</TD><TD>91k</TD><TD>256k</TD><TD>Up to size of print file</TD><TD>
Low</TD></TR>
<TR><TD>lpd</TD><TD>89k</TD><TD>89k</TD><TD>Up to size of print file</TD><TD>
Low</TD></TR>
<TR><TD>parallel</TD><TD>85k</TD><TD>85k</TD><TD>Up to size of print
file</TD><TD>Low</TD></TR>
<TR><TD>parallel</TD><TD>85k</TD><TD>85k</TD><TD>Up to size of print
file</TD><TD>Low</TD></TR>
<TR><TD>serial</TD><TD>85k</TD><TD>85k</TD><TD>Up to size of print file</TD><TD>
Low</TD></TR>
<TR><TD>socket</TD><TD>85k</TD><TD>85k</TD><TD>Up to size of print file</TD><TD>
@@ -158,10 +158,10 @@ Low</TD></TR>
<TR><TD>usb</TD><TD>85k</TD><TD>85k</TD><TD>Up to size of print file</TD><TD>
Low</TD></TR>
<TR><TH COLSPAN="3">CGIs</TH></TR>
<TR><TH>Program</TH><TH>Base Memory</TH><TH>Max Memory</TH><TH>Temp
Files</TH><TH>CPU Usage</TH></TR>
<TR><TD>admin.cgi</TD><TD>107k</TD><TD>256k</TD><TD>Up to size of PPD
file</TD><TD>Medium</TD></TR>
<TR><TH>Program</TH><TH>Base Memory</TH><TH>Max Memory</TH><TH>Temp
Files</TH><TH>CPU Usage</TH></TR>
<TR><TD>admin.cgi</TD><TD>107k</TD><TD>256k</TD><TD>Up to size of PPD
file</TD><TD>Medium</TD></TR>
<TR><TD>classes.cgi</TD><TD>95k</TD><TD>Size of class objects</TD><TD>
None</TD><TD>Medium</TD></TR>
<TR><TD>jobs.cgi</TD><TD>93k</TD><TD>Size of job objects</TD><TD>None</TD><TD>
@@ -169,8 +169,8 @@ Medium</TD></TR>
<TR><TD>printers.cgi</TD><TD>95k</TD><TD>Size of printer objects</TD><TD>
None</TD><TD>Medium</TD></TR>
<TR><TH COLSPAN="3">Command-Line Programs</TH></TR>
<TR><TH>Program</TH><TH>Base Memory</TH><TH>Max Memory</TH><TH>Temp
Files</TH><TH>CPU Usage</TH></TR>
<TR><TH>Program</TH><TH>Base Memory</TH><TH>Max Memory</TH><TH>Temp
Files</TH><TH>CPU Usage</TH></TR>
<TR><TD>accept</TD><TD>88k</TD><TD>128k</TD><TD>None</TD><TD>Low</TD></TR>
<TR><TD>cancel</TD><TD>88k</TD><TD>128k</TD><TD>None</TD><TD>Low</TD></TR>
<TR><TD>disable</TD><TD>88k</TD><TD>128k</TD><TD>None</TD><TD>Low</TD></TR>
@@ -188,31 +188,31 @@ None</TD><TD>Medium</TD></TR>
Medium</TD></TR>
<TR><TD>lpr</TD><TD>87k</TD><TD>256k</TD><TD>None</TD><TD>Low</TD></TR>
<TR><TD>lprm</TD><TD>84k</TD><TD>128k</TD><TD>None</TD><TD>Low</TD></TR>
<TR><TD>lpstat</TD><TD>119k</TD><TD>Size of job, printer, and class
objects</TD><TD>None</TD><TD>Medium</TD></TR>
<TR><TD>lpstat</TD><TD>119k</TD><TD>Size of job, printer, and class
objects</TD><TD>None</TD><TD>Medium</TD></TR>
<TR><TD>reject</TD><TD>88k</TD><TD>128k</TD><TD>None</TD><TD>Low</TD></TR>
<TR><TH COLSPAN="3">Daemons</TH></TR>
<TR><TH>Program</TH><TH>Base Memory</TH><TH>Max Memory</TH><TH>Temp
Files</TH><TH>CPU Usage</TH></TR>
<TR><TD>cups-lpd</TD><TD>92k</TD><TD>256k</TD><TD>One file per control
or data file from client</TD><TD>Low</TD></TR>
<TR><TH>Program</TH><TH>Base Memory</TH><TH>Max Memory</TH><TH>Temp
Files</TH><TH>CPU Usage</TH></TR>
<TR><TD>cups-lpd</TD><TD>92k</TD><TD>256k</TD><TD>One file per control
or data file from client</TD><TD>Low</TD></TR>
<TR><TD>cupsd</TD><TD>308k</TD><TD>See Scheduler Requirements</TD><TD>
See Scheduler Requirements</TD><TD>Medium</TD></TR>
<TR><TD>cups-polld</TD><TD>84k</TD><TD>Size of printer and class objects</TD><TD>
None</TD><TD>Low</TD></TR>
<TR><TH COLSPAN="3">Filters</TH></TR>
<TR><TH>Program</TH><TH>Base Memory</TH><TH>Max Memory</TH><TH>Temp
Files</TH><TH>CPU Usage</TH></TR>
<TR><TH>Program</TH><TH>Base Memory</TH><TH>Max Memory</TH><TH>Temp
Files</TH><TH>CPU Usage</TH></TR>
<TR><TD>hpgltops</TD><TD>263k</TD><TD>320k</TD><TD>None</TD><TD>Medium</TD>
</TR>
<TR><TD>imagetops</TD><TD>628k</TD><TD>10M</TD><TD>Swap file for
uncompressed image data</TD><TD>Medium</TD></TR>
<TR><TD>imagetoraster</TD><TD>652k</TD><TD>10M</TD><TD>Swap file for
uncompressed image data</TD><TD>High</TD></TR>
<TR><TD>pstops</TD><TD>775k</TD><TD>840k</TD><TD>Up to size of print
file</TD><TD>Medium</TD></TR>
<TR><TD>pstoraster</TD><TD>4M</TD><TD>14M</TD><TD>Swap file for command
lists</TD><TD>High</TD></TR>
<TR><TD>imagetops</TD><TD>628k</TD><TD>10M</TD><TD>Swap file for
uncompressed image data</TD><TD>Medium</TD></TR>
<TR><TD>imagetoraster</TD><TD>652k</TD><TD>10M</TD><TD>Swap file for
uncompressed image data</TD><TD>High</TD></TR>
<TR><TD>pstops</TD><TD>775k</TD><TD>840k</TD><TD>Up to size of print
file</TD><TD>Medium</TD></TR>
<TR><TD>pstoraster</TD><TD>4M</TD><TD>14M</TD><TD>Swap file for command
lists</TD><TD>High</TD></TR>
<TR><TD>rastertoepson</TD><TD>693k</TD><TD>1M</TD><TD>None</TD><TD>Low</TD>
</TR>
<TR><TD>rastertohp</TD><TD>690k</TD><TD>1M</TD><TD>None</TD><TD>Low</TD></TR>
@@ -222,11 +222,11 @@ Low</TD></TR>
</CENTER>
</P>
<H1><A NAME="4">4 Scheduler Objects</A></H1>
<P>The <CODE>cupsd</CODE> program is the CUPS scheduler process. It
manages many interdependent server objects that are used to manage and
print files to printers.</P>
<P>The following table provides the memory and disk cost associated with
each server object.
<P>The <CODE>cupsd</CODE> program is the CUPS scheduler process. It
manages many interdependent server objects that are used to manage and
print files to printers. </P>
<P>The following table provides the memory and disk cost associated
with each server object.
<CENTER>
<TABLE BORDER="1" WIDTH="80%">
<TR><TH>Object</TH><TH>Memory Per</TH><TH>Disk Per</TH></TR>
@@ -249,49 +249,49 @@ Low</TD></TR>
<H1 TYPE="A" VALUE="1"><A NAME="5">A Glossary</A></H1>
<H2><A NAME="5_1">A.1 Terms</A></H2>
<DL>
<DT>C</DT>
<DD>A computer language.</DD>
<DT>parallel</DT>
<DD>Sending or receiving data more than 1 bit at a time.</DD>
<DT>pipe</DT>
<DD>A one-way communications channel between two programs.</DD>
<DT>serial</DT>
<DD>Sending or receiving data 1 bit at a time.</DD>
<DT>socket</DT>
<DD>A two-way network communications channel.</DD>
<DT>C </DT>
<DD>A computer language. </DD>
<DT>parallel </DT>
<DD>Sending or receiving data more than 1 bit at a time. </DD>
<DT>pipe </DT>
<DD>A one-way communications channel between two programs. </DD>
<DT>serial </DT>
<DD>Sending or receiving data 1 bit at a time. </DD>
<DT>socket </DT>
<DD>A two-way network communications channel. </DD>
</DL>
<H2><A NAME="5_2">A.2 Acronyms</A></H2>
<DL>
<DT>ASCII</DT>
<DD>American Standard Code for Information Interchange</DD>
<DT>CUPS</DT>
<DD>Common UNIX Printing System</DD>
<DT>ESC/P</DT>
<DD>EPSON Standard Code for Printers</DD>
<DT>FTP</DT>
<DD>File Transfer Protocol</DD>
<DT>HP-GL</DT>
<DD>Hewlett-Packard Graphics Language</DD>
<DT>HP-PCL</DT>
<DD>Hewlett-Packard Page Control Language</DD>
<DT>HP-PJL</DT>
<DD>Hewlett-Packard Printer Job Language</DD>
<DT>IETF</DT>
<DD>Internet Engineering Task Force</DD>
<DT>IPP</DT>
<DD>Internet Printing Protocol</DD>
<DT>ISO</DT>
<DD>International Standards Organization</DD>
<DT>LPD</DT>
<DD>Line Printer Daemon</DD>
<DT>MIME</DT>
<DD>Multimedia Internet Mail Exchange</DD>
<DT>PPD</DT>
<DD>PostScript Printer Description</DD>
<DT>SMB</DT>
<DD>Server Message Block</DD>
<DT>TFTP</DT>
<DD>Trivial File Transfer Protocol</DD>
<DT>ASCII </DT>
<DD>American Standard Code for Information Interchange </DD>
<DT>CUPS </DT>
<DD>Common UNIX Printing System </DD>
<DT>ESC/P </DT>
<DD>EPSON Standard Code for Printers </DD>
<DT>FTP </DT>
<DD>File Transfer Protocol </DD>
<DT>HP-GL </DT>
<DD>Hewlett-Packard Graphics Language </DD>
<DT>HP-PCL </DT>
<DD>Hewlett-Packard Page Control Language </DD>
<DT>HP-PJL </DT>
<DD>Hewlett-Packard Printer Job Language </DD>
<DT>IETF </DT>
<DD>Internet Engineering Task Force </DD>
<DT>IPP </DT>
<DD>Internet Printing Protocol </DD>
<DT>ISO </DT>
<DD>International Standards Organization </DD>
<DT>LPD </DT>
<DD>Line Printer Daemon </DD>
<DT>MIME </DT>
<DD>Multimedia Internet Mail Exchange </DD>
<DT>PPD </DT>
<DD>PostScript Printer Description </DD>
<DT>SMB </DT>
<DD>Server Message Block </DD>
<DT>TFTP </DT>
<DD>Trivial File Transfer Protocol </DD>
</DL>
</BODY>
</HTML>
BIN
Ver Arquivo
Arquivo binário não exibido.
+186 -185
Ver Arquivo
@@ -1,27 +1,27 @@
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" "http://www.w3.org/TR/REC-html40/loose.dtd">
<HTML>
<HEAD>
<TITLE>CUPS Software Security Report</TITLE>
<TITLE> CUPS Software Security Report</TITLE>
<META NAME="author" CONTENT="Easy Software Products">
<META NAME="copyright" CONTENT="Copyright 1997-2001, All Rights Reserved">
<META NAME="docnumber" CONTENT="CUPS-SSR-1.1">
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; CHARSET=iso-8859-1">
<STYLE TYPE="text/css"><!--
BODY { font-family: serif }
H1 { font-family: sans-serif }
H2 { font-family: sans-serif }
H3 { font-family: sans-serif }
H4 { font-family: sans-serif }
H5 { font-family: sans-serif }
H6 { font-family: sans-serif }
SUB { font-size: smaller }
SUP { font-size: smaller }
PRE { font-family: monospace }
BODY { font-family: serif; font-size: 11.0pt }
H1 { font-family: sans-serif; font-size: 20.0pt }
H2 { font-family: sans-serif; font-size: 17.0pt }
H3 { font-family: sans-serif; font-size: 14.0pt }
H4 { font-family: sans-serif; font-size: 11.0pt }
H5 { font-family: sans-serif; font-size: 9.0pt }
H6 { font-family: sans-serif; font-size: 8.0pt }
SUB { font-size: 8.0pt }
SUP { font-size: 8.0pt }
PRE { font-size: 9.0pt }
--></STYLE>
</HEAD>
<BODY>
<CENTER><A HREF="#CONTENTS"><IMG SRC="images/cups-large.gif" BORDER="0" WIDTH="431" HEIGHT="511"><BR>
<H1>CUPS Software Security Report</H1></A><BR>
<CENTER><A HREF="#CONTENTS"><IMG SRC="images/cups-large.gif" BORDER="0" WIDTH="100%"><BR>
<H1> CUPS Software Security Report</H1></A><BR>
CUPS-SSR-1.1<BR>
Easy Software Products<BR>
Copyright 1997-2001, All Rights Reserved<BR>
@@ -57,28 +57,28 @@ Copyright 1997-2001, All Rights Reserved<BR>
<HR>
<H1><A NAME="1">1 Scope</A></H1>
<H2><A NAME="1_1">1.1 Identification</A></H2>
<P>This software security report provides an analysis of possible
security concerns for the Common UNIX Printing System (&quot;CUPS&quot;) Version
1.1.</P>
<P>This software security report provides an analysis of possible
security concerns for the Common UNIX Printing System (&quot;CUPS&quot;) Version
1.1.</P>
<H2><A NAME="1_2">1.2 System Overview</A></H2>
<P>CUPS provides a portable printing layer for UNIX&reg;-based operating
systems. It has been developed by<A HREF="http://www.easysw.com"> Easy
Software Products</A> to promote a standard printing solution for all
UNIX vendors and users. CUPS provides the System V and Berkeley
command-line interfaces.</P>
<P>CUPS uses the Internet Printing Protocol (&quot;IPP&quot;) as the basis for
managing print jobs and queues. The Line Printer Daemon (&quot;LPD&quot;) Server
Message Block (&quot;SMB&quot;), and AppSocket (a.k.a. JetDirect) protocols are
also supported with reduced functionality. CUPS adds network printer
browsing and PostScript Printer Description (&quot;PPD&quot;) based printing
options to support real-world printing under UNIX.</P>
<P>CUPS also includes a customized version of GNU Ghostscript (currently
based off GNU Ghostscript 5.50) and an image file RIP that are used to
support non-PostScript printers. Sample drivers for HP and EPSON
printers are included that use these filters.</P>
<P>CUPS provides a portable printing layer for UNIX&reg;-based operating
systems. It has been developed by <A HREF="http://www.easysw.com">Easy
Software Products</A> to promote a standard printing solution for all
UNIX vendors and users. CUPS provides the System V and Berkeley
command-line interfaces. </P>
<P>CUPS uses the Internet Printing Protocol (&quot;IPP&quot;) as the basis for
managing print jobs and queues. The Line Printer Daemon (&quot;LPD&quot;) Server
Message Block (&quot;SMB&quot;), and AppSocket (a.k.a. JetDirect) protocols are
also supported with reduced functionality. CUPS adds network printer
browsing and PostScript Printer Description (&quot;PPD&quot;) based printing
options to support real-world printing under UNIX. </P>
<P>CUPS also includes a customized version of GNU Ghostscript
(currently based off GNU Ghostscript 5.50) and an image file RIP that
are used to support non-PostScript printers. Sample drivers for HP and
EPSON printers are included that use these filters. </P>
<H2><A NAME="1_3">1.3 Document Overview</A></H2>
<P>This software security report is organized into the following
sections:</P>
<P>This software security report is organized into the following
sections:</P>
<UL>
<LI>1 - Scope</LI>
<LI>2 - References</LI>
@@ -88,182 +88,183 @@ Copyright 1997-2001, All Rights Reserved<BR>
</UL>
<H1><A NAME="2">2 References</A></H1>
<H2><A NAME="2_1">2.1 CUPS Documentation</A></H2>
<P>The following CUPS documentation is referenced by this document:</P>
<P>The following CUPS documentation is referenced by this document: </P>
<UL>
<LI>CUPS-CMP-1.1: CUPS Configuration Management Plan</LI>
<LI>CUPS-IDD-1.1: CUPS System Interface Design Description</LI>
<LI>CUPS-IPP-1.1: CUPS Implementation of IPP</LI>
<LI>CUPS-SAM-1.1.x: CUPS Software Administrators Manual</LI>
<LI>CUPS-SDD-1.1: CUPS Software Design Description</LI>
<LI>CUPS-SPM-1.1.x: CUPS Software Programming Manual</LI>
<LI>CUPS-SSR-1.1: CUPS Software Security Report</LI>
<LI>CUPS-STP-1.1: CUPS Software Test Plan</LI>
<LI>CUPS-SUM-1.1.x: CUPS Software Users Manual</LI>
<LI>CUPS-SVD-1.1: CUPS Software Version Description</LI>
<LI>CUPS-CMP-1.1: CUPS Configuration Management Plan </LI>
<LI>CUPS-IDD-1.1: CUPS System Interface Design Description </LI>
<LI>CUPS-IPP-1.1: CUPS Implementation of IPP </LI>
<LI>CUPS-SAM-1.1.x: CUPS Software Administrators Manual </LI>
<LI>CUPS-SDD-1.1: CUPS Software Design Description </LI>
<LI>CUPS-SPM-1.1.x: CUPS Software Programming Manual </LI>
<LI>CUPS-SSR-1.1: CUPS Software Security Report </LI>
<LI>CUPS-STP-1.1: CUPS Software Test Plan </LI>
<LI>CUPS-SUM-1.1.x: CUPS Software Users Manual </LI>
<LI>CUPS-SVD-1.1: CUPS Software Version Description </LI>
</UL>
<H2><A NAME="2_2">2.2 Other Documents</A></H2>
<P>The following non-CUPS documents are referenced by this document:</P>
<P>The following non-CUPS documents are referenced by this document: </P>
<UL>
<LI><A HREF="http://partners.adobe.com/asn/developer/PDFS/TN/5003.PPD_Spec_v4.3.pdf">
Adobe PostScript Printer Description File Format Specification, Version
4.3.</A></LI>
Adobe PostScript Printer Description File Format Specification,
Version 4.3.</A></LI>
<LI><A HREF="http://partners.adobe.com/asn/developer/PDFS/TN/PLRM.pdf">
Adobe PostScript Language Reference, Third Edition.</A></LI>
<LI>IPP: Job and Printer Set Operations</LI>
<LI>IPP/1.1: Encoding and Transport</LI>
<LI>IPP/1.1: Implementers Guide</LI>
<LI>IPP/1.1: Model and Semantics</LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc1179.txt">RFC 1179, Line Printer
Daemon Protocol</A></LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc2567.txt">RFC 2567, Design Goals
for an Internet Printing Protocol</A></LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc2568.txt">RFC 2568, Rationale
for the Structure of the Model and Protocol</A> for the Internet
Printing Protocol</LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc2569.txt">RFC 2569, Mapping
between LPD and IPP Protocols</A></LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc2616.txt">RFC 2616, Hypertext
Transfer Protocol -- HTTP/1.1</A></LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc2617.txt">RFC 2617, HTTP
Authentication: Basic and Digest Access</A> Authentication</LI>
Adobe PostScript Language Reference, Third Edition.</A></LI>
<LI>IPP: Job and Printer Set Operations </LI>
<LI>IPP/1.1: Encoding and Transport </LI>
<LI>IPP/1.1: Implementers Guide </LI>
<LI>IPP/1.1: Model and Semantics </LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc1179.txt">RFC 1179, Line
Printer Daemon Protocol</A></LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc2567.txt">RFC 2567, Design
Goals for an Internet Printing Protocol</A></LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc2568.txt">RFC 2568, Rationale
for the Structure of the Model and Protocol</A> for the Internet
Printing Protocol</LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc2569.txt">RFC 2569, Mapping
between LPD and IPP Protocols</A></LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc2616.txt">RFC 2616, Hypertext
Transfer Protocol -- HTTP/1.1</A></LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc2617.txt">RFC 2617, HTTP
Authentication: Basic and Digest Access</A> Authentication </LI>
</UL>
<H1><A NAME="3">3 Local Access Risks</A></H1>
<P>Local access risks are those that can be exploited only with a local
user account. This section does not address issues related to
dissemination of the root password or other security issues associated
with the UNIX operating system.</P>
<P>Local access risks are those that can be exploited only with a local
user account. This section does not address issues related to
dissemination of the root password or other security issues associated
with the UNIX operating system. </P>
<H2><A NAME="3_1">3.1 Security Breaches</A></H2>
<P>There is one known security vulnerability with local access:</P>
<P>There is one known security vulnerability with local access: </P>
<OL>
<LI>Device URIs are passed to backend filters in argv[0] and in an
environment variable. Since device URIs can contain usernames and
passwords it may be possible for a local user to gain access to a
remote resource.</LI>
<P>We recommend that any password-protected accounts used for remote
printing have limited access priviledges so that the possible damages
can be minimized.</P>
<P>The device URI is &quot;sanitized&quot; (the username and password are removed)
when sent to an IPP client so that a remote user cannot exploit this
vulnerability.</P>
<LI>Device URIs are passed to backend filters in argv[0] and in an
environment variable. Since device URIs can contain usernames and
passwords it may be possible for a local user to gain access to a
remote resource. </LI>
<P>We recommend that any password-protected accounts used for remote
printing have limited access priviledges so that the possible damages
can be minimized. </P>
<P>The device URI is &quot;sanitized&quot; (the username and password are
removed) when sent to an IPP client so that a remote user cannot
exploit this vulnerability. </P>
</OL>
<H1><A NAME="4">4 Remote Access Risks</A></H1>
<P>Remote access risks are those that can be exploited without a local
user account and/or from a remote system. This section does not address
issues related to network or firewall security.</P>
<P>Remote access risks are those that can be exploited without a local
user account and/or from a remote system. This section does not address
issues related to network or firewall security. </P>
<H2><A NAME="4_1">4.1 Denial of Service Attacks</A></H2>
<P>Like all Internet services, the CUPS server is vulnerable to denial
of service attacks, including:</P>
<P>Like all Internet services, the CUPS server is vulnerable to denial
of service attacks, including: </P>
<OL>
<LI>Establishing multiple connections to the server until the server
will accept no more.</LI>
<P>This cannot be protected against by the current software. It is
possible that future versions of the CUPS software could be configured
to limit the number of connections allowed from a single host, however
that still would not prevent a distributed attack.</P>
<LI>Repeatedly opening and closing connections to the server as fast as
possible.</LI>
<P>There is no easy way of protecting against this in the CUPS software.
If the attack is coming from outside the local network it might be
possible to filter such an attack, however once the connection request
has been received by the server it must at least accept the connection
to find out who is connecting.</P>
<LI>Flooding the network with broadcast packets on port 631.</LI>
<P>It might be possible to disable browsing if this condition is
detected by the CUPS software, however if there are large numbers of
printers available on the network such an algorithm might think that an
attack was occurring when instead a valid update was being received.</P>
<LI>Sending partial IPP requests; specifically, sending part of an
attribute value and then stopping transmission.</LI>
<P>The current code is structured to read and write the IPP request data
on-the-fly, so there is no easy way to protect against this for large
attribute values.</P>
<LI>Sending large/long print jobs to printers, preventing other users
from printing.</LI>
<P>There are limited facilities for protecting against large print jobs
(the <CODE>MaxRequestSize</CODE> attribute), however this will not
protect printers from malicious users and print files that generate
hundreds or thousands of pages. In general, we recommend restricting
printer access to known hosts or networks, and adding user-level access
control as needed for expensive printers.</P>
<LI>Establishing multiple connections to the server until the server
will accept no more. </LI>
<P>This cannot be protected against by the current software. It is
possible that future versions of the CUPS software could be configured
to limit the number of connections allowed from a single host, however
that still would not prevent a distributed attack. </P>
<LI>Repeatedly opening and closing connections to the server as fast
as possible. </LI>
<P>There is no easy way of protecting against this in the CUPS
software. If the attack is coming from outside the local network it
might be possible to filter such an attack, however once the
connection request has been received by the server it must at least
accept the connection to find out who is connecting. </P>
<LI>Flooding the network with broadcast packets on port 631. </LI>
<P>It might be possible to disable browsing if this condition is
detected by the CUPS software, however if there are large numbers of
printers available on the network such an algorithm might think that
an attack was occurring when instead a valid update was being
received. </P>
<LI>Sending partial IPP requests; specifically, sending part of an
attribute value and then stopping transmission. </LI>
<P>The current code is structured to read and write the IPP request
data on-the-fly, so there is no easy way to protect against this for
large attribute values. </P>
<LI>Sending large/long print jobs to printers, preventing other users
from printing. </LI>
<P>There are limited facilities for protecting against large print
jobs (the <CODE>MaxRequestSize</CODE> attribute), however this will
not protect printers from malicious users and print files that
generate hundreds or thousands of pages. In general, we recommend
restricting printer access to known hosts or networks, and adding
user-level access control as needed for expensive printers. </P>
</OL>
<H2><A NAME="4_2">4.2 Security Breaches</A></H2>
<P>The current CUPS server supports Basic, Digest, and local certificate
authentication:</P>
<P>The current CUPS server supports Basic, Digest, and local
certificate authentication: </P>
<OL>
<LI>Basic authentication essentially places the clear text of the
username and password on the network. Since CUPS uses the UNIX username
and password account information, the authentication information could
be used to gain access to accounts (possibly priviledged accounts) on
the server.</LI>
<LI>Digest authentication uses an MD5 checksum of the username,
password, and domain (&quot;CUPS&quot;), so the original username and password is
not sent over the network. However, the current implementation does not
authenticate the entire message and uses the client's IP address for
the nonce value, making it possible to launch &quot;man in the middle&quot; and
replay attacks from the same client. The next minor release of CUPS
will support Digest authentication of the entire message body,
effectively stopping these methods of attack.</LI>
<LI>Local certificate authentication passes 128-bit &quot;certificates&quot; that
identify an authenticated user. Certificates are created on-the-fly
from random data and stored in files under <CODE>/etc/cups/certs</CODE>
. They have restricted read permissions: root + system for the root
certificate, and lp + system for CGI certificates. Because certificates
are only available on the local system, the CUPS server does not accept
local authentication unless the client is connected to the localhost
address (127.0.0.1.)</LI>
<LI>Basic authentication essentially places the clear text of the
username and password on the network. Since CUPS uses the UNIX
username and password account information, the authentication
information could be used to gain access to accounts (possibly
priviledged accounts) on the server. </LI>
<LI>Digest authentication uses an MD5 checksum of the username,
password, and domain (&quot;CUPS&quot;), so the original username and password
is not sent over the network. However, the current implementation does
not authenticate the entire message and uses the client's IP address
for the nonce value, making it possible to launch &quot;man in the middle&quot;
and replay attacks from the same client. The next minor release of
CUPS will support Digest authentication of the entire message body,
effectively stopping these methods of attack. </LI>
<LI>Local certificate authentication passes 128-bit &quot;certificates&quot;
that identify an authenticated user. Certificates are created
on-the-fly from random data and stored in files under <CODE>
/etc/cups/certs</CODE>. They have restricted read permissions: root +
system for the root certificate, and lp + system for CGI certificates.
Because certificates are only available on the local system, the CUPS
server does not accept local authentication unless the client is
connected to the localhost address (127.0.0.1.) </LI>
</OL>
<P>The default CUPS configuration disables remote administration. We do
not recommend that remote administration be enabled for all hosts.
However, if you have a trusted network or subnet, access can be
restricted accordingly. Also, we highly recommend using Digest
authentication when possible. Unfortunately, most web browsers do not
support Digest authentication at this time.</P>
<P>The default CUPS configuration disables remote administration. We do
not recommend that remote administration be enabled for all hosts.
However, if you have a trusted network or subnet, access can be
restricted accordingly. Also, we highly recommend using Digest
authentication when possible. Unfortunately, most web browsers do not
support Digest authentication at this time. </P>
<H1 TYPE="A" VALUE="1"><A NAME="5">A Glossary</A></H1>
<H2><A NAME="5_1">A.1 Terms</A></H2>
<DL>
<DT>C</DT>
<DD>A computer language.</DD>
<DT>parallel</DT>
<DD>Sending or receiving data more than 1 bit at a time.</DD>
<DT>pipe</DT>
<DD>A one-way communications channel between two programs.</DD>
<DT>serial</DT>
<DD>Sending or receiving data 1 bit at a time.</DD>
<DT>socket</DT>
<DD>A two-way network communications channel.</DD>
<DT>C </DT>
<DD>A computer language. </DD>
<DT>parallel </DT>
<DD>Sending or receiving data more than 1 bit at a time. </DD>
<DT>pipe </DT>
<DD>A one-way communications channel between two programs. </DD>
<DT>serial </DT>
<DD>Sending or receiving data 1 bit at a time. </DD>
<DT>socket </DT>
<DD>A two-way network communications channel. </DD>
</DL>
<H2><A NAME="5_2">A.2 Acronyms</A></H2>
<DL>
<DT>ASCII</DT>
<DD>American Standard Code for Information Interchange</DD>
<DT>CUPS</DT>
<DD>Common UNIX Printing System</DD>
<DT>ESC/P</DT>
<DD>EPSON Standard Code for Printers</DD>
<DT>FTP</DT>
<DD>File Transfer Protocol</DD>
<DT>HP-GL</DT>
<DD>Hewlett-Packard Graphics Language</DD>
<DT>HP-PCL</DT>
<DD>Hewlett-Packard Page Control Language</DD>
<DT>HP-PJL</DT>
<DD>Hewlett-Packard Printer Job Language</DD>
<DT>IETF</DT>
<DD>Internet Engineering Task Force</DD>
<DT>IPP</DT>
<DD>Internet Printing Protocol</DD>
<DT>ISO</DT>
<DD>International Standards Organization</DD>
<DT>LPD</DT>
<DD>Line Printer Daemon</DD>
<DT>MIME</DT>
<DD>Multimedia Internet Mail Exchange</DD>
<DT>PPD</DT>
<DD>PostScript Printer Description</DD>
<DT>SMB</DT>
<DD>Server Message Block</DD>
<DT>TFTP</DT>
<DD>Trivial File Transfer Protocol</DD>
<DT>ASCII </DT>
<DD>American Standard Code for Information Interchange </DD>
<DT>CUPS </DT>
<DD>Common UNIX Printing System </DD>
<DT>ESC/P </DT>
<DD>EPSON Standard Code for Printers </DD>
<DT>FTP </DT>
<DD>File Transfer Protocol </DD>
<DT>HP-GL </DT>
<DD>Hewlett-Packard Graphics Language </DD>
<DT>HP-PCL </DT>
<DD>Hewlett-Packard Page Control Language </DD>
<DT>HP-PJL </DT>
<DD>Hewlett-Packard Printer Job Language </DD>
<DT>IETF </DT>
<DD>Internet Engineering Task Force </DD>
<DT>IPP </DT>
<DD>Internet Printing Protocol </DD>
<DT>ISO </DT>
<DD>International Standards Organization </DD>
<DT>LPD </DT>
<DD>Line Printer Daemon </DD>
<DT>MIME </DT>
<DD>Multimedia Internet Mail Exchange </DD>
<DT>PPD </DT>
<DD>PostScript Printer Description </DD>
<DT>SMB </DT>
<DD>Server Message Block </DD>
<DT>TFTP </DT>
<DD>Trivial File Transfer Protocol </DD>
</DL>
</BODY>
</HTML>
BIN
Ver Arquivo
Arquivo binário não exibido.
+148 -148
Ver Arquivo
@@ -1,27 +1,27 @@
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" "http://www.w3.org/TR/REC-html40/loose.dtd">
<HTML>
<HEAD>
<TITLE>CUPS Software Test Plan</TITLE>
<TITLE> CUPS Software Test Plan</TITLE>
<META NAME="author" CONTENT="Easy Software Products">
<META NAME="copyright" CONTENT="Copyright 1997-2001, All Rights Reserved">
<META NAME="docnumber" CONTENT="CUPS-STP-1.1">
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; CHARSET=iso-8859-1">
<STYLE TYPE="text/css"><!--
BODY { font-family: serif }
H1 { font-family: sans-serif }
H2 { font-family: sans-serif }
H3 { font-family: sans-serif }
H4 { font-family: sans-serif }
H5 { font-family: sans-serif }
H6 { font-family: sans-serif }
SUB { font-size: smaller }
SUP { font-size: smaller }
PRE { font-family: monospace }
BODY { font-family: serif; font-size: 11.0pt }
H1 { font-family: sans-serif; font-size: 20.0pt }
H2 { font-family: sans-serif; font-size: 17.0pt }
H3 { font-family: sans-serif; font-size: 14.0pt }
H4 { font-family: sans-serif; font-size: 11.0pt }
H5 { font-family: sans-serif; font-size: 9.0pt }
H6 { font-family: sans-serif; font-size: 8.0pt }
SUB { font-size: 8.0pt }
SUP { font-size: 8.0pt }
PRE { font-size: 9.0pt }
--></STYLE>
</HEAD>
<BODY>
<CENTER><A HREF="#CONTENTS"><IMG SRC="images/cups-large.gif" BORDER="0" WIDTH="431" HEIGHT="511"><BR>
<H1>CUPS Software Test Plan</H1></A><BR>
<CENTER><A HREF="#CONTENTS"><IMG SRC="images/cups-large.gif" BORDER="0" WIDTH="100%"><BR>
<H1> CUPS Software Test Plan</H1></A><BR>
CUPS-STP-1.1<BR>
Easy Software Products<BR>
Copyright 1997-2001, All Rights Reserved<BR>
@@ -68,27 +68,27 @@ Copyright 1997-2001, All Rights Reserved<BR>
<HR>
<H1><A NAME="1">1 Scope</A></H1>
<H2><A NAME="1_1">1.1 Identification</A></H2>
<P>This software test plan provides detailed tests that are used to
evaluate the stability and compliance of the Common UNIX Printing
System (&quot;CUPS&quot;) Version 1.1.</P>
<P>This software test plan provides detailed tests that are used to
evaluate the stability and compliance of the Common UNIX Printing
System (&quot;CUPS&quot;) Version 1.1. </P>
<H2><A NAME="1_2">1.2 System Overview</A></H2>
<P>CUPS provides a portable printing layer for UNIX&reg;-based operating
systems. It has been developed by<A HREF="http://www.easysw.com"> Easy
Software Products</A> to promote a standard printing solution for all
UNIX vendors and users. CUPS provides the System V and Berkeley
command-line interfaces.</P>
<P>CUPS uses the Internet Printing Protocol (&quot;IPP&quot;) as the basis for
managing print jobs and queues. The Line Printer Daemon (&quot;LPD&quot;) Server
Message Block (&quot;SMB&quot;), and AppSocket (a.k.a. JetDirect) protocols are
also supported with reduced functionality. CUPS adds network printer
browsing and PostScript Printer Description (&quot;PPD&quot;) based printing
options to support real-world printing under UNIX.</P>
<P>CUPS also includes a customized version of GNU Ghostscript (currently
based off GNU Ghostscript 5.50) and an image file RIP that are used to
support non-PostScript printers. Sample drivers for HP and EPSON
printers are included that use these filters.</P>
<P>CUPS provides a portable printing layer for UNIX&reg;-based operating
systems. It has been developed by <A HREF="http://www.easysw.com">Easy
Software Products</A> to promote a standard printing solution for all
UNIX vendors and users. CUPS provides the System V and Berkeley
command-line interfaces. </P>
<P>CUPS uses the Internet Printing Protocol (&quot;IPP&quot;) as the basis for
managing print jobs and queues. The Line Printer Daemon (&quot;LPD&quot;) Server
Message Block (&quot;SMB&quot;), and AppSocket (a.k.a. JetDirect) protocols are
also supported with reduced functionality. CUPS adds network printer
browsing and PostScript Printer Description (&quot;PPD&quot;) based printing
options to support real-world printing under UNIX. </P>
<P>CUPS also includes a customized version of GNU Ghostscript
(currently based off GNU Ghostscript 5.50) and an image file RIP that
are used to support non-PostScript printers. Sample drivers for HP and
EPSON printers are included that use these filters. </P>
<H2><A NAME="1_3">1.3 Document Overview</A></H2>
<P>This software test plan is organized into the following sections:</P>
<P>This software test plan is organized into the following sections: </P>
<UL>
<LI>1 - Scope</LI>
<LI>2 - References</LI>
@@ -99,164 +99,164 @@ Copyright 1997-2001, All Rights Reserved<BR>
</UL>
<H1><A NAME="2">2 References</A></H1>
<H2><A NAME="2_1">2.1 CUPS Documentation</A></H2>
<P>The following CUPS documentation is referenced by this document:</P>
<P>The following CUPS documentation is referenced by this document: </P>
<UL>
<LI>CUPS-CMP-1.1: CUPS Configuration Management Plan</LI>
<LI>CUPS-IDD-1.1: CUPS System Interface Design Description</LI>
<LI>CUPS-IPP-1.1: CUPS Implementation of IPP</LI>
<LI>CUPS-SAM-1.1.x: CUPS Software Administrators Manual</LI>
<LI>CUPS-SDD-1.1: CUPS Software Design Description</LI>
<LI>CUPS-SPM-1.1.x: CUPS Software Programming Manual</LI>
<LI>CUPS-SSR-1.1: CUPS Software Security Report</LI>
<LI>CUPS-STP-1.1: CUPS Software Test Plan</LI>
<LI>CUPS-SUM-1.1.x: CUPS Software Users Manual</LI>
<LI>CUPS-SVD-1.1: CUPS Software Version Description</LI>
<LI>CUPS-CMP-1.1: CUPS Configuration Management Plan </LI>
<LI>CUPS-IDD-1.1: CUPS System Interface Design Description </LI>
<LI>CUPS-IPP-1.1: CUPS Implementation of IPP </LI>
<LI>CUPS-SAM-1.1.x: CUPS Software Administrators Manual </LI>
<LI>CUPS-SDD-1.1: CUPS Software Design Description </LI>
<LI>CUPS-SPM-1.1.x: CUPS Software Programming Manual </LI>
<LI>CUPS-SSR-1.1: CUPS Software Security Report </LI>
<LI>CUPS-STP-1.1: CUPS Software Test Plan </LI>
<LI>CUPS-SUM-1.1.x: CUPS Software Users Manual </LI>
<LI>CUPS-SVD-1.1: CUPS Software Version Description </LI>
</UL>
<H2><A NAME="2_2">2.2 Other Documents</A></H2>
<P>The following non-CUPS documents are referenced by this document:</P>
<P>The following non-CUPS documents are referenced by this document: </P>
<UL>
<LI><A HREF="http://partners.adobe.com/asn/developer/PDFS/TN/5003.PPD_Spec_v4.3.pdf">
Adobe PostScript Printer Description File Format Specification, Version
4.3.</A></LI>
Adobe PostScript Printer Description File Format Specification,
Version 4.3.</A></LI>
<LI><A HREF="http://partners.adobe.com/asn/developer/PDFS/TN/PLRM.pdf">
Adobe PostScript Language Reference, Third Edition.</A></LI>
<LI>IPP: Job and Printer Set Operations</LI>
<LI>IPP/1.1: Encoding and Transport</LI>
<LI>IPP/1.1: Implementers Guide</LI>
<LI>IPP/1.1: Model and Semantics</LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc1179.txt">RFC 1179, Line Printer
Daemon Protocol</A></LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc2567.txt">RFC 2567, Design Goals
for an Internet Printing Protocol</A></LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc2568.txt">RFC 2568, Rationale
for the Structure of the Model and Protocol</A> for the Internet
Printing Protocol</LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc2569.txt">RFC 2569, Mapping
between LPD and IPP Protocols</A></LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc2616.txt">RFC 2616, Hypertext
Transfer Protocol -- HTTP/1.1</A></LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc2617.txt">RFC 2617, HTTP
Authentication: Basic and Digest Access</A> Authentication</LI>
Adobe PostScript Language Reference, Third Edition.</A></LI>
<LI>IPP: Job and Printer Set Operations </LI>
<LI>IPP/1.1: Encoding and Transport </LI>
<LI>IPP/1.1: Implementers Guide </LI>
<LI>IPP/1.1: Model and Semantics </LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc1179.txt">RFC 1179, Line
Printer Daemon Protocol</A></LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc2567.txt">RFC 2567, Design
Goals for an Internet Printing Protocol</A></LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc2568.txt">RFC 2568, Rationale
for the Structure of the Model and Protocol</A> for the Internet
Printing Protocol</LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc2569.txt">RFC 2569, Mapping
between LPD and IPP Protocols</A></LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc2616.txt">RFC 2616, Hypertext
Transfer Protocol -- HTTP/1.1</A></LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc2617.txt">RFC 2617, HTTP
Authentication: Basic and Digest Access</A> Authentication </LI>
</UL>
<H1><A NAME="3">3 Test Procedure</A></H1>
<P>The test software and data files are located in the<VAR> test</VAR>
subdirectory of the source distribution. A script is provided to
compile the <CODE>ipptest</CODE> program and run all of the tests that
follow, producing a success/fail report.</P>
<P>The <CODE>test</CODE> target of the top-level makefile can be used to
run this script:</P>
<P>The test software and data files are located in the <VAR>test</VAR>
subdirectory of the source distribution. A script is provided to
compile the <CODE>ipptest</CODE> program and run all of the tests that
follow, producing a success/fail report. </P>
<P>The <CODE>test</CODE> target of the top-level makefile can be used
to run this script: </P>
<UL>
<PRE>
make test
</PRE>
</UL>
<P>or you can run the test script directly:</P>
<P>or you can run the test script directly: </P>
<UL>
<PRE>
cd test
./run-stp-tests
</PRE>
</UL>
<P>A Software Test Report is stored in HTML and PDF files that are
generated using the<A HREF="http://www.easysw.com/htmldoc"> HTMLDOC</A>
software.</P>
<P>A Software Test Report is stored in HTML and PDF files that are
generated using the <A HREF="http://www.easysw.com/htmldoc">HTMLDOC</A>
software. </P>
<H1><A NAME="4">4 IPP Compliance Tests</A></H1>
<P>This section describes the tests used to validate the IPP standards
compliance of the CUPS server.</P>
<P>This section describes the tests used to validate the IPP standards
compliance of the CUPS server. </P>
<H2><A NAME="4_1">4.1 Request Tests</A></H2>
<P>These tests verify that the CUPS scheduler only accepts valid IPP
requests that start with the <CODE>attributes-charset</CODE> and <CODE>
<P>These tests verify that the CUPS scheduler only accepts valid IPP
requests that start with the <CODE>attributes-charset</CODE> and <CODE>
attributes-natural-language</CODE> attributes and also contain a <CODE>
printer-uri</CODE> or <CODE>job-uri</CODE> attribute.</P>
printer-uri</CODE> or <CODE>job-uri</CODE> attribute. </P>
<P>It also verifies that the CUPS scheduler always responds with <CODE>
attributes-charset</CODE> and <CODE>attributes-natural-language</CODE>
attributes, using default values if they are not provided by the
client.</P>
attributes, using default values if they are not provided by the
client. </P>
<H2><A NAME="4_2">4.2 CUPS Printer Operation Tests</A></H2>
<P>These tests verify that the CUPS printer operations are supported and
function properly. Two printers called <CODE>Test1</CODE> and <CODE>
Test2</CODE> are created, one as a PostScript printer and one as a
raster printer.</P>
<P>These tests verify that the CUPS printer operations are supported
and function properly. Two printers called <CODE>Test1</CODE> and <CODE>
Test2</CODE> are created, one as a PostScript printer and one as a
raster printer. </P>
<H2><A NAME="4_3">4.3 Job Operation Tests</A></H2>
<P>These test verify that the CUPS scheduler accepts print jobs for all
supported file formats and that the <CODE>cancel-job</CODE>, <CODE>
hold-job</CODE>, and <CODE>resume-job</CODE> operations work.</P>
<P>These test verify that the CUPS scheduler accepts print jobs for all
supported file formats and that the <CODE>cancel-job</CODE>, <CODE>
hold-job</CODE>, and <CODE>resume-job</CODE> operations work. </P>
<H1><A NAME="5">5 Command Tests</A></H1>
<P>This section describes the tests used to validate the Berkeley and
System V commands included with CUPS.</P>
<P>This section describes the tests used to validate the Berkeley and
System V commands included with CUPS. </P>
<H2><A NAME="5_1">5.1 lpadmin</A></H2>
<P>This test verifies that printers can be added, modified, and
defaulted using the <CODE>lpadmin</CODE> command.</P>
<P>This test verifies that printers can be added, modified, and
defaulted using the <CODE>lpadmin</CODE> command. </P>
<H2><A NAME="5_2">5.2 lpc</A></H2>
<P>This test verifies that the <CODE>lpc</CODE> command can show the
current status of all print queues.</P>
<P>This test verifies that the <CODE>lpc</CODE> command can show the
current status of all print queues. </P>
<H2><A NAME="5_3">5.3 lpq</A></H2>
<P>This test verifies that the <CODE>lpq</CODE> command lists any jobs
in the queue.</P>
<P>This test verifies that the <CODE>lpq</CODE> command lists any jobs
in the queue. </P>
<H2><A NAME="5_4">5.4 lpstat</A></H2>
<P>This test verifies that the <CODE>lpstat</CODE> command works with
all reports using the &quot;<CODE>-t</CODE>&quot; option.</P>
<P>This test verifies that the <CODE>lpstat</CODE> command works with
all reports using the &quot;<CODE>-t</CODE>&quot; option. </P>
<H2><A NAME="5_5">5.5 lp</A></H2>
<P>This test verifies that the <CODE>lp</CODE> command works with both
the default destination and a specific destination.</P>
<P>This test verifies that the <CODE>lp</CODE> command works with both
the default destination and a specific destination. </P>
<H2><A NAME="5_6">5.6 lpr</A></H2>
<P>This test verifies that the <CODE>lpr</CODE> command works with both
the default destination and a specific destination.</P>
<P>This test verifies that the <CODE>lpr</CODE> command works with both
the default destination and a specific destination. </P>
<H2><A NAME="5_7">5.7 lprm</A></H2>
<P>This test verifies that the <CODE>lprm</CODE> command can properly
cancel a job.</P>
<P>This test verifies that the <CODE>lprm</CODE> command can properly
cancel a job. </P>
<H2><A NAME="5_8">5.8 cancel</A></H2>
<P>This test verifies that the <CODE>cancel</CODE> command can properly
cancel a job or all jobs.</P>
<P>This test verifies that the <CODE>cancel</CODE> command can properly
cancel a job or all jobs. </P>
<H2><A NAME="5_9">5.9 lpinfo</A></H2>
<P>This test verifies that the <CODE>lpinfo</CODE> command returns a
list of available printer drivers and devices.</P>
<P>This test verifies that the <CODE>lpinfo</CODE> command returns a
list of available printer drivers and devices. </P>
<H1 TYPE="A" VALUE="1"><A NAME="6">A Glossary</A></H1>
<H2><A NAME="6_1">A.1 Terms</A></H2>
<DL>
<DT>C</DT>
<DD>A computer language.</DD>
<DT>parallel</DT>
<DD>Sending or receiving data more than 1 bit at a time.</DD>
<DT>pipe</DT>
<DD>A one-way communications channel between two programs.</DD>
<DT>serial</DT>
<DD>Sending or receiving data 1 bit at a time.</DD>
<DT>socket</DT>
<DD>A two-way network communications channel.</DD>
<DT>C </DT>
<DD>A computer language. </DD>
<DT>parallel </DT>
<DD>Sending or receiving data more than 1 bit at a time. </DD>
<DT>pipe </DT>
<DD>A one-way communications channel between two programs. </DD>
<DT>serial </DT>
<DD>Sending or receiving data 1 bit at a time. </DD>
<DT>socket </DT>
<DD>A two-way network communications channel. </DD>
</DL>
<H2><A NAME="6_2">A.2 Acronyms</A></H2>
<DL>
<DT>ASCII</DT>
<DD>American Standard Code for Information Interchange</DD>
<DT>CUPS</DT>
<DD>Common UNIX Printing System</DD>
<DT>ESC/P</DT>
<DD>EPSON Standard Code for Printers</DD>
<DT>FTP</DT>
<DD>File Transfer Protocol</DD>
<DT>HP-GL</DT>
<DD>Hewlett-Packard Graphics Language</DD>
<DT>HP-PCL</DT>
<DD>Hewlett-Packard Page Control Language</DD>
<DT>HP-PJL</DT>
<DD>Hewlett-Packard Printer Job Language</DD>
<DT>IETF</DT>
<DD>Internet Engineering Task Force</DD>
<DT>IPP</DT>
<DD>Internet Printing Protocol</DD>
<DT>ISO</DT>
<DD>International Standards Organization</DD>
<DT>LPD</DT>
<DD>Line Printer Daemon</DD>
<DT>MIME</DT>
<DD>Multimedia Internet Mail Exchange</DD>
<DT>PPD</DT>
<DD>PostScript Printer Description</DD>
<DT>SMB</DT>
<DD>Server Message Block</DD>
<DT>TFTP</DT>
<DD>Trivial File Transfer Protocol</DD>
<DT>ASCII </DT>
<DD>American Standard Code for Information Interchange </DD>
<DT>CUPS </DT>
<DD>Common UNIX Printing System </DD>
<DT>ESC/P </DT>
<DD>EPSON Standard Code for Printers </DD>
<DT>FTP </DT>
<DD>File Transfer Protocol </DD>
<DT>HP-GL </DT>
<DD>Hewlett-Packard Graphics Language </DD>
<DT>HP-PCL </DT>
<DD>Hewlett-Packard Page Control Language </DD>
<DT>HP-PJL </DT>
<DD>Hewlett-Packard Printer Job Language </DD>
<DT>IETF </DT>
<DD>Internet Engineering Task Force </DD>
<DT>IPP </DT>
<DD>Internet Printing Protocol </DD>
<DT>ISO </DT>
<DD>International Standards Organization </DD>
<DT>LPD </DT>
<DD>Line Printer Daemon </DD>
<DT>MIME </DT>
<DD>Multimedia Internet Mail Exchange </DD>
<DT>PPD </DT>
<DD>PostScript Printer Description </DD>
<DT>SMB </DT>
<DD>Server Message Block </DD>
<DT>TFTP </DT>
<DD>Trivial File Transfer Protocol </DD>
</DL>
</BODY>
</HTML>
BIN
Ver Arquivo
Arquivo binário não exibido.
+1013 -1013
Ver Arquivo
Diferenças do arquivo suprimidas por serem muito extensas Carregar Diff
BIN
Ver Arquivo
Arquivo binário não exibido.
+6 -15
Ver Arquivo
@@ -2,7 +2,7 @@
<HEAD>
<META NAME="Description" CONTENT="Common UNIX Printing System Software Users Manual">
<META NAME="COPYRIGHT" CONTENT="Copyright 1997-2001, All Rights Reserved">
<META NAME="DOCNUMBER" CONTENT="CUPS-SUM-1.1.9">
<META NAME="DOCNUMBER" CONTENT="CUPS-SUM-1.1.7">
<META NAME="Author" CONTENT="Easy Software Products">
<TITLE>CUPS Software Users Manual</TITLE>
</HEAD>
@@ -11,7 +11,7 @@
<H1 ALIGN="RIGHT">Preface</H1>
<P>This software users manual describes how to use the Common UNIX Printing
System<SUP>TM</SUP> ("CUPS<SUP>TM</SUP>") Version 1.1.9.
System<SUP>TM</SUP> ("CUPS<SUP>TM</SUP>") Version 1.1.7.
<EMBED SRC="system-overview.shtml">
@@ -592,36 +592,27 @@ image on the page:
<H3>Scaling the Image</H3>
<P>The <CODE>-o scaling=percent</CODE>, <CODE>-o
ppi=value</CODE>, and <CODE>-o natural-scaling=percent</CODE>
<P>The <CODE>-o scaling=percent</CODE> and <CODE>-o ppi=value</CODE>
options change the size of a printed image:
<UL><PRE>
<B>lp -o scaling=<I>percent</I> filename ENTER</B>
<B>lp -o ppi=<I>value</I> filename ENTER</B>
<B>lpr -o natural-scaling=<I>percent</I> filename ENTER</B>
<B>lpr -o ppi=<I>value</I> filename ENTER</B>
</PRE></UL>
<P>The <CODE>scaling=percent</CODE> value is a number from 1 to 800
<P>The <CODE>percent</CODE> value is a number from 1 to 800
specifying the size in relation to the page (<I>not</I> the image.) A
scaling of 100 percent will fill the page as completely as the image
aspect ratio allows. A scaling of 200 percent will print on up to 4
pages.
<P>The <CODE>ppi=value</CODE> value is a number from 1 to 1200 specifying the
<P>The ppi <CODE>value</CODE> is a number from 1 to 1200 specifying the
resolution of the image in pixels per inch. An image that is 3000x2400
pixels will print 10x8 inches at 300 pixels per inch, for example. If
the specified resolution makes the image larger than the page, multiple
pages will be printed to satisfy the request.
<P>The <CODE>natural-scaling=percent</CODE> value is a number
from 1 to 800 specifying the size in relation to the natural
image size. A scaling of 100 percent will print the image at its
natural size, while a scaling of 50 percent will print the image
at half its natural size. If the specified scaling makes the
image larger than the page, multiple pages will be printed to
satisfy the request.
<H3>Adjusting the Hue (Tint) of an Image</H3>
<P>The <CODE>-o hue=value</CODE> option will adjust the hue of the
+156 -155
Ver Arquivo
@@ -1,27 +1,27 @@
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" "http://www.w3.org/TR/REC-html40/loose.dtd">
<HTML>
<HEAD>
<TITLE>CUPS Software Version Description</TITLE>
<TITLE> CUPS Software Version Description</TITLE>
<META NAME="author" CONTENT="Easy Software Products">
<META NAME="copyright" CONTENT="Copyright 1997-2001, All Rights Reserved">
<META NAME="docnumber" CONTENT="CUPS-SVD-1.1">
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; CHARSET=iso-8859-1">
<STYLE TYPE="text/css"><!--
BODY { font-family: serif }
H1 { font-family: sans-serif }
H2 { font-family: sans-serif }
H3 { font-family: sans-serif }
H4 { font-family: sans-serif }
H5 { font-family: sans-serif }
H6 { font-family: sans-serif }
SUB { font-size: smaller }
SUP { font-size: smaller }
PRE { font-family: monospace }
BODY { font-family: serif; font-size: 11.0pt }
H1 { font-family: sans-serif; font-size: 20.0pt }
H2 { font-family: sans-serif; font-size: 17.0pt }
H3 { font-family: sans-serif; font-size: 14.0pt }
H4 { font-family: sans-serif; font-size: 11.0pt }
H5 { font-family: sans-serif; font-size: 9.0pt }
H6 { font-family: sans-serif; font-size: 8.0pt }
SUB { font-size: 8.0pt }
SUP { font-size: 8.0pt }
PRE { font-size: 9.0pt }
--></STYLE>
</HEAD>
<BODY>
<CENTER><A HREF="#CONTENTS"><IMG SRC="images/cups-large.gif" BORDER="0" WIDTH="431" HEIGHT="511"><BR>
<H1>CUPS Software Version Description</H1></A><BR>
<CENTER><A HREF="#CONTENTS"><IMG SRC="images/cups-large.gif" BORDER="0" WIDTH="100%"><BR>
<H1> CUPS Software Version Description</H1></A><BR>
CUPS-SVD-1.1<BR>
Easy Software Products<BR>
Copyright 1997-2001, All Rights Reserved<BR>
@@ -76,27 +76,27 @@ Copyright 1997-2001, All Rights Reserved<BR>
<HR>
<H1><A NAME="1">1 Scope</A></H1>
<H2><A NAME="1_1">1.1 Identification</A></H2>
This software version description document provides release information
for the Common UNIX Printing System (&quot;CUPS&quot;) Version 1.1.
This software version description document provides release
information for the Common UNIX Printing System (&quot;CUPS&quot;) Version 1.1.
<H2><A NAME="1_2">1.2 System Overview</A></H2>
<P>CUPS provides a portable printing layer for UNIX&reg;-based operating
systems. It has been developed by<A HREF="http://www.easysw.com"> Easy
Software Products</A> to promote a standard printing solution for all
UNIX vendors and users. CUPS provides the System V and Berkeley
command-line interfaces.</P>
<P>CUPS uses the Internet Printing Protocol (&quot;IPP&quot;) as the basis for
managing print jobs and queues. The Line Printer Daemon (&quot;LPD&quot;) Server
Message Block (&quot;SMB&quot;), and AppSocket (a.k.a. JetDirect) protocols are
also supported with reduced functionality. CUPS adds network printer
browsing and PostScript Printer Description (&quot;PPD&quot;) based printing
options to support real-world printing under UNIX.</P>
<P>CUPS also includes a customized version of GNU Ghostscript (currently
based off GNU Ghostscript 5.50) and an image file RIP that are used to
support non-PostScript printers. Sample drivers for HP and EPSON
printers are included that use these filters.</P>
<P>CUPS provides a portable printing layer for UNIX&reg;-based operating
systems. It has been developed by <A HREF="http://www.easysw.com">Easy
Software Products</A> to promote a standard printing solution for all
UNIX vendors and users. CUPS provides the System V and Berkeley
command-line interfaces. </P>
<P>CUPS uses the Internet Printing Protocol (&quot;IPP&quot;) as the basis for
managing print jobs and queues. The Line Printer Daemon (&quot;LPD&quot;) Server
Message Block (&quot;SMB&quot;), and AppSocket (a.k.a. JetDirect) protocols are
also supported with reduced functionality. CUPS adds network printer
browsing and PostScript Printer Description (&quot;PPD&quot;) based printing
options to support real-world printing under UNIX. </P>
<P>CUPS also includes a customized version of GNU Ghostscript
(currently based off GNU Ghostscript 5.50) and an image file RIP that
are used to support non-PostScript printers. Sample drivers for HP and
EPSON printers are included that use these filters. </P>
<H2><A NAME="1_3">1.3 Document Overview</A></H2>
<P>This software version description document is organized into the
following sections:</P>
<P>This software version description document is organized into the
following sections:</P>
<UL>
<LI><A HREF="#1">1 - Scope</A></LI>
<LI><A HREF="#2">2 - References</A></LI>
@@ -106,108 +106,108 @@ Copyright 1997-2001, All Rights Reserved<BR>
</UL>
<H1><A NAME="2">2 References</A></H1>
<H2><A NAME="2_1">2.1 CUPS Documentation</A></H2>
<P>The following CUPS documentation is referenced by this document:</P>
<P>The following CUPS documentation is referenced by this document: </P>
<UL>
<LI>CUPS-CMP-1.1: CUPS Configuration Management Plan</LI>
<LI>CUPS-IDD-1.1: CUPS System Interface Design Description</LI>
<LI>CUPS-IPP-1.1: CUPS Implementation of IPP</LI>
<LI>CUPS-SAM-1.1.x: CUPS Software Administrators Manual</LI>
<LI>CUPS-SDD-1.1: CUPS Software Design Description</LI>
<LI>CUPS-SPM-1.1.x: CUPS Software Programming Manual</LI>
<LI>CUPS-SSR-1.1: CUPS Software Security Report</LI>
<LI>CUPS-STP-1.1: CUPS Software Test Plan</LI>
<LI>CUPS-SUM-1.1.x: CUPS Software Users Manual</LI>
<LI>CUPS-SVD-1.1: CUPS Software Version Description</LI>
<LI>CUPS-CMP-1.1: CUPS Configuration Management Plan </LI>
<LI>CUPS-IDD-1.1: CUPS System Interface Design Description </LI>
<LI>CUPS-IPP-1.1: CUPS Implementation of IPP </LI>
<LI>CUPS-SAM-1.1.x: CUPS Software Administrators Manual </LI>
<LI>CUPS-SDD-1.1: CUPS Software Design Description </LI>
<LI>CUPS-SPM-1.1.x: CUPS Software Programming Manual </LI>
<LI>CUPS-SSR-1.1: CUPS Software Security Report </LI>
<LI>CUPS-STP-1.1: CUPS Software Test Plan </LI>
<LI>CUPS-SUM-1.1.x: CUPS Software Users Manual </LI>
<LI>CUPS-SVD-1.1: CUPS Software Version Description </LI>
</UL>
<H2><A NAME="2_2">2.2 Other Documents</A></H2>
<P>The following non-CUPS documents are referenced by this document:</P>
<P>The following non-CUPS documents are referenced by this document: </P>
<UL>
<LI><A HREF="http://partners.adobe.com/asn/developer/PDFS/TN/5003.PPD_Spec_v4.3.pdf">
Adobe PostScript Printer Description File Format Specification, Version
4.3.</A></LI>
Adobe PostScript Printer Description File Format Specification,
Version 4.3.</A></LI>
<LI><A HREF="http://partners.adobe.com/asn/developer/PDFS/TN/PLRM.pdf">
Adobe PostScript Language Reference, Third Edition.</A></LI>
<LI>IPP: Job and Printer Set Operations</LI>
<LI>IPP/1.1: Encoding and Transport</LI>
<LI>IPP/1.1: Implementers Guide</LI>
<LI>IPP/1.1: Model and Semantics</LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc1179.txt">RFC 1179, Line Printer
Daemon Protocol</A></LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc2567.txt">RFC 2567, Design Goals
for an Internet Printing Protocol</A></LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc2568.txt">RFC 2568, Rationale
for the Structure of the Model and Protocol</A> for the Internet
Printing Protocol</LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc2569.txt">RFC 2569, Mapping
between LPD and IPP Protocols</A></LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc2616.txt">RFC 2616, Hypertext
Transfer Protocol -- HTTP/1.1</A></LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc2617.txt">RFC 2617, HTTP
Authentication: Basic and Digest Access</A> Authentication</LI>
Adobe PostScript Language Reference, Third Edition.</A></LI>
<LI>IPP: Job and Printer Set Operations </LI>
<LI>IPP/1.1: Encoding and Transport </LI>
<LI>IPP/1.1: Implementers Guide </LI>
<LI>IPP/1.1: Model and Semantics </LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc1179.txt">RFC 1179, Line
Printer Daemon Protocol</A></LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc2567.txt">RFC 2567, Design
Goals for an Internet Printing Protocol</A></LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc2568.txt">RFC 2568, Rationale
for the Structure of the Model and Protocol</A> for the Internet
Printing Protocol</LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc2569.txt">RFC 2569, Mapping
between LPD and IPP Protocols</A></LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc2616.txt">RFC 2616, Hypertext
Transfer Protocol -- HTTP/1.1</A></LI>
<LI><A HREF="http://www.ietf.org/rfc/rfc2617.txt">RFC 2617, HTTP
Authentication: Basic and Digest Access</A> Authentication </LI>
</UL>
<H1><A NAME="3">3 Additions</A></H1>
<P>CUPS 1.1 includes many new features from the 1.0.x releases.</P>
<P>CUPS 1.1 includes many new features from the 1.0.x releases. </P>
<H2><A NAME="3_1">3.1 Filters</A></H2>
<H3><A NAME="3_1_1">3.1.1 <CODE>imagetoraster</CODE>, <CODE>imagetops</CODE>
</A></H3>
<P>The image file filters have been upgraded to support conversion of
Microsoft Bitmap (&quot;BMP&quot;) and Alias PIX files.</P>
<P>The image file filters have been upgraded to support conversion of
Microsoft Bitmap (&quot;BMP&quot;) and Alias PIX files. </P>
<H3><A NAME="3_1_2">3.1.2 pdftops</A></H3>
<P>A new pdftops filter has been developed that is based on the
excellent Xpdf 0.90 software from Derek B. Noonburg. The new filter is
faster, smaller, and considerably more reliable than the
Ghostscript-based filter in CUPS 1.0.</P>
<P>A new pdftops filter has been developed that is based on the
excellent Xpdf 0.90 software from Derek B. Noonburg. The new filter is
faster, smaller, and considerably more reliable than the
Ghostscript-based filter in CUPS 1.0. </P>
<H3><A NAME="3_1_3">3.1.3 pstoraster</A></H3>
<P>The <CODE>pstoraster</CODE> filter has been integrated with GNU
GhostScript 5.50. The new RIP supports most Level 3 PostScript language
features.</P>
<P>The <CODE>pstoraster</CODE> filter has been integrated with GNU
GhostScript 5.50. The new RIP supports most Level 3 PostScript language
features. </P>
<H3><A NAME="3_1_4">3.1.4 rastertoepson</A></H3>
<P>The new <CODE>rastertoepson</CODE> filter supports EPSON printers
using the ESC/P or ESC/P2 command sets. PPDs are supplied for 9-pin,
24-pin, Stylus Color, and Stylus Photo printers.</P>
<P>The new <CODE>rastertoepson</CODE> filter supports EPSON printers
using the ESC/P or ESC/P2 command sets. PPDs are supplied for 9-pin,
24-pin, Stylus Color, and Stylus Photo printers. </P>
<H2><A NAME="3_2">3.2 User-Defined Printers and Options</A></H2>
<P>The new <CODE>lpoptions</CODE> command allows users to configure
default document options and create additional &quot;instances&quot; of existing
printers, each with unique options.</P>
<P>The new <CODE>lpoptions</CODE> command allows users to configure
default document options and create additional &quot;instances&quot; of existing
printers, each with unique options. </P>
<P>The <CODE>lp</CODE>, <CODE>lpr</CODE>, and <CODE>lpstat</CODE>
commands have been upgraded to use this option and printer instance
information automatically.</P>
commands have been upgraded to use this option and printer instance
information automatically. </P>
<H2><A NAME="3_3">3.3 Daemons</A></H2>
<P>CUPS 1.1 includes two new daemons that provide enhanced network
printing support.</P>
<P>CUPS 1.1 includes two new daemons that provide enhanced network
printing support. </P>
<H3><A NAME="3_3_1">3.3.1 cups-lpd</A></H3>
<P>The <CODE>cups-lpd</CODE> daemon provides support for clients using
the Line Printer Daemon protocol.</P>
<P>The <CODE>cups-lpd</CODE> daemon provides support for clients using
the Line Printer Daemon protocol. </P>
<H3><A NAME="3_3_2">3.3.2 cups-polld</A></H3>
<P>The <CODE>cups-polld</CODE> daemon provides remote polling services
for the scheduler.</P>
<P>The <CODE>cups-polld</CODE> daemon provides remote polling services
for the scheduler. </P>
<H2><A NAME="3_4">3.4 Commands</A></H2>
<P>CUPS 1.1 includes several new printing commands.</P>
<P>CUPS 1.1 includes several new printing commands. </P>
<H3><A NAME="3_4_1">3.4.1 lpoptions</A></H3>
<P>The <CODE>lpoptions</CODE> command provides user-defined printers and
options.</P>
<P>The <CODE>lpoptions</CODE> command provides user-defined printers
and options. </P>
<H3><A NAME="3_4_2">3.4.2 lpmove</A></H3>
<P>The <CODE>lpmove</CODE> command moves a print job to a new
destination.</P>
<P>The <CODE>lpmove</CODE> command moves a print job to a new
destination. </P>
<H3><A NAME="3_4_3">3.4.3 lpinfo</A></H3>
<P>The <CODE>lpinfo</CODE> command lists the available PPD files or
devices.</P>
<P>The <CODE>lpinfo</CODE> command lists the available PPD files or
devices. </P>
<H2><A NAME="3_5">3.5 IPP Implementation</A></H2>
<P>CUPS 1.1 adds support for the <CODE>set-job-attributes</CODE>
extension operation as well as two new CUPS-specific extension
operations to determine which devices and printer drivers are available
on the system.</P>
<P>Further information on the CUPS implementation of IPP can be found in
CUPS-IPP-1.1.</P>
extension operation as well as two new CUPS-specific extension
operations to determine which devices and printer drivers are available
on the system. </P>
<P>Further information on the CUPS implementation of IPP can be found
in CUPS-IPP-1.1. </P>
<H1><A NAME="4">4 Changes</A></H1>
<P>CUPS 1.1 includes many changes from the 1.0.x releases.</P>
<P>CUPS 1.1 includes many changes from the 1.0.x releases. </P>
<H2><A NAME="4_1">4.1 Directory Structure</A></H2>
<P>The directory structure in CUPS 1.1 has been modified to conform to
the Filesystem Hierarchy Standard, 2.0. The following table describes
the new file locations.
<P>The directory structure in CUPS 1.1 has been modified to conform to
the Filesystem Hierarchy Standard, 2.0. The following table describes
the new file locations.
<CENTER>
<TABLE BORDER WIDTH="80%"><CAPTION> Table 1: Directory structure changes
from CUPS 1.0.x to 1.1.x.</CAPTION>
<TABLE BORDER WIDTH="80%"><CAPTION> Table 1: Directory structure
changes from CUPS 1.0.x to 1.1.x.</CAPTION>
<TR><TH>Description</TH><TH>CUPS 1.0.x</TH><TH>CUPS 1.1.x</TH></TR>
<TR><TD>Backends</TD><TD>/var/cups/backend</TD><TD>/usr/lib/cups/backend</TD>
</TR>
@@ -231,66 +231,67 @@ Adobe PostScript Language Reference, Third Edition.</A></LI>
</CENTER>
</P>
<H2><A NAME="4_2">4.2 IPP Implementation</A></H2>
<P>CUPS 1.1 is based on version 1.1 of the Internet Printing Protocol.</P>
<P>CUPS 1.1 is based on version 1.1 of the Internet Printing Protocol. </P>
<P>The new scheduler supports the <CODE>create-job</CODE> and <CODE>
send-document</CODE> operations. In addition, the <CODE>job-sheets</CODE>
, <CODE>job-sheets-default</CODE>, and <CODE>job-sheets-supported</CODE>
attributes are now supported for banner pages.</P>
attributes are now supported for banner pages. </P>
<P>The <CODE>CUPS-get-printers</CODE> and <CODE>CUPS-get-classes</CODE>
operations have been upgraded to support limited filtering based upon
the <CODE>printer-type</CODE>, <CODE>printer-location</CODE>, <CODE>
printer-info</CODE>, and <CODE>printer-make-and-model</CODE> attributes.</P>
operations have been upgraded to support limited filtering based upon
the <CODE>printer-type</CODE>, <CODE>printer-location</CODE>, <CODE>
printer-info</CODE>, and <CODE>printer-make-and-model</CODE>
attributes. </P>
<P>The <CODE>CUPS-add-printer</CODE> operation now supports the <CODE>
ppd-name</CODE> attribute to specify a locally-available PPD file rather
than sending the PPD file from the client with the request.</P>
<P>Further information on the CUPS implementation of IPP can be found in
CUPS-IPP-1.1.</P>
ppd-name</CODE> attribute to specify a locally-available PPD file
rather than sending the PPD file from the client with the request. </P>
<P>Further information on the CUPS implementation of IPP can be found
in CUPS-IPP-1.1. </P>
<H1 TYPE="A" VALUE="1"><A NAME="5">A Glossary</A></H1>
<H2><A NAME="5_1">A.1 Terms</A></H2>
<DL>
<DT>C</DT>
<DD>A computer language.</DD>
<DT>parallel</DT>
<DD>Sending or receiving data more than 1 bit at a time.</DD>
<DT>pipe</DT>
<DD>A one-way communications channel between two programs.</DD>
<DT>serial</DT>
<DD>Sending or receiving data 1 bit at a time.</DD>
<DT>socket</DT>
<DD>A two-way network communications channel.</DD>
<DT>C </DT>
<DD>A computer language. </DD>
<DT>parallel </DT>
<DD>Sending or receiving data more than 1 bit at a time. </DD>
<DT>pipe </DT>
<DD>A one-way communications channel between two programs. </DD>
<DT>serial </DT>
<DD>Sending or receiving data 1 bit at a time. </DD>
<DT>socket </DT>
<DD>A two-way network communications channel. </DD>
</DL>
<H2><A NAME="5_2">A.2 Acronyms</A></H2>
<DL>
<DT>ASCII</DT>
<DD>American Standard Code for Information Interchange</DD>
<DT>CUPS</DT>
<DD>Common UNIX Printing System</DD>
<DT>ESC/P</DT>
<DD>EPSON Standard Code for Printers</DD>
<DT>FTP</DT>
<DD>File Transfer Protocol</DD>
<DT>HP-GL</DT>
<DD>Hewlett-Packard Graphics Language</DD>
<DT>HP-PCL</DT>
<DD>Hewlett-Packard Page Control Language</DD>
<DT>HP-PJL</DT>
<DD>Hewlett-Packard Printer Job Language</DD>
<DT>IETF</DT>
<DD>Internet Engineering Task Force</DD>
<DT>IPP</DT>
<DD>Internet Printing Protocol</DD>
<DT>ISO</DT>
<DD>International Standards Organization</DD>
<DT>LPD</DT>
<DD>Line Printer Daemon</DD>
<DT>MIME</DT>
<DD>Multimedia Internet Mail Exchange</DD>
<DT>PPD</DT>
<DD>PostScript Printer Description</DD>
<DT>SMB</DT>
<DD>Server Message Block</DD>
<DT>TFTP</DT>
<DD>Trivial File Transfer Protocol</DD>
<DT>ASCII </DT>
<DD>American Standard Code for Information Interchange </DD>
<DT>CUPS </DT>
<DD>Common UNIX Printing System </DD>
<DT>ESC/P </DT>
<DD>EPSON Standard Code for Printers </DD>
<DT>FTP </DT>
<DD>File Transfer Protocol </DD>
<DT>HP-GL </DT>
<DD>Hewlett-Packard Graphics Language </DD>
<DT>HP-PCL </DT>
<DD>Hewlett-Packard Page Control Language </DD>
<DT>HP-PJL </DT>
<DD>Hewlett-Packard Printer Job Language </DD>
<DT>IETF </DT>
<DD>Internet Engineering Task Force </DD>
<DT>IPP </DT>
<DD>Internet Printing Protocol </DD>
<DT>ISO </DT>
<DD>International Standards Organization </DD>
<DT>LPD </DT>
<DD>Line Printer Daemon </DD>
<DT>MIME </DT>
<DD>Multimedia Internet Mail Exchange </DD>
<DT>PPD </DT>
<DD>PostScript Printer Description </DD>
<DT>SMB </DT>
<DD>Server Message Block </DD>
<DT>TFTP </DT>
<DD>Trivial File Transfer Protocol </DD>
</DL>
</BODY>
</HTML>
BIN
Ver Arquivo
Arquivo binário não exibido.
+11 -17
Ver Arquivo
@@ -59,14 +59,20 @@ clean:
#
install:
$(INSTALL_DIR) $(LIBDIR)
-$(MKDIR) $(LIBDIR)
$(CHMOD) ugo+rx $(LIBDIR)
$(INSTALL_LIB) $(LIBCUPSIMAGE) $(LIBDIR)
if test $(LIBCUPSIMAGE) != "libcupsimage.a" -a $(LIBCUPSIMAGE) != "libcupsimage.la"; then \
$(INSTALL_LIB) `basename $(LIBCUPSIMAGE) .2` $(LIBDIR); \
-if test $(LIBCUPSIMAGE) != "libcupsimage.a" -a $(LIBCUPSIMAGE) != "libcupsimage.la"; then \
$(RM) $(LIBDIR)/`basename $(LIBCUPSIMAGE) .2`; \
$(LN) $(LIBCUPSIMAGE) $(LIBDIR)/`basename $(LIBCUPSIMAGE) .2`; \
fi
$(INSTALL_DIR) $(SERVERBIN)/filter
-$(MKDIR) $(SERVERBIN)/filter
$(CHMOD) ugo+rx $(SERVERBIN)
$(CHMOD) ugo+rx $(SERVERBIN)/filter
$(INSTALL_BIN) $(TARGETS) $(SERVERBIN)/filter
$(INSTALL_DIR) $(INCLUDEDIR)/cups
-$(MKDIR) $(INCLUDEDIR)/cups
$(CHMOD) ugo+rx $(INCLUDEDIR)
$(CHMOD) ugo+rx $(INCLUDEDIR)/cups
$(INSTALL_DATA) raster.h $(INCLUDEDIR)/cups
@@ -101,18 +107,6 @@ libcupsimage.so.2 libcupsimage.sl.2: $(IMAGEOBJS) ../Makedefs
$(LN) $@ `basename $@ .2`
#
# libcupsimage_s.a
#
libcupsimage_s.a: $(IMAGEOBJS) ../Makedefs
echo Linking $@...
$(DSO) $(DSOFLAGS) -o libcupsimage_s.o $(IMAGEOBJS) $(DSOLIBS) \
$(LINKCUPS) -lm
$(RM) $@
$(AR) $(ARFLAGS) $@ libcupsimage_s.o
#
# libcupsimage.la
#
+1 -1
Ver Arquivo
@@ -98,7 +98,7 @@ ImageReadJPEG(image_t *img, /* IO - Image */
}
fprintf(stderr, "DEBUG: JPEG image %dx%dx%d, %dx%d PPI\n",
img->xsize, img->ysize, cinfo.output_components,
img->xsize, img->colorspace, cinfo.output_components,
img->xppi, img->yppi);
ImageSetMaxTiles(img, 0);
+2 -10
Ver Arquivo
@@ -305,12 +305,6 @@ main(int argc, /* I - Number of command-line arguments */
xinches = (float)img->xsize / (float)xppi;
yinches = (float)img->ysize / (float)yppi;
if ((val = cupsGetOption("natural-scaling", num_options, options)) != NULL)
{
xinches = xinches * atoi(val) / 100;
yinches = yinches * atoi(val) / 100;
}
if (cupsGetOption("orientation", num_options, options) == NULL &&
cupsGetOption("landscape", num_options, options) == NULL)
{
@@ -599,10 +593,8 @@ main(int argc, /* I - Number of command-line arguments */
for (xpage = 0; xpage < xpages; xpage ++)
for (ypage = 0; ypage < ypages; ypage ++, page ++)
{
if (ppd && ppd->num_filters == 0)
fprintf(stderr, "PAGE: %d %d\n", page, realcopies);
fprintf(stderr, "INFO: Printing page %d...\n", page);
fprintf(stderr, "PAGE: %d %d\n", page, realcopies);
fprintf(stderr, "INFO: Printing page %d...\n", page);
printf("%%%%Page: %d %d\n", page, page);
-6
Ver Arquivo
@@ -677,12 +677,6 @@ main(int argc, /* I - Number of command-line arguments */
xinches = (float)img->xsize / (float)xppi;
yinches = (float)img->ysize / (float)yppi;
if ((val = cupsGetOption("natural-scaling", num_options, options)) != NULL)
{
xinches = xinches * atoi(val) / 100;
yinches = yinches * atoi(val) / 100;
}
if (cupsGetOption("orientation", num_options, options) == NULL &&
cupsGetOption("landscape", num_options, options) == NULL)
{
+65 -231
Ver Arquivo
@@ -59,8 +59,7 @@ int Order = 0, /* 0 = normal, 1 = reverse pages */
Flip = 0, /* Flip/mirror pages */
NUp = 1, /* Number of pages on each sheet (1, 2, 4) */
Collate = 0, /* Collate copies? */
Copies = 1, /* Number of copies */
UseESPsp = 0; /* Use ESPshowpage? */
Copies = 1; /* Number of copies */
/*
@@ -93,7 +92,6 @@ main(int argc, /* I - Number of command-line arguments */
int number; /* Page number */
int slowcollate; /* 1 if we need to collate manually */
int sloworder; /* 1 if we need to order manually */
int slowduplex; /* 1 if we need an even number of pages */
char line[8192]; /* Line buffer */
float g; /* Gamma correction value */
float b; /* Brightness factor */
@@ -101,9 +99,7 @@ main(int argc, /* I - Number of command-line arguments */
int nbytes, /* Number of bytes read */
tbytes; /* Total bytes to read for binary data */
int page; /* Current page sequence number */
int real_page; /* "Real" page number in document */
int page_count; /* Page count for NUp */
int basepage; /* Base page number */
int subpage; /* Sub-page number */
int copy; /* Current copy */
int saweof; /* Did we see a %%EOF tag? */
@@ -140,8 +136,7 @@ main(int argc, /* I - Number of command-line arguments */
if ((fp = fopen(argv[6], "rb")) == NULL)
{
fprintf(stderr, "ERROR: unable to open print file \"%s\" - %s\n",
argv[6], strerror(errno));
perror("ERROR: unable to open print file - ");
return (1);
}
}
@@ -201,22 +196,6 @@ main(int argc, /* I - Number of command-line arguments */
* See if we have to filter the fast or slow way...
*/
if (ppd && ppd->manual_copies && Duplex && Copies > 1)
{
/*
* Force collated copies when printing a duplexed document to
* a non-PS printer that doesn't do hardware copy generation.
* Otherwise the copies will end up on the front/back side of
* each page. Also, set the "slowduplex" option to make sure
* that we output an even number of pages...
*/
Collate = 1;
slowduplex = 1;
}
else
slowduplex = 0;
if (ppdFindOption(ppd, "Collate") == NULL && Collate && Copies > 1)
slowcollate = 1;
else
@@ -283,46 +262,26 @@ main(int argc, /* I - Number of command-line arguments */
ppdEmit(ppd, stdout, PPD_ORDER_ANY);
ppdEmit(ppd, stdout, PPD_ORDER_PROLOG);
puts("userdict begin\n"
"/ESPshowpage /showpage load def\n"
"/showpage { } def\n"
"end");
if (g != 1.0 || b != 1.0)
printf("{ neg 1 add dup 0 lt { pop 1 } { %.3f exp neg 1 add } "
"ifelse %.3f mul } bind settransfer\n", g, b);
/*
* Figure out if we should use ESPshowpage or not...
*/
val = cupsGetOption("page-label", num_options, options);
if (val != NULL || getenv("CLASSIFICATION") != NULL || NUp > 1)
{
/*
* Yes, use ESPshowpage...
*/
UseESPsp = 1;
WriteLabelProlog(val);
puts("userdict begin\n"
"/ESPshowpage /showpage load def\n"
"/showpage { } def\n"
"end");
}
WriteLabelProlog(cupsGetOption("page-label", num_options, options));
if (Copies > 1 && (!Collate || !slowcollate))
{
if (Collate)
printf("%%%%Requirements: numcopies(%d) collate\n", Copies);
else
printf("%%%%Requirements: numcopies(%d)\n", Copies);
if (LanguageLevel == 1)
if (ppd == NULL || ppd->language_level == 1)
printf("/#copies %d def\n", Copies);
else
printf("<</NumCopies %d>>setpagedevice\n", Copies);
}
if (strncmp(line, "%!PS-Adobe-", 11) == 0)
if (strncmp(line, "%!PS-Adobe-", 11) == 0 && atof(line + 11) >= 3.0)
{
/*
* OK, we have DSC comments; read until we find a %%Page comment...
@@ -331,10 +290,6 @@ main(int argc, /* I - Number of command-line arguments */
level = 0;
while (psgets(line, sizeof(line), fp) != NULL)
{
if (strncmp(line, "%%", 2) == 0)
fprintf(stderr, "DEBUG: %d %s", level, line);
if (strncmp(line, "%%BeginDocument:", 16) == 0 ||
strncmp(line, "%%BeginDocument ", 16) == 0) /* Adobe Acrobat BUG */
level ++;
@@ -351,8 +306,6 @@ main(int argc, /* I - Number of command-line arguments */
*/
tbytes = atoi(strchr(line, ':') + 1);
fputs(line, stdout);
while (tbytes > 0)
{
if (tbytes > sizeof(line))
@@ -360,29 +313,19 @@ main(int argc, /* I - Number of command-line arguments */
else
nbytes = fread(line, 1, tbytes, fp);
if (nbytes < 1)
{
perror("ERROR: Early end-of-file while reading binary data");
return (1);
}
fwrite(line, 1, nbytes, stdout);
tbytes -= nbytes;
}
}
else
fputs(line, stdout);
}
/*
* Then read all of the pages, filtering as needed...
*/
for (page = 1, real_page = 1;;)
for (page = 1;;)
{
if (strncmp(line, "%%", 2) == 0)
fprintf(stderr, "DEBUG: %d %s", level, line);
if (strncmp(line, "%%BeginDocument:", 16) == 0 ||
strncmp(line, "%%BeginDocument ", 16) == 0) /* Adobe Acrobat BUG */
level ++;
@@ -398,46 +341,45 @@ main(int argc, /* I - Number of command-line arguments */
}
else if (strncmp(line, "%%Page:", 7) == 0 && level == 0)
{
if (!check_range(real_page))
if (sscanf(line, "%*s%*s%d", &number) == 1)
{
while (psgets(line, sizeof(line), fp) != NULL)
if (strncmp(line, "%%BeginDocument:", 16) == 0 ||
strncmp(line, "%%BeginDocument ", 16) == 0) /* Adobe Acrobat BUG */
level ++;
else if (strcmp(line, "%%EndDocument") == 0 && level > 0)
level --;
else if (strncmp(line, "%%Page:", 7) == 0 && level == 0)
if (!check_range(number))
{
while (psgets(line, sizeof(line), fp) != NULL)
if (strncmp(line, "%%BeginDocument:", 16) == 0 ||
strncmp(line, "%%BeginDocument ", 16) == 0) /* Adobe Acrobat BUG */
level ++;
else if (strcmp(line, "%%EndDocument") == 0 && level > 0)
level --;
else if (strncmp(line, "%%Page:", 7) == 0 && level == 0)
break;
continue;
}
if (!sloworder && NumPages > 0)
end_nup(NumPages - 1);
if (slowcollate || sloworder)
Pages[NumPages] = ftell(temp);
if (!sloworder)
{
if ((NumPages & (NUp - 1)) == 0)
{
real_page ++;
break;
if (ppd == NULL || ppd->num_filters == 0)
fprintf(stderr, "PAGE: %d %d\n", page, Copies);
printf("%%%%Page: %d %d\n", page, page);
page ++;
ppdEmit(ppd, stdout, PPD_ORDER_PAGE);
}
continue;
}
if (!sloworder && NumPages > 0)
end_nup(NumPages - 1);
if (slowcollate || sloworder)
Pages[NumPages] = ftell(temp);
if (!sloworder)
{
if ((NumPages & (NUp - 1)) == 0)
{
if (ppd == NULL || ppd->num_filters == 0)
fprintf(stderr, "PAGE: %d %d\n", page, Copies);
printf("%%%%Page: %d %d\n", page, page);
page ++;
ppdEmit(ppd, stdout, PPD_ORDER_PAGE);
start_nup(NumPages);
}
start_nup(NumPages);
NumPages ++;
}
NumPages ++;
real_page ++;
}
else if (strncmp(line, "%%BeginBinary:", 14) == 0 ||
(strncmp(line, "%%BeginData:", 12) == 0 &&
@@ -448,12 +390,6 @@ main(int argc, /* I - Number of command-line arguments */
*/
tbytes = atoi(strchr(line, ':') + 1);
if (!sloworder)
fputs(line, stdout);
if (slowcollate || sloworder)
fputs(line, temp);
while (tbytes > 0)
{
if (tbytes > sizeof(line))
@@ -461,17 +397,11 @@ main(int argc, /* I - Number of command-line arguments */
else
nbytes = fread(line, 1, tbytes, fp);
if (nbytes < 1)
{
perror("ERROR: Early end-of-file while reading binary data");
return (1);
}
if (!sloworder)
fwrite(line, 1, nbytes, stdout);
if (slowcollate || sloworder)
fwrite(line, 1, nbytes, temp);
fwrite(line, 1, nbytes, stdout);
tbytes -= nbytes;
}
@@ -503,33 +433,16 @@ main(int argc, /* I - Number of command-line arguments */
start_nup(NUp - 1);
end_nup(NUp - 1);
}
if (slowduplex && !(page & 1))
{
/*
* Make sure we have an even number of pages...
*/
if (ppd == NULL || ppd->num_filters == 0)
fprintf(stderr, "PAGE: %d %d\n", page, Copies);
printf("%%%%Page: %d %d\n", page, page);
page ++;
ppdEmit(ppd, stdout, PPD_ORDER_PAGE);
start_nup(NUp - 1);
puts("showpage");
end_nup(NUp - 1);
}
}
if (slowcollate || sloworder)
{
Pages[NumPages] = ftell(temp);
page = 1;
if (!sloworder)
{
while (Copies > 1)
while (Copies > 0)
{
rewind(temp);
@@ -556,24 +469,6 @@ main(int argc, /* I - Number of command-line arguments */
end_nup(NUp - 1);
}
if (slowduplex && !(page & 1))
{
/*
* Make sure we have an even number of pages...
*/
if (ppd == NULL || ppd->num_filters == 0)
fprintf(stderr, "PAGE: %d 1\n", page);
printf("%%%%Page: %d %d\n", page, page);
page ++;
ppdEmit(ppd, stdout, PPD_ORDER_PAGE);
start_nup(NUp - 1);
puts("showpage");
end_nup(NUp - 1);
}
Copies --;
}
}
@@ -584,25 +479,21 @@ main(int argc, /* I - Number of command-line arguments */
do
{
if (slowduplex && (page_count & 1))
{
basepage = page_count - 1;
}
else
basepage = page_count - 1 - slowduplex;
for (; basepage >= 0; basepage -= 1 + slowduplex)
for (page = page_count - 1; page >= 0; page --)
{
if (ppd == NULL || ppd->num_filters == 0)
fprintf(stderr, "PAGE: %d %d\n", page,
fprintf(stderr, "PAGE: %d %d\n", page + 1,
slowcollate ? 1 : Copies);
printf("%%%%Page: %d %d\n", page, page);
page ++;
if (slowcollate)
printf("%%%%Page: %d %d\n", page + 1,
page_count - page + copy * page_count);
else
printf("%%%%Page: %d %d\n", page + 1, page_count - page);
ppdEmit(ppd, stdout, PPD_ORDER_PAGE);
for (subpage = 0, number = basepage * NUp;
for (subpage = 0, number = page * NUp;
subpage < NUp && number < NumPages;
subpage ++, number ++)
{
@@ -617,56 +508,6 @@ main(int argc, /* I - Number of command-line arguments */
start_nup(NUp - 1);
end_nup(NUp - 1);
}
if (slowduplex)
{
if (number < NumPages)
{
if (ppd == NULL || ppd->num_filters == 0)
fprintf(stderr, "PAGE: %d %d\n", page,
slowcollate ? 1 : Copies);
printf("%%%%Page: %d %d\n", page, page);
page ++;
ppdEmit(ppd, stdout, PPD_ORDER_PAGE);
for (subpage = 0, number = (basepage + 1) * NUp;
subpage < NUp && number < NumPages;
subpage ++, number ++)
{
start_nup(number);
fseek(temp, Pages[number], SEEK_SET);
copy_bytes(temp, Pages[number + 1] - Pages[number]);
end_nup(number);
}
if (number & (NUp - 1))
{
start_nup(NUp - 1);
end_nup(NUp - 1);
}
}
else
{
/*
* Make sure we have an even number of pages...
*/
if (ppd == NULL || ppd->num_filters == 0)
fprintf(stderr, "PAGE: %d %d\n", page, slowcollate ? 1 : Copies);
printf("%%%%Page: %d %d\n", page, page);
page ++;
ppdEmit(ppd, stdout, PPD_ORDER_PAGE);
start_nup(NUp - 1);
puts("showpage");
end_nup(NUp - 1);
basepage = page_count - 1;
}
}
}
copy ++;
@@ -703,18 +544,15 @@ main(int argc, /* I - Number of command-line arguments */
ppdEmit(ppd, stdout, PPD_ORDER_PAGE);
saweof = 1;
while ((nbytes = fread(line, 1, sizeof(line), fp)) > 0)
while (psgets(line, sizeof(line), fp) != NULL)
{
fwrite(line, 1, nbytes, stdout);
fputs(line, stdout);
if (slowcollate)
fwrite(line, 1, nbytes, temp);
fputs(line, temp);
}
if (UseESPsp)
puts("ESPshowpage");
puts("ESPshowpage");
if (slowcollate)
{
@@ -728,8 +566,7 @@ main(int argc, /* I - Number of command-line arguments */
copy_bytes(temp, 0);
Copies --;
if (UseESPsp)
puts("ESPshowpage");
puts("ESPshowpage");
}
}
}
@@ -747,7 +584,7 @@ main(int argc, /* I - Number of command-line arguments */
if (ppd != NULL && ppd->jcl_end)
fputs(ppd->jcl_end, stdout);
else if (ppd != NULL && ppd->num_filters == 0)
else if (ppd->num_filters == 0)
putchar(0x04);
/*
@@ -850,7 +687,7 @@ copy_bytes(FILE *fp, /* I - File to read from */
while (nleft > 0 || length == 0)
{
if (nleft > sizeof(buffer) || length == 0)
if (nleft > sizeof(buffer))
nbytes = sizeof(buffer);
else
nbytes = nleft;
@@ -878,15 +715,12 @@ end_nup(int number) /* I - Page number */
switch (NUp)
{
case 1 :
if (UseESPsp)
{
WriteLabels();
puts("ESPshowpage");
}
WriteLabels();
puts("ESPshowpage");
break;
case 2 :
if ((number & 1) == 1 && UseESPsp)
if ((number & 1) == 1)
{
WriteLabels();
puts("ESPshowpage");
@@ -894,7 +728,7 @@ end_nup(int number) /* I - Page number */
break;
case 4 :
if ((number & 3) == 3 && UseESPsp)
if ((number & 3) == 3)
{
WriteLabels();
puts("ESPshowpage");
+34 -72
Ver Arquivo
@@ -55,8 +55,6 @@
#define EPSON_24PIN 1
#define EPSON_COLOR 2
#define EPSON_PHOTO 3
#define EPSON_ICOLOR 4
#define EPSON_IPHOTO 5
/*
@@ -73,8 +71,7 @@
unsigned char *Planes[6], /* Output buffers */
*CompBuffer, /* Compression buffer */
*LineBuffers[2]; /* Line bitmap buffers */
int Model, /* Model number */
NumPlanes, /* Number of color planes */
int NumPlanes, /* Number of color planes */
Feed; /* Number of lines to skip */
int DotBit, /* Bit in buffers */
DotBytes, /* # bytes in a dot column */
@@ -167,8 +164,6 @@ StartPage(const ppd_file_t *ppd, /* I - PPD file */
* See which type of printer we are using...
*/
Model = ppd->model_number;
switch (ppd->model_number)
{
case EPSON_9PIN :
@@ -222,7 +217,8 @@ StartPage(const ppd_file_t *ppd, /* I - PPD file */
}
break;
default :
case EPSON_COLOR :
case EPSON_PHOTO :
/*
* Set graphics mode...
*/
@@ -233,20 +229,8 @@ StartPage(const ppd_file_t *ppd, /* I - PPD file */
* Set the media size...
*/
if (Model < EPSON_ICOLOR)
{
pwrite("\033(U\001\000", 5); /* Resolution/units */
putchar(3600 / header->HWResolution[1]);
}
else
{
pwrite("\033(U\005\000", 5);
putchar(1440 / header->HWResolution[1]);
putchar(1440 / header->HWResolution[1]);
putchar(1440 / header->HWResolution[0]);
putchar(0xa0); /* n/1440ths... */
putchar(0x05);
}
pwrite("\033(U\001\000", 5); /* Resolution/units */
putchar(3600 / header->HWResolution[1]);
n = header->PageSize[1] * header->HWResolution[1] / 72.0;
@@ -454,7 +438,7 @@ CompressData(const unsigned char *line, /* I - Data to compress */
unsigned char *comp_ptr, /* Pointer into compression buffer */
temp; /* Current byte */
int count; /* Count of bytes for output */
static int ctable[6] = { 0, 2, 1, 4, 18, 17 };
static int ctable[6] = { 0, 2, 1, 4, 2, 1 };
/* KCMYcm color values */
@@ -586,58 +570,36 @@ CompressData(const unsigned char *line, /* I - Data to compress */
break;
}
/*
* Set the color if necessary...
*/
if (NumPlanes > 1)
{
if (plane > 3)
printf("\033(r%c%c%c%c", 2, 0, 1, ctable[plane]);
/* Set extended color */
else if (NumPlanes == 3)
printf("\033r%c", ctable[plane + 1]);
/* Set color */
else
printf("\033r%c", ctable[plane]); /* Set color */
}
/*
* Send a raster plane...
*/
putchar(0x0d); /* Move print head to left margin */
if (Model < EPSON_ICOLOR)
{
/*
* Do graphics the "old" way...
*/
if (NumPlanes > 1)
{
/*
* Set the color...
*/
if (plane > 3)
printf("\033(r%c%c%c%c", 2, 0, 1, ctable[plane] & 15);
/* Set extended color */
else if (NumPlanes == 3)
printf("\033r%c", ctable[plane + 1]);
/* Set color */
else
printf("\033r%c", ctable[plane]); /* Set color */
}
/*
* Send a raster plane...
*/
length *= 8;
printf("\033."); /* Raster graphics */
putchar(type);
putchar(ystep);
putchar(xstep);
putchar(1);
putchar(length);
putchar(length >> 8);
}
else
{
/*
* Do graphics the "new" way...
*/
printf("\033i");
putchar(ctable[plane]);
putchar(type);
putchar(1);
putchar(length & 255);
putchar(length >> 8);
putchar(1);
putchar(0);
}
length *= 8;
printf("\033."); /* Raster graphics */
putchar(type);
putchar(ystep);
putchar(xstep);
putchar(1);
putchar(length);
putchar(length >> 8);
pwrite(line_ptr, line_end - line_ptr);
fflush(stdout);
-4
Ver Arquivo
@@ -736,8 +736,6 @@ WriteProlog(const char *title, /* I - Title of job */
printf("%%%%BeginResource: font %s\n", fonts[i]);
/**** MRS: Need to use CUPS_FONTPATH env var! ****/
/**** Also look for Fontmap file or name.pfa, name.pfb... ****/
snprintf(filename, sizeof(filename), "%s/fonts/%s", datadir, fonts[i]);
if ((fp = fopen(filename, "rb")) != NULL)
{
@@ -765,8 +763,6 @@ WriteProlog(const char *title, /* I - Title of job */
{
if (Glyphs[Codes[i * 256 + ch]])
printf("/%s", Glyphs[Codes[i * 256 + ch]]);
else if (Codes[i * 256 + ch] > 255)
printf("/uni%04X", Codes[i * 256 + ch]);
else
printf("/.notdef");
+3 -1
Ver Arquivo
@@ -64,7 +64,9 @@ clean:
#
install:
$(INSTALL_DIR) $(DATADIR)/fonts
-$(MKDIR) $(DATADIR)/fonts
$(CHMOD) ugo+rx $(DATADIR)
$(CHMOD) ugo+rx $(DATADIR)/fonts
$(INSTALL_DATA) $(FONTS) $(DATADIR)/fonts
-251
Ver Arquivo
@@ -1,251 +0,0 @@
#!/bin/sh
#
# install - install a program, script, or datafile
# This comes from X11R5 (mit/util/scripts/install.sh).
#
# Copyright 1991 by the Massachusetts Institute of Technology
#
# Permission to use, copy, modify, distribute, and sell this software and its
# documentation for any purpose is hereby granted without fee, provided that
# the above copyright notice appear in all copies and that both that
# copyright notice and this permission notice appear in supporting
# documentation, and that the name of M.I.T. not be used in advertising or
# publicity pertaining to distribution of the software without specific,
# written prior permission. M.I.T. makes no representations about the
# suitability of this software for any purpose. It is provided "as is"
# without express or implied warranty.
#
# Calling this script install-sh is preferred over install.sh, to prevent
# `make' implicit rules from creating a file called install from it
# when there is no Makefile.
#
# This script is compatible with the BSD install script, but was written
# from scratch. It can only install one file at a time, a restriction
# shared with many OS's install programs.
# set DOITPROG to echo to test this script
# Don't use :- since 4.3BSD and earlier shells don't like it.
doit="${DOITPROG-}"
# put in absolute paths if you don't have them in your path; or use env. vars.
mvprog="${MVPROG-mv}"
cpprog="${CPPROG-cp}"
chmodprog="${CHMODPROG-chmod}"
chownprog="${CHOWNPROG-chown}"
chgrpprog="${CHGRPPROG-chgrp}"
stripprog="${STRIPPROG-strip}"
rmprog="${RMPROG-rm}"
mkdirprog="${MKDIRPROG-mkdir}"
transformbasename=""
transform_arg=""
instcmd="$mvprog"
chmodcmd="$chmodprog 0755"
chowncmd=""
chgrpcmd=""
stripcmd=""
rmcmd="$rmprog -f"
mvcmd="$mvprog"
src=""
dst=""
dir_arg=""
while [ x"$1" != x ]; do
case $1 in
-c) instcmd="$cpprog"
shift
continue;;
-d) dir_arg=true
shift
continue;;
-m) chmodcmd="$chmodprog $2"
shift
shift
continue;;
-o) chowncmd="$chownprog $2"
shift
shift
continue;;
-g) chgrpcmd="$chgrpprog $2"
shift
shift
continue;;
-s) stripcmd="$stripprog"
shift
continue;;
-t=*) transformarg=`echo $1 | sed 's/-t=//'`
shift
continue;;
-b=*) transformbasename=`echo $1 | sed 's/-b=//'`
shift
continue;;
*) if [ x"$src" = x ]
then
src=$1
else
# this colon is to work around a 386BSD /bin/sh bug
:
dst=$1
fi
shift
continue;;
esac
done
if [ x"$src" = x ]
then
echo "install: no input file specified"
exit 1
else
true
fi
if [ x"$dir_arg" != x ]; then
dst=$src
src=""
if [ -d $dst ]; then
instcmd=:
chmodcmd=""
else
instcmd=mkdir
fi
else
# Waiting for this to be detected by the "$instcmd $src $dsttmp" command
# might cause directories to be created, which would be especially bad
# if $src (and thus $dsttmp) contains '*'.
if [ -f $src -o -d $src ]
then
true
else
echo "install: $src does not exist"
exit 1
fi
if [ x"$dst" = x ]
then
echo "install: no destination specified"
exit 1
else
true
fi
# If destination is a directory, append the input filename; if your system
# does not like double slashes in filenames, you may need to add some logic
if [ -d $dst ]
then
dst="$dst"/`basename $src`
else
true
fi
fi
## this sed command emulates the dirname command
dstdir=`echo $dst | sed -e 's,[^/]*$,,;s,/$,,;s,^$,.,'`
# Make sure that the destination directory exists.
# this part is taken from Noah Friedman's mkinstalldirs script
# Skip lots of stat calls in the usual case.
if [ ! -d "$dstdir" ]; then
defaultIFS='
'
IFS="${IFS-${defaultIFS}}"
oIFS="${IFS}"
# Some sh's can't handle IFS=/ for some reason.
IFS='%'
set - `echo ${dstdir} | sed -e 's@/@%@g' -e 's@^%@/@'`
IFS="${oIFS}"
pathcomp=''
while [ $# -ne 0 ] ; do
pathcomp="${pathcomp}${1}"
shift
if [ ! -d "${pathcomp}" ] ;
then
$mkdirprog "${pathcomp}"
else
true
fi
pathcomp="${pathcomp}/"
done
fi
if [ x"$dir_arg" != x ]
then
$doit $instcmd $dst &&
if [ x"$chowncmd" != x ]; then $doit $chowncmd $dst; else true ; fi &&
if [ x"$chgrpcmd" != x ]; then $doit $chgrpcmd $dst; else true ; fi &&
if [ x"$stripcmd" != x ]; then $doit $stripcmd $dst; else true ; fi &&
if [ x"$chmodcmd" != x ]; then $doit $chmodcmd $dst; else true ; fi
else
# If we're going to rename the final executable, determine the name now.
if [ x"$transformarg" = x ]
then
dstfile=`basename $dst`
else
dstfile=`basename $dst $transformbasename |
sed $transformarg`$transformbasename
fi
# don't allow the sed command to completely eliminate the filename
if [ x"$dstfile" = x ]
then
dstfile=`basename $dst`
else
true
fi
# Make a temp file name in the proper directory.
dsttmp=$dstdir/#inst.$$#
# Move or copy the file name to the temp name
$doit $instcmd $src $dsttmp &&
trap "rm -f ${dsttmp}" 0 &&
# and set any options; do chmod last to preserve setuid bits
# If any of these fail, we abort the whole thing. If we want to
# ignore errors from any of these, just make sure not to ignore
# errors from the above "$doit $instcmd $src $dsttmp" command.
if [ x"$chowncmd" != x ]; then $doit $chowncmd $dsttmp; else true;fi &&
if [ x"$chgrpcmd" != x ]; then $doit $chgrpcmd $dsttmp; else true;fi &&
if [ x"$stripcmd" != x ]; then $doit $stripcmd $dsttmp; else true;fi &&
if [ x"$chmodcmd" != x ]; then $doit $chmodcmd $dsttmp; else true;fi &&
# Now rename the file to the real destination.
$doit $rmcmd -f $dstdir/$dstfile &&
$doit $mvcmd $dsttmp $dstdir/$dstfile
fi &&
exit 0
+6 -2
Ver Arquivo
@@ -50,9 +50,13 @@ clean:
#
install:
$(INSTALL_DIR) $(LOCALEDIR)
-$(MKDIR) $(LOCALEDIR)
$(CHMOD) ugo+rx $(LOCALEDIR)
for dir in $(LOCALES) ; do \
$(INSTALL_DIR) $(LOCALEDIR)/$$dir ; \
if test ! -d $(LOCALEDIR)/$$dir ; then \
$(MKDIR) $(LOCALEDIR)/$$dir ; \
$(CHMOD) ugo+rx $(LOCALEDIR)/$$dir ; \
fi ; \
$(INSTALL_DATA) $$dir/cups_$$dir $(LOCALEDIR)/$$dir ; \
done
+28 -27
Ver Arquivo
@@ -28,16 +28,16 @@ include ../Makedefs
# Man pages...
#
MAN1 = backend.man filter.man lp.man lpoptions.man lppasswd.man \
lpq.man lprm.man lpr.man lpstat.man
MAN1 = backend.man filter.man lp.man lpoptions.man lpq.man lprm.man \
lpr.man lpstat.man
MAN5 = classes.conf.man cupsd.conf.man mime.convs.man mime.types.man \
printers.conf.man
MAN8 = accept.man cups-lpd.man cups-polld.man cupsd.man enable.man \
lpadmin.man lpinfo.man lpmove.man lpc.man
CAT1 = $(MAN1:.man=.$(CAT1EXT))
CAT5 = $(MAN5:.man=.$(CAT5EXT))
CAT8 = $(MAN8:.man=.$(CAT8EXT))
CAT5 = $(MAN5:.man=.$(CAT1EXT))
CAT8 = $(MAN8:.man=.$(CAT1EXT))
#
@@ -60,42 +60,43 @@ clean:
#
install:
$(INSTALL_DIR) $(MANDIR)/man1
-$(MKDIR) $(MANDIR)/man1
-$(CHMOD) ugo+rx $(MANDIR)
-$(CHMOD) ugo+rx $(MANDIR)/man1
for file in $(MAN1); do \
$(INSTALL_MAN) $$file $(MANDIR)/man1/`basename $$file man`1; \
done
$(RM) cancel.1
$(LN) lp.1 cancel.1
$(INSTALL_MAN) cancel.1 $(MANDIR)/man1
$(INSTALL_DIR) $(MANDIR)/man5
$(RM) $(MANDIR)/man1/cancel.1
$(LN) lp.1 $(MANDIR)/man1/cancel.1
-$(MKDIR) $(MANDIR)/man5
-$(CHMOD) ugo+rx $(MANDIR)/man5
for file in $(MAN5); do \
$(INSTALL_MAN) $$file $(MANDIR)/man5/`basename $$file man`5; \
done
$(INSTALL_DIR) $(AMANDIR)/man$(MAN8EXT)
-$(MKDIR) $(AMANDIR)/man$(MAN8EXT)
-$(CHMOD) ugo+rx $(AMANDIR)/man$(MAN8EXT)
for file in $(MAN8); do \
$(INSTALL_MAN) $$file $(AMANDIR)/man$(MAN8EXT)/`basename $$file man`$(MAN8EXT); \
done
$(RM) reject.$(MAN8EXT)
$(LN) accept.$(MAN8EXT) reject.$(MAN8EXT)
$(INSTALL_MAN) reject.$(MAN8EXT) $(AMANDIR)/man$(MAN8EXT)
$(RM) $(AMANDIR)/man$(MAN8EXT)/reject.$(MAN8EXT)
$(LN) accept.$(MAN8EXT) $(AMANDIR)/man$(MAN8EXT)/reject.$(MAN8EXT)
$(RM) $(AMANDIR)/man$(MAN8EXT)/disable.$(MAN8EXT)
$(LN) enable.$(MAN8EXT) disable.$(MAN8EXT)
$(INSTALL_MAN) disable.$(MAN8EXT) $(AMANDIR)/man$(MAN8EXT)
$(INSTALL_DIR) $(MANDIR)/cat1
$(LN) enable.$(MAN8EXT) $(AMANDIR)/man$(MAN8EXT)/disable.$(MAN8EXT)
-$(MKDIR) $(MANDIR)/cat1
-$(CHMOD) ugo+rx $(MANDIR)/cat1
$(INSTALL_MAN) $(CAT1) $(MANDIR)/cat1
$(RM) cancel.$(CAT1EXT)
$(LN) lp.$(CAT1EXT) cancel.$(CAT1EXT)
$(INSTALL_MAN) cancel.$(CAT1EXT) $(MANDIR)/cat1
$(INSTALL_DIR) $(MANDIR)/cat5
$(RM) $(MANDIR)/cat1/cancel.$(CAT1EXT)
$(LN) lp.$(CAT1EXT) $(MANDIR)/cat1/cancel.$(CAT1EXT)
-$(MKDIR) $(MANDIR)/cat5
-$(CHMOD) ugo+rx $(MANDIR)/cat5
$(INSTALL_MAN) $(CAT5) $(MANDIR)/cat5
$(INSTALL_DIR) $(AMANDIR)/cat$(MAN8EXT)
-$(MKDIR) $(AMANDIR)/cat$(MAN8EXT)
-$(CHMOD) ugo+rx $(AMANDIR)/cat$(MAN8EXT)
$(INSTALL_MAN) $(CAT8) $(AMANDIR)/cat$(MAN8EXT)
$(RM) reject.$(CAT8EXT)
$(LN) accept.$(CAT8EXT) reject.$(CAT8EXT)
$(INSTALL_MAN) reject.$(CAT8EXT) $(AMANDIR)/cat$(MAN8EXT)
$(RM) disable.$(CAT8EXT)
$(LN) enable.$(CAT8EXT) disable.$(CAT8EXT)
$(INSTALL_MAN) disable.$(CAT8EXT) $(AMANDIR)/cat$(MAN8EXT)
$(RM) $(AMANDIR)/cat$(MAN8EXT)/reject.$(CAT8EXT)
$(LN) accept.$(CAT1EXT) $(AMANDIR)/cat$(MAN8EXT)/reject.$(CAT8EXT)
$(RM) $(AMANDIR)/cat$(MAN8EXT)/disable.$(CAT8EXT)
$(LN) enable.$(CAT1EXT) $(AMANDIR)/cat$(MAN8EXT)/disable.$(CAT8EXT)
#
+2 -17
Ver Arquivo
@@ -1,5 +1,5 @@
.\"
.\" "$Id: lpadmin.man 1770 2001-06-07 21:47:38Z mike $"
.\" "$Id: lpadmin.man 1522 2001-01-23 17:36:24Z mike $"
.\"
.\" lpadmin man page for the Common UNIX Printing System (CUPS).
.\"
@@ -84,21 +84,6 @@ directory.
Sets a PPD or server option for the printer. PPD options can be listed
using the \fI-l\fR option with the \fIlpoptions(1)\fR command.
.TP 5
\-o \fIjob-k-limit=value\fR
.br
Sets the kilobyte limit for per-user quotas. The value is an integer number
of kilobytes; one kilobyte is 1024 bytes.
.TP 5
\-o \fIjob-page-limit=value\fR
.br
Sets the page limit for per-user quotas. The value is the integer number of
pages that can be printed; double-sided pages are counted as two pages.
.TP 5
\-o \fIjob-quota-period=value\fR
.br
Sets the accounting period for per-user quotas. The value is an integer number
of seconds; 86,400 seconds are in one day.
.TP 5
\-r \fIclass\fR
.br
Removes the named \fIprinter\fR from \fIclass\fR. If the resulting class
@@ -151,5 +136,5 @@ http://localhost:631/documentation.html
.SH COPYRIGHT
Copyright 1993-2001 by Easy Software Products, All Rights Reserved.
.\"
.\" End of "$Id: lpadmin.man 1770 2001-06-07 21:47:38Z mike $".
.\" End of "$Id: lpadmin.man 1522 2001-01-23 17:36:24Z mike $".
.\"
-61
Ver Arquivo
@@ -1,61 +0,0 @@
.\"
.\" "$Id: lppasswd.man 1770 2001-06-07 21:47:38Z mike $"
.\"
.\" lpadmin man page for the Common UNIX Printing System (CUPS).
.\"
.\" Copyright 1997-2001 by Easy Software Products.
.\"
.\" These coded instructions, statements, and computer programs are the
.\" property of Easy Software Products and are protected by Federal
.\" copyright law. Distribution and use rights are outlined in the file
.\" "LICENSE.txt" which should have been included with this file. If this
.\" file is missing or damaged please contact Easy Software Products
.\" at:
.\"
.\" Attn: CUPS Licensing Information
.\" Easy Software Products
.\" 44141 Airport View Drive, Suite 204
.\" Hollywood, Maryland 20636-3111 USA
.\"
.\" Voice: (301) 373-9603
.\" EMail: cups-info@cups.org
.\" WWW: http://www.cups.org
.\"
.TH lppasswd 1 "Common UNIX Printing System" "7 June 2001" "Easy Software Products"
.SH NAME
lppasswd \- add, change, or delete digest passwords.
.SH SYNOPSIS
.B lppasswd
[ -a ] [ -g
.I groupname
] [ -x ] [
.I username
]
.SH DESCRIPTION
\fIlppasswd\fR adds, changes, or deletes passwords in the CUPS digest
password file, \fIpasswd.md5\fR. When run by a normal user, \fIlppasswd\fR
will prompt for the old and new passwords. When run by the super-user,
\fIlppasswd\fR can add new accounts (\fI-a username\fR), change existing
accounts (\fIusername\fR), or delete accounts (\fI-x username\fR) in the
digest password file. Digest usernames do not have to match local UNIX
usernames, but only UNIX usernames are supported by the CUPS client programs
(\fIlp(1)\fR, \fIlpr(1)\fR, etc.)
.LP
The \fI-g\fR option specifies a group other than the system group - "sys",
"system", or "root", depending on the operating system.
.SH SECURITY ISSUES
The \fIlppasswd\fR command is installed setuid to root. While every attempt
has been made to make it secure against exploits that could grant super-user
priviledges to unpriviledged users, paranoid system administrators may wish
to disable or change the ownership of the program to an unpriviledged
account.
.SH SEE ALSO
lp(1), lpr(1),
CUPS Software Administrators Manual,
CUPS Software Users Manual,
http://localhost:631/documentation.html
.SH COPYRIGHT
Copyright 1993-2001 by Easy Software Products, All Rights Reserved.
.\"
.\" End of "$Id: lppasswd.man 1770 2001-06-07 21:47:38Z mike $".
.\"
+4 -1
Ver Arquivo
@@ -43,7 +43,10 @@ clean:
#
install:
$(INSTALL_DIR) $(SERVERBIN)/filter
$(MKDIR) $(SERVERBIN)/filter
$(CHMOD) ugo+rx $(SERVERBIN)
$(CHMOD) ugo+rx $(SERVERBIN)/filter
$(RM) $(SERVERBIN)/filter/pdftops
$(INSTALL_BIN) pdftops $(SERVERBIN)/filter
+5 -3
Ver Arquivo
@@ -180,7 +180,11 @@ static const char *prolog[] = {
" sub 1 index length dup 0 ne { div } { pop pop 0 } ifelse",
" pdfWordSpacing 0 pdfTextMat dtransform 32",
" 4 3 roll pdfCharSpacing add 0 pdfTextMat dtransform",
#if 0 /* temporary fix until we can figure out why the width is wrong */
" 6 5 roll awidthshow",
#else
" 6 5 roll show pop pop pop pop pop",
#endif /* 0 */
" 0 pdfTextRise neg pdfTextMat dtransform rmoveto } def",
"/TJm { pdfFontSize 0.001 mul mul neg 0",
" pdfTextMat dtransform rmoveto } def",
@@ -619,8 +623,6 @@ void PSOutputDev::setupFont(GfxFont *font) {
break;
}
}
fprintf(stderr, "DEBUG: PDF font name = %s, psName = %s\n",
name->getCString(), psName ? psName : "(null)");
}
if (!psName) {
if (font->isFixedWidth())
@@ -671,7 +673,7 @@ void PSOutputDev::setupFont(GfxFont *font) {
writePS((i == 0) ? "[ " : " ");
for (j = 0; j < 8; ++j) {
charName = font->getCharName(i+j);
writePS("/%s", charName ? charName : (i + j) == 32 ? "space" : ".notdef");
writePS("/%s", charName ? charName : ".notdef");
}
writePS((i == 256-8) ? "]\n" : "\n");
}
+6 -18
Ver Arquivo
@@ -760,9 +760,7 @@ int ASCIIHexStream::lookChar() {
GString *ASCIIHexStream::getPSFilter(const char *indent) {
GString *s;
if (!(s = str->getPSFilter(indent))) {
return NULL;
}
s = str->getPSFilter(indent);
s->append(indent)->append("/ASCIIHexDecode filter\n");
return s;
}
@@ -840,9 +838,7 @@ int ASCII85Stream::lookChar() {
GString *ASCII85Stream::getPSFilter(const char *indent) {
GString *s;
if (!(s = str->getPSFilter(indent))) {
return NULL;
}
s = str->getPSFilter(indent);
s->append(indent)->append("/ASCII85Decode filter\n");
return s;
}
@@ -1159,9 +1155,7 @@ GString *LZWStream::getPSFilter(const char *indent) {
if (pred) {
return NULL;
}
if (!(s = str->getPSFilter(indent))) {
return NULL;
}
s = str->getPSFilter(indent);
s->append(indent)->append("/LZWDecode filter\n");
return s;
}
@@ -1195,9 +1189,7 @@ void RunLengthStream::reset() {
GString *RunLengthStream::getPSFilter(const char *indent) {
GString *s;
if (!(s = str->getPSFilter(indent))) {
return NULL;
}
s = str->getPSFilter(indent);
s->append(indent)->append("/RunLengthDecode filter\n");
return s;
}
@@ -1748,9 +1740,7 @@ GString *CCITTFaxStream::getPSFilter(const char *indent) {
GString *s;
char s1[50];
if (!(s = str->getPSFilter(indent))) {
return NULL;
}
s = str->getPSFilter(indent);
s->append(indent)->append("<< ");
if (encoding != 0) {
sprintf(s1, "/K %d ", encoding);
@@ -2742,9 +2732,7 @@ int DCTStream::read16() {
GString *DCTStream::getPSFilter(const char *indent) {
GString *s;
if (!(s = str->getPSFilter(indent))) {
return NULL;
}
s = str->getPSFilter(indent);
s->append(indent)->append("<< >> /DCTDecode filter\n");
return s;
}
+17 -8
Ver Arquivo
@@ -38,13 +38,6 @@
# include <cups/cups.h>
#endif // HAVE_LIBCUPS
#ifdef __sun
// Solaris doesn't define mkstemp()...
extern "C" {
extern int mkstemp(char *);
}
#endif // __sun
// Some systems don't define this, so just make it something reasonably
// large.
#ifndef PATH_MAX
@@ -457,7 +450,23 @@ time_t getModTime(const char *fileName) {
}
GBool openTempFile(GString **name, FILE **f, const char *mode, const char *ext) {
#if defined(VMS) || defined(__EMX__) || defined(WIN32) || defined(ACORN) || defined(MACOS)
#ifdef HAVE_LIBCUPS
char filename[1024]; // Name of temporary file...
int fd; // File descriptor...
(void)ext;
// Use the CUPS temporary file function on all platforms...
if ((fd = cupsTempFd(filename, sizeof(filename))) < 0)
return (gFalse);
// Make the file descriptor a FILE *, and copy the temp filename...
*f = fdopen(fd, mode);
*name = new GString(filename);
return (gTrue);
#elif defined(VMS) || defined(__EMX__) || defined(WIN32) || defined(ACORN) || defined(MACOS)
//---------- non-Unix ----------
char *s;
+1 -1
Ver Arquivo
@@ -181,7 +181,7 @@ int main(int argc, char *argv[]) {
// read config file
#ifdef HAVE_LIBCUPS
if ((server_root = getenv("CUPS_SERVERROOT")) != NULL) {
sprintf(tempfile, "%s/pdftops.conf", server_root);
sprintf(tempfile, "%s/xpdf.conf", server_root);
initParams(tempfile);
} else
#endif /* HAVE_LIBCUPS */

Alguns arquivos não foram exibidos porque demasiados arquivos foram alterados neste diff Mostrar Mais