]> git.ipfire.org Git - thirdparty/cups.git/commitdiff
Merge changes from CUPS 1.5svn-r9105.
authormsweet <msweet@a1ca3aef-8c08-0410-bb20-df032aa958be>
Mon, 12 Apr 2010 04:23:14 +0000 (04:23 +0000)
committermsweet <msweet@a1ca3aef-8c08-0410-bb20-df032aa958be>
Mon, 12 Apr 2010 04:23:14 +0000 (04:23 +0000)
git-svn-id: svn+ssh://src.apple.com/svn/cups/easysw/current@2070 a1ca3aef-8c08-0410-bb20-df032aa958be

51 files changed:
CHANGES-1.4.txt
Makedefs.in
Makefile
backend/Dependencies
berkeley/Dependencies
config-scripts/cups-common.m4
config-scripts/cups-defaults.m4
config-scripts/cups-scripting.m4
config-scripts/cups-ssl.m4
config.h.in
cups/Dependencies
cups/Makefile
cups/cups-private.h
cups/cups.h
cups/debug.c
cups/globals.c
cups/http-private.h
cups/http-support.c
cups/http.c
cups/language.c
cups/libcups_s.exp
cups/request.c
cups/string.c
cups/testarray.c
cups/testhttp.c
cups/testipp.c
cups/testppd.c
cups/testsnmp.c
cups/transcode.c
cups/usersys.c
cups/util.c
doc/de/index.html.in
driver/Makefile
filter/Dependencies
filter/Makefile
locale/Dependencies
locale/Makefile
ppdc/Dependencies
ppdc/Makefile
ppdc/sample.drv
scheduler/Dependencies
scheduler/ipp.c
scheduler/main.c
scheduler/process.c
scheduler/server.c
systemv/Dependencies
templates/de/header.tmpl.in
test/Dependencies
test/print-job-hold.test
test/print-job.test
vcnet/config.h

index 4f32dc5c5de0cd1edd9e2d4536bd054489394c82..70fe55b8792385a20db71843ccec97bd55541457 100644 (file)
@@ -4,6 +4,10 @@ CHANGES-1.4.txt
 CHANGES IN CUPS V1.4.4
 
        - Documentation updates (STR #3453, STR #3527, STR #3528, STR #3529)
+       - The GNU TLS and OpenSSL interfaces have been made thread-safe
+         (STR #3461)
+       - Fixed an IPP conformance issue with the scheduler's Send-Document
+         implementation (STR #3514)
        - Added additional validation checks for the 1284 device ID (STR #3534)
        - Fixed a problem with the RPM spec file (STR #3544)
        - The lpstat command did not limit the job list to the specified
index bb1e3dd4f63f229349b3a5ea105fa7ef20ae4774..21b5874925a48ae0e3cd8c3bd67744d3fad9c27b 100644 (file)
@@ -124,6 +124,7 @@ ARCHFLAGS   =       @ARCHFLAGS@
 ARFLAGS                =       @ARFLAGS@
 BACKLIBS       =       @BACKLIBS@
 BANNERTOPS     =       @BANNERTOPS@
+BUILDDIRS      =       @BUILDDIRS@
 CFLAGS         =       @CPPFLAGS@ @CFLAGS@
 COMMONLIBS     =       @LIBS@
 CUPSDLIBS      =       @CUPSDLIBS@
@@ -266,7 +267,7 @@ DBUSDIR             =       @DBUSDIR@
 
 .c.o:
        echo Compiling $<...
-       $(CC) $(ARCHFLAGS) $(OPTIM) $(ALL_CFLAGS) -c $<
+       $(CC) $(ARCHFLAGS) $(OPTIM) $(ALL_CFLAGS) -c -o $@ $<
 
 .c.32.o:
        echo Compiling 32-bit $<...
@@ -278,7 +279,7 @@ DBUSDIR             =       @DBUSDIR@
 
 .cxx.o:
        echo Compiling $<...
-       $(CXX) $(ARCHFLAGS) $(OPTIM) $(ALL_CXXFLAGS) -c $<
+       $(CXX) $(ARCHFLAGS) $(OPTIM) $(ALL_CXXFLAGS) -c -o $@ $<
 
 .man.1 .man.1m .man.3 .man.5 .man.7 .man.8:
        echo Linking $<...
index 2c3e7e9ffebf82832be1e8ab9f1d1f42b49fd8c6..96f9c53d6e4d60bd7eaa644d773bdede0efc0ca8 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -27,10 +27,7 @@ include Makedefs
 # Directories to make...
 #
 
-DIRS   =       cups filter backend berkeley cgi-bin driver locale man monitor \
-               notifier ppdc scheduler systemv test \
-               $(PHPDIR) \
-               conf data desktop doc examples $(FONTS) templates
+DIRS   =       cups test $(BUILDDIRS) $(PHPDIR) $(FONTS)
 
 
 #
index b4e2e6205a529f14c46dfa1fb36c059848db5aa1..e8d270afae41da0a697c8a609e90d75279e40223 100644 (file)
@@ -24,7 +24,8 @@ dnssd.o: ../cups/debug-private.h ../cups/language-private.h
 dnssd.o: ../cups/transcode.h ../cups/snmp-private.h ../cups/http.h
 dnssd.o: ../cups/string-private.h ../config.h ../cups/array.h
 pap.o: ../config.h ../cups/cups.h ../cups/backend.h ../cups/versioning.h
-pap.o: ../cups/sidechannel.h
+pap.o: ../cups/sidechannel.h ../cups/language-private.h ../cups/transcode.h
+pap.o: ../cups/language.h ../cups/array.h
 parallel.o: backend-private.h ../cups/backend.h ../cups/versioning.h
 parallel.o: ../cups/sidechannel.h ../cups/ppd-private.h ../cups/ppd.h
 parallel.o: ../cups/cups.h ../cups/file.h ../cups/ipp.h ../cups/language.h
@@ -67,6 +68,7 @@ test1284.o: ../cups/string-private.h ../cups/debug-private.h
 test1284.o: ../cups/ppd-private.h ../cups/http-private.h
 test1284.o: ../cups/md5-private.h ../cups/ipp-private.h ../cups/ipp.h
 test1284.o: ../cups/http.h ../cups/language-private.h
+test1284.o: ../cups/thread-private.h
 testbackend.o: ../cups/string-private.h ../config.h ../cups/cups.h
 testbackend.o: ../cups/sidechannel.h ../cups/versioning.h
 testsupplies.o: backend-private.h ../cups/backend.h ../cups/versioning.h
index 7a3341fb61f5adeb3aa88e10cef52be5e5fc32ac..297ddba7ffdd640c4b944177b73030ac46ecd7c8 100644 (file)
@@ -7,6 +7,7 @@ lpc.o: ../cups/debug-private.h ../cups/ppd-private.h ../cups/ppd.h
 lpc.o: ../cups/cups.h ../cups/pwg-private.h ../cups/http-private.h
 lpc.o: ../cups/http.h ../cups/md5-private.h ../cups/ipp-private.h
 lpc.o: ../cups/ipp.h ../cups/language-private.h ../cups/transcode.h
+lpc.o: ../cups/thread-private.h
 lpq.o: ../cups/cups-private.h ../cups/cups.h ../cups/file.h
 lpq.o: ../cups/versioning.h ../cups/ipp.h ../cups/http.h ../cups/language.h
 lpq.o: ../cups/array.h ../cups/string-private.h ../config.h
@@ -14,6 +15,7 @@ lpq.o: ../cups/debug-private.h ../cups/ppd-private.h ../cups/ppd.h
 lpq.o: ../cups/cups.h ../cups/pwg-private.h ../cups/http-private.h
 lpq.o: ../cups/http.h ../cups/md5-private.h ../cups/ipp-private.h
 lpq.o: ../cups/ipp.h ../cups/language-private.h ../cups/transcode.h
+lpq.o: ../cups/thread-private.h
 lpr.o: ../cups/cups-private.h ../cups/cups.h ../cups/file.h
 lpr.o: ../cups/versioning.h ../cups/ipp.h ../cups/http.h ../cups/language.h
 lpr.o: ../cups/array.h ../cups/string-private.h ../config.h
@@ -21,6 +23,7 @@ lpr.o: ../cups/debug-private.h ../cups/ppd-private.h ../cups/ppd.h
 lpr.o: ../cups/cups.h ../cups/pwg-private.h ../cups/http-private.h
 lpr.o: ../cups/http.h ../cups/md5-private.h ../cups/ipp-private.h
 lpr.o: ../cups/ipp.h ../cups/language-private.h ../cups/transcode.h
+lpr.o: ../cups/thread-private.h
 lprm.o: ../cups/cups-private.h ../cups/cups.h ../cups/file.h
 lprm.o: ../cups/versioning.h ../cups/ipp.h ../cups/http.h ../cups/language.h
 lprm.o: ../cups/array.h ../cups/string-private.h ../config.h
@@ -28,3 +31,4 @@ lprm.o: ../cups/debug-private.h ../cups/ppd-private.h ../cups/ppd.h
 lprm.o: ../cups/cups.h ../cups/pwg-private.h ../cups/http-private.h
 lprm.o: ../cups/http.h ../cups/md5-private.h ../cups/ipp-private.h
 lprm.o: ../cups/ipp.h ../cups/language-private.h ../cups/transcode.h
+lprm.o: ../cups/thread-private.h
index 3616619818e2c46f07a429281e4fe3b67853a273..ffdaec63d2b718b6e0963aa159bfa52805b9d854 100644 (file)
@@ -1,9 +1,9 @@
 dnl
 dnl "$Id: cups-common.m4 8781 2009-08-28 17:34:54Z mike $"
 dnl
-dnl   Common configuration stuff for the Common UNIX Printing System (CUPS).
+dnl   Common configuration stuff for CUPS.
 dnl
-dnl   Copyright 2007-2009 by Apple Inc.
+dnl   Copyright 2007-2010 by Apple Inc.
 dnl   Copyright 1997-2007 by Easy Software Products, all rights reserved.
 dnl
 dnl   These coded instructions, statements, and computer programs are the
@@ -22,9 +22,9 @@ AC_CONFIG_HEADER(config.h)
 dnl Version number information...
 CUPS_VERSION="1.5svn"
 CUPS_REVISION=""
-#if test -z "$CUPS_REVISION" -a -d .svn; then
-#      CUPS_REVISION="-r`svnversion . | awk -F: '{print $NF}' | sed -e '1,$s/[[a-zA-Z]]*//g'`"
-#fi
+if test -z "$CUPS_REVISION" -a -d .svn; then
+       CUPS_REVISION="-r`svnversion . | awk -F: '{print $NF}' | sed -e '1,$s/[[a-zA-Z]]*//g'`"
+fi
 CUPS_BUILD="cups-$CUPS_VERSION"
 
 AC_ARG_WITH(cups_build, [  --with-cups-build       set "cups-config --build" string ],
@@ -291,10 +291,14 @@ case $uname in
                 LIBS="-framework SystemConfiguration -framework CoreFoundation -framework Security $LIBS"
 
                dnl Check for framework headers...
+               AC_CHECK_HEADER(ApplicationServices/ApplicationServices.h,AC_DEFINE(HAVE_APPLICATIONSERVICES_H))
                AC_CHECK_HEADER(CoreFoundation/CoreFoundation.h,AC_DEFINE(HAVE_COREFOUNDATION_H))
                AC_CHECK_HEADER(CoreFoundation/CFPriv.h,AC_DEFINE(HAVE_CFPRIV_H))
                AC_CHECK_HEADER(CoreFoundation/CFBundlePriv.h,AC_DEFINE(HAVE_CFBUNDLEPRIV_H))
 
+               dnl Check for dynamic store function...
+               AC_CHECK_FUNCS(SCDynamicStoreCopyComputerName)
+
                dnl Check for the new membership functions in MacOSX 10.4...
                AC_CHECK_HEADER(membership.h,AC_DEFINE(HAVE_MEMBERSHIP_H))
                AC_CHECK_HEADER(membershipPriv.h,AC_DEFINE(HAVE_MEMBERSHIPPRIV_H))
@@ -348,6 +352,30 @@ AC_DEFINE_UNQUOTED(CUPS_DEFAULT_PRINTOPERATOR_AUTH, "$CUPS_DEFAULT_PRINTOPERATOR
 AC_SUBST(CUPS_SYSTEM_AUTHKEY)
 AC_SUBST(LEGACY_BACKENDS)
 
+dnl Check for build components
+COMPONENTS="all"
+
+AC_ARG_WITH(components, [  --with-components       set components to build:
+                           - "all" (default) builds everything
+                           - "core" builds libcups and ipptool],
+       COMPONENTS="$withval")
+
+case "$COMPONENTS" in
+       all)
+               BUILDDIRS="filter backend berkeley cgi-bin driver monitor notifier ppdc scheduler systemv conf data locale man doc examples templates"
+               ;;
+
+       core)
+               BUILDDIRS="data locale"
+               ;;
+
+       *)
+               AC_MSG_ERROR([Bad build component "$COMPONENT" specified!])
+               ;;
+esac
+
+AC_SUBST(BUILDDIRS)
+
 dnl
 dnl End of "$Id: cups-common.m4 8781 2009-08-28 17:34:54Z mike $".
 dnl
index 2864cbad4ef533f651087adb624ec4a90c9efc1f..24003f5a1d203f8ed58e5e896f22a3e59a7b1066 100644 (file)
@@ -1,10 +1,9 @@
 dnl
 dnl "$Id: cups-defaults.m4 7959 2008-09-17 19:30:58Z mike $"
 dnl
-dnl   Default cupsd configuration settings for the Common UNIX Printing System
-dnl   (CUPS).
+dnl   Default cupsd configuration settings for CUPS.
 dnl
-dnl   Copyright 2007-2009 by Apple Inc.
+dnl   Copyright 2007-2010 by Apple Inc.
 dnl   Copyright 2006-2007 by Easy Software Products, all rights reserved.
 dnl
 dnl   These coded instructions, statements, and computer programs are the
index a8960070ec9a35ceafa0d1fd22775f70a351e369..4bfb4e15a098453ea43ba455afdb321860869036 100644 (file)
@@ -1,9 +1,9 @@
 dnl
 dnl "$Id: cups-scripting.m4 7915 2008-09-07 22:18:29Z mike $"
 dnl
-dnl   Scripting configuration stuff for the Common UNIX Printing System (CUPS).
+dnl   Scripting configuration stuff for CUPS.
 dnl
-dnl   Copyright 2007-2008 by Apple Inc.
+dnl   Copyright 2007-2010 by Apple Inc.
 dnl   Copyright 1997-2006 by Easy Software Products, all rights reserved.
 dnl
 dnl   These coded instructions, statements, and computer programs are the
index b0139c78c255b31e185ea2a9ac80af4e46ae8d56..f8c8697558d8f3e6a54d516bd7c7dec6953a3b67 100644 (file)
@@ -61,12 +61,29 @@ if test x$enable_ssl != xno; then
     dnl Then look for GNU TLS...
     if test $have_ssl = 0 -a "x${enable_gnutls}" != "xno" -a "x$PKGCONFIG" != x; then
        AC_PATH_PROG(LIBGNUTLSCONFIG,libgnutls-config)
+       AC_PATH_PROG(LIBGCRYPTCONFIG,libgcrypt-config)
        if $PKGCONFIG --exists gnutls; then
            have_ssl=1
            SSLLIBS=`$PKGCONFIG --libs gnutls`
            SSLFLAGS=`$PKGCONFIG --cflags gnutls`
            AC_DEFINE(HAVE_SSL)
            AC_DEFINE(HAVE_GNUTLS)
+       elif "x$LIBGNUTLSCONFIG" != x; then
+           have_ssl=1
+           SSLLIBS=`$LIBGNUTLSCONFIG --libs`
+           SSLFLAGS=`$LIBGNUTLSCONFIG --cflags`
+           AC_DEFINE(HAVE_SSL)
+           AC_DEFINE(HAVE_GNUTLS)
+       fi
+
+       if test $have_ssl = 1; then
+            if $PKGCONFIG --exists gcrypt; then
+               SSLLIBS="$SSLLIBS `$PKGCONFIG --libs gcrypt`"
+               SSLFLAGS="$SSLFLAGS `$PKGCONFIG --cflags gcrypt`"
+           elif "x$LIBGCRYPTCONFIG" != x; then
+               SSLLIBS="$SSLLIBS `$LIBGCRYPTCONFIG --libs`"
+               SSLFLAGS="$SSLFLAGS `$LIBGCRYPTCONFIG --cflags`"
+           fi
        fi
     fi
 
index d6cf1234b032b3335b16aa4e396b305924bcc8af..e386560afc50b10cf7471e43b141f3b2e6c57ed4 100644 (file)
 
 #undef HAVE_LAUNCH_H
 #undef HAVE_LAUNCHD
-#define CUPS_DEFAULT_LAUNCHD_CONF ""
 
 
 /*
 #undef HAVE_CFBUNDLEPRIV_H
 
 
+/*
+ * Do we have ApplicationServices public headers?
+ */
+
+#undef HAVE_APPLICATIONSERVICES_H
+
+
+/*
+ * Do we have the SCDynamicStoreCopyComputerName function?
+ */
+
+#undef HAVE_SCDYNAMICSTORECOPYCOMPUTERNAME
+
+
 /*
  * Do we have MacOSX 10.4's mbr_XXX functions()?
  */
index 56639ae695ea792f0d28283928d7ffc1e8218216..822b97627a2a369b63558bfa086d7f94d1ef14ad 100644 (file)
@@ -4,130 +4,131 @@ adminutil.o: cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 adminutil.o: language.h array.h string-private.h ../config.h debug-private.h
 adminutil.o: ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 adminutil.o: ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-adminutil.o: language-private.h ../cups/transcode.h adminutil.h
+adminutil.o: language-private.h ../cups/transcode.h thread-private.h
+adminutil.o: adminutil.h
 array.o: string-private.h ../config.h debug-private.h array.h versioning.h
 attr.o: cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 attr.o: language.h array.h string-private.h ../config.h debug-private.h
 attr.o: ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 attr.o: ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-attr.o: language-private.h ../cups/transcode.h
+attr.o: language-private.h ../cups/transcode.h thread-private.h
 auth.o: cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 auth.o: language.h array.h string-private.h ../config.h debug-private.h
 auth.o: ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 auth.o: ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-auth.o: language-private.h ../cups/transcode.h
+auth.o: language-private.h ../cups/transcode.h thread-private.h
 backchannel.o: cups.h
 backend.o: cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 backend.o: language.h array.h string-private.h ../config.h debug-private.h
 backend.o: ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 backend.o: ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-backend.o: language-private.h ../cups/transcode.h backend.h
+backend.o: language-private.h ../cups/transcode.h thread-private.h backend.h
 conflicts.o: cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 conflicts.o: language.h array.h string-private.h ../config.h debug-private.h
 conflicts.o: ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 conflicts.o: ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-conflicts.o: language-private.h ../cups/transcode.h
+conflicts.o: language-private.h ../cups/transcode.h thread-private.h
 custom.o: cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 custom.o: language.h array.h string-private.h ../config.h debug-private.h
 custom.o: ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 custom.o: ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-custom.o: language-private.h ../cups/transcode.h
+custom.o: language-private.h ../cups/transcode.h thread-private.h
 debug.o: cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 debug.o: language.h array.h string-private.h ../config.h debug-private.h
 debug.o: ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 debug.o: ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-debug.o: language-private.h ../cups/transcode.h
+debug.o: language-private.h ../cups/transcode.h thread-private.h
 dest.o: cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 dest.o: language.h array.h string-private.h ../config.h debug-private.h
 dest.o: ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 dest.o: ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-dest.o: language-private.h ../cups/transcode.h
+dest.o: language-private.h ../cups/transcode.h thread-private.h
 dir.o: string-private.h ../config.h debug-private.h dir.h versioning.h
 emit.o: cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 emit.o: language.h array.h string-private.h ../config.h debug-private.h
 emit.o: ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 emit.o: ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-emit.o: language-private.h ../cups/transcode.h
+emit.o: language-private.h ../cups/transcode.h thread-private.h
 encode.o: cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 encode.o: language.h array.h string-private.h ../config.h debug-private.h
 encode.o: ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 encode.o: ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-encode.o: language-private.h ../cups/transcode.h
+encode.o: language-private.h ../cups/transcode.h thread-private.h
 file.o: file-private.h cups-private.h ../cups/cups.h file.h versioning.h
 file.o: ipp.h http.h language.h array.h string-private.h ../config.h
 file.o: debug-private.h ppd-private.h ../cups/ppd.h cups.h pwg-private.h
 file.o: http-private.h ../cups/http.h md5-private.h ipp-private.h
-file.o: ../cups/ipp.h language-private.h ../cups/transcode.h
+file.o: ../cups/ipp.h language-private.h ../cups/transcode.h thread-private.h
 getdevices.o: cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 getdevices.o: language.h array.h string-private.h ../config.h debug-private.h
 getdevices.o: ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 getdevices.o: ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-getdevices.o: language-private.h ../cups/transcode.h
+getdevices.o: language-private.h ../cups/transcode.h thread-private.h
 getifaddrs.o: http-private.h ../config.h ../cups/http.h md5-private.h
 getifaddrs.o: ipp-private.h ../cups/ipp.h
 getputfile.o: cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 getputfile.o: language.h array.h string-private.h ../config.h debug-private.h
 getputfile.o: ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 getputfile.o: ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-getputfile.o: language-private.h ../cups/transcode.h
+getputfile.o: language-private.h ../cups/transcode.h thread-private.h
 globals.o: cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 globals.o: language.h array.h string-private.h ../config.h debug-private.h
 globals.o: ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 globals.o: ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-globals.o: language-private.h ../cups/transcode.h
+globals.o: language-private.h ../cups/transcode.h thread-private.h
 http.o: cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 http.o: language.h array.h string-private.h ../config.h debug-private.h
 http.o: ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 http.o: ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-http.o: language-private.h ../cups/transcode.h
+http.o: language-private.h ../cups/transcode.h thread-private.h
 http-addr.o: cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 http-addr.o: language.h array.h string-private.h ../config.h debug-private.h
 http-addr.o: ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 http-addr.o: ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-http-addr.o: language-private.h ../cups/transcode.h
+http-addr.o: language-private.h ../cups/transcode.h thread-private.h
 http-addrlist.o: cups-private.h ../cups/cups.h file.h versioning.h ipp.h
 http-addrlist.o: http.h language.h array.h string-private.h ../config.h
 http-addrlist.o: debug-private.h ppd-private.h ../cups/ppd.h cups.h
 http-addrlist.o: pwg-private.h http-private.h ../cups/http.h md5-private.h
 http-addrlist.o: ipp-private.h ../cups/ipp.h language-private.h
-http-addrlist.o: ../cups/transcode.h
+http-addrlist.o: ../cups/transcode.h thread-private.h
 http-support.o: cups-private.h ../cups/cups.h file.h versioning.h ipp.h
 http-support.o: http.h language.h array.h string-private.h ../config.h
 http-support.o: debug-private.h ppd-private.h ../cups/ppd.h cups.h
 http-support.o: pwg-private.h http-private.h ../cups/http.h md5-private.h
 http-support.o: ipp-private.h ../cups/ipp.h language-private.h
-http-support.o: ../cups/transcode.h
+http-support.o: ../cups/transcode.h thread-private.h
 ipp.o: cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 ipp.o: language.h array.h string-private.h ../config.h debug-private.h
 ipp.o: ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 ipp.o: ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-ipp.o: language-private.h ../cups/transcode.h
+ipp.o: language-private.h ../cups/transcode.h thread-private.h
 ipp-support.o: cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 ipp-support.o: language.h array.h string-private.h ../config.h
 ipp-support.o: debug-private.h ppd-private.h ../cups/ppd.h cups.h
 ipp-support.o: pwg-private.h http-private.h ../cups/http.h md5-private.h
 ipp-support.o: ipp-private.h ../cups/ipp.h language-private.h
-ipp-support.o: ../cups/transcode.h
+ipp-support.o: ../cups/transcode.h thread-private.h
 langprintf.o: cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 langprintf.o: language.h array.h string-private.h ../config.h debug-private.h
 langprintf.o: ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 langprintf.o: ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-langprintf.o: language-private.h ../cups/transcode.h
+langprintf.o: language-private.h ../cups/transcode.h thread-private.h
 language.o: cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 language.o: language.h array.h string-private.h ../config.h debug-private.h
 language.o: ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 language.o: ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-language.o: language-private.h ../cups/transcode.h
+language.o: language-private.h ../cups/transcode.h thread-private.h
 localize.o: cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 localize.o: language.h array.h string-private.h ../config.h debug-private.h
 localize.o: ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 localize.o: ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-localize.o: language-private.h ../cups/transcode.h
+localize.o: language-private.h ../cups/transcode.h thread-private.h
 mark.o: cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 mark.o: language.h array.h string-private.h ../config.h debug-private.h
 mark.o: ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 mark.o: ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-mark.o: language-private.h ../cups/transcode.h
+mark.o: language-private.h ../cups/transcode.h thread-private.h
 md5.o: md5-private.h string-private.h ../config.h
 md5passwd.o: http-private.h ../config.h ../cups/http.h md5-private.h
 md5passwd.o: ipp-private.h ../cups/ipp.h string-private.h
@@ -135,7 +136,7 @@ notify.o: cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 notify.o: language.h array.h string-private.h ../config.h debug-private.h
 notify.o: ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 notify.o: ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-notify.o: language-private.h ../cups/transcode.h
+notify.o: language-private.h ../cups/transcode.h thread-private.h
 options.o: cups.h string-private.h ../config.h debug-private.h
 page.o: string-private.h ../config.h debug-private.h ppd.h cups.h array.h
 page.o: versioning.h file.h
@@ -143,56 +144,63 @@ ppd.o: cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 ppd.o: language.h array.h string-private.h ../config.h debug-private.h
 ppd.o: ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 ppd.o: ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-ppd.o: language-private.h ../cups/transcode.h
+ppd.o: language-private.h ../cups/transcode.h thread-private.h
 pwg-file.o: cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 pwg-file.o: language.h array.h string-private.h ../config.h debug-private.h
 pwg-file.o: ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 pwg-file.o: ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-pwg-file.o: language-private.h ../cups/transcode.h
+pwg-file.o: language-private.h ../cups/transcode.h thread-private.h
 pwg-media.o: cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 pwg-media.o: language.h array.h string-private.h ../config.h debug-private.h
 pwg-media.o: ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 pwg-media.o: ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-pwg-media.o: language-private.h ../cups/transcode.h
+pwg-media.o: language-private.h ../cups/transcode.h thread-private.h
 pwg-ppd.o: cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 pwg-ppd.o: language.h array.h string-private.h ../config.h debug-private.h
 pwg-ppd.o: ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 pwg-ppd.o: ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-pwg-ppd.o: language-private.h ../cups/transcode.h
+pwg-ppd.o: language-private.h ../cups/transcode.h thread-private.h
 request.o: cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 request.o: language.h array.h string-private.h ../config.h debug-private.h
 request.o: ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 request.o: ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-request.o: language-private.h ../cups/transcode.h
+request.o: language-private.h ../cups/transcode.h thread-private.h
 sidechannel.o: sidechannel.h versioning.h string-private.h ../config.h
 sidechannel.o: debug-private.h
 snmp.o: cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 snmp.o: language.h array.h string-private.h ../config.h debug-private.h
 snmp.o: ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 snmp.o: ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-snmp.o: language-private.h ../cups/transcode.h snmp-private.h
+snmp.o: language-private.h ../cups/transcode.h thread-private.h
+snmp.o: snmp-private.h
 snprintf.o: string-private.h ../config.h
-string.o: string-private.h ../config.h debug-private.h array.h versioning.h
+string.o: string-private.h ../config.h debug-private.h thread-private.h
+string.o: array.h versioning.h
 tempfile.o: cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 tempfile.o: language.h array.h string-private.h ../config.h debug-private.h
 tempfile.o: ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 tempfile.o: ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-tempfile.o: language-private.h ../cups/transcode.h
+tempfile.o: language-private.h ../cups/transcode.h thread-private.h
+thread.o: cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
+thread.o: language.h array.h string-private.h ../config.h debug-private.h
+thread.o: ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
+thread.o: ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
+thread.o: language-private.h ../cups/transcode.h thread-private.h
 transcode.o: cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 transcode.o: language.h array.h string-private.h ../config.h debug-private.h
 transcode.o: ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 transcode.o: ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-transcode.o: language-private.h ../cups/transcode.h
+transcode.o: language-private.h ../cups/transcode.h thread-private.h
 usersys.o: cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 usersys.o: language.h array.h string-private.h ../config.h debug-private.h
 usersys.o: ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 usersys.o: ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-usersys.o: language-private.h ../cups/transcode.h
+usersys.o: language-private.h ../cups/transcode.h thread-private.h
 util.o: cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 util.o: language.h array.h string-private.h ../config.h debug-private.h
 util.o: ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 util.o: ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-util.o: language-private.h ../cups/transcode.h
+util.o: language-private.h ../cups/transcode.h thread-private.h
 testadmin.o: adminutil.h cups.h string-private.h ../config.h
 testarray.o: string-private.h ../config.h debug-private.h array.h
 testarray.o: versioning.h dir.h
@@ -205,161 +213,163 @@ testhttp.o: string-private.h ../config.h http-private.h ../cups/http.h
 testhttp.o: md5-private.h ipp-private.h ../cups/ipp.h
 testi18n.o: string-private.h ../config.h language-private.h
 testi18n.o: ../cups/transcode.h language.h array.h versioning.h
-testipp.o: ../cups/file.h versioning.h string-private.h ../config.h
-testipp.o: ipp-private.h ../cups/ipp.h
+testipp.o: file.h versioning.h string-private.h ../config.h ipp-private.h
+testipp.o: ../cups/ipp.h
 testoptions.o: cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 testoptions.o: language.h array.h string-private.h ../config.h
 testoptions.o: debug-private.h ppd-private.h ../cups/ppd.h cups.h
 testoptions.o: pwg-private.h http-private.h ../cups/http.h md5-private.h
 testoptions.o: ipp-private.h ../cups/ipp.h language-private.h
-testoptions.o: ../cups/transcode.h
+testoptions.o: ../cups/transcode.h thread-private.h
 testlang.o: cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 testlang.o: language.h array.h string-private.h ../config.h debug-private.h
 testlang.o: ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 testlang.o: ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-testlang.o: language-private.h ../cups/transcode.h
+testlang.o: language-private.h ../cups/transcode.h thread-private.h
 testppd.o: cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 testppd.o: language.h array.h string-private.h ../config.h debug-private.h
 testppd.o: ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 testppd.o: ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-testppd.o: language-private.h ../cups/transcode.h
+testppd.o: language-private.h ../cups/transcode.h thread-private.h
 testpwg.o: ppd-private.h ../cups/ppd.h cups.h array.h versioning.h file.h
 testpwg.o: pwg-private.h ../cups/cups.h ipp.h http.h language.h
 testsnmp.o: cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 testsnmp.o: language.h array.h string-private.h ../config.h debug-private.h
 testsnmp.o: ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 testsnmp.o: ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-testsnmp.o: language-private.h ../cups/transcode.h snmp-private.h
+testsnmp.o: language-private.h ../cups/transcode.h thread-private.h
+testsnmp.o: snmp-private.h
 # DO NOT DELETE
 
 adminutil.32.o: adminutil.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 adminutil.32.o: adminutil.c  language.h array.h string-private.h ../config.h debug-private.h
 adminutil.32.o: adminutil.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 adminutil.32.o: adminutil.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-adminutil.32.o: adminutil.c  language-private.h ../cups/transcode.h adminutil.h
+adminutil.32.o: adminutil.c  language-private.h ../cups/transcode.h thread-private.h
+adminutil.32.o: adminutil.c  adminutil.h
 array.32.o: array.c  string-private.h ../config.h debug-private.h array.h versioning.h
 attr.32.o: attr.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 attr.32.o: attr.c  language.h array.h string-private.h ../config.h debug-private.h
 attr.32.o: attr.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 attr.32.o: attr.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-attr.32.o: attr.c  language-private.h ../cups/transcode.h
+attr.32.o: attr.c  language-private.h ../cups/transcode.h thread-private.h
 auth.32.o: auth.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 auth.32.o: auth.c  language.h array.h string-private.h ../config.h debug-private.h
 auth.32.o: auth.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 auth.32.o: auth.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-auth.32.o: auth.c  language-private.h ../cups/transcode.h
+auth.32.o: auth.c  language-private.h ../cups/transcode.h thread-private.h
 backchannel.32.o: backchannel.c  cups.h
 backend.32.o: backend.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 backend.32.o: backend.c  language.h array.h string-private.h ../config.h debug-private.h
 backend.32.o: backend.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 backend.32.o: backend.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-backend.32.o: backend.c  language-private.h ../cups/transcode.h backend.h
+backend.32.o: backend.c  language-private.h ../cups/transcode.h thread-private.h backend.h
 conflicts.32.o: conflicts.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 conflicts.32.o: conflicts.c  language.h array.h string-private.h ../config.h debug-private.h
 conflicts.32.o: conflicts.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 conflicts.32.o: conflicts.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-conflicts.32.o: conflicts.c  language-private.h ../cups/transcode.h
+conflicts.32.o: conflicts.c  language-private.h ../cups/transcode.h thread-private.h
 custom.32.o: custom.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 custom.32.o: custom.c  language.h array.h string-private.h ../config.h debug-private.h
 custom.32.o: custom.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 custom.32.o: custom.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-custom.32.o: custom.c  language-private.h ../cups/transcode.h
+custom.32.o: custom.c  language-private.h ../cups/transcode.h thread-private.h
 debug.32.o: debug.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 debug.32.o: debug.c  language.h array.h string-private.h ../config.h debug-private.h
 debug.32.o: debug.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 debug.32.o: debug.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-debug.32.o: debug.c  language-private.h ../cups/transcode.h
+debug.32.o: debug.c  language-private.h ../cups/transcode.h thread-private.h
 dest.32.o: dest.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 dest.32.o: dest.c  language.h array.h string-private.h ../config.h debug-private.h
 dest.32.o: dest.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 dest.32.o: dest.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-dest.32.o: dest.c  language-private.h ../cups/transcode.h
+dest.32.o: dest.c  language-private.h ../cups/transcode.h thread-private.h
 dir.32.o: dir.c  string-private.h ../config.h debug-private.h dir.h versioning.h
 emit.32.o: emit.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 emit.32.o: emit.c  language.h array.h string-private.h ../config.h debug-private.h
 emit.32.o: emit.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 emit.32.o: emit.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-emit.32.o: emit.c  language-private.h ../cups/transcode.h
+emit.32.o: emit.c  language-private.h ../cups/transcode.h thread-private.h
 encode.32.o: encode.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 encode.32.o: encode.c  language.h array.h string-private.h ../config.h debug-private.h
 encode.32.o: encode.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 encode.32.o: encode.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-encode.32.o: encode.c  language-private.h ../cups/transcode.h
+encode.32.o: encode.c  language-private.h ../cups/transcode.h thread-private.h
 file.32.o: file.c  file-private.h cups-private.h ../cups/cups.h file.h versioning.h
 file.32.o: file.c  ipp.h http.h language.h array.h string-private.h ../config.h
 file.32.o: file.c  debug-private.h ppd-private.h ../cups/ppd.h cups.h pwg-private.h
 file.32.o: file.c  http-private.h ../cups/http.h md5-private.h ipp-private.h
-file.32.o: file.c  ../cups/ipp.h language-private.h ../cups/transcode.h
+file.32.o: file.c  ../cups/ipp.h language-private.h ../cups/transcode.h thread-private.h
 getdevices.32.o: getdevices.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 getdevices.32.o: getdevices.c  language.h array.h string-private.h ../config.h debug-private.h
 getdevices.32.o: getdevices.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 getdevices.32.o: getdevices.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-getdevices.32.o: getdevices.c  language-private.h ../cups/transcode.h
+getdevices.32.o: getdevices.c  language-private.h ../cups/transcode.h thread-private.h
 getifaddrs.32.o: getifaddrs.c  http-private.h ../config.h ../cups/http.h md5-private.h
 getifaddrs.32.o: getifaddrs.c  ipp-private.h ../cups/ipp.h
 getputfile.32.o: getputfile.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 getputfile.32.o: getputfile.c  language.h array.h string-private.h ../config.h debug-private.h
 getputfile.32.o: getputfile.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 getputfile.32.o: getputfile.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-getputfile.32.o: getputfile.c  language-private.h ../cups/transcode.h
+getputfile.32.o: getputfile.c  language-private.h ../cups/transcode.h thread-private.h
 globals.32.o: globals.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 globals.32.o: globals.c  language.h array.h string-private.h ../config.h debug-private.h
 globals.32.o: globals.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 globals.32.o: globals.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-globals.32.o: globals.c  language-private.h ../cups/transcode.h
+globals.32.o: globals.c  language-private.h ../cups/transcode.h thread-private.h
 http.32.o: http.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 http.32.o: http.c  language.h array.h string-private.h ../config.h debug-private.h
 http.32.o: http.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 http.32.o: http.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-http.32.o: http.c  language-private.h ../cups/transcode.h
+http.32.o: http.c  language-private.h ../cups/transcode.h thread-private.h
 http-addr.32.o: http-addr.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 http-addr.32.o: http-addr.c  language.h array.h string-private.h ../config.h debug-private.h
 http-addr.32.o: http-addr.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 http-addr.32.o: http-addr.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-http-addr.32.o: http-addr.c  language-private.h ../cups/transcode.h
+http-addr.32.o: http-addr.c  language-private.h ../cups/transcode.h thread-private.h
 http-addrlist.32.o: http-addrlist.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h
 http-addrlist.32.o: http-addrlist.c  http.h language.h array.h string-private.h ../config.h
 http-addrlist.32.o: http-addrlist.c  debug-private.h ppd-private.h ../cups/ppd.h cups.h
 http-addrlist.32.o: http-addrlist.c  pwg-private.h http-private.h ../cups/http.h md5-private.h
 http-addrlist.32.o: http-addrlist.c  ipp-private.h ../cups/ipp.h language-private.h
-http-addrlist.32.o: http-addrlist.c  ../cups/transcode.h
+http-addrlist.32.o: http-addrlist.c  ../cups/transcode.h thread-private.h
 http-support.32.o: http-support.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h
 http-support.32.o: http-support.c  http.h language.h array.h string-private.h ../config.h
 http-support.32.o: http-support.c  debug-private.h ppd-private.h ../cups/ppd.h cups.h
 http-support.32.o: http-support.c  pwg-private.h http-private.h ../cups/http.h md5-private.h
 http-support.32.o: http-support.c  ipp-private.h ../cups/ipp.h language-private.h
-http-support.32.o: http-support.c  ../cups/transcode.h
+http-support.32.o: http-support.c  ../cups/transcode.h thread-private.h
 ipp.32.o: ipp.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 ipp.32.o: ipp.c  language.h array.h string-private.h ../config.h debug-private.h
 ipp.32.o: ipp.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 ipp.32.o: ipp.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-ipp.32.o: ipp.c  language-private.h ../cups/transcode.h
+ipp.32.o: ipp.c  language-private.h ../cups/transcode.h thread-private.h
 ipp-support.32.o: ipp-support.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 ipp-support.32.o: ipp-support.c  language.h array.h string-private.h ../config.h
 ipp-support.32.o: ipp-support.c  debug-private.h ppd-private.h ../cups/ppd.h cups.h
 ipp-support.32.o: ipp-support.c  pwg-private.h http-private.h ../cups/http.h md5-private.h
 ipp-support.32.o: ipp-support.c  ipp-private.h ../cups/ipp.h language-private.h
-ipp-support.32.o: ipp-support.c  ../cups/transcode.h
+ipp-support.32.o: ipp-support.c  ../cups/transcode.h thread-private.h
 langprintf.32.o: langprintf.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 langprintf.32.o: langprintf.c  language.h array.h string-private.h ../config.h debug-private.h
 langprintf.32.o: langprintf.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 langprintf.32.o: langprintf.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-langprintf.32.o: langprintf.c  language-private.h ../cups/transcode.h
+langprintf.32.o: langprintf.c  language-private.h ../cups/transcode.h thread-private.h
 language.32.o: language.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 language.32.o: language.c  language.h array.h string-private.h ../config.h debug-private.h
 language.32.o: language.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 language.32.o: language.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-language.32.o: language.c  language-private.h ../cups/transcode.h
+language.32.o: language.c  language-private.h ../cups/transcode.h thread-private.h
 localize.32.o: localize.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 localize.32.o: localize.c  language.h array.h string-private.h ../config.h debug-private.h
 localize.32.o: localize.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 localize.32.o: localize.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-localize.32.o: localize.c  language-private.h ../cups/transcode.h
+localize.32.o: localize.c  language-private.h ../cups/transcode.h thread-private.h
 mark.32.o: mark.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 mark.32.o: mark.c  language.h array.h string-private.h ../config.h debug-private.h
 mark.32.o: mark.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 mark.32.o: mark.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-mark.32.o: mark.c  language-private.h ../cups/transcode.h
+mark.32.o: mark.c  language-private.h ../cups/transcode.h thread-private.h
 md5.32.o: md5.c  md5-private.h string-private.h ../config.h
 md5passwd.32.o: md5passwd.c  http-private.h ../config.h ../cups/http.h md5-private.h
 md5passwd.32.o: md5passwd.c  ipp-private.h ../cups/ipp.h string-private.h
@@ -367,7 +377,7 @@ notify.32.o: notify.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h h
 notify.32.o: notify.c  language.h array.h string-private.h ../config.h debug-private.h
 notify.32.o: notify.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 notify.32.o: notify.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-notify.32.o: notify.c  language-private.h ../cups/transcode.h
+notify.32.o: notify.c  language-private.h ../cups/transcode.h thread-private.h
 options.32.o: options.c  cups.h string-private.h ../config.h debug-private.h
 page.32.o: page.c  string-private.h ../config.h debug-private.h ppd.h cups.h array.h
 page.32.o: page.c  versioning.h file.h
@@ -375,56 +385,63 @@ ppd.32.o: ppd.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 ppd.32.o: ppd.c  language.h array.h string-private.h ../config.h debug-private.h
 ppd.32.o: ppd.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 ppd.32.o: ppd.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-ppd.32.o: ppd.c  language-private.h ../cups/transcode.h
+ppd.32.o: ppd.c  language-private.h ../cups/transcode.h thread-private.h
 pwg-file.32.o: pwg-file.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 pwg-file.32.o: pwg-file.c  language.h array.h string-private.h ../config.h debug-private.h
 pwg-file.32.o: pwg-file.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 pwg-file.32.o: pwg-file.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-pwg-file.32.o: pwg-file.c  language-private.h ../cups/transcode.h
+pwg-file.32.o: pwg-file.c  language-private.h ../cups/transcode.h thread-private.h
 pwg-media.32.o: pwg-media.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 pwg-media.32.o: pwg-media.c  language.h array.h string-private.h ../config.h debug-private.h
 pwg-media.32.o: pwg-media.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 pwg-media.32.o: pwg-media.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-pwg-media.32.o: pwg-media.c  language-private.h ../cups/transcode.h
+pwg-media.32.o: pwg-media.c  language-private.h ../cups/transcode.h thread-private.h
 pwg-ppd.32.o: pwg-ppd.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 pwg-ppd.32.o: pwg-ppd.c  language.h array.h string-private.h ../config.h debug-private.h
 pwg-ppd.32.o: pwg-ppd.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 pwg-ppd.32.o: pwg-ppd.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-pwg-ppd.32.o: pwg-ppd.c  language-private.h ../cups/transcode.h
+pwg-ppd.32.o: pwg-ppd.c  language-private.h ../cups/transcode.h thread-private.h
 request.32.o: request.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 request.32.o: request.c  language.h array.h string-private.h ../config.h debug-private.h
 request.32.o: request.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 request.32.o: request.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-request.32.o: request.c  language-private.h ../cups/transcode.h
+request.32.o: request.c  language-private.h ../cups/transcode.h thread-private.h
 sidechannel.32.o: sidechannel.c  sidechannel.h versioning.h string-private.h ../config.h
 sidechannel.32.o: sidechannel.c  debug-private.h
 snmp.32.o: snmp.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 snmp.32.o: snmp.c  language.h array.h string-private.h ../config.h debug-private.h
 snmp.32.o: snmp.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 snmp.32.o: snmp.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-snmp.32.o: snmp.c  language-private.h ../cups/transcode.h snmp-private.h
+snmp.32.o: snmp.c  language-private.h ../cups/transcode.h thread-private.h
+snmp.32.o: snmp.c  snmp-private.h
 snprintf.32.o: snprintf.c  string-private.h ../config.h
-string.32.o: string.c  string-private.h ../config.h debug-private.h array.h versioning.h
+string.32.o: string.c  string-private.h ../config.h debug-private.h thread-private.h
+string.32.o: string.c  array.h versioning.h
 tempfile.32.o: tempfile.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 tempfile.32.o: tempfile.c  language.h array.h string-private.h ../config.h debug-private.h
 tempfile.32.o: tempfile.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 tempfile.32.o: tempfile.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-tempfile.32.o: tempfile.c  language-private.h ../cups/transcode.h
+tempfile.32.o: tempfile.c  language-private.h ../cups/transcode.h thread-private.h
+thread.32.o: thread.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
+thread.32.o: thread.c  language.h array.h string-private.h ../config.h debug-private.h
+thread.32.o: thread.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
+thread.32.o: thread.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
+thread.32.o: thread.c  language-private.h ../cups/transcode.h thread-private.h
 transcode.32.o: transcode.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 transcode.32.o: transcode.c  language.h array.h string-private.h ../config.h debug-private.h
 transcode.32.o: transcode.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 transcode.32.o: transcode.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-transcode.32.o: transcode.c  language-private.h ../cups/transcode.h
+transcode.32.o: transcode.c  language-private.h ../cups/transcode.h thread-private.h
 usersys.32.o: usersys.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 usersys.32.o: usersys.c  language.h array.h string-private.h ../config.h debug-private.h
 usersys.32.o: usersys.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 usersys.32.o: usersys.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-usersys.32.o: usersys.c  language-private.h ../cups/transcode.h
+usersys.32.o: usersys.c  language-private.h ../cups/transcode.h thread-private.h
 util.32.o: util.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 util.32.o: util.c  language.h array.h string-private.h ../config.h debug-private.h
 util.32.o: util.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 util.32.o: util.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-util.32.o: util.c  language-private.h ../cups/transcode.h
+util.32.o: util.c  language-private.h ../cups/transcode.h thread-private.h
 testadmin.32.o: testadmin.c  adminutil.h cups.h string-private.h ../config.h
 testarray.32.o: testarray.c  string-private.h ../config.h debug-private.h array.h
 testarray.32.o: testarray.c  versioning.h dir.h
@@ -437,161 +454,163 @@ testhttp.32.o: testhttp.c  string-private.h ../config.h http-private.h ../cups/h
 testhttp.32.o: testhttp.c  md5-private.h ipp-private.h ../cups/ipp.h
 testi18n.32.o: testi18n.c  string-private.h ../config.h language-private.h
 testi18n.32.o: testi18n.c  ../cups/transcode.h language.h array.h versioning.h
-testipp.32.o: testipp.c  ../cups/file.h versioning.h string-private.h ../config.h
-testipp.32.o: testipp.c  ipp-private.h ../cups/ipp.h
+testipp.32.o: testipp.c  file.h versioning.h string-private.h ../config.h ipp-private.h
+testipp.32.o: testipp.c  ../cups/ipp.h
 testoptions.32.o: testoptions.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 testoptions.32.o: testoptions.c  language.h array.h string-private.h ../config.h
 testoptions.32.o: testoptions.c  debug-private.h ppd-private.h ../cups/ppd.h cups.h
 testoptions.32.o: testoptions.c  pwg-private.h http-private.h ../cups/http.h md5-private.h
 testoptions.32.o: testoptions.c  ipp-private.h ../cups/ipp.h language-private.h
-testoptions.32.o: testoptions.c  ../cups/transcode.h
+testoptions.32.o: testoptions.c  ../cups/transcode.h thread-private.h
 testlang.32.o: testlang.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 testlang.32.o: testlang.c  language.h array.h string-private.h ../config.h debug-private.h
 testlang.32.o: testlang.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 testlang.32.o: testlang.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-testlang.32.o: testlang.c  language-private.h ../cups/transcode.h
+testlang.32.o: testlang.c  language-private.h ../cups/transcode.h thread-private.h
 testppd.32.o: testppd.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 testppd.32.o: testppd.c  language.h array.h string-private.h ../config.h debug-private.h
 testppd.32.o: testppd.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 testppd.32.o: testppd.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-testppd.32.o: testppd.c  language-private.h ../cups/transcode.h
+testppd.32.o: testppd.c  language-private.h ../cups/transcode.h thread-private.h
 testpwg.32.o: testpwg.c  ppd-private.h ../cups/ppd.h cups.h array.h versioning.h file.h
 testpwg.32.o: testpwg.c  pwg-private.h ../cups/cups.h ipp.h http.h language.h
 testsnmp.32.o: testsnmp.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 testsnmp.32.o: testsnmp.c  language.h array.h string-private.h ../config.h debug-private.h
 testsnmp.32.o: testsnmp.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 testsnmp.32.o: testsnmp.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-testsnmp.32.o: testsnmp.c  language-private.h ../cups/transcode.h snmp-private.h
+testsnmp.32.o: testsnmp.c  language-private.h ../cups/transcode.h thread-private.h
+testsnmp.32.o: testsnmp.c  snmp-private.h
 # DO NOT DELETE
 
 adminutil.64.o: adminutil.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 adminutil.64.o: adminutil.c  language.h array.h string-private.h ../config.h debug-private.h
 adminutil.64.o: adminutil.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 adminutil.64.o: adminutil.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-adminutil.64.o: adminutil.c  language-private.h ../cups/transcode.h adminutil.h
+adminutil.64.o: adminutil.c  language-private.h ../cups/transcode.h thread-private.h
+adminutil.64.o: adminutil.c  adminutil.h
 array.64.o: array.c  string-private.h ../config.h debug-private.h array.h versioning.h
 attr.64.o: attr.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 attr.64.o: attr.c  language.h array.h string-private.h ../config.h debug-private.h
 attr.64.o: attr.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 attr.64.o: attr.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-attr.64.o: attr.c  language-private.h ../cups/transcode.h
+attr.64.o: attr.c  language-private.h ../cups/transcode.h thread-private.h
 auth.64.o: auth.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 auth.64.o: auth.c  language.h array.h string-private.h ../config.h debug-private.h
 auth.64.o: auth.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 auth.64.o: auth.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-auth.64.o: auth.c  language-private.h ../cups/transcode.h
+auth.64.o: auth.c  language-private.h ../cups/transcode.h thread-private.h
 backchannel.64.o: backchannel.c  cups.h
 backend.64.o: backend.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 backend.64.o: backend.c  language.h array.h string-private.h ../config.h debug-private.h
 backend.64.o: backend.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 backend.64.o: backend.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-backend.64.o: backend.c  language-private.h ../cups/transcode.h backend.h
+backend.64.o: backend.c  language-private.h ../cups/transcode.h thread-private.h backend.h
 conflicts.64.o: conflicts.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 conflicts.64.o: conflicts.c  language.h array.h string-private.h ../config.h debug-private.h
 conflicts.64.o: conflicts.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 conflicts.64.o: conflicts.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-conflicts.64.o: conflicts.c  language-private.h ../cups/transcode.h
+conflicts.64.o: conflicts.c  language-private.h ../cups/transcode.h thread-private.h
 custom.64.o: custom.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 custom.64.o: custom.c  language.h array.h string-private.h ../config.h debug-private.h
 custom.64.o: custom.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 custom.64.o: custom.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-custom.64.o: custom.c  language-private.h ../cups/transcode.h
+custom.64.o: custom.c  language-private.h ../cups/transcode.h thread-private.h
 debug.64.o: debug.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 debug.64.o: debug.c  language.h array.h string-private.h ../config.h debug-private.h
 debug.64.o: debug.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 debug.64.o: debug.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-debug.64.o: debug.c  language-private.h ../cups/transcode.h
+debug.64.o: debug.c  language-private.h ../cups/transcode.h thread-private.h
 dest.64.o: dest.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 dest.64.o: dest.c  language.h array.h string-private.h ../config.h debug-private.h
 dest.64.o: dest.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 dest.64.o: dest.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-dest.64.o: dest.c  language-private.h ../cups/transcode.h
+dest.64.o: dest.c  language-private.h ../cups/transcode.h thread-private.h
 dir.64.o: dir.c  string-private.h ../config.h debug-private.h dir.h versioning.h
 emit.64.o: emit.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 emit.64.o: emit.c  language.h array.h string-private.h ../config.h debug-private.h
 emit.64.o: emit.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 emit.64.o: emit.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-emit.64.o: emit.c  language-private.h ../cups/transcode.h
+emit.64.o: emit.c  language-private.h ../cups/transcode.h thread-private.h
 encode.64.o: encode.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 encode.64.o: encode.c  language.h array.h string-private.h ../config.h debug-private.h
 encode.64.o: encode.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 encode.64.o: encode.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-encode.64.o: encode.c  language-private.h ../cups/transcode.h
+encode.64.o: encode.c  language-private.h ../cups/transcode.h thread-private.h
 file.64.o: file.c  file-private.h cups-private.h ../cups/cups.h file.h versioning.h
 file.64.o: file.c  ipp.h http.h language.h array.h string-private.h ../config.h
 file.64.o: file.c  debug-private.h ppd-private.h ../cups/ppd.h cups.h pwg-private.h
 file.64.o: file.c  http-private.h ../cups/http.h md5-private.h ipp-private.h
-file.64.o: file.c  ../cups/ipp.h language-private.h ../cups/transcode.h
+file.64.o: file.c  ../cups/ipp.h language-private.h ../cups/transcode.h thread-private.h
 getdevices.64.o: getdevices.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 getdevices.64.o: getdevices.c  language.h array.h string-private.h ../config.h debug-private.h
 getdevices.64.o: getdevices.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 getdevices.64.o: getdevices.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-getdevices.64.o: getdevices.c  language-private.h ../cups/transcode.h
+getdevices.64.o: getdevices.c  language-private.h ../cups/transcode.h thread-private.h
 getifaddrs.64.o: getifaddrs.c  http-private.h ../config.h ../cups/http.h md5-private.h
 getifaddrs.64.o: getifaddrs.c  ipp-private.h ../cups/ipp.h
 getputfile.64.o: getputfile.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 getputfile.64.o: getputfile.c  language.h array.h string-private.h ../config.h debug-private.h
 getputfile.64.o: getputfile.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 getputfile.64.o: getputfile.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-getputfile.64.o: getputfile.c  language-private.h ../cups/transcode.h
+getputfile.64.o: getputfile.c  language-private.h ../cups/transcode.h thread-private.h
 globals.64.o: globals.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 globals.64.o: globals.c  language.h array.h string-private.h ../config.h debug-private.h
 globals.64.o: globals.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 globals.64.o: globals.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-globals.64.o: globals.c  language-private.h ../cups/transcode.h
+globals.64.o: globals.c  language-private.h ../cups/transcode.h thread-private.h
 http.64.o: http.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 http.64.o: http.c  language.h array.h string-private.h ../config.h debug-private.h
 http.64.o: http.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 http.64.o: http.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-http.64.o: http.c  language-private.h ../cups/transcode.h
+http.64.o: http.c  language-private.h ../cups/transcode.h thread-private.h
 http-addr.64.o: http-addr.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 http-addr.64.o: http-addr.c  language.h array.h string-private.h ../config.h debug-private.h
 http-addr.64.o: http-addr.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 http-addr.64.o: http-addr.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-http-addr.64.o: http-addr.c  language-private.h ../cups/transcode.h
+http-addr.64.o: http-addr.c  language-private.h ../cups/transcode.h thread-private.h
 http-addrlist.64.o: http-addrlist.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h
 http-addrlist.64.o: http-addrlist.c  http.h language.h array.h string-private.h ../config.h
 http-addrlist.64.o: http-addrlist.c  debug-private.h ppd-private.h ../cups/ppd.h cups.h
 http-addrlist.64.o: http-addrlist.c  pwg-private.h http-private.h ../cups/http.h md5-private.h
 http-addrlist.64.o: http-addrlist.c  ipp-private.h ../cups/ipp.h language-private.h
-http-addrlist.64.o: http-addrlist.c  ../cups/transcode.h
+http-addrlist.64.o: http-addrlist.c  ../cups/transcode.h thread-private.h
 http-support.64.o: http-support.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h
 http-support.64.o: http-support.c  http.h language.h array.h string-private.h ../config.h
 http-support.64.o: http-support.c  debug-private.h ppd-private.h ../cups/ppd.h cups.h
 http-support.64.o: http-support.c  pwg-private.h http-private.h ../cups/http.h md5-private.h
 http-support.64.o: http-support.c  ipp-private.h ../cups/ipp.h language-private.h
-http-support.64.o: http-support.c  ../cups/transcode.h
+http-support.64.o: http-support.c  ../cups/transcode.h thread-private.h
 ipp.64.o: ipp.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 ipp.64.o: ipp.c  language.h array.h string-private.h ../config.h debug-private.h
 ipp.64.o: ipp.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 ipp.64.o: ipp.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-ipp.64.o: ipp.c  language-private.h ../cups/transcode.h
+ipp.64.o: ipp.c  language-private.h ../cups/transcode.h thread-private.h
 ipp-support.64.o: ipp-support.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 ipp-support.64.o: ipp-support.c  language.h array.h string-private.h ../config.h
 ipp-support.64.o: ipp-support.c  debug-private.h ppd-private.h ../cups/ppd.h cups.h
 ipp-support.64.o: ipp-support.c  pwg-private.h http-private.h ../cups/http.h md5-private.h
 ipp-support.64.o: ipp-support.c  ipp-private.h ../cups/ipp.h language-private.h
-ipp-support.64.o: ipp-support.c  ../cups/transcode.h
+ipp-support.64.o: ipp-support.c  ../cups/transcode.h thread-private.h
 langprintf.64.o: langprintf.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 langprintf.64.o: langprintf.c  language.h array.h string-private.h ../config.h debug-private.h
 langprintf.64.o: langprintf.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 langprintf.64.o: langprintf.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-langprintf.64.o: langprintf.c  language-private.h ../cups/transcode.h
+langprintf.64.o: langprintf.c  language-private.h ../cups/transcode.h thread-private.h
 language.64.o: language.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 language.64.o: language.c  language.h array.h string-private.h ../config.h debug-private.h
 language.64.o: language.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 language.64.o: language.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-language.64.o: language.c  language-private.h ../cups/transcode.h
+language.64.o: language.c  language-private.h ../cups/transcode.h thread-private.h
 localize.64.o: localize.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 localize.64.o: localize.c  language.h array.h string-private.h ../config.h debug-private.h
 localize.64.o: localize.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 localize.64.o: localize.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-localize.64.o: localize.c  language-private.h ../cups/transcode.h
+localize.64.o: localize.c  language-private.h ../cups/transcode.h thread-private.h
 mark.64.o: mark.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 mark.64.o: mark.c  language.h array.h string-private.h ../config.h debug-private.h
 mark.64.o: mark.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 mark.64.o: mark.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-mark.64.o: mark.c  language-private.h ../cups/transcode.h
+mark.64.o: mark.c  language-private.h ../cups/transcode.h thread-private.h
 md5.64.o: md5.c  md5-private.h string-private.h ../config.h
 md5passwd.64.o: md5passwd.c  http-private.h ../config.h ../cups/http.h md5-private.h
 md5passwd.64.o: md5passwd.c  ipp-private.h ../cups/ipp.h string-private.h
@@ -599,7 +618,7 @@ notify.64.o: notify.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h h
 notify.64.o: notify.c  language.h array.h string-private.h ../config.h debug-private.h
 notify.64.o: notify.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 notify.64.o: notify.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-notify.64.o: notify.c  language-private.h ../cups/transcode.h
+notify.64.o: notify.c  language-private.h ../cups/transcode.h thread-private.h
 options.64.o: options.c  cups.h string-private.h ../config.h debug-private.h
 page.64.o: page.c  string-private.h ../config.h debug-private.h ppd.h cups.h array.h
 page.64.o: page.c  versioning.h file.h
@@ -607,56 +626,63 @@ ppd.64.o: ppd.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 ppd.64.o: ppd.c  language.h array.h string-private.h ../config.h debug-private.h
 ppd.64.o: ppd.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 ppd.64.o: ppd.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-ppd.64.o: ppd.c  language-private.h ../cups/transcode.h
+ppd.64.o: ppd.c  language-private.h ../cups/transcode.h thread-private.h
 pwg-file.64.o: pwg-file.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 pwg-file.64.o: pwg-file.c  language.h array.h string-private.h ../config.h debug-private.h
 pwg-file.64.o: pwg-file.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 pwg-file.64.o: pwg-file.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-pwg-file.64.o: pwg-file.c  language-private.h ../cups/transcode.h
+pwg-file.64.o: pwg-file.c  language-private.h ../cups/transcode.h thread-private.h
 pwg-media.64.o: pwg-media.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 pwg-media.64.o: pwg-media.c  language.h array.h string-private.h ../config.h debug-private.h
 pwg-media.64.o: pwg-media.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 pwg-media.64.o: pwg-media.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-pwg-media.64.o: pwg-media.c  language-private.h ../cups/transcode.h
+pwg-media.64.o: pwg-media.c  language-private.h ../cups/transcode.h thread-private.h
 pwg-ppd.64.o: pwg-ppd.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 pwg-ppd.64.o: pwg-ppd.c  language.h array.h string-private.h ../config.h debug-private.h
 pwg-ppd.64.o: pwg-ppd.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 pwg-ppd.64.o: pwg-ppd.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-pwg-ppd.64.o: pwg-ppd.c  language-private.h ../cups/transcode.h
+pwg-ppd.64.o: pwg-ppd.c  language-private.h ../cups/transcode.h thread-private.h
 request.64.o: request.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 request.64.o: request.c  language.h array.h string-private.h ../config.h debug-private.h
 request.64.o: request.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 request.64.o: request.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-request.64.o: request.c  language-private.h ../cups/transcode.h
+request.64.o: request.c  language-private.h ../cups/transcode.h thread-private.h
 sidechannel.64.o: sidechannel.c  sidechannel.h versioning.h string-private.h ../config.h
 sidechannel.64.o: sidechannel.c  debug-private.h
 snmp.64.o: snmp.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 snmp.64.o: snmp.c  language.h array.h string-private.h ../config.h debug-private.h
 snmp.64.o: snmp.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 snmp.64.o: snmp.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-snmp.64.o: snmp.c  language-private.h ../cups/transcode.h snmp-private.h
+snmp.64.o: snmp.c  language-private.h ../cups/transcode.h thread-private.h
+snmp.64.o: snmp.c  snmp-private.h
 snprintf.64.o: snprintf.c  string-private.h ../config.h
-string.64.o: string.c  string-private.h ../config.h debug-private.h array.h versioning.h
+string.64.o: string.c  string-private.h ../config.h debug-private.h thread-private.h
+string.64.o: string.c  array.h versioning.h
 tempfile.64.o: tempfile.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 tempfile.64.o: tempfile.c  language.h array.h string-private.h ../config.h debug-private.h
 tempfile.64.o: tempfile.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 tempfile.64.o: tempfile.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-tempfile.64.o: tempfile.c  language-private.h ../cups/transcode.h
+tempfile.64.o: tempfile.c  language-private.h ../cups/transcode.h thread-private.h
+thread.64.o: thread.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
+thread.64.o: thread.c  language.h array.h string-private.h ../config.h debug-private.h
+thread.64.o: thread.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
+thread.64.o: thread.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
+thread.64.o: thread.c  language-private.h ../cups/transcode.h thread-private.h
 transcode.64.o: transcode.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 transcode.64.o: transcode.c  language.h array.h string-private.h ../config.h debug-private.h
 transcode.64.o: transcode.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 transcode.64.o: transcode.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-transcode.64.o: transcode.c  language-private.h ../cups/transcode.h
+transcode.64.o: transcode.c  language-private.h ../cups/transcode.h thread-private.h
 usersys.64.o: usersys.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 usersys.64.o: usersys.c  language.h array.h string-private.h ../config.h debug-private.h
 usersys.64.o: usersys.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 usersys.64.o: usersys.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-usersys.64.o: usersys.c  language-private.h ../cups/transcode.h
+usersys.64.o: usersys.c  language-private.h ../cups/transcode.h thread-private.h
 util.64.o: util.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 util.64.o: util.c  language.h array.h string-private.h ../config.h debug-private.h
 util.64.o: util.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 util.64.o: util.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-util.64.o: util.c  language-private.h ../cups/transcode.h
+util.64.o: util.c  language-private.h ../cups/transcode.h thread-private.h
 testadmin.64.o: testadmin.c  adminutil.h cups.h string-private.h ../config.h
 testarray.64.o: testarray.c  string-private.h ../config.h debug-private.h array.h
 testarray.64.o: testarray.c  versioning.h dir.h
@@ -669,28 +695,29 @@ testhttp.64.o: testhttp.c  string-private.h ../config.h http-private.h ../cups/h
 testhttp.64.o: testhttp.c  md5-private.h ipp-private.h ../cups/ipp.h
 testi18n.64.o: testi18n.c  string-private.h ../config.h language-private.h
 testi18n.64.o: testi18n.c  ../cups/transcode.h language.h array.h versioning.h
-testipp.64.o: testipp.c  ../cups/file.h versioning.h string-private.h ../config.h
-testipp.64.o: testipp.c  ipp-private.h ../cups/ipp.h
+testipp.64.o: testipp.c  file.h versioning.h string-private.h ../config.h ipp-private.h
+testipp.64.o: testipp.c  ../cups/ipp.h
 testoptions.64.o: testoptions.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 testoptions.64.o: testoptions.c  language.h array.h string-private.h ../config.h
 testoptions.64.o: testoptions.c  debug-private.h ppd-private.h ../cups/ppd.h cups.h
 testoptions.64.o: testoptions.c  pwg-private.h http-private.h ../cups/http.h md5-private.h
 testoptions.64.o: testoptions.c  ipp-private.h ../cups/ipp.h language-private.h
-testoptions.64.o: testoptions.c  ../cups/transcode.h
+testoptions.64.o: testoptions.c  ../cups/transcode.h thread-private.h
 testlang.64.o: testlang.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 testlang.64.o: testlang.c  language.h array.h string-private.h ../config.h debug-private.h
 testlang.64.o: testlang.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 testlang.64.o: testlang.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-testlang.64.o: testlang.c  language-private.h ../cups/transcode.h
+testlang.64.o: testlang.c  language-private.h ../cups/transcode.h thread-private.h
 testppd.64.o: testppd.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 testppd.64.o: testppd.c  language.h array.h string-private.h ../config.h debug-private.h
 testppd.64.o: testppd.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 testppd.64.o: testppd.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-testppd.64.o: testppd.c  language-private.h ../cups/transcode.h
+testppd.64.o: testppd.c  language-private.h ../cups/transcode.h thread-private.h
 testpwg.64.o: testpwg.c  ppd-private.h ../cups/ppd.h cups.h array.h versioning.h file.h
 testpwg.64.o: testpwg.c  pwg-private.h ../cups/cups.h ipp.h http.h language.h
 testsnmp.64.o: testsnmp.c  cups-private.h ../cups/cups.h file.h versioning.h ipp.h http.h
 testsnmp.64.o: testsnmp.c  language.h array.h string-private.h ../config.h debug-private.h
 testsnmp.64.o: testsnmp.c  ppd-private.h ../cups/ppd.h cups.h pwg-private.h http-private.h
 testsnmp.64.o: testsnmp.c  ../cups/http.h md5-private.h ipp-private.h ../cups/ipp.h
-testsnmp.64.o: testsnmp.c  language-private.h ../cups/transcode.h snmp-private.h
+testsnmp.64.o: testsnmp.c  language-private.h ../cups/transcode.h thread-private.h
+testsnmp.64.o: testsnmp.c  snmp-private.h
index b565c436a42b17083b61d9d07472926fced45650..cd557d57a1f4bec52df94b64a41a5002820417ee 100644 (file)
@@ -65,6 +65,7 @@ LIBOBJS       =       \
                snprintf.o \
                string.o \
                tempfile.o \
+               thread.o \
                transcode.o \
                usersys.o \
                util.o
@@ -121,7 +122,9 @@ HEADERSPRIV =       \
                ppd-private.h \
                pwg-private.h \
                snmp-private.h \
-               string-private.h
+               string-private.h \
+               thread-private.h
+
 
 #
 # Targets in this directory...
@@ -283,7 +286,7 @@ install64bit:
 
 uninstall: $(UNINSTALL32) $(UNINSTALL64)
        $(RM) $(LIBDIR)/libcups.2.dylib
-       $(RM) $(LIBDIR)/libcups.a
+       $(RM) $(LIBDIR)/$(LIBCUPSSTATIC)
        $(RM) $(LIBDIR)/libcups.dylib
        $(RM) $(LIBDIR)/libcups_s.a
        $(RM) $(LIBDIR)/libcups.sl
index 0a0e9e2bc91155e12fc7d059fad163cccd947327..051d3c4a907f82e9c3d55ea41a98e95c3c52b481 100644 (file)
@@ -30,9 +30,7 @@
 #  include "ipp-private.h"
 #  include "language-private.h"
 #  include "pwg-private.h"
-#  ifdef HAVE_PTHREAD_H
-#    include <pthread.h>
-#  endif /* HAVE_PTHREAD_H */
+#  include "thread-private.h"
 
 
 /*
@@ -150,7 +148,9 @@ extern http_t               *_cupsConnect(void);
 extern int             _cupsGet1284Values(const char *device_id,
                                           cups_option_t **values);
 extern const char      *_cupsGetPassword(const char *prompt);
+extern void            _cupsGlobalLock(void);
 extern _cups_globals_t *_cupsGlobals(void);
+extern void            _cupsGlobalUnlock(void);
 extern void            _cupsSetDefaults(void);
 extern void            _cupsSetError(ipp_status_t status, const char *message,
                                      int localize);
index 2a256c2e4b300f057a344431640b21f97d3359d8..d21f2bd40e14e20a0466b8c7030177ab6b0e8aab 100644 (file)
@@ -25,6 +25,7 @@
 #  include <sys/types.h>
 #  if defined(WIN32) && !defined(__CUPS_SSIZE_T_DEFINED)
 #    define __CUPS_SSIZE_T_DEFINED
+#    include <stddef.h>
 /* Windows does not support the ssize_t type, so map it to off_t... */
 typedef off_t ssize_t;                 /* @private@ */
 #  endif /* WIN32 && !__CUPS_SSIZE_T_DEFINED */
index fe170d707e9374dc704fad521685484fea175d19..c119c67418e0b752aa445349d4671267e68567f1 100644 (file)
@@ -25,6 +25,7 @@
  */
 
 #include "cups-private.h"
+#include "thread-private.h"
 #ifdef WIN32
 #  include <io.h>
 #else
@@ -57,10 +58,8 @@ static regex_t               *debug_filter = NULL;
                                        /* Filter expression for messages */
 #  endif /* !WIN32 */
 static int             debug_init = 0; /* Did we initialize debugging? */
-#  ifdef HAVE_PTHREAD_H
-static pthread_mutex_t debug_mutex = PTHREAD_MUTEX_INITIALIZER;
+static _cups_mutex_t   debug_mutex = _CUPS_MUTEX_INITIALIZER;
                                        /* Mutex to control initialization */
-#  endif /* HAVE_PTHREAD_H */
 
 
 /*
@@ -244,11 +243,11 @@ debug_vsnprintf(char       *buffer,       /* O - Output buffer */
            if ((width + 2) > sizeof(temp))
              break;
 
-#ifdef HAVE_LONG_LONG
+#  ifdef HAVE_LONG_LONG
             if (size == 'L')
              sprintf(temp, tformat, va_arg(ap, long long));
            else
-#endif /* HAVE_LONG_LONG */
+#  endif /* HAVE_LONG_LONG */
             if (size == 'l')
              sprintf(temp, tformat, va_arg(ap, long));
            else
@@ -411,7 +410,7 @@ _cups_debug_printf(const char *format,      /* I - Printf-style format string */
                        *cups_debug_level,
                                        /* CUPS_DEBUG_LEVEL environment variable */
                        *cups_debug_log;/* CUPS_DEBUG_LOG environment variable */
-                       
+
 
  /*
   * See if we need to do any logging...
@@ -424,7 +423,7 @@ _cups_debug_printf(const char *format,      /* I - Printf-style format string */
     * thread already did it...
     */
 
-    pthread_mutex_lock(&debug_mutex);
+    _cupsMutexLock(&debug_mutex);
 
     if (!debug_init)
     {
@@ -462,7 +461,7 @@ _cups_debug_printf(const char *format,      /* I - Printf-style format string */
       debug_init = 1;
     }
 
-    pthread_mutex_unlock(&debug_mutex);
+    _cupsMutexUnlock(&debug_mutex);
   }
 
   if (_cups_debug_fd < 0)
@@ -484,9 +483,9 @@ _cups_debug_printf(const char *format,      /* I - Printf-style format string */
   {
     int        result;                         /* Filter result */
 
-    pthread_mutex_lock(&debug_mutex);
+    _cupsMutexLock(&debug_mutex);
     result = regexec(debug_filter, format, 0, NULL, 0);
-    pthread_mutex_unlock(&debug_mutex);
+    _cupsMutexUnlock(&debug_mutex);
 
     if (result)
       return;
@@ -538,12 +537,6 @@ _cups_debug_puts(const char *s)            /* I - String to output */
 
   _cups_debug_printf(format, s);
 }
-
-
-#elif defined(__APPLE__)
-/* Mac OS X needs these stubbed since we reference them in the libcups.exp file */
-void   _cups_debug_printf(const char *format, ...) {}
-void   _cups_debug_puts(const char *s) {}
 #endif /* DEBUG */
 
 
index b21924a4197c2e73c3cc9845386706ab42bc287a..00a73691cfb5eb8237ee3707b6d9f8b38112f5de 100644 (file)
  *
  * Contents:
  *
- *   _cupsGlobals()      - Return a pointer to thread local storage.
- *   cups_env_init()      - Initialize environment variables.
- *   globals_init()       - Initialize globals once.
- *   globals_destructor() - Free memory allocated by _cupsGlobals().
+ *   _cupsGlobalLock()    - Lock the global mutex.
+ *   _cupsGlobals()       - Return a pointer to thread local storage
+ *   _cupsGlobalUnlock()  - Unlock the global mutex.
+ *   DllMain()            - Main entry for library.
+ *   cups_globals_alloc() - Allocate and initialize global data.
+ *   cups_globals_free()  - Free global data.
+ *   cups_globals_init()  - Initialize environment variables.
  */
 
 /*
 
 
 /*
- * 'cups_env_init()' - Initialize environment variables.
+ * Local globals...
  */
 
-static void
-cups_env_init(_cups_globals_t *g)      /* I - Global data */
-{
-#ifdef WIN32
-  HKEY         key;                    /* Registry key */
-  DWORD                size;                   /* Size of string */
-  static char  installdir[1024],       /* Install directory */
-               confdir[1024],          /* Server root directory */
-               localedir[1024];        /* Locale directory */
 
+static _cups_threadkey_t cups_globals_key = _CUPS_THREADKEY_INITIALIZER;
+                                       /* Thread local storage key */
+#ifdef HAVE_PTHREAD_H
+static pthread_once_t  cups_globals_key_once = PTHREAD_ONCE_INIT;
+                                       /* One-time initialization object */
+#endif /* HAVE_PTHREAD_H */
+static _cups_mutex_t   cups_global_mutex = _CUPS_MUTEX_INITIALIZER;
+                                       /* Global critical section */
 
- /*
-  * Open the registry...
-  */
 
-  strcpy(installdir, "C:/Program Files/cups.org");
+/*
+ * Local functions...
+ */
 
-  if (!RegOpenKeyEx(HKEY_LOCAL_MACHINE, "SOFTWARE\\cups.org", 0, KEY_READ,
-                    &key))
-  {
-   /*
-    * Grab the installation directory...
-    */
+static _cups_globals_t *cups_globals_alloc(void);
+static void            cups_globals_free(_cups_globals_t *g);
+#ifdef HAVE_PTHREAD_H
+static void            cups_globals_init(void);
+#endif /* HAVE_PTHREAD_H */
 
-    size = sizeof(installdir);
-    RegQueryValueEx(key, "installdir", NULL, NULL, installdir, &size);
-    RegCloseKey(key);
-  }
 
-  snprintf(confdir, sizeof(confdir), "%s/conf", installdir);
-  snprintf(localedir, sizeof(localedir), "%s/locale", installdir);
+/*
+ * '_cupsGlobalLock()' - Lock the global mutex.
+ */
 
-  if ((g->cups_datadir = getenv("CUPS_DATADIR")) == NULL)
-    g->cups_datadir = installdir;
+void
+_cupsGlobalLock(void)
+{
+#ifdef HAVE_PTHREAD_H
+  pthread_mutex_lock(&cups_global_mutex);
+#elif defined(WIN32)
+  EnterCriticalSection(&cups_global_mutex->m_criticalSection);
+#endif /* HAVE_PTHREAD_H */
+}
 
-  if ((g->cups_serverbin = getenv("CUPS_SERVERBIN")) == NULL)
-    g->cups_serverbin = installdir;
 
-  if ((g->cups_serverroot = getenv("CUPS_SERVERROOT")) == NULL)
-    g->cups_serverroot = confdir;
+/*
+ * '_cupsGlobals()' - Return a pointer to thread local storage
+ */
 
-  if ((g->cups_statedir = getenv("CUPS_STATEDIR")) == NULL)
-    g->cups_statedir = confdir;
+_cups_globals_t *                      /* O - Pointer to global data */
+_cupsGlobals(void)
+{
+  _cups_globals_t *cg;                 /* Pointer to global data */
 
-  if ((g->localedir = getenv("LOCALEDIR")) == NULL)
-    g->localedir = localedir;
 
-#else
-#  ifdef HAVE_GETEUID
-  if ((geteuid() != getuid() && getuid()) || getegid() != getgid())
-#  else
-  if (!getuid())
-#  endif /* HAVE_GETEUID */
+#ifdef HAVE_PTHREAD_H
+ /*
+  * Initialize the global data exactly once...
+  */
+
+  pthread_once(&cups_globals_key_once, cups_globals_init);
+#endif /* HAVE_PTHREAD_H */
+
+ /*
+  * See if we have allocated the data yet...
+  */
+
+  if ((cg = (_cups_globals_t *)_cupsThreadGetData(cups_globals_key)) == NULL)
   {
    /*
-    * When running setuid/setgid, don't allow environment variables to override
-    * the directories...
+    * No, allocate memory as set the pointer for the key...
     */
 
-    g->cups_datadir    = CUPS_DATADIR;
-    g->cups_serverbin  = CUPS_SERVERBIN;
-    g->cups_serverroot = CUPS_SERVERROOT;
-    g->cups_statedir   = CUPS_STATEDIR;
-    g->localedir       = CUPS_LOCALEDIR;
+    if ((cg = cups_globals_alloc()) != NULL)
+      _cupsThreadSetData(cups_globals_key, cg);
   }
-  else
-  {
-   /*
-    * Allow directories to be overridden by environment variables.
-    */
 
-    if ((g->cups_datadir = getenv("CUPS_DATADIR")) == NULL)
-      g->cups_datadir = CUPS_DATADIR;
+ /*
+  * Return the pointer to the data...
+  */
 
-    if ((g->cups_serverbin = getenv("CUPS_SERVERBIN")) == NULL)
-      g->cups_serverbin = CUPS_SERVERBIN;
+  return (cg);
+}
 
-    if ((g->cups_serverroot = getenv("CUPS_SERVERROOT")) == NULL)
-      g->cups_serverroot = CUPS_SERVERROOT;
 
-    if ((g->cups_statedir = getenv("CUPS_STATEDIR")) == NULL)
-      g->cups_statedir = CUPS_STATEDIR;
+/*
+ * '_cupsGlobalUnlock()' - Unlock the global mutex.
+ */
 
-    if ((g->localedir = getenv("LOCALEDIR")) == NULL)
-      g->localedir = CUPS_LOCALEDIR;
-  }
-#endif /* WIN32 */
+void
+_cupsGlobalUnlock(void)
+{
+#ifdef HAVE_PTHREAD_H
+  pthread_mutex_unlock(&cups_global_mutex);
+#elif defined(WIN32)
+  LeaveCriticalSection(&cups_global_mutex->m_criticalSection);
+#endif /* HAVE_PTHREAD_H */
 }
 
 
-#ifdef HAVE_PTHREAD_H
+#ifdef WIN32
 /*
- * Implement per-thread globals...
+ * 'DllMain()' - Main entry for library.
  */
 
-/*
- * Local globals...
- */
+BOOL WINAPI                            /* O - Success/failure */
+DllMain(HINSTANCE hinst,               /* I - DLL module handle */
+        DWORD     reason,              /* I - Reason */
+        LPVOID    reserved)            /* I - Unused */
+{
+  _cups_globals_t *cg;                 /* Global data */
 
-static pthread_key_t   globals_key = -1;
-                                       /* Thread local storage key */
-static pthread_once_t  globals_key_once = PTHREAD_ONCE_INIT;
-                                       /* One-time initialization object */
 
+  (void)hinst;
+  (void)reserved;
 
-/*
- * Local functions...
- */
+  switch (reason)
+  {
+    case DLL_PROCESS_ATTACH :          /* Called on library initialization */
+        InitializeCriticalSection(&cups_global_lock);
+
+        if ((cups_globals_key = TlsAlloc()) == TLS_OUT_OF_INDEXES)
+          return (FALSE);
+        break;
+
+    case DLL_THREAD_DETACH :           /* Called when a thread terminates */
+        if ((cg = (_cups_globals_t *)TlsGetValue(cups_globals_key)) != NULL)
+          cups_globals_free(cg);
+        break;
+
+    case DLL_PROCESS_DETACH :          /* Called when library is unloaded */
+        if ((cg = (_cups_globals_t *)TlsGetValue(cups_globals_key)) != NULL)
+          cups_globals_free(cg);
 
-static void    globals_init();
-static void    globals_destructor(void *value);
+        TlsFree(cups_globals_key);
+        DeleteCriticalSection(&cups_global_lock);
+        break;
+
+    default:
+        break;
+  }
+
+  return (TRUE);
+}
+#endif /* WIN32 */
 
 
 /*
- * '_cupsGlobals()' - Return a pointer to thread local storage
+ * 'cups_globals_alloc()' - Allocate and initialize global data.
  */
 
-_cups_globals_t *                      /* O - Pointer to global data */
-_cupsGlobals(void)
+static _cups_globals_t *               /* O - Pointer to global data */
+cups_globals_alloc(void)
 {
-  _cups_globals_t *globals;            /* Pointer to global data */
+  _cups_globals_t *cg = malloc(sizeof(_cups_globals_t));
+                                       /* Pointer to global data */
+#ifdef WIN32
+  HKEY         key;                    /* Registry key */
+  DWORD                size;                   /* Size of string */
+  static char  installdir[1024],       /* Install directory */
+               confdir[1024],          /* Server root directory */
+               localedir[1024];        /* Locale directory */
+#endif /* WIN32 */
+
 
+  if (!cg)
+    return (NULL);
 
  /*
-  * Initialize the global data exactly once...
+  * Clear the global storage and set the default encryption and password
+  * callback values...
   */
 
-  pthread_once(&globals_key_once, globals_init);
+  memset(cg, 0, sizeof(_cups_globals_t));
+  cg->encryption  = (http_encryption_t)-1;
+  cg->password_cb = (cups_password_cb2_t)_cupsGetPassword;
 
  /*
-  * See if we have allocated the data yet...
+  * Then set directories as appropriate...
+  */
+
+#ifdef WIN32
+ /*
+  * Open the registry...
   */
 
-  if ((globals = (_cups_globals_t *)pthread_getspecific(globals_key)) == NULL)
+  strcpy(installdir, "C:/Program Files/cups.org");
+
+  if (!RegOpenKeyEx(HKEY_LOCAL_MACHINE, "SOFTWARE\\cups.org", 0, KEY_READ,
+                    &key))
   {
    /*
-    * No, allocate memory as set the pointer for the key...
+    * Grab the installation directory...
     */
 
-    globals = calloc(1, sizeof(_cups_globals_t));
-    pthread_setspecific(globals_key, globals);
+    size = sizeof(installdir);
+    RegQueryValueEx(key, "installdir", NULL, NULL, installdir, &size);
+    RegCloseKey(key);
+  }
+
+  snprintf(confdir, sizeof(confdir), "%s/conf", installdir);
+  snprintf(localedir, sizeof(localedir), "%s/locale", installdir);
+
+  if ((cg->cups_datadir = getenv("CUPS_DATADIR")) == NULL)
+    cg->cups_datadir = installdir;
 
+  if ((cg->cups_serverbin = getenv("CUPS_SERVERBIN")) == NULL)
+    cg->cups_serverbin = installdir;
+
+  if ((cg->cups_serverroot = getenv("CUPS_SERVERROOT")) == NULL)
+    cg->cups_serverroot = confdir;
+
+  if ((cg->cups_statedir = getenv("CUPS_STATEDIR")) == NULL)
+    cg->cups_statedir = confdir;
+
+  if ((cg->localedir = getenv("LOCALEDIR")) == NULL)
+    cg->localedir = localedir;
+
+#else
+#  ifdef HAVE_GETEUID
+  if ((geteuid() != getuid() && getuid()) || getegid() != getgid())
+#  else
+  if (!getuid())
+#  endif /* HAVE_GETEUID */
+  {
    /*
-    * Initialize variables that have non-zero values
+    * When running setuid/setgid, don't allow environment variables to override
+    * the directories...
     */
 
-    globals->encryption  = (http_encryption_t)-1;
-    globals->password_cb = (cups_password_cb2_t)_cupsGetPassword;
-
-    cups_env_init(globals);
+    cg->cups_datadir    = CUPS_DATADIR;
+    cg->cups_serverbin  = CUPS_SERVERBIN;
+    cg->cups_serverroot = CUPS_SERVERROOT;
+    cg->cups_statedir   = CUPS_STATEDIR;
+    cg->localedir       = CUPS_LOCALEDIR;
   }
+  else
+  {
+   /*
+    * Allow directories to be overridden by environment variables.
+    */
 
- /*
-  * Return the pointer to the data...
-  */
+    if ((cg->cups_datadir = getenv("CUPS_DATADIR")) == NULL)
+      cg->cups_datadir = CUPS_DATADIR;
 
-  return (globals);
-}
+    if ((cg->cups_serverbin = getenv("CUPS_SERVERBIN")) == NULL)
+      cg->cups_serverbin = CUPS_SERVERBIN;
 
+    if ((cg->cups_serverroot = getenv("CUPS_SERVERROOT")) == NULL)
+      cg->cups_serverroot = CUPS_SERVERROOT;
 
-/*
- * 'globals_init()' - Initialize globals once.
- */
+    if ((cg->cups_statedir = getenv("CUPS_STATEDIR")) == NULL)
+      cg->cups_statedir = CUPS_STATEDIR;
 
-static void
-globals_init()
-{
-  pthread_key_create(&globals_key, globals_destructor);
+    if ((cg->localedir = getenv("LOCALEDIR")) == NULL)
+      cg->localedir = CUPS_LOCALEDIR;
+  }
+#endif /* WIN32 */
+
+  return (cg);
 }
 
 
 /*
- * 'globals_destructor()' - Free memory allocated by _cupsGlobals().
+ * 'cups_globals_free()' - Free global data.
  */
 
 static void
-globals_destructor(void *value)                /* I - Data to free */
+cups_globals_free(_cups_globals_t *cg) /* I - Pointer to global data */
 {
-  int                  i;              /* Looping var */
   _ipp_buffer_t                *buffer,        /* Current IPP read/write buffer */
                        *next;          /* Next buffer */
-  _cups_globals_t      *cg;            /* Global data */
 
 
-  cg = (_cups_globals_t *)value;
-
-  httpClose(cg->http);
-
-  for (i = 0; i < 3; i ++)
-    cupsFileClose(cg->stdio_files[i]);
-
   if (cg->last_status_message)
     _cupsStrFree(cg->last_status_message);
 
-  cupsFreeOptions(cg->cupsd_num_settings, cg->cupsd_settings);
-
   for (buffer = cg->ipp_buffers; buffer; buffer = next)
   {
     next = buffer->next;
@@ -238,47 +314,31 @@ globals_destructor(void *value)           /* I - Data to free */
   cupsArrayDelete(cg->pwg_size_lut);
   cupsArrayDelete(cg->leg_size_lut);
 
-  free(value);
-}
+  httpClose(cg->http);
 
+  cupsFileClose(cg->stdio_files[0]);
+  cupsFileClose(cg->stdio_files[1]);
+  cupsFileClose(cg->stdio_files[2]);
 
-#else
-/*
- * Implement static globals...
- */
+  cupsFreeOptions(cg->cupsd_num_settings, cg->cupsd_settings);
 
+  free(cg);
+}
+
+
+#ifdef HAVE_PTHREAD_H
 /*
- * '_cupsGlobals()' - Return a pointer to thread local storage.
+ * 'cups_globals_init()' - Initialize environment variables.
  */
 
-_cups_globals_t *                      /* O - Pointer to global data */
-_cupsGlobals(void)
+static void
+cups_globals_init(void)
 {
-  static _cups_globals_t globals;      /* Global data */
-  static int           initialized = 0;/* Global data initialized? */
-
-
  /*
-  * Initialize global data as needed...
+  * Register the global data for this thread...
   */
 
-  if (!initialized)
-  {
-    initialized = 1;
-
-   /*
-    * Initialize global variables...
-    */
-
-    memset(&globals, 0, sizeof(globals));
-
-    globals.encryption  = (http_encryption_t)-1;
-    globals.password_cb = (cups_password_cb2_t)_cupsGetPassword;
-
-    cups_env_init(&globals);
-  }
-
-  return (&globals);
+  pthread_key_create(&cups_globals_key, (void (*)(void *))cups_globals_free);
 }
 #endif /* HAVE_PTHREAD_H */
 
index 4a08eb9e3b7dcfb251b5ff4c75cc6c046a414205..50f094cbafb091bd79ed8a7bd91decf792c5af0b 100644 (file)
@@ -99,6 +99,7 @@ extern BIO_METHOD *_httpBIOMethods(void);
  * The GNU TLS library is more of a "bare metal" SSL/TLS library...
  */
 #    include <gnutls/gnutls.h>
+#    include <gcrypt.h>
 
 typedef struct
 {
@@ -265,11 +266,15 @@ extern void       _cups_freeifaddrs(struct ifaddrs *addrs);
 extern int             _httpAddrPort(http_addr_t *addr);
 extern http_t          *_httpCreate(const char *host, int port,
                                     http_encryption_t encryption);
+extern void            _httpDisconnect(http_t *http);
 extern char            *_httpEncodeURI(char *dst, const char *src,
                                        size_t dstsize);
+extern ssize_t         _httpPeek(http_t *http, char *buffer, size_t length);
 extern const char      *_httpResolveURI(const char *uri, char *resolved_uri,
                                         size_t resolved_size, int log);
 extern int             _httpWait(http_t *http, int msec, int usessl);
+
+
 #endif /* !_CUPS_HTTP_PRIVATE_H_ */
 
 /*
index 8d9be10e0d2e9f46afa26c555b1553761081e74c..f1e4893d3612969c3cba1e7f11f01a7e4d39612f 100644 (file)
 #include "cups-private.h"
 #ifdef HAVE_DNSSD
 #  include <dns_sd.h>
-#  include <poll.h>
+#  ifdef WIN32
+#    include <io.h>
+#  elif defined(HAVE_POLL)
+#    include <poll.h>
+#  else
+#    include <sys/select.h>
+#  endif /* WIN32 */
 #endif /* HAVE_DNSSD */
 
 
@@ -107,7 +113,7 @@ static char         *http_copy_encode(char *dst, const char *src,
                                          char *dstend, const char *reserved,
                                          const char *term, int encode);
 #ifdef HAVE_DNSSD
-static void            resolve_callback(DNSServiceRef sdRef,
+static void DNSSD_API  resolve_callback(DNSServiceRef sdRef,
                                         DNSServiceFlags flags,
                                         uint32_t interfaceIndex,
                                         DNSServiceErrorType errorCode,
@@ -1354,8 +1360,12 @@ _httpResolveURI(
     char               *regtype,       /* Pointer to type in hostname */
                        *domain;        /* Pointer to domain in hostname */
     _http_uribuf_t     uribuf;         /* URI buffer */
+#ifdef HAVE_POLL
     struct pollfd      polldata;       /* Polling data */
-
+#else /* select() */
+    fd_set             input_set;      /* Input set for select() */
+    struct timeval     stimeout;       /* Timeout value for select() */
+#endif /* HAVE_POLL */
 
     if (logit)
       fprintf(stderr, "DEBUG: Resolving \"%s\"...\n", hostname);
@@ -1431,11 +1441,23 @@ _httpResolveURI(
 
          timeout = (time(NULL) < (start_time + 60)) ? 2000 : -1;
 
+#ifdef HAVE_POLL
          polldata.fd     = DNSServiceRefSockFD(ref);
          polldata.events = POLLIN;
 
          fds = poll(&polldata, 1, timeout);
 
+#else /* select() */
+         FD_ZERO(&input_set);
+         FD_SET(DNSServiceRefSockFD(ref), &input_set);
+
+         stimeout.tv_sec  = ((int)timeout) / 1000;
+         stimeout.tv_usec = ((int)(timeout) * 1000) % 1000000;
+
+         fds = select(DNSServiceRefSockFD(ref)+1, &input_set, NULL, NULL, 
+                      timeout < 0.0 ? NULL : &stimeout); 
+#endif /* HAVE_POLL */
+
          if (fds < 0)
          {
            if (errno != EINTR && errno != EAGAIN)
@@ -1634,7 +1656,7 @@ http_copy_encode(char       *dst, /* O - Destination buffer */
  * 'resolve_callback()' - Build a device URI for the given service name.
  */
 
-static void
+static void DNSSD_API
 resolve_callback(
     DNSServiceRef       sdRef,         /* I - Service reference */
     DNSServiceFlags     flags,         /* I - Results flags */
index 3293c88990864eba95792948a63988ed882d9996..666c6458cea8e7a129428b061de2367c3a8a5b7c 100644 (file)
  *                          server.
  *   httpClearCookie()    - Clear the cookie value(s).
  *   httpClearFields()    - Clear HTTP request fields.
- *   httpClose()          - Close an HTTP connection...
+ *   httpClose()          - Close an HTTP connection.
+ *   httpConnect()        - Connect to a HTTP server.
  *   httpConnectEncrypt() - Connect to a HTTP server using encryption.
  *   _httpCreate()        - Create an unconnected HTTP connection.
  *   httpDelete()         - Send a DELETE request to the server.
+ *   _httpDisconnect()    - Disconnect a HTTP connection.
  *   httpEncryption()     - Set the required encryption on the link.
  *   httpError()          - Get the last error on a connection.
  *   httpFlush()          - Flush data from a HTTP connection.
@@ -52,6 +54,7 @@
  *   httpInitialize()     - Initialize the HTTP interface library and set the
  *                          default HTTP proxy (if any).
  *   httpOptions()        - Send an OPTIONS request to the server.
+ *   _httpPeek()          - Peek at data from a HTTP connection.
  *   httpPost()           - Send a POST request to the server.
  *   httpPrintf()         - Print a formatted string to a HTTP connection.
  *   httpPut()            - Send a PUT request to the server.
@@ -61,7 +64,7 @@
  *   _httpReadGNUTLS()    - Read function for the GNU TLS library.
  *   httpReconnect()      - Reconnect to a HTTP server.
  *   httpSetAuthString()  - Set the current authorization string.
- *   httpSetCookie()      - Set the cookie value(s)...
+ *   httpSetCookie()      - Set the cookie value(s).
  *   httpSetExpect()      - Set the Expect: header in a request.
  *   httpSetField()       - Set the value of an HTTP header.
  *   httpSetLength()      - Set the content-length and content-encoding.
  *   http_debug_hex()     - Do a hex dump of a buffer.
  *   http_field()         - Return the field index for a field name.
  *   http_read_ssl()      - Read from a SSL/TLS connection.
+ *   http_locking_cb()    - Lock/unlock a thread's mutex.
  *   http_send()          - Send a request with all fields and the trailing
  *                          blank line.
  *   http_setup_ssl()     - Set up SSL/TLS support on a connection.
  *   http_shutdown_ssl()  - Shut down SSL/TLS on a connection.
+ *   http_threadid_cb()   - Return the current thread ID.
  *   http_upgrade()       - Force upgrade to TLS encryption.
  *   http_write()         - Write a buffer to a HTTP connection.
  *   http_write_chunk()   - Write a chunked buffer.
@@ -139,6 +144,19 @@ static int         http_setup_ssl(http_t *http);
 static void            http_shutdown_ssl(http_t *http);
 static int             http_upgrade(http_t *http);
 static int             http_write_ssl(http_t *http, const char *buf, int len);
+
+#  ifdef HAVE_GNUTLS
+#    ifdef HAVE_PTHREAD_H
+GCRY_THREAD_OPTION_PTHREAD_IMPL;
+#    endif /* HAVE_PTHREAD_H */
+
+#  elif defined(HAVE_LIBSSL)
+static _cups_mutex_t   *http_locks;    /* OpenSSL lock mutexes */
+
+static void            http_locking_cb(int mode, int type, const char *file,
+                                       int line);
+static unsigned long   http_threadid_cb(void);
+#  endif /* HAVE_GNUTLS */
 #endif /* HAVE_SSL */
 
 
@@ -307,7 +325,7 @@ httpClearFields(http_t *http)               /* I - Connection to server */
 
 
 /*
- * 'httpClose()' - Close an HTTP connection...
+ * 'httpClose()' - Close an HTTP connection.
  */
 
 void
@@ -320,25 +338,28 @@ httpClose(http_t *http)                   /* I - Connection to server */
 
   DEBUG_printf(("httpClose(http=%p)", http));
 
+ /*
+  * Range check input...
+  */
+
   if (!http)
     return;
 
+ /*
+  * Close any open connection...
+  */
+
+  _httpDisconnect(http);
+
+ /*
+  * Free memory used...
+  */
+
   httpAddrFreeList(http->addrlist);
 
   if (http->cookie)
     free(http->cookie);
 
-#ifdef HAVE_SSL
-  if (http->tls)
-    http_shutdown_ssl(http);
-#endif /* HAVE_SSL */
-
-#ifdef WIN32
-  closesocket(http->fd);
-#else
-  close(http->fd);
-#endif /* WIN32 */
-
 #ifdef HAVE_GSSAPI
   if (http->gssctx != GSS_C_NO_CONTEXT)
     gss_delete_sec_context(&minor_status, &http->gssctx, GSS_C_NO_BUFFER);
@@ -502,6 +523,28 @@ httpDelete(http_t     *http,               /* I - Connection to server */
 }
 
 
+/*
+ * '_httpDisconnect()' - Disconnect a HTTP connection.
+ */
+
+void
+_httpDisconnect(http_t *http)          /* I - Connection to server */
+{
+#ifdef HAVE_SSL
+  if (http->tls)
+    http_shutdown_ssl(http);
+#endif /* HAVE_SSL */
+
+#ifdef WIN32
+  closesocket(http->fd);
+#else
+  close(http->fd);
+#endif /* WIN32 */
+
+  http->fd = -1;
+}
+
+
 /*
  * 'httpEncryption()' - Set the required encryption on the link.
  */
@@ -1174,21 +1217,26 @@ httpHead(http_t     *http,              /* I - Connection to server */
 void
 httpInitialize(void)
 {
+  static int   initialized = 0;        /* Have we been called before? */
+#ifdef WIN32
+  WSADATA      winsockdata;            /* WinSock data */
+#endif /* WIN32 */
 #ifdef HAVE_LIBSSL
-#  ifndef WIN32
-  struct timeval       curtime;        /* Current time in microseconds */
-#  endif /* !WIN32 */
-  int                  i;              /* Looping var */
-  unsigned char                data[1024];     /* Seed data */
+  int          i;                      /* Looping var */
+  unsigned char        data[1024];             /* Seed data */
 #endif /* HAVE_LIBSSL */
 
-#ifdef WIN32
-  WSADATA      winsockdata;            /* WinSock data */
-  static int   initialized = 0;        /* Has WinSock been initialized? */
 
+  _cupsGlobalLock();
+  if (initialized)
+  {
+    _cupsGlobalUnlock();
+    return;
+  }
+
+#ifdef WIN32
+  WSAStartup(MAKEWORD(1,1), &winsockdata);
 
-  if (!initialized)
-    WSAStartup(MAKEWORD(1,1), &winsockdata);
 #elif !defined(SO_NOSIGPIPE)
  /*
   * Ignore SIGPIPE signals...
@@ -1196,6 +1244,7 @@ httpInitialize(void)
 
 #  ifdef HAVE_SIGSET
   sigset(SIGPIPE, SIG_IGN);
+
 #  elif defined(HAVE_SIGACTION)
   struct sigaction     action;         /* POSIX sigaction data */
 
@@ -1203,35 +1252,63 @@ httpInitialize(void)
   memset(&action, 0, sizeof(action));
   action.sa_handler = SIG_IGN;
   sigaction(SIGPIPE, &action, NULL);
+
 #  else
   signal(SIGPIPE, SIG_IGN);
 #  endif /* !SO_NOSIGPIPE */
 #endif /* WIN32 */
 
 #ifdef HAVE_GNUTLS
+ /*
+  * Make sure we handle threading properly...
+  */
+
+#  ifdef HAVE_PTHREAD_H
+  gcry_control(GCRYCTL_SET_THREAD_CBS, &gcry_threads_pthread);
+#  endif /* HAVE_PTHREAD_H */
+
+ /*
+  * Initialize GNU TLS...
+  */
+
   gnutls_global_init();
-#endif /* HAVE_GNUTLS */
 
-#ifdef HAVE_LIBSSL
+#elif defined(HAVE_LIBSSL)
+ /*
+  * Initialize OpenSSL...
+  */
+
   SSL_load_error_strings();
   SSL_library_init();
 
+ /*
+  * Set the threading callbacks...
+  */
+
+  http_locks = calloc(CRYPTO_num_locks(), sizeof(_cups_mutex_t));
+#  ifdef HAVE_PTHREAD_H
+  for (i = 0; i < CRYPTO_num_locks(); i ++)
+    pthread_mutex_init(http_locks + i, NULL);
+#  endif /* HAVE_PTHREAD_H */
+
+  CRYPTO_set_id_callback(http_threadid_cb);
+  CRYPTO_set_locking_callback(http_locking_cb);
+
  /*
   * Using the current time is a dubious random seed, but on some systems
   * it is the best we can do (on others, this seed isn't even used...)
   */
 
-#  ifdef WIN32
-#  else
-  gettimeofday(&curtime, NULL);
-  srand(curtime.tv_sec + curtime.tv_usec);
-#  endif /* WIN32 */
+  CUPS_SRAND(time(NULL));
 
   for (i = 0; i < sizeof(data); i ++)
-    data[i] = rand();
+    data[i] = CUPS_RAND();
 
   RAND_seed(data, sizeof(data));
-#endif /* HAVE_LIBSSL */
+#endif /* HAVE_GNUTLS */
+
+  initialized = 1;
+  _cupsGlobalUnlock();
 }
 
 
@@ -1247,6 +1324,176 @@ httpOptions(http_t     *http,           /* I - Connection to server */
 }
 
 
+/*
+ * '_httpPeek()' - Peek at data from a HTTP connection.
+ *
+ * This function copies available data from the given HTTP connection, reading
+ * a buffer as needed.  The data is still available for reading using
+ * @link httpRead@ or @link httpRead2@.
+ *
+ * For non-blocking connections the usual timeouts apply.
+ */
+
+ssize_t                                        /* O - Number of bytes copied */
+_httpPeek(http_t *http,                        /* I - Connection to server */
+          char   *buffer,              /* I - Buffer for data */
+         size_t length)                /* I - Maximum number of bytes */
+{
+  ssize_t      bytes;                  /* Bytes read */
+  char         len[32];                /* Length string */
+
+
+  DEBUG_printf(("_httpPeek(http=%p, buffer=%p, length=" CUPS_LLFMT ")",
+                http, buffer, CUPS_LLCAST length));
+
+  if (http == NULL || buffer == NULL)
+    return (-1);
+
+  http->activity = time(NULL);
+  http->error    = 0;
+
+  if (length <= 0)
+    return (0);
+
+  if (http->data_encoding == HTTP_ENCODE_CHUNKED &&
+      http->data_remaining <= 0)
+  {
+    DEBUG_puts("2_httpPeek: Getting chunk length...");
+
+    if (httpGets(len, sizeof(len), http) == NULL)
+    {
+      DEBUG_puts("1_httpPeek: Could not get length!");
+      return (0);
+    }
+
+    http->data_remaining = strtoll(len, NULL, 16);
+    if (http->data_remaining < 0)
+    {
+      DEBUG_puts("1_httpPeek: Negative chunk length!");
+      return (0);
+    }
+  }
+
+  DEBUG_printf(("2_httpPeek: data_remaining=" CUPS_LLFMT,
+                CUPS_LLCAST http->data_remaining));
+
+  if (http->data_remaining <= 0)
+  {
+   /*
+    * A zero-length chunk ends a transfer; unless we are reading POST
+    * data, go idle...
+    */
+
+    if (http->data_encoding == HTTP_ENCODE_CHUNKED)
+      httpGets(len, sizeof(len), http);
+
+    if (http->state == HTTP_POST_RECV)
+      http->state ++;
+    else
+      http->state = HTTP_WAITING;
+
+   /*
+    * Prevent future reads for this request...
+    */
+
+    http->data_encoding = HTTP_ENCODE_LENGTH;
+
+    return (0);
+  }
+  else if (length > (size_t)http->data_remaining)
+    length = (size_t)http->data_remaining;
+
+  if (http->used == 0)
+  {
+   /*
+    * Buffer small reads for better performance...
+    */
+
+    if (!http->blocking && !httpWait(http, 10000))
+      return (0);
+
+    if (http->data_remaining > sizeof(http->buffer))
+      bytes = sizeof(http->buffer);
+    else
+      bytes = http->data_remaining;
+
+#ifdef HAVE_SSL
+    if (http->tls)
+      bytes = http_read_ssl(http, http->buffer, bytes);
+    else
+#endif /* HAVE_SSL */
+    {
+      DEBUG_printf(("2_httpPeek: reading %d bytes from socket into buffer...",
+                    (int)bytes));
+
+      bytes = recv(http->fd, http->buffer, bytes, 0);
+
+      DEBUG_printf(("2_httpPeek: read %d bytes from socket into buffer...",
+                    (int)bytes));
+    }
+
+    if (bytes > 0)
+      http->used = bytes;
+    else if (bytes < 0)
+    {
+#ifdef WIN32
+      http->error = WSAGetLastError();
+      return (-1);
+#else
+      if (errno != EINTR && errno != EAGAIN)
+      {
+        http->error = errno;
+        return (-1);
+      }
+#endif /* WIN32 */
+    }
+    else
+    {
+      http->error = EPIPE;
+      return (0);
+    }
+  }
+
+  if (http->used > 0)
+  {
+    if (length > (size_t)http->used)
+      length = (size_t)http->used;
+
+    bytes = (ssize_t)length;
+
+    DEBUG_printf(("2_httpPeek: grabbing %d bytes from input buffer...",
+                  (int)bytes));
+
+    memcpy(buffer, http->buffer, length);
+  }
+  else
+    bytes = 0;
+
+  if (bytes < 0)
+  {
+#ifdef WIN32
+    http->error = WSAGetLastError();
+#else
+    if (errno == EINTR || errno == EAGAIN)
+      bytes = 0;
+    else
+      http->error = errno;
+#endif /* WIN32 */
+  }
+  else if (bytes == 0)
+  {
+    http->error = EPIPE;
+    return (0);
+  }
+
+#ifdef DEBUG
+  http_debug_hex("_httpPeek", buffer, (int)bytes);
+#endif /* DEBUG */
+
+  return (bytes);
+}
+
+
 /*
  * 'httpPost()' - Send a POST request to the server.
  */
@@ -1819,7 +2066,7 @@ httpSetAuthString(http_t     *http,       /* I - Connection to server */
 
 
 /*
- * 'httpSetCookie()' - Set the cookie value(s)...
+ * 'httpSetCookie()' - Set the cookie value(s).
  *
  * @since CUPS 1.1.19/Mac OS X 10.3@
  */
@@ -2805,6 +3052,25 @@ http_read_ssl(http_t *http,              /* I - Connection to server */
 #endif /* HAVE_SSL */
 
 
+#ifdef HAVE_LIBSSL
+/*
+ * 'http_locking_cb()' - Lock/unlock a thread's mutex.
+ */
+
+static void
+http_locking_cb(int        mode,       /* I - Lock mode */
+               int        type,        /* I - Lock type */
+               const char *file,       /* I - Source file */
+               int        line)        /* I - Line number */
+{
+  if (mode & CRYPTO_LOCK)
+    _cupsMutexLock(http_locks + type);
+  else
+    _cupsMutexUnlock(http_locks + type);
+}
+#endif /* HAVE_LIBSSL */
+
+
 /*
  * 'http_send()' - Send a request with all fields and the trailing blank line.
  */
@@ -3176,6 +3442,23 @@ http_shutdown_ssl(http_t *http)          /* I - Connection to server */
 #endif /* HAVE_SSL */
 
 
+#ifdef HAVE_LIBSSL
+/*
+ * 'http_threadid_cb()' - Return the current thread ID.
+ */
+
+static unsigned long                   /* O - Thread ID */
+http_threadid_cb(void)
+{
+#  ifdef HAVE_PTHREAD_H
+  return ((unsigned long)pthread_self());
+#  else
+  return (0);
+#  endif /* HAVE_PTHREAD_H */
+}
+#endif /* HAVE_LIBSSL */
+
+
 #ifdef HAVE_SSL
 /*
  * 'http_upgrade()' - Force upgrade to TLS encryption.
index 6f3f3ac1c26c96408fec4bc16977dd5caaada541..00b2de3ad40e3e641bfeb40c7f9c329318f48242 100644 (file)
  * Local globals...
  */
 
-#ifdef HAVE_PTHREAD_H
-static pthread_mutex_t lang_mutex = PTHREAD_MUTEX_INITIALIZER;
+static _cups_mutex_t   lang_mutex = _CUPS_MUTEX_INITIALIZER;
                                        /* Mutex to control access to cache */
-#endif /* HAVE_PTHREAD_H */
 static cups_lang_t     *lang_cache = NULL;
                                        /* Language string cache */
 static const char * const lang_encodings[] =
@@ -311,9 +309,7 @@ cupsLangFlush(void)
   * Free all languages in the cache...
   */
 
-#ifdef HAVE_PTHREAD_H
-  pthread_mutex_lock(&lang_mutex);
-#endif /* HAVE_PTHREAD_H */
+  _cupsMutexLock(&lang_mutex);
 
   for (lang = lang_cache; lang != NULL; lang = next)
   {
@@ -333,9 +329,7 @@ cupsLangFlush(void)
 
   lang_cache = NULL;
 
-#ifdef HAVE_PTHREAD_H
-  pthread_mutex_unlock(&lang_mutex);
-#endif /* HAVE_PTHREAD_H */
+  _cupsMutexUnlock(&lang_mutex);
 }
 
 
@@ -348,16 +342,12 @@ cupsLangFlush(void)
 void
 cupsLangFree(cups_lang_t *lang)                /* I - Language to free */
 {
-#ifdef HAVE_PTHREAD_H
-  pthread_mutex_lock(&lang_mutex);
-#endif /* HAVE_PTHREAD_H */
+  _cupsMutexLock(&lang_mutex);
 
   if (lang != NULL && lang->used > 0)
     lang->used --;
 
-#ifdef HAVE_PTHREAD_H
-  pthread_mutex_unlock(&lang_mutex);
-#endif /* HAVE_PTHREAD_H */
+  _cupsMutexUnlock(&lang_mutex);
 }
 
 
@@ -698,15 +688,11 @@ cupsLangGet(const char *language) /* I - Language or locale */
     filename[0] = '\0';                        /* anti-compiler-warning-code */
   }
 
-#ifdef HAVE_PTHREAD_H
-  pthread_mutex_lock(&lang_mutex);
-#endif /* HAVE_PTHREAD_H */
+  _cupsMutexLock(&lang_mutex);
 
   if ((lang = cups_cache_lookup(real, encoding)) != NULL)
   {
-#ifdef HAVE_PTHREAD_H
-    pthread_mutex_unlock(&lang_mutex);
-#endif /* HAVE_PTHREAD_H */
+    _cupsMutexUnlock(&lang_mutex);
 
     DEBUG_printf(("3cupsLangGet: Using cached copy of \"%s\"...", real));
 
@@ -752,9 +738,7 @@ cupsLangGet(const char *language)   /* I - Language or locale */
 
     if ((lang = calloc(sizeof(cups_lang_t), 1)) == NULL)
     {
-#ifdef HAVE_PTHREAD_H
-      pthread_mutex_unlock(&lang_mutex);
-#endif /* HAVE_PTHREAD_H */
+      _cupsMutexUnlock(&lang_mutex);
 
       return (NULL);
     }
@@ -793,9 +777,7 @@ cupsLangGet(const char *language)   /* I - Language or locale */
   * Return...
   */
 
-#ifdef HAVE_PTHREAD_H
-  pthread_mutex_unlock(&lang_mutex);
-#endif /* HAVE_PTHREAD_H */
+  _cupsMutexUnlock(&lang_mutex);
 
   return (lang);
 }
@@ -812,6 +794,8 @@ const char *                                /* O - Localized message */
 _cupsLangString(cups_lang_t *lang,     /* I - Language */
                 const char  *message)  /* I - Message */
 {
+  const char *s;                       /* Localized message */
+
  /*
   * Range check input...
   */
@@ -819,21 +803,13 @@ _cupsLangString(cups_lang_t *lang,        /* I - Language */
   if (!lang || !message)
     return (message);
 
-#ifdef HAVE_PTHREAD_H
-  {
-    const char *s;                     /* Localized message */
-
-    pthread_mutex_lock(&lang_mutex);
+  _cupsMutexLock(&lang_mutex);
 
-    s = _cupsMessageLookup(lang->strings, message);
+  s = _cupsMessageLookup(lang->strings, message);
 
-    pthread_mutex_unlock(&lang_mutex);
+  _cupsMutexUnlock(&lang_mutex);
 
-    return (s);
-  }
-#else
-  return (_cupsMessageLookup(lang->strings, message));
-#endif /* HAVE_PTHREAD_H */
+  return (s);
 }
 
 
index 79564a6c3c4c336e5cf76f163046098d4da7a540..35037ea5b0c4fcfbe9cfdbebf28588db5e6c4ab7 100644 (file)
@@ -45,7 +45,9 @@ _httpAddrPort
 _httpBIOMethods
 _httpCreate
 _httpEncodeURI
+_httpPeek
 _httpResolveURI
+_httpWait
 _ippAddAttr
 _ippFreeAttr
 _ppdFreeLanguages
index 60d80e5a6f02fec08cf358b682d699f1d54d9c7f..4285eeb872842d8e8b2ac41be9e177f038407a90 100644 (file)
  *   cupsDoIORequest()      - Do an IPP request with file descriptors.
  *   cupsDoRequest()        - Do an IPP request.
  *   cupsGetResponse()      - Get a response to an IPP request.
+ *   cupsLastError()        - Return the last IPP status code.
+ *   cupsLastErrorString()  - Return the last IPP status-message.
  *   cupsReadResponseData() - Read additional data after the IPP response.
  *   cupsSendRequest()      - Send an IPP request.
  *   cupsWriteRequestData() - Write additional data after an IPP request.
+ *   _cupsConnect()         - Get the default server connection...
  *   _cupsSetError()        - Set the last IPP status code and status-message.
  *   _cupsSetHTTPError()    - Set the last error using the HTTP status.
  */
@@ -299,7 +302,7 @@ cupsDoIORequest(http_t     *http,   /* I - Connection to server or @code CUPS_HTTP
  /*
   * Delete the original request and return the response...
   */
-  
+
   ippDelete(request);
 
   return (response);
@@ -477,6 +480,30 @@ cupsGetResponse(http_t     *http,  /* I - Connection to server or @code CUPS_HTTP
 }
 
 
+/*
+ * 'cupsLastError()' - Return the last IPP status code.
+ */
+
+ipp_status_t                           /* O - IPP status code from last request */
+cupsLastError(void)
+{
+  return (_cupsGlobals()->last_error);
+}
+
+
+/*
+ * 'cupsLastErrorString()' - Return the last IPP status-message.
+ *
+ * @since CUPS 1.2/Mac OS X 10.5@
+ */
+
+const char *                           /* O - status-message text from last request */
+cupsLastErrorString(void)
+{
+  return (_cupsGlobals()->last_status_message);
+}
+
+
 /*
  * 'cupsReadResponseData()' - Read additional data after the IPP response.
  *
@@ -524,7 +551,7 @@ cupsReadResponseData(
  *
  * Use httpWrite() to write any additional data (document, PPD file, etc.)
  * for the request, cupsGetResponse() to get the IPP response, and httpRead()
- * to read any additional data following the response. Only one request can be 
+ * to read any additional data following the response. Only one request can be
  * sent/queued at a time.
  *
  * Unlike cupsDoFileRequest(), cupsDoIORequest(), and cupsDoRequest(), the
@@ -816,6 +843,67 @@ cupsWriteRequestData(
 }
 
 
+/*
+ * '_cupsConnect()' - Get the default server connection...
+ */
+
+http_t *                               /* O - HTTP connection */
+_cupsConnect(void)
+{
+  _cups_globals_t *cg = _cupsGlobals();        /* Pointer to library globals */
+
+
+ /*
+  * See if we are connected to the same server...
+  */
+
+  if (cg->http)
+  {
+   /*
+    * Compare the connection hostname, port, and encryption settings to
+    * the cached defaults; these were initialized the first time we
+    * connected...
+    */
+
+    if (strcmp(cg->http->hostname, cg->server) ||
+        cg->ipp_port != _httpAddrPort(cg->http->hostaddr) ||
+        (cg->http->encryption != cg->encryption &&
+        cg->http->encryption == HTTP_ENCRYPT_NEVER))
+    {
+     /*
+      * Need to close the current connection because something has changed...
+      */
+
+      httpClose(cg->http);
+      cg->http = NULL;
+    }
+  }
+
+ /*
+  * (Re)connect as needed...
+  */
+
+  if (!cg->http)
+  {
+    if ((cg->http = httpConnectEncrypt(cupsServer(), ippPort(),
+                                       cupsEncryption())) == NULL)
+    {
+      if (errno)
+        _cupsSetError(IPP_SERVICE_UNAVAILABLE, NULL, 0);
+      else
+        _cupsSetError(IPP_SERVICE_UNAVAILABLE,
+                     _("Unable to connect to host."), 1);
+    }
+  }
+
+ /*
+  * Return the cached connection...
+  */
+
+  return (cg->http);
+}
+
+
 /*
  * '_cupsSetError()' - Set the last IPP status code and status-message.
  */
index 9e60076a2c85331ad1db86e9b7117dfbe5f85c33..96f6728a84dec6cdf967948653711838f9c2d763 100644 (file)
 
 #include "string-private.h"
 #include "debug-private.h"
+#include "thread-private.h"
 #include "array.h"
-#include <stdlib.h>
 #include <stddef.h>
 #include <limits.h>
-#ifdef HAVE_PTHREAD_H
-#  include <pthread.h>
-#endif /* HAVE_PTHREAD_H */
 
 
 /*
  * Local globals...
  */
 
-#ifdef HAVE_PTHREAD_H
-static pthread_mutex_t sp_mutex = PTHREAD_MUTEX_INITIALIZER;
+static _cups_mutex_t   sp_mutex = _CUPS_MUTEX_INITIALIZER;
                                        /* Mutex to control access to pool */
-#endif /* HAVE_PTHREAD_H */
 static cups_array_t    *stringpool = NULL;
                                        /* Global string pool */
 
@@ -88,18 +83,14 @@ _cupsStrAlloc(const char *s)                /* I - String */
   * Get the string pool...
   */
 
-#ifdef HAVE_PTHREAD_H
-  pthread_mutex_lock(&sp_mutex);
-#endif /* HAVE_PTHREAD_H */
+  _cupsMutexLock(&sp_mutex);
 
   if (!stringpool)
     stringpool = cupsArrayNew((cups_array_func_t)compare_sp_items, NULL);
 
   if (!stringpool)
   {
-#ifdef HAVE_PTHREAD_H
-    pthread_mutex_unlock(&sp_mutex);
-#endif /* HAVE_PTHREAD_H */
+    _cupsMutexUnlock(&sp_mutex);
 
     return (NULL);
   }
@@ -127,9 +118,7 @@ _cupsStrAlloc(const char *s)                /* I - String */
       abort();
 #endif /* DEBUG_GUARDS */
 
-#ifdef HAVE_PTHREAD_H
-    pthread_mutex_unlock(&sp_mutex);
-#endif /* HAVE_PTHREAD_H */
+    _cupsMutexUnlock(&sp_mutex);
 
     return (item->str);
   }
@@ -141,9 +130,7 @@ _cupsStrAlloc(const char *s)                /* I - String */
   item = (_cups_sp_item_t *)calloc(1, sizeof(_cups_sp_item_t) + strlen(s));
   if (!item)
   {
-#ifdef HAVE_PTHREAD_H
-    pthread_mutex_unlock(&sp_mutex);
-#endif /* HAVE_PTHREAD_H */
+    _cupsMutexUnlock(&sp_mutex);
 
     return (NULL);
   }
@@ -165,9 +152,7 @@ _cupsStrAlloc(const char *s)                /* I - String */
 
   cupsArrayAdd(stringpool, item);
 
-#ifdef HAVE_PTHREAD_H
-  pthread_mutex_unlock(&sp_mutex);
-#endif /* HAVE_PTHREAD_H */
+  _cupsMutexUnlock(&sp_mutex);
 
   return (item->str);
 }
@@ -186,9 +171,7 @@ _cupsStrFlush(void)
   DEBUG_printf(("4_cupsStrFlush: %d strings in array",
                 cupsArrayCount(stringpool)));
 
-#ifdef HAVE_PTHREAD_H
-  pthread_mutex_lock(&sp_mutex);
-#endif /* HAVE_PTHREAD_H */
+  _cupsMutexLock(&sp_mutex);
 
   for (item = (_cups_sp_item_t *)cupsArrayFirst(stringpool);
        item;
@@ -198,9 +181,7 @@ _cupsStrFlush(void)
   cupsArrayDelete(stringpool);
   stringpool = NULL;
 
-#ifdef HAVE_PTHREAD_H
-  pthread_mutex_unlock(&sp_mutex);
-#endif /* HAVE_PTHREAD_H */
+  _cupsMutexUnlock(&sp_mutex);
 }
 
 
@@ -317,9 +298,7 @@ _cupsStrFree(const char *s)         /* I - String to free */
   * See if the string is already in the pool...
   */
 
-#ifdef HAVE_PTHREAD_H
-  pthread_mutex_lock(&sp_mutex);
-#endif /* HAVE_PTHREAD_H */
+  _cupsMutexLock(&sp_mutex);
 
   key = (_cups_sp_item_t *)(s - offsetof(_cups_sp_item_t, str));
 
@@ -353,9 +332,7 @@ _cupsStrFree(const char *s)         /* I - String to free */
     }
   }
 
-#ifdef HAVE_PTHREAD_H
-  pthread_mutex_unlock(&sp_mutex);
-#endif /* HAVE_PTHREAD_H */
+  _cupsMutexUnlock(&sp_mutex);
 }
 
 
@@ -386,15 +363,11 @@ _cupsStrRetain(const char *s)             /* I - String to retain */
     }
 #endif /* DEBUG_GUARDS */
 
-#ifdef HAVE_PTHREAD_H
-    pthread_mutex_lock(&sp_mutex);
-#endif /* HAVE_PTHREAD_H */
+    _cupsMutexLock(&sp_mutex);
 
     item->ref_count ++;
 
-#ifdef HAVE_PTHREAD_H
-    pthread_mutex_unlock(&sp_mutex);
-#endif /* HAVE_PTHREAD_H */
+    _cupsMutexUnlock(&sp_mutex);
   }
 
   return ((char *)s);
@@ -558,9 +531,7 @@ _cupsStrStatistics(size_t *alloc_bytes,     /* O - Allocated bytes */
   * Loop through strings in pool, counting everything up...
   */
 
-#ifdef HAVE_PTHREAD_H
-  pthread_mutex_lock(&sp_mutex);
-#endif /* HAVE_PTHREAD_H */
+  _cupsMutexLock(&sp_mutex);
 
   for (count = 0, abytes = 0, tbytes = 0,
            item = (_cups_sp_item_t *)cupsArrayFirst(stringpool);
@@ -577,9 +548,7 @@ _cupsStrStatistics(size_t *alloc_bytes,     /* O - Allocated bytes */
     tbytes += item->ref_count * len;
   }
 
-#ifdef HAVE_PTHREAD_H
-  pthread_mutex_unlock(&sp_mutex);
-#endif /* HAVE_PTHREAD_H */
+  _cupsMutexUnlock(&sp_mutex);
 
  /*
   * Return values...
index a34d1f4e45be0d0d96690c60251f87e17e90cf82..2e254c24e198ec48cddea8c07965cb5424f262c7 100644 (file)
@@ -29,8 +29,6 @@
 #include "debug-private.h"
 #include "array.h"
 #include "dir.h"
-#include <stdio.h>
-#include <stdlib.h>
 
 
 /*
index 4763c2ba902ca0152a88c0ec4c87a0aa22ba84db..b4213d9907753124c72dc7f1eabcbeac59078832 100644 (file)
@@ -25,7 +25,6 @@
 
 #include "string-private.h"
 #include "http-private.h"
-#include <stdlib.h>
 
 
 /*
index ce27728b002cfbada17e979a839f84410a6f15ea..b5c3148b3514378e00910372719a1be0a48233f0 100644 (file)
@@ -27,8 +27,7 @@
  * Include necessary headers...
  */
 
-#include <stdlib.h>
-#include <cups/file.h>
+#include "file.h"
 #include "string-private.h"
 #include "ipp-private.h"
 #ifdef WIN32
index a77490e4254f6c94038cfa6d07275896e7e4a31c..db3037b67a2db06c6891cfba1d3c8b8ac130e9cd 100644 (file)
@@ -24,7 +24,6 @@
  */
 
 #include "cups-private.h"
-#include <stdlib.h>
 #include <sys/stat.h>
 #ifdef WIN32
 #  include <io.h>
@@ -697,7 +696,7 @@ main(int  argc,                             /* I - Number of command-line arguments */
     }
     else
       puts("FAIL (No conflicts!)");
-    
+
     fputs("ppdInstallableConflict(): ", stdout);
     if (ppdInstallableConflict(ppd, "Duplex", "DuplexNoTumble") &&
         !ppdInstallableConflict(ppd, "Duplex", "None"))
index b846b9e2cee646bf9e861fe5ab958b1a32a7c6e4..3a3eb9f70c53484f8c15ffda93b73bce9a95ef1f 100644 (file)
@@ -27,7 +27,6 @@
 
 #include "cups-private.h"
 #include "snmp-private.h"
-#include <stdlib.h>
 
 
 /*
index 2bda3c145cefe372812464078a0a3ad0139ab840..3a00fcd9a5673a53653f33973dece74480f913d8 100644 (file)
@@ -42,7 +42,6 @@
 
 #include "cups-private.h"
 #include <limits.h>
-#include <stdlib.h>
 #include <time.h>
 
 
  * Local globals...
  */
 
-#ifdef HAVE_PTHREAD_H
-static pthread_mutex_t map_mutex = PTHREAD_MUTEX_INITIALIZER;
+static _cups_mutex_t   map_mutex = _CUPS_MUTEX_INITIALIZER;
                                        /* Mutex to control access to maps */
-#endif /* HAVE_PTHREAD_H */
 static _cups_cmap_t    *cmap_cache = NULL;
                                        /* SBCS Charmap Cache */
 static _cups_vmap_t    *vmap_cache = NULL;
@@ -104,9 +101,7 @@ _cupsCharmapFlush(void)
                *vnext;                 /* Next Legacy VBCS Charset Map */
 
 
-#ifdef HAVE_PTHREAD_H
-  pthread_mutex_lock(&map_mutex);
-#endif /* HAVE_PTHREAD_H */
+  _cupsMutexLock(&map_mutex);
 
  /*
   * Loop through SBCS charset map cache, free all memory...
@@ -134,9 +129,7 @@ _cupsCharmapFlush(void)
 
   vmap_cache = NULL;
 
-#ifdef HAVE_PTHREAD_H
-  pthread_mutex_unlock(&map_mutex);
-#endif /* HAVE_PTHREAD_H */
+  _cupsMutexUnlock(&map_mutex);
 }
 
 
@@ -158,9 +151,7 @@ _cupsCharmapFree(
   * See if we already have this SBCS charset map loaded...
   */
 
-#ifdef HAVE_PTHREAD_H
-  pthread_mutex_lock(&map_mutex);
-#endif /* HAVE_PTHREAD_H */
+  _cupsMutexLock(&map_mutex);
 
   for (cmap = cmap_cache; cmap; cmap = cmap->next)
   {
@@ -186,9 +177,7 @@ _cupsCharmapFree(
     }
   }
 
-#ifdef HAVE_PTHREAD_H
-  pthread_mutex_unlock(&map_mutex);
-#endif /* HAVE_PTHREAD_H */
+  _cupsMutexUnlock(&map_mutex);
 }
 
 
@@ -224,15 +213,11 @@ _cupsCharmapGet(
   * Lookup or get the charset map pointer and return...
   */
 
-#ifdef HAVE_PTHREAD_H
-  pthread_mutex_lock(&map_mutex);
-#endif /* HAVE_PTHREAD_H */
+  _cupsMutexLock(&map_mutex);
 
   charmap = get_charmap(encoding);
 
-#ifdef HAVE_PTHREAD_H
-  pthread_mutex_unlock(&map_mutex);
-#endif /* HAVE_PTHREAD_H */
+  _cupsMutexUnlock(&map_mutex);
 
   return (charmap);
 }
@@ -320,18 +305,14 @@ cupsCharsetToUTF8(
   * Convert input legacy charset to UTF-8...
   */
 
-#ifdef HAVE_PTHREAD_H
-  pthread_mutex_lock(&map_mutex);
-#endif /* HAVE_PTHREAD_H */
+  _cupsMutexLock(&map_mutex);
 
   if (encoding < CUPS_ENCODING_SBCS_END)
     bytes = conv_sbcs_to_utf8(dest, (cups_sbcs_t *)src, maxout, encoding);
   else
     bytes = conv_vbcs_to_utf8(dest, (cups_sbcs_t *)src, maxout, encoding);
 
-#ifdef HAVE_PTHREAD_H
-  pthread_mutex_unlock(&map_mutex);
-#endif /* HAVE_PTHREAD_H */
+  _cupsMutexUnlock(&map_mutex);
 
   return (bytes);
 }
@@ -422,18 +403,14 @@ cupsUTF8ToCharset(
   * Convert input UTF-8 to legacy charset...
   */
 
-#ifdef HAVE_PTHREAD_H
-  pthread_mutex_lock(&map_mutex);
-#endif /* HAVE_PTHREAD_H */
+  _cupsMutexLock(&map_mutex);
 
   if (encoding < CUPS_ENCODING_SBCS_END)
     bytes = conv_utf8_to_sbcs((cups_sbcs_t *)dest, src, maxout, encoding);
   else
     bytes = conv_utf8_to_vbcs((cups_sbcs_t *)dest, src, maxout, encoding);
 
-#ifdef HAVE_PTHREAD_H
-  pthread_mutex_unlock(&map_mutex);
-#endif /* HAVE_PTHREAD_H */
+  _cupsMutexUnlock(&map_mutex);
 
   return (bytes);
 }
index 92bd2ca172ccb2d97d623fd34c0dd0f431001320..4a774c7d8e237772d1ddf945e5928014696fd2f0 100644 (file)
@@ -340,6 +340,7 @@ cupsSetUser(const char *user)               /* I - User name */
 const char *                           /* O - User name */
 cupsUser(void)
 {
+  const char   *user;                  /* USER environment variable */
   _cups_globals_t *cg = _cupsGlobals();        /* Pointer to library globals */
 
 
@@ -372,11 +373,19 @@ cupsUser(void)
     }
     else
 #endif /* WIN32 */
+    if ((user = getenv("USER")) != NULL)
+    {
+     /*
+      * Use the username from the "USER" environment variable...
+      */
+      strlcpy(cg->user, user, sizeof(cg->user));
+    }
+    else
     {
      /*
       * Use the default "unknown" user name...
       */
-      
+
       strcpy(cg->user, "unknown");
     }
   }
@@ -501,7 +510,7 @@ _cupsSetDefaults(void)
   if (!cg->ipp_port)
   {
     const char         *ipp_port;      /* IPP_PORT environment variable */
-    struct servent     *service;       /* Port number info */  
+    struct servent     *service;       /* Port number info */
 
 
     if ((ipp_port = getenv("IPP_PORT")) != NULL)
index 1b9b839d168032b9b4e0c3a9b2cb6fa2c76eb161..80f36d153a047cc5c9189233ac879d0a584b91aa 100644 (file)
@@ -18,7 +18,7 @@
  *
  *   cupsCancelJob()        - Cancel a print job on the default server.
  *   cupsCancelJob2()       - Cancel or purge a print job.
- *   cupsCreateJob()        - Create an empty job.
+ *   cupsCreateJob()        - Create an empty job for streaming.
  *   cupsFinishDocument()   - Finish sending a document.
  *   cupsFreeJobs()         - Free memory used by job data.
  *   cupsGetClasses()       - Get a list of printer classes from the default
@@ -37,8 +37,6 @@
  *                            server if it has changed.
  *   cupsGetPrinters()      - Get a list of printers from the default server.
  *   cupsGetServerPPD()     - Get an available PPD file from the server.
- *   cupsLastError()        - Return the last IPP status code.
- *   cupsLastErrorString()  - Return the last IPP status-message.
  *   cupsPrintFile()        - Print a file to a printer or class on the default
  *                            server.
  *   cupsPrintFile2()       - Print a file to a printer or class on the
@@ -49,7 +47,6 @@
  *                            the specified server.
  *   cupsStartDocument()    - Add a document to a job created with
  *                            cupsCreateJob().
- *   _cupsConnect()         - Get the default server connection...
  *   cups_get_printer_uri() - Get the printer-uri-supported attribute for the
  *                            first printer in a class.
  */
@@ -59,7 +56,6 @@
  */
 
 #include "cups-private.h"
-#include <stdlib.h>
 #include <fcntl.h>
 #include <sys/stat.h>
 #if defined(WIN32) || defined(__EMX__)
@@ -1333,30 +1329,6 @@ cupsGetServerPPD(http_t     *http,       /* I - Connection to server or @code CUPS_HTT
 }
 
 
-/*
- * 'cupsLastError()' - Return the last IPP status code.
- */
-
-ipp_status_t                           /* O - IPP status code from last request */
-cupsLastError(void)
-{
-  return (_cupsGlobals()->last_error);
-}
-
-
-/*
- * 'cupsLastErrorString()' - Return the last IPP status-message.
- *
- * @since CUPS 1.2/Mac OS X 10.5@
- */
-
-const char *                           /* O - status-message text from last request */
-cupsLastErrorString(void)
-{
-  return (_cupsGlobals()->last_status_message);
-}
-
-
 /*
  * 'cupsPrintFile()' - Print a file to a printer or class on the default server.
  */
@@ -1622,67 +1594,6 @@ cupsStartDocument(
 }
 
 
-/*
- * '_cupsConnect()' - Get the default server connection...
- */
-
-http_t *                               /* O - HTTP connection */
-_cupsConnect(void)
-{
-  _cups_globals_t *cg = _cupsGlobals();        /* Pointer to library globals */
-
-
- /*
-  * See if we are connected to the same server...
-  */
-
-  if (cg->http)
-  {
-   /*
-    * Compare the connection hostname, port, and encryption settings to
-    * the cached defaults; these were initialized the first time we
-    * connected...
-    */
-
-    if (strcmp(cg->http->hostname, cg->server) ||
-        cg->ipp_port != _httpAddrPort(cg->http->hostaddr) ||
-        (cg->http->encryption != cg->encryption &&
-        cg->http->encryption == HTTP_ENCRYPT_NEVER))
-    {
-     /*
-      * Need to close the current connection because something has changed...
-      */
-
-      httpClose(cg->http);
-      cg->http = NULL;
-    }
-  }
-
- /*
-  * (Re)connect as needed...
-  */
-
-  if (!cg->http)
-  {
-    if ((cg->http = httpConnectEncrypt(cupsServer(), ippPort(),
-                                       cupsEncryption())) == NULL)
-    {
-      if (errno)
-        _cupsSetError(IPP_SERVICE_UNAVAILABLE, NULL, 0);
-      else
-        _cupsSetError(IPP_SERVICE_UNAVAILABLE,
-                     _("Unable to connect to host."), 1);
-    }
-  }
-
- /*
-  * Return the cached connection...
-  */
-
-  return (cg->http);
-}
-
-
 /*
  * 'cups_get_printer_uri()' - Get the printer-uri-supported attribute for the
  *                            first printer in a class.
index 85c66ab91e7e41e3238d152bc942b9772aae51b3..6ca957e3211f8aab066c229409a23d75169bd466 100644 (file)
@@ -16,7 +16,7 @@ SRC="/images/left.gif" WIDTH="64" HEIGHT="36" BORDER="0" ALT=""></A></TD>
 <TD CLASS="sel"><A HREF="/">&nbsp;&nbsp;Startseite&nbsp;&nbsp;</A></TD>
 <TD CLASS="unsel"><A HREF="/admin">&nbsp;&nbsp;Verwaltung&nbsp;&nbsp;</A></TD>
 <TD CLASS="unsel"><A HREF="/classes/">&nbsp;&nbsp;Klassen&nbsp;&nbsp;</A></TD>
-<TD CLASS="unsel"><A HREF="/help/">&nbsp;&nbsp;Online&nbsp;Hilfe&nbsp;&nbsp;</A></TD>
+<TD CLASS="unsel"><A HREF="/help/">&nbsp;&nbsp;Online-&nbsp;Hilfe&nbsp;&nbsp;</A></TD>
 <TD CLASS="unsel"><A HREF="/jobs/">&nbsp;&nbsp;Auftr&auml;ge&nbsp;&nbsp;</A></TD>
 <TD CLASS="unsel"><A HREF="/printers/">&nbsp;&nbsp;Drucker&nbsp;&nbsp;</A></TD>
 <TD CLASS="unsel" WIDTH="100%"><FORM ACTION="/help/" METHOD="GET"><INPUT
@@ -31,7 +31,7 @@ AUTOSAVE="org.cups.help" RESULTS="20"></FORM></TD>
 
 <H1>Common UNIX Printing System @CUPS_VERSION@</H1>
 
-<P>CUPS ist das auf Standards basierte, Open-Source Drucker System, welches von
+<P>CUPS ist das auf Standards basierte, Opensource-Drucksystem, welches von
 <A HREF="http://www.apple.com/">Apple Inc.</A> f&uuml;r Mac OS<SUP>&reg;</SUP> X und
 andere UNIX<SUP>&reg;</SUP>-&auml;hnliche Betriebssysteme entwickelt wird.</P>
 
@@ -46,13 +46,13 @@ HEIGHT="128" ALT="CUPS"></A></TD>
 
 <H2>CUPS f&uuml;r Benutzer</H2>
 
-<P><A HREF="help/overview.html">CUPS &Uuml;bersicht</A></P>
+<P><A HREF="help/overview.html">CUPS.&Uuml;bersicht</A></P>
 
 <P><A HREF="help/options.html">Kommandozeilendruck und Einstellungen</A></P>
 
 <P><A HREF="help/whatsnew.html">Neues in CUPS 1.4</A></P>
 
-<P><A HREF="http://www.cups.org/newsgroups.php?gcups.general">Benutzer Forum</A></P>
+<P><A HREF="http://www.cups.org/newsgroups.php?gcups.general">Benutzerforum</A></P>
 
 </TD><TD VALIGN="top" STYLE="border-right: dotted thin #cccccc; padding-left: 20px; padding-right: 20px;">
 
@@ -66,7 +66,7 @@ HEIGHT="128" ALT="CUPS"></A></TD>
 
 <P><A HREF="help/security.html">Sicherheit des Servers</A></P>
 
-<P><A HREF="help/kerberos.html">Benutzen der Kerberos Authentifizierung</A></P>
+<P><A HREF="help/kerberos.html">Verwenden der Kerberos Authentifizierung</A></P>
 
 <P><A HREF="help/network.html">Benutzen von Netzwerkdruckern</A></P>
 
@@ -78,21 +78,21 @@ HEIGHT="128" ALT="CUPS"></A></TD>
 
 <H2>CUPS f&uuml;r Entwickler</H2>
 
-<P><A HREF="help/api-overview.html">Einf&uuml;hrung in die CUPS Programmierung</A></P>
+<P><A HREF="help/api-overview.html">Einf&uuml;hrung in die CUPS-Programmierung</A></P>
 
-<P><A HREF="help/api-cups.html">CUPS API</A></P>
+<P><A HREF="help/api-cups.html">CUPS-API</A></P>
 
-<P><A HREF="help/api-filter.html">Filter und Backend Programmierung</A></P>
+<P><A HREF="help/api-filter.html">Filter- und Backend-Programmierung</A></P>
 
-<P><A HREF="help/api-httpipp.html">HTTP und IPP APIs</A></P>
+<P><A HREF="help/api-httpipp.html">HTTP- und IPP-APIs</A></P>
 
-<P><A HREF="help/api-ppd.html">PPD API</A></P>
+<P><A HREF="help/api-ppd.html">PPD-API</A></P>
 
-<P><A HREF="help/api-raster.html">Raster API</A></P>
+<P><A HREF="help/api-raster.html">Raster-API</A></P>
 
 <P><A HREF="help/ref-ppdcfile.html">PPD Compiler Driver Information File Reference</A></P>
 
-<P><A HREF="http://www.cups.org/newsgroups.php?gcups.development">Entwickler Forum</A></P>
+<P><A HREF="http://www.cups.org/newsgroups.php?gcups.development">Entwicklerforum</A></P>
 
 </TD></TR>
 </TABLE>
index 8f017ace1d45922829fdf492982c39c1f9a017b1..21fdfe29cfa340b6db60c1fe1e93d5a8806ef0bc 100644 (file)
@@ -269,10 +269,10 @@ test:
 # testcmyk, test cmyk separation functions.
 #
 
-testcmyk:              test testcmyk.o libcupsdriver.a ../cups/libcups.a
+testcmyk:              test testcmyk.o libcupsdriver.a ../cups/$(LIBCUPSSTATIC)
        echo Linking $@...
        $(CC) $(ARCHFLAGS) $(LDFLAGS) -o $@ testcmyk.o libcupsdriver.a \
-               ../cups/libcups.a $(LIBGSSAPI) $(SSLLIBS) $(DNSSDLIBS) \
+               ../cups/$(LIBCUPSSTATIC) $(LIBGSSAPI) $(SSLLIBS) $(DNSSDLIBS) \
                $(COMMONLIBS) $(LIBZ)
        echo Running CMYK API tests...
        ./testcmyk > test/testcmyk.log
@@ -282,10 +282,10 @@ testcmyk:         test testcmyk.o libcupsdriver.a ../cups/libcups.a
 # testdither, test dithering functions.
 #
 
-testdither:            test testdither.o libcupsdriver.a ../cups/libcups.a
+testdither:            test testdither.o libcupsdriver.a ../cups/$(LIBCUPSSTATIC)
        echo Linking $@...
        $(CC) $(ARCHFLAGS) $(LDFLAGS) -o $@ testdither.o libcupsdriver.a \
-               ../cups/libcups.a $(LIBGSSAPI) $(SSLLIBS) $(DNSSDLIBS) \
+               ../cups/$(LIBCUPSSTATIC) $(LIBGSSAPI) $(SSLLIBS) $(DNSSDLIBS) \
                $(COMMONLIBS) $(LIBZ)
        echo Running dither API tests...
        ./testdither > test/0-255.pgm 2>test/0-255.log
@@ -302,10 +302,10 @@ testdither:               test testdither.o libcupsdriver.a ../cups/libcups.a
 # testrgb, test RGB separation functions.
 #
 
-testrgb:               test testrgb.o libcupsdriver.a ../cups/libcups.a
+testrgb:               test testrgb.o libcupsdriver.a ../cups/$(LIBCUPSSTATIC)
        echo Linking $@...
        $(CC) $(ARCHFLAGS) $(LDFLAGS) -o $@ testrgb.o libcupsdriver.a \
-               ../cups/libcups.a $(LIBGSSAPI) $(SSLLIBS) $(DNSSDLIBS) \
+               ../cups/$(LIBCUPSSTATIC) $(LIBGSSAPI) $(SSLLIBS) $(DNSSDLIBS) \
                $(COMMONLIBS) $(LIBZ)
        echo Running RGB API tests...
        ./testrgb > test/testrgb.log 2>&1 || echo "RGB tests failed!"
index 6283b6abf3a23e9d6ddc74c12f7f501f89a55d9a..c84e4072f0d118fed8445ac653aa38af6ed42d5c 100644 (file)
@@ -87,19 +87,25 @@ gziptoany.o: ../cups/ipp.h ../cups/http.h ../cups/language.h ../cups/array.h
 gziptoany.o: ../cups/pwg-private.h ../cups/http-private.h ../cups/http.h
 gziptoany.o: ../cups/md5-private.h ../cups/ipp-private.h ../cups/ipp.h
 gziptoany.o: ../cups/language-private.h ../cups/transcode.h
+gziptoany.o: ../cups/thread-private.h
 imagetops.o: common.h ../cups/string-private.h ../config.h ../cups/cups.h
 imagetops.o: ../cups/ppd.h ../cups/cups.h ../cups/file.h ../cups/versioning.h
 imagetops.o: ../cups/ipp.h ../cups/http.h ../cups/language.h ../cups/array.h
 imagetops.o: image.h ../cups/raster.h ../cups/ppd.h
+imagetops.o: ../cups/language-private.h ../cups/transcode.h
 imagetoraster.o: common.h ../cups/string-private.h ../config.h ../cups/cups.h
 imagetoraster.o: ../cups/ppd.h ../cups/cups.h ../cups/file.h
 imagetoraster.o: ../cups/versioning.h ../cups/ipp.h ../cups/http.h
 imagetoraster.o: ../cups/language.h ../cups/array.h image-private.h image.h
 imagetoraster.o: ../cups/raster.h ../cups/ppd.h ../cups/debug-private.h
+imagetoraster.o: ../cups/language-private.h ../cups/transcode.h
 common.o: common.h ../cups/string-private.h ../config.h ../cups/cups.h
 common.o: ../cups/ppd.h ../cups/cups.h ../cups/file.h ../cups/versioning.h
 common.o: ../cups/ipp.h ../cups/http.h ../cups/language.h ../cups/array.h
-pdftops.o: ../cups/cups.h
+pdftops.o: ../cups/cups.h ../cups/ppd.h ../cups/cups.h ../cups/file.h
+pdftops.o: ../cups/versioning.h ../cups/ipp.h ../cups/http.h
+pdftops.o: ../cups/language.h ../cups/array.h ../cups/string-private.h
+pdftops.o: ../config.h ../cups/language-private.h ../cups/transcode.h
 pstext.o: pstext.h common.h ../cups/string-private.h ../config.h
 pstext.o: ../cups/cups.h ../cups/ppd.h ../cups/cups.h ../cups/file.h
 pstext.o: ../cups/versioning.h ../cups/ipp.h ../cups/http.h
@@ -235,19 +241,25 @@ gziptoany.32.o: gziptoany.c  ../cups/ipp.h ../cups/http.h ../cups/language.h ../
 gziptoany.32.o: gziptoany.c  ../cups/pwg-private.h ../cups/http-private.h ../cups/http.h
 gziptoany.32.o: gziptoany.c  ../cups/md5-private.h ../cups/ipp-private.h ../cups/ipp.h
 gziptoany.32.o: gziptoany.c  ../cups/language-private.h ../cups/transcode.h
+gziptoany.32.o: gziptoany.c  ../cups/thread-private.h
 imagetops.32.o: imagetops.c  common.h ../cups/string-private.h ../config.h ../cups/cups.h
 imagetops.32.o: imagetops.c  ../cups/ppd.h ../cups/cups.h ../cups/file.h ../cups/versioning.h
 imagetops.32.o: imagetops.c  ../cups/ipp.h ../cups/http.h ../cups/language.h ../cups/array.h
 imagetops.32.o: imagetops.c  image.h ../cups/raster.h ../cups/ppd.h
+imagetops.32.o: imagetops.c  ../cups/language-private.h ../cups/transcode.h
 imagetoraster.32.o: imagetoraster.c  common.h ../cups/string-private.h ../config.h ../cups/cups.h
 imagetoraster.32.o: imagetoraster.c  ../cups/ppd.h ../cups/cups.h ../cups/file.h
 imagetoraster.32.o: imagetoraster.c  ../cups/versioning.h ../cups/ipp.h ../cups/http.h
 imagetoraster.32.o: imagetoraster.c  ../cups/language.h ../cups/array.h image-private.h image.h
 imagetoraster.32.o: imagetoraster.c  ../cups/raster.h ../cups/ppd.h ../cups/debug-private.h
+imagetoraster.32.o: imagetoraster.c  ../cups/language-private.h ../cups/transcode.h
 common.32.o: common.c  common.h ../cups/string-private.h ../config.h ../cups/cups.h
 common.32.o: common.c  ../cups/ppd.h ../cups/cups.h ../cups/file.h ../cups/versioning.h
 common.32.o: common.c  ../cups/ipp.h ../cups/http.h ../cups/language.h ../cups/array.h
-pdftops.32.o: pdftops.c  ../cups/cups.h
+pdftops.32.o: pdftops.c  ../cups/cups.h ../cups/ppd.h ../cups/cups.h ../cups/file.h
+pdftops.32.o: pdftops.c  ../cups/versioning.h ../cups/ipp.h ../cups/http.h
+pdftops.32.o: pdftops.c  ../cups/language.h ../cups/array.h ../cups/string-private.h
+pdftops.32.o: pdftops.c  ../config.h ../cups/language-private.h ../cups/transcode.h
 pstext.32.o: pstext.c  pstext.h common.h ../cups/string-private.h ../config.h
 pstext.32.o: pstext.c  ../cups/cups.h ../cups/ppd.h ../cups/cups.h ../cups/file.h
 pstext.32.o: pstext.c  ../cups/versioning.h ../cups/ipp.h ../cups/http.h
@@ -383,19 +395,25 @@ gziptoany.64.o: gziptoany.c  ../cups/ipp.h ../cups/http.h ../cups/language.h ../
 gziptoany.64.o: gziptoany.c  ../cups/pwg-private.h ../cups/http-private.h ../cups/http.h
 gziptoany.64.o: gziptoany.c  ../cups/md5-private.h ../cups/ipp-private.h ../cups/ipp.h
 gziptoany.64.o: gziptoany.c  ../cups/language-private.h ../cups/transcode.h
+gziptoany.64.o: gziptoany.c  ../cups/thread-private.h
 imagetops.64.o: imagetops.c  common.h ../cups/string-private.h ../config.h ../cups/cups.h
 imagetops.64.o: imagetops.c  ../cups/ppd.h ../cups/cups.h ../cups/file.h ../cups/versioning.h
 imagetops.64.o: imagetops.c  ../cups/ipp.h ../cups/http.h ../cups/language.h ../cups/array.h
 imagetops.64.o: imagetops.c  image.h ../cups/raster.h ../cups/ppd.h
+imagetops.64.o: imagetops.c  ../cups/language-private.h ../cups/transcode.h
 imagetoraster.64.o: imagetoraster.c  common.h ../cups/string-private.h ../config.h ../cups/cups.h
 imagetoraster.64.o: imagetoraster.c  ../cups/ppd.h ../cups/cups.h ../cups/file.h
 imagetoraster.64.o: imagetoraster.c  ../cups/versioning.h ../cups/ipp.h ../cups/http.h
 imagetoraster.64.o: imagetoraster.c  ../cups/language.h ../cups/array.h image-private.h image.h
 imagetoraster.64.o: imagetoraster.c  ../cups/raster.h ../cups/ppd.h ../cups/debug-private.h
+imagetoraster.64.o: imagetoraster.c  ../cups/language-private.h ../cups/transcode.h
 common.64.o: common.c  common.h ../cups/string-private.h ../config.h ../cups/cups.h
 common.64.o: common.c  ../cups/ppd.h ../cups/cups.h ../cups/file.h ../cups/versioning.h
 common.64.o: common.c  ../cups/ipp.h ../cups/http.h ../cups/language.h ../cups/array.h
-pdftops.64.o: pdftops.c  ../cups/cups.h
+pdftops.64.o: pdftops.c  ../cups/cups.h ../cups/ppd.h ../cups/cups.h ../cups/file.h
+pdftops.64.o: pdftops.c  ../cups/versioning.h ../cups/ipp.h ../cups/http.h
+pdftops.64.o: pdftops.c  ../cups/language.h ../cups/array.h ../cups/string-private.h
+pdftops.64.o: pdftops.c  ../config.h ../cups/language-private.h ../cups/transcode.h
 pstext.64.o: pstext.c  pstext.h common.h ../cups/string-private.h ../config.h
 pstext.64.o: pstext.c  ../cups/cups.h ../cups/ppd.h ../cups/cups.h ../cups/file.h
 pstext.64.o: pstext.c  ../cups/versioning.h ../cups/ipp.h ../cups/http.h
index 184b3072dab81bb16900ee7967f8c329618c787e..7ddbb1dc1f2cdd2dbf6e3a834e1d7b425456cd14 100644 (file)
@@ -466,10 +466,10 @@ rastertohp:       rastertohp.o ../cups/$(LIBCUPS) $(LIBCUPSIMAGE)
 # testraster
 #
 
-testraster:    testraster.o ../cups/libcups.a libcupsimage.a
+testraster:    testraster.o ../cups/$(LIBCUPSSTATIC) libcupsimage.a
        echo Linking $@...
        $(CC) $(ARCHFLAGS) $(LDFLAGS) -o $@ testraster.o libcupsimage.a \
-               ../cups/libcups.a $(IMGLIBS) $(DSOLIBS) $(COMMONLIBS) \
+               ../cups/$(LIBCUPSSTATIC) $(IMGLIBS) $(DSOLIBS) $(COMMONLIBS) \
                $(SSLLIBS) $(DNSSDLIBS) $(LIBGSSAPI)
        echo Running raster API tests...
        ./testraster
index 748a12ff0f3e94c156292f529b5ae3a9c3fb1525..da2e94cd3672fa00609bfe241ae78c67471b570f 100644 (file)
@@ -7,7 +7,7 @@ checkpo.o: ../config.h ../cups/debug-private.h ../cups/ppd-private.h
 checkpo.o: ../cups/ppd.h ../cups/cups.h ../cups/pwg-private.h
 checkpo.o: ../cups/http-private.h ../cups/http.h ../cups/md5-private.h
 checkpo.o: ../cups/ipp-private.h ../cups/ipp.h ../cups/language-private.h
-checkpo.o: ../cups/transcode.h
+checkpo.o: ../cups/transcode.h ../cups/thread-private.h
 po2strings.o: ../cups/cups-private.h ../cups/cups.h ../cups/file.h
 po2strings.o: ../cups/versioning.h ../cups/ipp.h ../cups/http.h
 po2strings.o: ../cups/language.h ../cups/array.h ../cups/string-private.h
@@ -15,7 +15,7 @@ po2strings.o: ../config.h ../cups/debug-private.h ../cups/ppd-private.h
 po2strings.o: ../cups/ppd.h ../cups/cups.h ../cups/pwg-private.h
 po2strings.o: ../cups/http-private.h ../cups/http.h ../cups/md5-private.h
 po2strings.o: ../cups/ipp-private.h ../cups/ipp.h ../cups/language-private.h
-po2strings.o: ../cups/transcode.h
+po2strings.o: ../cups/transcode.h ../cups/thread-private.h
 translate.o: ../cups/cups-private.h ../cups/cups.h ../cups/file.h
 translate.o: ../cups/versioning.h ../cups/ipp.h ../cups/http.h
 translate.o: ../cups/language.h ../cups/array.h ../cups/string-private.h
@@ -23,4 +23,4 @@ translate.o: ../config.h ../cups/debug-private.h ../cups/ppd-private.h
 translate.o: ../cups/ppd.h ../cups/cups.h ../cups/pwg-private.h
 translate.o: ../cups/http-private.h ../cups/http.h ../cups/md5-private.h
 translate.o: ../cups/ipp-private.h ../cups/ipp.h ../cups/language-private.h
-translate.o: ../cups/transcode.h
+translate.o: ../cups/transcode.h ../cups/thread-private.h
index 25506f86fe23fb6696c69b1691064b5df5c34eff..def61eb48e172c1cefe26d1232efda5d601d32f0 100644 (file)
@@ -144,9 +144,9 @@ pot:
 # checkpo filename.po [... filenameN.po]
 #
 
-checkpo:       checkpo.o ../cups/libcups.a
+checkpo:       checkpo.o ../cups/$(LIBCUPSSTATIC)
        echo Linking $<...
-       $(CC) $(LDFLAGS) -o checkpo checkpo.o ../cups/libcups.a \
+       $(CC) $(LDFLAGS) -o checkpo checkpo.o ../cups/$(LIBCUPSSTATIC) \
                $(LIBGSSAPI) $(SSLLIBS) $(DNSSDLIBS) $(COMMONLIBS) $(LIBZ)
 
 checkall:      checkpo
@@ -162,9 +162,9 @@ checkall:   checkpo
 # po2strings filename.po filename.strings
 #
 
-po2strings:    po2strings.o ../cups/libcups.a
+po2strings:    po2strings.o ../cups/$(LIBCUPSSTATIC)
        echo Linking $<...
-       $(CC) $(LDFLAGS) -o po2strings po2strings.o ../cups/libcups.a \
+       $(CC) $(LDFLAGS) -o po2strings po2strings.o ../cups/$(LIBCUPSSTATIC) \
                $(LIBGSSAPI) $(SSLLIBS) $(DNSSDLIBS) $(COMMONLIBS) $(LIBZ)
 
 
@@ -187,9 +187,9 @@ strings2po: strings2po.o
 # translate outfile language
 #
 
-translate:     translate.o ../cups/libcups.a
+translate:     translate.o ../cups/$(LIBCUPSSTATIC)
        echo Linking $<...
-       $(CC) $(LDFLAGS) -o translate translate.o ../cups/libcups.a \
+       $(CC) $(LDFLAGS) -o translate translate.o ../cups/$(LIBCUPSSTATIC) \
                $(LIBGSSAPI) $(SSLLIBS) $(DNSSDLIBS) $(COMMONLIBS) $(LIBZ)
 
 
index d5b07be19df4c9152859bdbb1eb1dd504dbe545a..42c909e102885497dfd5ce23ac2be5f1312c2ca3 100644 (file)
@@ -8,6 +8,7 @@ ppdc-array.o: ../cups/ppd-private.h ../cups/ppd.h ../cups/cups.h
 ppdc-array.o: ../cups/pwg-private.h ../cups/http-private.h ../cups/http.h
 ppdc-array.o: ../cups/md5-private.h ../cups/ipp-private.h ../cups/ipp.h
 ppdc-array.o: ../cups/language-private.h ../cups/transcode.h
+ppdc-array.o: ../cups/thread-private.h
 ppdc-attr.o: ppdc-private.h ppdc.h ../cups/file.h ../cups/versioning.h
 ppdc-attr.o: ../cups/cups-private.h ../cups/cups.h ../cups/file.h
 ppdc-attr.o: ../cups/ipp.h ../cups/http.h ../cups/language.h ../cups/array.h
@@ -16,6 +17,7 @@ ppdc-attr.o: ../cups/ppd-private.h ../cups/ppd.h ../cups/cups.h
 ppdc-attr.o: ../cups/pwg-private.h ../cups/http-private.h ../cups/http.h
 ppdc-attr.o: ../cups/md5-private.h ../cups/ipp-private.h ../cups/ipp.h
 ppdc-attr.o: ../cups/language-private.h ../cups/transcode.h
+ppdc-attr.o: ../cups/thread-private.h
 ppdc-catalog.o: ppdc-private.h ppdc.h ../cups/file.h ../cups/versioning.h
 ppdc-catalog.o: ../cups/cups-private.h ../cups/cups.h ../cups/file.h
 ppdc-catalog.o: ../cups/ipp.h ../cups/http.h ../cups/language.h
@@ -24,6 +26,7 @@ ppdc-catalog.o: ../cups/debug-private.h ../cups/ppd-private.h ../cups/ppd.h
 ppdc-catalog.o: ../cups/cups.h ../cups/pwg-private.h ../cups/http-private.h
 ppdc-catalog.o: ../cups/http.h ../cups/md5-private.h ../cups/ipp-private.h
 ppdc-catalog.o: ../cups/ipp.h ../cups/language-private.h ../cups/transcode.h
+ppdc-catalog.o: ../cups/thread-private.h
 ppdc-choice.o: ppdc-private.h ppdc.h ../cups/file.h ../cups/versioning.h
 ppdc-choice.o: ../cups/cups-private.h ../cups/cups.h ../cups/file.h
 ppdc-choice.o: ../cups/ipp.h ../cups/http.h ../cups/language.h
@@ -32,6 +35,7 @@ ppdc-choice.o: ../cups/debug-private.h ../cups/ppd-private.h ../cups/ppd.h
 ppdc-choice.o: ../cups/cups.h ../cups/pwg-private.h ../cups/http-private.h
 ppdc-choice.o: ../cups/http.h ../cups/md5-private.h ../cups/ipp-private.h
 ppdc-choice.o: ../cups/ipp.h ../cups/language-private.h ../cups/transcode.h
+ppdc-choice.o: ../cups/thread-private.h
 ppdc-constraint.o: ppdc-private.h ppdc.h ../cups/file.h ../cups/versioning.h
 ppdc-constraint.o: ../cups/cups-private.h ../cups/cups.h ../cups/file.h
 ppdc-constraint.o: ../cups/ipp.h ../cups/http.h ../cups/language.h
@@ -41,6 +45,7 @@ ppdc-constraint.o: ../cups/ppd.h ../cups/cups.h ../cups/pwg-private.h
 ppdc-constraint.o: ../cups/http-private.h ../cups/http.h
 ppdc-constraint.o: ../cups/md5-private.h ../cups/ipp-private.h ../cups/ipp.h
 ppdc-constraint.o: ../cups/language-private.h ../cups/transcode.h
+ppdc-constraint.o: ../cups/thread-private.h
 ppdc-driver.o: ppdc-private.h ppdc.h ../cups/file.h ../cups/versioning.h
 ppdc-driver.o: ../cups/cups-private.h ../cups/cups.h ../cups/file.h
 ppdc-driver.o: ../cups/ipp.h ../cups/http.h ../cups/language.h
@@ -49,6 +54,7 @@ ppdc-driver.o: ../cups/debug-private.h ../cups/ppd-private.h ../cups/ppd.h
 ppdc-driver.o: ../cups/cups.h ../cups/pwg-private.h ../cups/http-private.h
 ppdc-driver.o: ../cups/http.h ../cups/md5-private.h ../cups/ipp-private.h
 ppdc-driver.o: ../cups/ipp.h ../cups/language-private.h ../cups/transcode.h
+ppdc-driver.o: ../cups/thread-private.h
 ppdc-file.o: ppdc-private.h ppdc.h ../cups/file.h ../cups/versioning.h
 ppdc-file.o: ../cups/cups-private.h ../cups/cups.h ../cups/file.h
 ppdc-file.o: ../cups/ipp.h ../cups/http.h ../cups/language.h ../cups/array.h
@@ -57,6 +63,7 @@ ppdc-file.o: ../cups/ppd-private.h ../cups/ppd.h ../cups/cups.h
 ppdc-file.o: ../cups/pwg-private.h ../cups/http-private.h ../cups/http.h
 ppdc-file.o: ../cups/md5-private.h ../cups/ipp-private.h ../cups/ipp.h
 ppdc-file.o: ../cups/language-private.h ../cups/transcode.h
+ppdc-file.o: ../cups/thread-private.h
 ppdc-filter.o: ppdc-private.h ppdc.h ../cups/file.h ../cups/versioning.h
 ppdc-filter.o: ../cups/cups-private.h ../cups/cups.h ../cups/file.h
 ppdc-filter.o: ../cups/ipp.h ../cups/http.h ../cups/language.h
@@ -65,6 +72,7 @@ ppdc-filter.o: ../cups/debug-private.h ../cups/ppd-private.h ../cups/ppd.h
 ppdc-filter.o: ../cups/cups.h ../cups/pwg-private.h ../cups/http-private.h
 ppdc-filter.o: ../cups/http.h ../cups/md5-private.h ../cups/ipp-private.h
 ppdc-filter.o: ../cups/ipp.h ../cups/language-private.h ../cups/transcode.h
+ppdc-filter.o: ../cups/thread-private.h
 ppdc-font.o: ppdc-private.h ppdc.h ../cups/file.h ../cups/versioning.h
 ppdc-font.o: ../cups/cups-private.h ../cups/cups.h ../cups/file.h
 ppdc-font.o: ../cups/ipp.h ../cups/http.h ../cups/language.h ../cups/array.h
@@ -73,6 +81,7 @@ ppdc-font.o: ../cups/ppd-private.h ../cups/ppd.h ../cups/cups.h
 ppdc-font.o: ../cups/pwg-private.h ../cups/http-private.h ../cups/http.h
 ppdc-font.o: ../cups/md5-private.h ../cups/ipp-private.h ../cups/ipp.h
 ppdc-font.o: ../cups/language-private.h ../cups/transcode.h
+ppdc-font.o: ../cups/thread-private.h
 ppdc-group.o: ppdc-private.h ppdc.h ../cups/file.h ../cups/versioning.h
 ppdc-group.o: ../cups/cups-private.h ../cups/cups.h ../cups/file.h
 ppdc-group.o: ../cups/ipp.h ../cups/http.h ../cups/language.h ../cups/array.h
@@ -81,6 +90,7 @@ ppdc-group.o: ../cups/ppd-private.h ../cups/ppd.h ../cups/cups.h
 ppdc-group.o: ../cups/pwg-private.h ../cups/http-private.h ../cups/http.h
 ppdc-group.o: ../cups/md5-private.h ../cups/ipp-private.h ../cups/ipp.h
 ppdc-group.o: ../cups/language-private.h ../cups/transcode.h
+ppdc-group.o: ../cups/thread-private.h
 ppdc-import.o: ppdc-private.h ppdc.h ../cups/file.h ../cups/versioning.h
 ppdc-import.o: ../cups/cups-private.h ../cups/cups.h ../cups/file.h
 ppdc-import.o: ../cups/ipp.h ../cups/http.h ../cups/language.h
@@ -89,6 +99,7 @@ ppdc-import.o: ../cups/debug-private.h ../cups/ppd-private.h ../cups/ppd.h
 ppdc-import.o: ../cups/cups.h ../cups/pwg-private.h ../cups/http-private.h
 ppdc-import.o: ../cups/http.h ../cups/md5-private.h ../cups/ipp-private.h
 ppdc-import.o: ../cups/ipp.h ../cups/language-private.h ../cups/transcode.h
+ppdc-import.o: ../cups/thread-private.h
 ppdc-mediasize.o: ppdc-private.h ppdc.h ../cups/file.h ../cups/versioning.h
 ppdc-mediasize.o: ../cups/cups-private.h ../cups/cups.h ../cups/file.h
 ppdc-mediasize.o: ../cups/ipp.h ../cups/http.h ../cups/language.h
@@ -97,7 +108,7 @@ ppdc-mediasize.o: ../cups/debug-private.h ../cups/ppd-private.h ../cups/ppd.h
 ppdc-mediasize.o: ../cups/cups.h ../cups/pwg-private.h ../cups/http-private.h
 ppdc-mediasize.o: ../cups/http.h ../cups/md5-private.h ../cups/ipp-private.h
 ppdc-mediasize.o: ../cups/ipp.h ../cups/language-private.h
-ppdc-mediasize.o: ../cups/transcode.h
+ppdc-mediasize.o: ../cups/transcode.h ../cups/thread-private.h
 ppdc-message.o: ppdc-private.h ppdc.h ../cups/file.h ../cups/versioning.h
 ppdc-message.o: ../cups/cups-private.h ../cups/cups.h ../cups/file.h
 ppdc-message.o: ../cups/ipp.h ../cups/http.h ../cups/language.h
@@ -106,6 +117,7 @@ ppdc-message.o: ../cups/debug-private.h ../cups/ppd-private.h ../cups/ppd.h
 ppdc-message.o: ../cups/cups.h ../cups/pwg-private.h ../cups/http-private.h
 ppdc-message.o: ../cups/http.h ../cups/md5-private.h ../cups/ipp-private.h
 ppdc-message.o: ../cups/ipp.h ../cups/language-private.h ../cups/transcode.h
+ppdc-message.o: ../cups/thread-private.h
 ppdc-option.o: ppdc-private.h ppdc.h ../cups/file.h ../cups/versioning.h
 ppdc-option.o: ../cups/cups-private.h ../cups/cups.h ../cups/file.h
 ppdc-option.o: ../cups/ipp.h ../cups/http.h ../cups/language.h
@@ -114,6 +126,7 @@ ppdc-option.o: ../cups/debug-private.h ../cups/ppd-private.h ../cups/ppd.h
 ppdc-option.o: ../cups/cups.h ../cups/pwg-private.h ../cups/http-private.h
 ppdc-option.o: ../cups/http.h ../cups/md5-private.h ../cups/ipp-private.h
 ppdc-option.o: ../cups/ipp.h ../cups/language-private.h ../cups/transcode.h
+ppdc-option.o: ../cups/thread-private.h
 ppdc-profile.o: ppdc-private.h ppdc.h ../cups/file.h ../cups/versioning.h
 ppdc-profile.o: ../cups/cups-private.h ../cups/cups.h ../cups/file.h
 ppdc-profile.o: ../cups/ipp.h ../cups/http.h ../cups/language.h
@@ -122,6 +135,7 @@ ppdc-profile.o: ../cups/debug-private.h ../cups/ppd-private.h ../cups/ppd.h
 ppdc-profile.o: ../cups/cups.h ../cups/pwg-private.h ../cups/http-private.h
 ppdc-profile.o: ../cups/http.h ../cups/md5-private.h ../cups/ipp-private.h
 ppdc-profile.o: ../cups/ipp.h ../cups/language-private.h ../cups/transcode.h
+ppdc-profile.o: ../cups/thread-private.h
 ppdc-shared.o: ppdc-private.h ppdc.h ../cups/file.h ../cups/versioning.h
 ppdc-shared.o: ../cups/cups-private.h ../cups/cups.h ../cups/file.h
 ppdc-shared.o: ../cups/ipp.h ../cups/http.h ../cups/language.h
@@ -130,6 +144,7 @@ ppdc-shared.o: ../cups/debug-private.h ../cups/ppd-private.h ../cups/ppd.h
 ppdc-shared.o: ../cups/cups.h ../cups/pwg-private.h ../cups/http-private.h
 ppdc-shared.o: ../cups/http.h ../cups/md5-private.h ../cups/ipp-private.h
 ppdc-shared.o: ../cups/ipp.h ../cups/language-private.h ../cups/transcode.h
+ppdc-shared.o: ../cups/thread-private.h
 ppdc-source.o: ppdc-private.h ppdc.h ../cups/file.h ../cups/versioning.h
 ppdc-source.o: ../cups/cups-private.h ../cups/cups.h ../cups/file.h
 ppdc-source.o: ../cups/ipp.h ../cups/http.h ../cups/language.h
@@ -138,8 +153,9 @@ ppdc-source.o: ../cups/debug-private.h ../cups/ppd-private.h ../cups/ppd.h
 ppdc-source.o: ../cups/cups.h ../cups/pwg-private.h ../cups/http-private.h
 ppdc-source.o: ../cups/http.h ../cups/md5-private.h ../cups/ipp-private.h
 ppdc-source.o: ../cups/ipp.h ../cups/language-private.h ../cups/transcode.h
-ppdc-source.o: ../cups/raster.h ../cups/ppd.h ../data/epson.h ../data/escp.h
-ppdc-source.o: ../data/hp.h ../data/label.h ../data/pcl.h
+ppdc-source.o: ../cups/thread-private.h ../cups/raster.h ../cups/ppd.h
+ppdc-source.o: ../data/epson.h ../data/escp.h ../data/hp.h ../data/label.h
+ppdc-source.o: ../data/pcl.h
 ppdc-string.o: ppdc-private.h ppdc.h ../cups/file.h ../cups/versioning.h
 ppdc-string.o: ../cups/cups-private.h ../cups/cups.h ../cups/file.h
 ppdc-string.o: ../cups/ipp.h ../cups/http.h ../cups/language.h
@@ -148,6 +164,7 @@ ppdc-string.o: ../cups/debug-private.h ../cups/ppd-private.h ../cups/ppd.h
 ppdc-string.o: ../cups/cups.h ../cups/pwg-private.h ../cups/http-private.h
 ppdc-string.o: ../cups/http.h ../cups/md5-private.h ../cups/ipp-private.h
 ppdc-string.o: ../cups/ipp.h ../cups/language-private.h ../cups/transcode.h
+ppdc-string.o: ../cups/thread-private.h
 ppdc-variable.o: ppdc-private.h ppdc.h ../cups/file.h ../cups/versioning.h
 ppdc-variable.o: ../cups/cups-private.h ../cups/cups.h ../cups/file.h
 ppdc-variable.o: ../cups/ipp.h ../cups/http.h ../cups/language.h
@@ -156,6 +173,7 @@ ppdc-variable.o: ../cups/debug-private.h ../cups/ppd-private.h ../cups/ppd.h
 ppdc-variable.o: ../cups/cups.h ../cups/pwg-private.h ../cups/http-private.h
 ppdc-variable.o: ../cups/http.h ../cups/md5-private.h ../cups/ipp-private.h
 ppdc-variable.o: ../cups/ipp.h ../cups/language-private.h ../cups/transcode.h
+ppdc-variable.o: ../cups/thread-private.h
 genstrings.o: ppdc-private.h ppdc.h ../cups/file.h ../cups/versioning.h
 genstrings.o: ../cups/cups-private.h ../cups/cups.h ../cups/file.h
 genstrings.o: ../cups/ipp.h ../cups/http.h ../cups/language.h ../cups/array.h
@@ -164,6 +182,7 @@ genstrings.o: ../cups/ppd-private.h ../cups/ppd.h ../cups/cups.h
 genstrings.o: ../cups/pwg-private.h ../cups/http-private.h ../cups/http.h
 genstrings.o: ../cups/md5-private.h ../cups/ipp-private.h ../cups/ipp.h
 genstrings.o: ../cups/language-private.h ../cups/transcode.h
+genstrings.o: ../cups/thread-private.h
 ppdc.o: ppdc-private.h ppdc.h ../cups/file.h ../cups/versioning.h
 ppdc.o: ../cups/cups-private.h ../cups/cups.h ../cups/file.h ../cups/ipp.h
 ppdc.o: ../cups/http.h ../cups/language.h ../cups/array.h
@@ -172,6 +191,7 @@ ppdc.o: ../cups/ppd-private.h ../cups/ppd.h ../cups/cups.h
 ppdc.o: ../cups/pwg-private.h ../cups/http-private.h ../cups/http.h
 ppdc.o: ../cups/md5-private.h ../cups/ipp-private.h ../cups/ipp.h
 ppdc.o: ../cups/language-private.h ../cups/transcode.h
+ppdc.o: ../cups/thread-private.h
 ppdhtml.o: ppdc-private.h ppdc.h ../cups/file.h ../cups/versioning.h
 ppdhtml.o: ../cups/cups-private.h ../cups/cups.h ../cups/file.h ../cups/ipp.h
 ppdhtml.o: ../cups/http.h ../cups/language.h ../cups/array.h
@@ -180,6 +200,7 @@ ppdhtml.o: ../cups/ppd-private.h ../cups/ppd.h ../cups/cups.h
 ppdhtml.o: ../cups/pwg-private.h ../cups/http-private.h ../cups/http.h
 ppdhtml.o: ../cups/md5-private.h ../cups/ipp-private.h ../cups/ipp.h
 ppdhtml.o: ../cups/language-private.h ../cups/transcode.h
+ppdhtml.o: ../cups/thread-private.h
 ppdi.o: ppdc-private.h ppdc.h ../cups/file.h ../cups/versioning.h
 ppdi.o: ../cups/cups-private.h ../cups/cups.h ../cups/file.h ../cups/ipp.h
 ppdi.o: ../cups/http.h ../cups/language.h ../cups/array.h
@@ -188,6 +209,7 @@ ppdi.o: ../cups/ppd-private.h ../cups/ppd.h ../cups/cups.h
 ppdi.o: ../cups/pwg-private.h ../cups/http-private.h ../cups/http.h
 ppdi.o: ../cups/md5-private.h ../cups/ipp-private.h ../cups/ipp.h
 ppdi.o: ../cups/language-private.h ../cups/transcode.h
+ppdi.o: ../cups/thread-private.h
 ppdmerge.o: ../cups/cups-private.h ../cups/cups.h ../cups/file.h
 ppdmerge.o: ../cups/ipp.h ../cups/http.h ../cups/versioning.h
 ppdmerge.o: ../cups/language.h ../cups/array.h ../cups/string-private.h
@@ -195,7 +217,8 @@ ppdmerge.o: ../config.h ../cups/debug-private.h ../cups/ppd-private.h
 ppdmerge.o: ../cups/ppd.h ../cups/cups.h ../cups/pwg-private.h
 ppdmerge.o: ../cups/http-private.h ../cups/http.h ../cups/md5-private.h
 ppdmerge.o: ../cups/ipp-private.h ../cups/ipp.h ../cups/language-private.h
-ppdmerge.o: ../cups/transcode.h ../cups/ppd-private.h ../cups/array.h
+ppdmerge.o: ../cups/transcode.h ../cups/thread-private.h
+ppdmerge.o: ../cups/ppd-private.h ../cups/array.h
 ppdpo.o: ppdc-private.h ppdc.h ../cups/file.h ../cups/versioning.h
 ppdpo.o: ../cups/cups-private.h ../cups/cups.h ../cups/file.h ../cups/ipp.h
 ppdpo.o: ../cups/http.h ../cups/language.h ../cups/array.h
@@ -204,6 +227,7 @@ ppdpo.o: ../cups/ppd-private.h ../cups/ppd.h ../cups/cups.h
 ppdpo.o: ../cups/pwg-private.h ../cups/http-private.h ../cups/http.h
 ppdpo.o: ../cups/md5-private.h ../cups/ipp-private.h ../cups/ipp.h
 ppdpo.o: ../cups/language-private.h ../cups/transcode.h
+ppdpo.o: ../cups/thread-private.h
 testcatalog.o: ppdc-private.h ppdc.h ../cups/file.h ../cups/versioning.h
 testcatalog.o: ../cups/cups-private.h ../cups/cups.h ../cups/file.h
 testcatalog.o: ../cups/ipp.h ../cups/http.h ../cups/language.h
@@ -212,3 +236,4 @@ testcatalog.o: ../cups/debug-private.h ../cups/ppd-private.h ../cups/ppd.h
 testcatalog.o: ../cups/cups.h ../cups/pwg-private.h ../cups/http-private.h
 testcatalog.o: ../cups/http.h ../cups/md5-private.h ../cups/ipp-private.h
 testcatalog.o: ../cups/ipp.h ../cups/language-private.h ../cups/transcode.h
+testcatalog.o: ../cups/thread-private.h
index f58b6f88249e0f0d72c3045eae992995e25f8770..9f9e1993214fbe488a82e0ffc63f6d7cd33a3b6c 100644 (file)
@@ -256,7 +256,7 @@ ppdc:                       ppdc.o $(LIBCUPSPPDC) ../cups/$(LIBCUPS)
        $(CXX) $(LDFLAGS) -o $@ ppdc.o -L. -lcupsppdc $(LIBS)
 
 
-ppdc-static:           ppdc.o libcupsppdc.a  ../cups/$(LIBCUPSSTATIC) foo.drv foo-fr.po
+ppdc-static:           ppdc.o libcupsppdc.a ../cups/$(LIBCUPSSTATIC) foo.drv foo-fr.po
        echo Linking $@...
        $(CXX) $(ARCHFLAGS) $(LDFLAGS) -o ppdc-static ppdc.o libcupsppdc.a \
                ../cups/$(LIBCUPSSTATIC) $(LIBGSSAPI) $(SSLLIBS) $(DNSSDLIBS) \
index a51137eb601e91adf2ba5ea0574aa461ac0e6a79..29787997d3450127f987ad5c0d84beb1c52f4905 100644 (file)
@@ -117,7 +117,7 @@ Attribute "FileSystem" "" "False"
 Attribute "LandscapeOrientation" "" "Plus90"
 Attribute "TTRasterizer" "" "Type42"
 
-Copyright "Copyright 2007-2008 by Apple Inc."
+Copyright "Copyright 2007-2010 by Apple Inc."
 Copyright "Copyright 1997-2007 by Easy Software Products."
 Copyright ""
 Copyright "These coded instructions, statements, and computer programs are the"
@@ -128,7 +128,7 @@ Copyright "file is missing or damaged, see the license at \"http://www.cups.org/
 
 Font *
 
-Version "1.4"
+Version "1.5"
 
 // Dymo Label Printer
 {
index d32c5c9ba82624cb93bea6245263b85c729fe0ad..9d86f98dc8822fe1a2dd197a0ce4abefacf0f8a9 100644 (file)
@@ -6,10 +6,11 @@ auth.o: ../cups/array.h ../cups/string-private.h ../config.h
 auth.o: ../cups/debug-private.h ../cups/ppd-private.h ../cups/ppd.h
 auth.o: ../cups/cups.h ../cups/pwg-private.h ../cups/http-private.h
 auth.o: ../cups/http.h ../cups/md5-private.h ../cups/ipp-private.h
-auth.o: ../cups/ipp.h ../cups/language-private.h ../cups/transcode.h mime.h
-auth.o: ../cups/array.h ../cups/file.h sysman.h statbuf.h cert.h auth.h
-auth.o: client.h policy.h printers.h ../cups/pwg-private.h classes.h job.h
-auth.o: conf.h banners.h dirsvc.h network.h subscriptions.h
+auth.o: ../cups/ipp.h ../cups/language-private.h ../cups/transcode.h
+auth.o: ../cups/thread-private.h mime.h ../cups/array.h ../cups/file.h
+auth.o: sysman.h statbuf.h cert.h auth.h client.h policy.h printers.h
+auth.o: ../cups/pwg-private.h classes.h job.h conf.h banners.h dirsvc.h
+auth.o: network.h subscriptions.h
 banners.o: cupsd.h ../cups/cups-private.h ../cups/cups.h ../cups/file.h
 banners.o: ../cups/versioning.h ../cups/ipp.h ../cups/http.h
 banners.o: ../cups/language.h ../cups/array.h ../cups/string-private.h
@@ -17,20 +18,21 @@ banners.o: ../config.h ../cups/debug-private.h ../cups/ppd-private.h
 banners.o: ../cups/ppd.h ../cups/cups.h ../cups/pwg-private.h
 banners.o: ../cups/http-private.h ../cups/http.h ../cups/md5-private.h
 banners.o: ../cups/ipp-private.h ../cups/ipp.h ../cups/language-private.h
-banners.o: ../cups/transcode.h mime.h ../cups/array.h ../cups/file.h sysman.h
-banners.o: statbuf.h cert.h auth.h client.h policy.h printers.h
-banners.o: ../cups/pwg-private.h classes.h job.h conf.h banners.h dirsvc.h
-banners.o: network.h subscriptions.h ../cups/dir.h
+banners.o: ../cups/transcode.h ../cups/thread-private.h mime.h
+banners.o: ../cups/array.h ../cups/file.h sysman.h statbuf.h cert.h auth.h
+banners.o: client.h policy.h printers.h ../cups/pwg-private.h classes.h job.h
+banners.o: conf.h banners.h dirsvc.h network.h subscriptions.h ../cups/dir.h
 cert.o: cupsd.h ../cups/cups-private.h ../cups/cups.h ../cups/file.h
 cert.o: ../cups/versioning.h ../cups/ipp.h ../cups/http.h ../cups/language.h
 cert.o: ../cups/array.h ../cups/string-private.h ../config.h
 cert.o: ../cups/debug-private.h ../cups/ppd-private.h ../cups/ppd.h
 cert.o: ../cups/cups.h ../cups/pwg-private.h ../cups/http-private.h
 cert.o: ../cups/http.h ../cups/md5-private.h ../cups/ipp-private.h
-cert.o: ../cups/ipp.h ../cups/language-private.h ../cups/transcode.h mime.h
-cert.o: ../cups/array.h ../cups/file.h sysman.h statbuf.h cert.h auth.h
-cert.o: client.h policy.h printers.h ../cups/pwg-private.h classes.h job.h
-cert.o: conf.h banners.h dirsvc.h network.h subscriptions.h
+cert.o: ../cups/ipp.h ../cups/language-private.h ../cups/transcode.h
+cert.o: ../cups/thread-private.h mime.h ../cups/array.h ../cups/file.h
+cert.o: sysman.h statbuf.h cert.h auth.h client.h policy.h printers.h
+cert.o: ../cups/pwg-private.h classes.h job.h conf.h banners.h dirsvc.h
+cert.o: network.h subscriptions.h
 classes.o: cupsd.h ../cups/cups-private.h ../cups/cups.h ../cups/file.h
 classes.o: ../cups/versioning.h ../cups/ipp.h ../cups/http.h
 classes.o: ../cups/language.h ../cups/array.h ../cups/string-private.h
@@ -38,10 +40,10 @@ classes.o: ../config.h ../cups/debug-private.h ../cups/ppd-private.h
 classes.o: ../cups/ppd.h ../cups/cups.h ../cups/pwg-private.h
 classes.o: ../cups/http-private.h ../cups/http.h ../cups/md5-private.h
 classes.o: ../cups/ipp-private.h ../cups/ipp.h ../cups/language-private.h
-classes.o: ../cups/transcode.h mime.h ../cups/array.h ../cups/file.h sysman.h
-classes.o: statbuf.h cert.h auth.h client.h policy.h printers.h
-classes.o: ../cups/pwg-private.h classes.h job.h conf.h banners.h dirsvc.h
-classes.o: network.h subscriptions.h
+classes.o: ../cups/transcode.h ../cups/thread-private.h mime.h
+classes.o: ../cups/array.h ../cups/file.h sysman.h statbuf.h cert.h auth.h
+classes.o: client.h policy.h printers.h ../cups/pwg-private.h classes.h job.h
+classes.o: conf.h banners.h dirsvc.h network.h subscriptions.h
 client.o: cupsd.h ../cups/cups-private.h ../cups/cups.h ../cups/file.h
 client.o: ../cups/versioning.h ../cups/ipp.h ../cups/http.h
 client.o: ../cups/language.h ../cups/array.h ../cups/string-private.h
@@ -49,20 +51,21 @@ client.o: ../config.h ../cups/debug-private.h ../cups/ppd-private.h
 client.o: ../cups/ppd.h ../cups/cups.h ../cups/pwg-private.h
 client.o: ../cups/http-private.h ../cups/http.h ../cups/md5-private.h
 client.o: ../cups/ipp-private.h ../cups/ipp.h ../cups/language-private.h
-client.o: ../cups/transcode.h mime.h ../cups/array.h ../cups/file.h sysman.h
-client.o: statbuf.h cert.h auth.h client.h policy.h printers.h
-client.o: ../cups/pwg-private.h classes.h job.h conf.h banners.h dirsvc.h
-client.o: network.h subscriptions.h
+client.o: ../cups/transcode.h ../cups/thread-private.h mime.h ../cups/array.h
+client.o: ../cups/file.h sysman.h statbuf.h cert.h auth.h client.h policy.h
+client.o: printers.h ../cups/pwg-private.h classes.h job.h conf.h banners.h
+client.o: dirsvc.h network.h subscriptions.h
 conf.o: cupsd.h ../cups/cups-private.h ../cups/cups.h ../cups/file.h
 conf.o: ../cups/versioning.h ../cups/ipp.h ../cups/http.h ../cups/language.h
 conf.o: ../cups/array.h ../cups/string-private.h ../config.h
 conf.o: ../cups/debug-private.h ../cups/ppd-private.h ../cups/ppd.h
 conf.o: ../cups/cups.h ../cups/pwg-private.h ../cups/http-private.h
 conf.o: ../cups/http.h ../cups/md5-private.h ../cups/ipp-private.h
-conf.o: ../cups/ipp.h ../cups/language-private.h ../cups/transcode.h mime.h
-conf.o: ../cups/array.h ../cups/file.h sysman.h statbuf.h cert.h auth.h
-conf.o: client.h policy.h printers.h ../cups/pwg-private.h classes.h job.h
-conf.o: conf.h banners.h dirsvc.h network.h subscriptions.h
+conf.o: ../cups/ipp.h ../cups/language-private.h ../cups/transcode.h
+conf.o: ../cups/thread-private.h mime.h ../cups/array.h ../cups/file.h
+conf.o: sysman.h statbuf.h cert.h auth.h client.h policy.h printers.h
+conf.o: ../cups/pwg-private.h classes.h job.h conf.h banners.h dirsvc.h
+conf.o: network.h subscriptions.h
 dirsvc.o: cupsd.h ../cups/cups-private.h ../cups/cups.h ../cups/file.h
 dirsvc.o: ../cups/versioning.h ../cups/ipp.h ../cups/http.h
 dirsvc.o: ../cups/language.h ../cups/array.h ../cups/string-private.h
@@ -70,41 +73,43 @@ dirsvc.o: ../config.h ../cups/debug-private.h ../cups/ppd-private.h
 dirsvc.o: ../cups/ppd.h ../cups/cups.h ../cups/pwg-private.h
 dirsvc.o: ../cups/http-private.h ../cups/http.h ../cups/md5-private.h
 dirsvc.o: ../cups/ipp-private.h ../cups/ipp.h ../cups/language-private.h
-dirsvc.o: ../cups/transcode.h mime.h ../cups/array.h ../cups/file.h sysman.h
-dirsvc.o: statbuf.h cert.h auth.h client.h policy.h printers.h
-dirsvc.o: ../cups/pwg-private.h classes.h job.h conf.h banners.h dirsvc.h
-dirsvc.o: network.h subscriptions.h
+dirsvc.o: ../cups/transcode.h ../cups/thread-private.h mime.h ../cups/array.h
+dirsvc.o: ../cups/file.h sysman.h statbuf.h cert.h auth.h client.h policy.h
+dirsvc.o: printers.h ../cups/pwg-private.h classes.h job.h conf.h banners.h
+dirsvc.o: dirsvc.h network.h subscriptions.h
 env.o: cupsd.h ../cups/cups-private.h ../cups/cups.h ../cups/file.h
 env.o: ../cups/versioning.h ../cups/ipp.h ../cups/http.h ../cups/language.h
 env.o: ../cups/array.h ../cups/string-private.h ../config.h
 env.o: ../cups/debug-private.h ../cups/ppd-private.h ../cups/ppd.h
 env.o: ../cups/cups.h ../cups/pwg-private.h ../cups/http-private.h
 env.o: ../cups/http.h ../cups/md5-private.h ../cups/ipp-private.h
-env.o: ../cups/ipp.h ../cups/language-private.h ../cups/transcode.h mime.h
-env.o: ../cups/array.h ../cups/file.h sysman.h statbuf.h cert.h auth.h
-env.o: client.h policy.h printers.h ../cups/pwg-private.h classes.h job.h
-env.o: conf.h banners.h dirsvc.h network.h subscriptions.h
+env.o: ../cups/ipp.h ../cups/language-private.h ../cups/transcode.h
+env.o: ../cups/thread-private.h mime.h ../cups/array.h ../cups/file.h
+env.o: sysman.h statbuf.h cert.h auth.h client.h policy.h printers.h
+env.o: ../cups/pwg-private.h classes.h job.h conf.h banners.h dirsvc.h
+env.o: network.h subscriptions.h
 main.o: cupsd.h ../cups/cups-private.h ../cups/cups.h ../cups/file.h
 main.o: ../cups/versioning.h ../cups/ipp.h ../cups/http.h ../cups/language.h
 main.o: ../cups/array.h ../cups/string-private.h ../config.h
 main.o: ../cups/debug-private.h ../cups/ppd-private.h ../cups/ppd.h
 main.o: ../cups/cups.h ../cups/pwg-private.h ../cups/http-private.h
 main.o: ../cups/http.h ../cups/md5-private.h ../cups/ipp-private.h
-main.o: ../cups/ipp.h ../cups/language-private.h ../cups/transcode.h mime.h
-main.o: ../cups/array.h ../cups/file.h sysman.h statbuf.h cert.h auth.h
-main.o: client.h policy.h printers.h ../cups/pwg-private.h classes.h job.h
-main.o: conf.h banners.h dirsvc.h network.h subscriptions.h ../cups/dir.h
+main.o: ../cups/ipp.h ../cups/language-private.h ../cups/transcode.h
+main.o: ../cups/thread-private.h mime.h ../cups/array.h ../cups/file.h
+main.o: sysman.h statbuf.h cert.h auth.h client.h policy.h printers.h
+main.o: ../cups/pwg-private.h classes.h job.h conf.h banners.h dirsvc.h
+main.o: network.h subscriptions.h ../cups/dir.h
 ipp.o: cupsd.h ../cups/cups-private.h ../cups/cups.h ../cups/file.h
 ipp.o: ../cups/versioning.h ../cups/ipp.h ../cups/http.h ../cups/language.h
 ipp.o: ../cups/array.h ../cups/string-private.h ../config.h
 ipp.o: ../cups/debug-private.h ../cups/ppd-private.h ../cups/ppd.h
 ipp.o: ../cups/cups.h ../cups/pwg-private.h ../cups/http-private.h
 ipp.o: ../cups/http.h ../cups/md5-private.h ../cups/ipp-private.h
-ipp.o: ../cups/ipp.h ../cups/language-private.h ../cups/transcode.h mime.h
-ipp.o: ../cups/array.h ../cups/file.h sysman.h statbuf.h cert.h auth.h
-ipp.o: client.h policy.h printers.h ../cups/pwg-private.h classes.h job.h
-ipp.o: conf.h banners.h dirsvc.h network.h subscriptions.h
-ipp.o: ../cups/ppd-private.h
+ipp.o: ../cups/ipp.h ../cups/language-private.h ../cups/transcode.h
+ipp.o: ../cups/thread-private.h mime.h ../cups/array.h ../cups/file.h
+ipp.o: sysman.h statbuf.h cert.h auth.h client.h policy.h printers.h
+ipp.o: ../cups/pwg-private.h classes.h job.h conf.h banners.h dirsvc.h
+ipp.o: network.h subscriptions.h ../cups/ppd-private.h
 listen.o: cupsd.h ../cups/cups-private.h ../cups/cups.h ../cups/file.h
 listen.o: ../cups/versioning.h ../cups/ipp.h ../cups/http.h
 listen.o: ../cups/language.h ../cups/array.h ../cups/string-private.h
@@ -112,31 +117,32 @@ listen.o: ../config.h ../cups/debug-private.h ../cups/ppd-private.h
 listen.o: ../cups/ppd.h ../cups/cups.h ../cups/pwg-private.h
 listen.o: ../cups/http-private.h ../cups/http.h ../cups/md5-private.h
 listen.o: ../cups/ipp-private.h ../cups/ipp.h ../cups/language-private.h
-listen.o: ../cups/transcode.h mime.h ../cups/array.h ../cups/file.h sysman.h
-listen.o: statbuf.h cert.h auth.h client.h policy.h printers.h
-listen.o: ../cups/pwg-private.h classes.h job.h conf.h banners.h dirsvc.h
-listen.o: network.h subscriptions.h
+listen.o: ../cups/transcode.h ../cups/thread-private.h mime.h ../cups/array.h
+listen.o: ../cups/file.h sysman.h statbuf.h cert.h auth.h client.h policy.h
+listen.o: printers.h ../cups/pwg-private.h classes.h job.h conf.h banners.h
+listen.o: dirsvc.h network.h subscriptions.h
 job.o: cupsd.h ../cups/cups-private.h ../cups/cups.h ../cups/file.h
 job.o: ../cups/versioning.h ../cups/ipp.h ../cups/http.h ../cups/language.h
 job.o: ../cups/array.h ../cups/string-private.h ../config.h
 job.o: ../cups/debug-private.h ../cups/ppd-private.h ../cups/ppd.h
 job.o: ../cups/cups.h ../cups/pwg-private.h ../cups/http-private.h
 job.o: ../cups/http.h ../cups/md5-private.h ../cups/ipp-private.h
-job.o: ../cups/ipp.h ../cups/language-private.h ../cups/transcode.h mime.h
-job.o: ../cups/array.h ../cups/file.h sysman.h statbuf.h cert.h auth.h
-job.o: client.h policy.h printers.h ../cups/pwg-private.h classes.h job.h
-job.o: conf.h banners.h dirsvc.h network.h subscriptions.h ../cups/backend.h
-job.o: ../cups/dir.h
+job.o: ../cups/ipp.h ../cups/language-private.h ../cups/transcode.h
+job.o: ../cups/thread-private.h mime.h ../cups/array.h ../cups/file.h
+job.o: sysman.h statbuf.h cert.h auth.h client.h policy.h printers.h
+job.o: ../cups/pwg-private.h classes.h job.h conf.h banners.h dirsvc.h
+job.o: network.h subscriptions.h ../cups/backend.h ../cups/dir.h
 log.o: cupsd.h ../cups/cups-private.h ../cups/cups.h ../cups/file.h
 log.o: ../cups/versioning.h ../cups/ipp.h ../cups/http.h ../cups/language.h
 log.o: ../cups/array.h ../cups/string-private.h ../config.h
 log.o: ../cups/debug-private.h ../cups/ppd-private.h ../cups/ppd.h
 log.o: ../cups/cups.h ../cups/pwg-private.h ../cups/http-private.h
 log.o: ../cups/http.h ../cups/md5-private.h ../cups/ipp-private.h
-log.o: ../cups/ipp.h ../cups/language-private.h ../cups/transcode.h mime.h
-log.o: ../cups/array.h ../cups/file.h sysman.h statbuf.h cert.h auth.h
-log.o: client.h policy.h printers.h ../cups/pwg-private.h classes.h job.h
-log.o: conf.h banners.h dirsvc.h network.h subscriptions.h
+log.o: ../cups/ipp.h ../cups/language-private.h ../cups/transcode.h
+log.o: ../cups/thread-private.h mime.h ../cups/array.h ../cups/file.h
+log.o: sysman.h statbuf.h cert.h auth.h client.h policy.h printers.h
+log.o: ../cups/pwg-private.h classes.h job.h conf.h banners.h dirsvc.h
+log.o: network.h subscriptions.h
 network.o: ../cups/http-private.h ../config.h ../cups/http.h
 network.o: ../cups/md5-private.h ../cups/ipp-private.h ../cups/ipp.h cupsd.h
 network.o: ../cups/cups-private.h ../cups/cups.h ../cups/file.h
@@ -144,10 +150,11 @@ network.o: ../cups/versioning.h ../cups/ipp.h ../cups/http.h
 network.o: ../cups/language.h ../cups/array.h ../cups/string-private.h
 network.o: ../cups/debug-private.h ../cups/ppd-private.h ../cups/ppd.h
 network.o: ../cups/cups.h ../cups/pwg-private.h ../cups/http-private.h
-network.o: ../cups/language-private.h ../cups/transcode.h mime.h
-network.o: ../cups/array.h ../cups/file.h sysman.h statbuf.h cert.h auth.h
-network.o: client.h policy.h printers.h ../cups/pwg-private.h classes.h job.h
-network.o: conf.h banners.h dirsvc.h network.h subscriptions.h
+network.o: ../cups/language-private.h ../cups/transcode.h
+network.o: ../cups/thread-private.h mime.h ../cups/array.h ../cups/file.h
+network.o: sysman.h statbuf.h cert.h auth.h client.h policy.h printers.h
+network.o: ../cups/pwg-private.h classes.h job.h conf.h banners.h dirsvc.h
+network.o: network.h subscriptions.h
 policy.o: cupsd.h ../cups/cups-private.h ../cups/cups.h ../cups/file.h
 policy.o: ../cups/versioning.h ../cups/ipp.h ../cups/http.h
 policy.o: ../cups/language.h ../cups/array.h ../cups/string-private.h
@@ -155,10 +162,10 @@ policy.o: ../config.h ../cups/debug-private.h ../cups/ppd-private.h
 policy.o: ../cups/ppd.h ../cups/cups.h ../cups/pwg-private.h
 policy.o: ../cups/http-private.h ../cups/http.h ../cups/md5-private.h
 policy.o: ../cups/ipp-private.h ../cups/ipp.h ../cups/language-private.h
-policy.o: ../cups/transcode.h mime.h ../cups/array.h ../cups/file.h sysman.h
-policy.o: statbuf.h cert.h auth.h client.h policy.h printers.h
-policy.o: ../cups/pwg-private.h classes.h job.h conf.h banners.h dirsvc.h
-policy.o: network.h subscriptions.h
+policy.o: ../cups/transcode.h ../cups/thread-private.h mime.h ../cups/array.h
+policy.o: ../cups/file.h sysman.h statbuf.h cert.h auth.h client.h policy.h
+policy.o: printers.h ../cups/pwg-private.h classes.h job.h conf.h banners.h
+policy.o: dirsvc.h network.h subscriptions.h
 printers.o: cupsd.h ../cups/cups-private.h ../cups/cups.h ../cups/file.h
 printers.o: ../cups/versioning.h ../cups/ipp.h ../cups/http.h
 printers.o: ../cups/language.h ../cups/array.h ../cups/string-private.h
@@ -166,10 +173,11 @@ printers.o: ../config.h ../cups/debug-private.h ../cups/ppd-private.h
 printers.o: ../cups/ppd.h ../cups/cups.h ../cups/pwg-private.h
 printers.o: ../cups/http-private.h ../cups/http.h ../cups/md5-private.h
 printers.o: ../cups/ipp-private.h ../cups/ipp.h ../cups/language-private.h
-printers.o: ../cups/transcode.h mime.h ../cups/array.h ../cups/file.h
-printers.o: sysman.h statbuf.h cert.h auth.h client.h policy.h printers.h
-printers.o: ../cups/pwg-private.h classes.h job.h conf.h banners.h dirsvc.h
-printers.o: network.h subscriptions.h ../cups/dir.h
+printers.o: ../cups/transcode.h ../cups/thread-private.h mime.h
+printers.o: ../cups/array.h ../cups/file.h sysman.h statbuf.h cert.h auth.h
+printers.o: client.h policy.h printers.h ../cups/pwg-private.h classes.h
+printers.o: job.h conf.h banners.h dirsvc.h network.h subscriptions.h
+printers.o: ../cups/dir.h
 process.o: cupsd.h ../cups/cups-private.h ../cups/cups.h ../cups/file.h
 process.o: ../cups/versioning.h ../cups/ipp.h ../cups/http.h
 process.o: ../cups/language.h ../cups/array.h ../cups/string-private.h
@@ -177,10 +185,10 @@ process.o: ../config.h ../cups/debug-private.h ../cups/ppd-private.h
 process.o: ../cups/ppd.h ../cups/cups.h ../cups/pwg-private.h
 process.o: ../cups/http-private.h ../cups/http.h ../cups/md5-private.h
 process.o: ../cups/ipp-private.h ../cups/ipp.h ../cups/language-private.h
-process.o: ../cups/transcode.h mime.h ../cups/array.h ../cups/file.h sysman.h
-process.o: statbuf.h cert.h auth.h client.h policy.h printers.h
-process.o: ../cups/pwg-private.h classes.h job.h conf.h banners.h dirsvc.h
-process.o: network.h subscriptions.h
+process.o: ../cups/transcode.h ../cups/thread-private.h mime.h
+process.o: ../cups/array.h ../cups/file.h sysman.h statbuf.h cert.h auth.h
+process.o: client.h policy.h printers.h ../cups/pwg-private.h classes.h job.h
+process.o: conf.h banners.h dirsvc.h network.h subscriptions.h
 quotas.o: cupsd.h ../cups/cups-private.h ../cups/cups.h ../cups/file.h
 quotas.o: ../cups/versioning.h ../cups/ipp.h ../cups/http.h
 quotas.o: ../cups/language.h ../cups/array.h ../cups/string-private.h
@@ -188,10 +196,10 @@ quotas.o: ../config.h ../cups/debug-private.h ../cups/ppd-private.h
 quotas.o: ../cups/ppd.h ../cups/cups.h ../cups/pwg-private.h
 quotas.o: ../cups/http-private.h ../cups/http.h ../cups/md5-private.h
 quotas.o: ../cups/ipp-private.h ../cups/ipp.h ../cups/language-private.h
-quotas.o: ../cups/transcode.h mime.h ../cups/array.h ../cups/file.h sysman.h
-quotas.o: statbuf.h cert.h auth.h client.h policy.h printers.h
-quotas.o: ../cups/pwg-private.h classes.h job.h conf.h banners.h dirsvc.h
-quotas.o: network.h subscriptions.h
+quotas.o: ../cups/transcode.h ../cups/thread-private.h mime.h ../cups/array.h
+quotas.o: ../cups/file.h sysman.h statbuf.h cert.h auth.h client.h policy.h
+quotas.o: printers.h ../cups/pwg-private.h classes.h job.h conf.h banners.h
+quotas.o: dirsvc.h network.h subscriptions.h
 removefile.o: cupsd.h ../cups/cups-private.h ../cups/cups.h ../cups/file.h
 removefile.o: ../cups/versioning.h ../cups/ipp.h ../cups/http.h
 removefile.o: ../cups/language.h ../cups/array.h ../cups/string-private.h
@@ -199,10 +207,10 @@ removefile.o: ../config.h ../cups/debug-private.h ../cups/ppd-private.h
 removefile.o: ../cups/ppd.h ../cups/cups.h ../cups/pwg-private.h
 removefile.o: ../cups/http-private.h ../cups/http.h ../cups/md5-private.h
 removefile.o: ../cups/ipp-private.h ../cups/ipp.h ../cups/language-private.h
-removefile.o: ../cups/transcode.h mime.h ../cups/array.h ../cups/file.h
-removefile.o: sysman.h statbuf.h cert.h auth.h client.h policy.h printers.h
-removefile.o: ../cups/pwg-private.h classes.h job.h conf.h banners.h dirsvc.h
-removefile.o: network.h subscriptions.h
+removefile.o: ../cups/transcode.h ../cups/thread-private.h mime.h
+removefile.o: ../cups/array.h ../cups/file.h sysman.h statbuf.h cert.h auth.h
+removefile.o: client.h policy.h printers.h ../cups/pwg-private.h classes.h
+removefile.o: job.h conf.h banners.h dirsvc.h network.h subscriptions.h
 select.o: cupsd.h ../cups/cups-private.h ../cups/cups.h ../cups/file.h
 select.o: ../cups/versioning.h ../cups/ipp.h ../cups/http.h
 select.o: ../cups/language.h ../cups/array.h ../cups/string-private.h
@@ -210,10 +218,10 @@ select.o: ../config.h ../cups/debug-private.h ../cups/ppd-private.h
 select.o: ../cups/ppd.h ../cups/cups.h ../cups/pwg-private.h
 select.o: ../cups/http-private.h ../cups/http.h ../cups/md5-private.h
 select.o: ../cups/ipp-private.h ../cups/ipp.h ../cups/language-private.h
-select.o: ../cups/transcode.h mime.h ../cups/array.h ../cups/file.h sysman.h
-select.o: statbuf.h cert.h auth.h client.h policy.h printers.h
-select.o: ../cups/pwg-private.h classes.h job.h conf.h banners.h dirsvc.h
-select.o: network.h subscriptions.h
+select.o: ../cups/transcode.h ../cups/thread-private.h mime.h ../cups/array.h
+select.o: ../cups/file.h sysman.h statbuf.h cert.h auth.h client.h policy.h
+select.o: printers.h ../cups/pwg-private.h classes.h job.h conf.h banners.h
+select.o: dirsvc.h network.h subscriptions.h
 server.o: ../cups/http-private.h ../config.h ../cups/http.h
 server.o: ../cups/md5-private.h ../cups/ipp-private.h ../cups/ipp.h cupsd.h
 server.o: ../cups/cups-private.h ../cups/cups.h ../cups/file.h
@@ -221,10 +229,11 @@ server.o: ../cups/versioning.h ../cups/ipp.h ../cups/http.h
 server.o: ../cups/language.h ../cups/array.h ../cups/string-private.h
 server.o: ../cups/debug-private.h ../cups/ppd-private.h ../cups/ppd.h
 server.o: ../cups/cups.h ../cups/pwg-private.h ../cups/http-private.h
-server.o: ../cups/language-private.h ../cups/transcode.h mime.h
-server.o: ../cups/array.h ../cups/file.h sysman.h statbuf.h cert.h auth.h
-server.o: client.h policy.h printers.h ../cups/pwg-private.h classes.h job.h
-server.o: conf.h banners.h dirsvc.h network.h subscriptions.h
+server.o: ../cups/language-private.h ../cups/transcode.h
+server.o: ../cups/thread-private.h mime.h ../cups/array.h ../cups/file.h
+server.o: sysman.h statbuf.h cert.h auth.h client.h policy.h printers.h
+server.o: ../cups/pwg-private.h classes.h job.h conf.h banners.h dirsvc.h
+server.o: network.h subscriptions.h
 statbuf.o: cupsd.h ../cups/cups-private.h ../cups/cups.h ../cups/file.h
 statbuf.o: ../cups/versioning.h ../cups/ipp.h ../cups/http.h
 statbuf.o: ../cups/language.h ../cups/array.h ../cups/string-private.h
@@ -232,10 +241,10 @@ statbuf.o: ../config.h ../cups/debug-private.h ../cups/ppd-private.h
 statbuf.o: ../cups/ppd.h ../cups/cups.h ../cups/pwg-private.h
 statbuf.o: ../cups/http-private.h ../cups/http.h ../cups/md5-private.h
 statbuf.o: ../cups/ipp-private.h ../cups/ipp.h ../cups/language-private.h
-statbuf.o: ../cups/transcode.h mime.h ../cups/array.h ../cups/file.h sysman.h
-statbuf.o: statbuf.h cert.h auth.h client.h policy.h printers.h
-statbuf.o: ../cups/pwg-private.h classes.h job.h conf.h banners.h dirsvc.h
-statbuf.o: network.h subscriptions.h
+statbuf.o: ../cups/transcode.h ../cups/thread-private.h mime.h
+statbuf.o: ../cups/array.h ../cups/file.h sysman.h statbuf.h cert.h auth.h
+statbuf.o: client.h policy.h printers.h ../cups/pwg-private.h classes.h job.h
+statbuf.o: conf.h banners.h dirsvc.h network.h subscriptions.h
 subscriptions.o: cupsd.h ../cups/cups-private.h ../cups/cups.h ../cups/file.h
 subscriptions.o: ../cups/versioning.h ../cups/ipp.h ../cups/http.h
 subscriptions.o: ../cups/language.h ../cups/array.h ../cups/string-private.h
@@ -243,11 +252,11 @@ subscriptions.o: ../config.h ../cups/debug-private.h ../cups/ppd-private.h
 subscriptions.o: ../cups/ppd.h ../cups/cups.h ../cups/pwg-private.h
 subscriptions.o: ../cups/http-private.h ../cups/http.h ../cups/md5-private.h
 subscriptions.o: ../cups/ipp-private.h ../cups/ipp.h
-subscriptions.o: ../cups/language-private.h ../cups/transcode.h mime.h
-subscriptions.o: ../cups/array.h ../cups/file.h sysman.h statbuf.h cert.h
-subscriptions.o: auth.h client.h policy.h printers.h ../cups/pwg-private.h
-subscriptions.o: classes.h job.h conf.h banners.h dirsvc.h network.h
-subscriptions.o: subscriptions.h
+subscriptions.o: ../cups/language-private.h ../cups/transcode.h
+subscriptions.o: ../cups/thread-private.h mime.h ../cups/array.h
+subscriptions.o: ../cups/file.h sysman.h statbuf.h cert.h auth.h client.h
+subscriptions.o: policy.h printers.h ../cups/pwg-private.h classes.h job.h
+subscriptions.o: conf.h banners.h dirsvc.h network.h subscriptions.h
 sysman.o: cupsd.h ../cups/cups-private.h ../cups/cups.h ../cups/file.h
 sysman.o: ../cups/versioning.h ../cups/ipp.h ../cups/http.h
 sysman.o: ../cups/language.h ../cups/array.h ../cups/string-private.h
@@ -255,10 +264,10 @@ sysman.o: ../config.h ../cups/debug-private.h ../cups/ppd-private.h
 sysman.o: ../cups/ppd.h ../cups/cups.h ../cups/pwg-private.h
 sysman.o: ../cups/http-private.h ../cups/http.h ../cups/md5-private.h
 sysman.o: ../cups/ipp-private.h ../cups/ipp.h ../cups/language-private.h
-sysman.o: ../cups/transcode.h mime.h ../cups/array.h ../cups/file.h sysman.h
-sysman.o: statbuf.h cert.h auth.h client.h policy.h printers.h
-sysman.o: ../cups/pwg-private.h classes.h job.h conf.h banners.h dirsvc.h
-sysman.o: network.h subscriptions.h
+sysman.o: ../cups/transcode.h ../cups/thread-private.h mime.h ../cups/array.h
+sysman.o: ../cups/file.h sysman.h statbuf.h cert.h auth.h client.h policy.h
+sysman.o: printers.h ../cups/pwg-private.h classes.h job.h conf.h banners.h
+sysman.o: dirsvc.h network.h subscriptions.h
 filter.o: ../cups/string-private.h ../config.h ../cups/debug-private.h mime.h
 filter.o: ../cups/array.h ../cups/ipp.h ../cups/file.h
 mime.o: ../cups/string-private.h ../config.h ../cups/debug-private.h
@@ -273,7 +282,8 @@ cupsfilter.o: ../config.h ../cups/debug-private.h ../cups/ppd-private.h
 cupsfilter.o: ../cups/ppd.h ../cups/cups.h ../cups/pwg-private.h
 cupsfilter.o: ../cups/http-private.h ../cups/http.h ../cups/md5-private.h
 cupsfilter.o: ../cups/ipp-private.h ../cups/ipp.h ../cups/language-private.h
-cupsfilter.o: ../cups/transcode.h mime.h ../cups/array.h ../cups/file.h
+cupsfilter.o: ../cups/transcode.h ../cups/thread-private.h mime.h
+cupsfilter.o: ../cups/array.h ../cups/file.h
 cups-deviced.o: util.h ../cups/file-private.h ../cups/cups-private.h
 cups-deviced.o: ../cups/cups.h ../cups/file.h ../cups/versioning.h
 cups-deviced.o: ../cups/ipp.h ../cups/http.h ../cups/language.h
@@ -282,7 +292,7 @@ cups-deviced.o: ../cups/debug-private.h ../cups/ppd-private.h ../cups/ppd.h
 cups-deviced.o: ../cups/cups.h ../cups/pwg-private.h ../cups/http-private.h
 cups-deviced.o: ../cups/http.h ../cups/md5-private.h ../cups/ipp-private.h
 cups-deviced.o: ../cups/ipp.h ../cups/language-private.h ../cups/transcode.h
-cups-deviced.o: ../cups/array.h ../cups/dir.h
+cups-deviced.o: ../cups/thread-private.h ../cups/array.h ../cups/dir.h
 cups-lpd.o: ../cups/cups-private.h ../cups/cups.h ../cups/file.h
 cups-lpd.o: ../cups/versioning.h ../cups/ipp.h ../cups/http.h
 cups-lpd.o: ../cups/language.h ../cups/array.h ../cups/string-private.h
@@ -290,7 +300,7 @@ cups-lpd.o: ../config.h ../cups/debug-private.h ../cups/ppd-private.h
 cups-lpd.o: ../cups/ppd.h ../cups/cups.h ../cups/pwg-private.h
 cups-lpd.o: ../cups/http-private.h ../cups/http.h ../cups/md5-private.h
 cups-lpd.o: ../cups/ipp-private.h ../cups/ipp.h ../cups/language-private.h
-cups-lpd.o: ../cups/transcode.h
+cups-lpd.o: ../cups/transcode.h ../cups/thread-private.h
 cups-polld.o: ../cups/cups-private.h ../cups/cups.h ../cups/file.h
 cups-polld.o: ../cups/versioning.h ../cups/ipp.h ../cups/http.h
 cups-polld.o: ../cups/language.h ../cups/array.h ../cups/string-private.h
@@ -298,7 +308,7 @@ cups-polld.o: ../config.h ../cups/debug-private.h ../cups/ppd-private.h
 cups-polld.o: ../cups/ppd.h ../cups/cups.h ../cups/pwg-private.h
 cups-polld.o: ../cups/http-private.h ../cups/http.h ../cups/md5-private.h
 cups-polld.o: ../cups/ipp-private.h ../cups/ipp.h ../cups/language-private.h
-cups-polld.o: ../cups/transcode.h
+cups-polld.o: ../cups/transcode.h ../cups/thread-private.h
 testdirsvc.o: ../cups/cups.h ../cups/file.h ../cups/versioning.h
 testdirsvc.o: ../cups/ipp.h ../cups/http.h ../cups/language.h ../cups/array.h
 testdirsvc.o: ../cups/string-private.h ../config.h
@@ -322,7 +332,7 @@ util.o: ../config.h ../cups/debug-private.h ../cups/ppd-private.h
 util.o: ../cups/ppd.h ../cups/cups.h ../cups/pwg-private.h
 util.o: ../cups/http-private.h ../cups/http.h ../cups/md5-private.h
 util.o: ../cups/ipp-private.h ../cups/ipp.h ../cups/language-private.h
-util.o: ../cups/transcode.h
+util.o: ../cups/transcode.h ../cups/thread-private.h
 cups-driverd.o: util.h ../cups/file-private.h ../cups/cups-private.h
 cups-driverd.o: ../cups/cups.h ../cups/file.h ../cups/versioning.h
 cups-driverd.o: ../cups/ipp.h ../cups/http.h ../cups/language.h
@@ -331,5 +341,5 @@ cups-driverd.o: ../cups/debug-private.h ../cups/ppd-private.h ../cups/ppd.h
 cups-driverd.o: ../cups/cups.h ../cups/pwg-private.h ../cups/http-private.h
 cups-driverd.o: ../cups/http.h ../cups/md5-private.h ../cups/ipp-private.h
 cups-driverd.o: ../cups/ipp.h ../cups/language-private.h ../cups/transcode.h
-cups-driverd.o: ../cups/dir.h ../cups/ppd-private.h ../ppdc/ppdc.h
-cups-driverd.o: ../cups/file.h
+cups-driverd.o: ../cups/thread-private.h ../cups/dir.h ../cups/ppd-private.h
+cups-driverd.o: ../ppdc/ppdc.h ../cups/file.h
index 13d6d14929e00b2e55186664e4334c2f590e3876..3fcabd681936969f7df015a59179b0d607b106e3 100644 (file)
@@ -842,6 +842,9 @@ cupsdTimeoutJob(cupsd_job_t *job)   /* I - Job to timeout */
   * See if we need to add the ending sheet...
   */
 
+  if (!cupsdLoadJob(job))
+    return (-1);
+
   printer = cupsdFindDest(job->dest);
   attr    = ippFindAttribute(job->attrs, "job-sheets", IPP_TAG_NAME);
 
@@ -10223,6 +10226,17 @@ send_document(cupsd_client_t  *con,    /* I - Client connection */
 
   if (!con->filename)
   {
+   /*
+    * Check for an empty request with "last-document" set to true, which is
+    * used to close an "open" job by RFC 2911, section 3.3.2.
+    */
+
+    if (job->num_files > 0 &&
+        (attr = ippFindAttribute(con->request, "last-document",
+                                IPP_TAG_BOOLEAN)) != NULL &&
+        attr->values[0].boolean)
+      goto last_document;
+
     send_ipp_status(con, IPP_BAD_REQUEST, _("No file!?"));
     return;
   }
@@ -10379,6 +10393,8 @@ send_document(cupsd_client_t  *con,     /* I - Client connection */
   * Start the job if this is the last document...
   */
 
+  last_document:
+
   if ((attr = ippFindAttribute(con->request, "last-document",
                                IPP_TAG_BOOLEAN)) != NULL &&
       attr->values[0].boolean)
index 0eaeca4554c4930b1b901c351b9281f931952dd8..6b2283c4bfb97ffaacdd4108f2abfdc2706a176a 100644 (file)
@@ -1,7 +1,7 @@
 /*
  * "$Id: main.c 7925 2008-09-10 17:47:26Z mike $"
  *
- *   Scheduler main loop for the Common UNIX Printing System (CUPS).
+ *   Main loop for the CUPS scheduler.
  *
  *   Copyright 2007-2010 by Apple Inc.
  *   Copyright 1997-2007 by Easy Software Products, all rights reserved.
@@ -527,6 +527,8 @@ main(int  argc,                             /* I - Number of command-line args */
   * Startup the server...
   */
 
+  httpInitialize();
+
   cupsdStartServer();
 
  /*
index 2bc6d164a18014c00751fc429cc08d88282116d2..eb67c6c7dd4250ed7caeba1b8e229aa2529aa347 100644 (file)
@@ -31,7 +31,7 @@
 #include <grp.h>
 #ifdef __APPLE__
 #  include <libgen.h>
-#endif /* __APPLE__ */ 
+#endif /* __APPLE__ */
 #ifdef HAVE_SANDBOX_H
 #  define __APPLE_API_PRIVATE
 #  include <sandbox.h>
@@ -376,7 +376,7 @@ cupsdStartProcess(
   if (envp)
   {
    /*
-    * Add special voodoo magic for MacOS X - this allows MacOS X 
+    * Add special voodoo magic for Mac OS X - this allows Mac OS X
     * programs to access their bundle resources properly...
     */
 
index a8b851b2809312a173b14a1b40a5924a00edc360..438b142dc048799f1e64b845247ce126add6d8b7 100644 (file)
@@ -1,9 +1,9 @@
 /*
  * "$Id: server.c 7927 2008-09-10 22:05:29Z mike $"
  *
- *   Server start/stop routines for the Common UNIX Printing System (CUPS).
+ *   Server start/stop routines for the CUPS scheduler.
  *
- *   Copyright 2007-2008 by Apple Inc.
+ *   Copyright 2007-2010 by Apple Inc.
  *   Copyright 1997-2006 by Easy Software Products, all rights reserved.
  *
  *   These coded instructions, statements, and computer programs are the
@@ -44,41 +44,6 @@ static int   started = 0;
 void
 cupsdStartServer(void)
 {
-#ifdef HAVE_LIBSSL
-  int                  i;              /* Looping var */
-  struct timeval       curtime;        /* Current time in microseconds */
-  unsigned char                data[1024];     /* Seed data */
-#endif /* HAVE_LIBSSL */
-
-
-#ifdef HAVE_LIBSSL
- /*
-  * Initialize the encryption libraries...
-  */
-
-  SSL_library_init();
-  SSL_load_error_strings();
-
- /*
-  * Using the current time is a dubious random seed, but on some systems
-  * it is the best we can do (on others, this seed isn't even used...)
-  */
-
-  gettimeofday(&curtime, NULL);
-  srand(curtime.tv_sec + curtime.tv_usec);
-
-  for (i = 0; i < sizeof(data); i ++)
-    data[i] = rand(); /* Yes, this is a poor source of random data... */
-
-  RAND_seed(&data, sizeof(data));
-#elif defined(HAVE_GNUTLS)
- /*
-  * Initialize the encryption libraries...
-  */
-
-  gnutls_global_init();
-#endif /* HAVE_LIBSSL */
-
  /*
   * Create the default security profile...
   */
index e1d8379309030cde7ea1b4f6806299c3393a85a6..eca4275ebd3ae9ae082d233e801f2f8c411a056f 100644 (file)
@@ -7,7 +7,7 @@ cancel.o: ../config.h ../cups/debug-private.h ../cups/ppd-private.h
 cancel.o: ../cups/ppd.h ../cups/cups.h ../cups/pwg-private.h
 cancel.o: ../cups/http-private.h ../cups/http.h ../cups/md5-private.h
 cancel.o: ../cups/ipp-private.h ../cups/ipp.h ../cups/language-private.h
-cancel.o: ../cups/transcode.h
+cancel.o: ../cups/transcode.h ../cups/thread-private.h
 cupsaccept.o: ../cups/cups-private.h ../cups/cups.h ../cups/file.h
 cupsaccept.o: ../cups/versioning.h ../cups/ipp.h ../cups/http.h
 cupsaccept.o: ../cups/language.h ../cups/array.h ../cups/string-private.h
@@ -15,7 +15,7 @@ cupsaccept.o: ../config.h ../cups/debug-private.h ../cups/ppd-private.h
 cupsaccept.o: ../cups/ppd.h ../cups/cups.h ../cups/pwg-private.h
 cupsaccept.o: ../cups/http-private.h ../cups/http.h ../cups/md5-private.h
 cupsaccept.o: ../cups/ipp-private.h ../cups/ipp.h ../cups/language-private.h
-cupsaccept.o: ../cups/transcode.h
+cupsaccept.o: ../cups/transcode.h ../cups/thread-private.h
 cupsaddsmb.o: ../cups/cups-private.h ../cups/cups.h ../cups/file.h
 cupsaddsmb.o: ../cups/versioning.h ../cups/ipp.h ../cups/http.h
 cupsaddsmb.o: ../cups/language.h ../cups/array.h ../cups/string-private.h
@@ -23,7 +23,8 @@ cupsaddsmb.o: ../config.h ../cups/debug-private.h ../cups/ppd-private.h
 cupsaddsmb.o: ../cups/ppd.h ../cups/cups.h ../cups/pwg-private.h
 cupsaddsmb.o: ../cups/http-private.h ../cups/http.h ../cups/md5-private.h
 cupsaddsmb.o: ../cups/ipp-private.h ../cups/ipp.h ../cups/language-private.h
-cupsaddsmb.o: ../cups/transcode.h ../cups/adminutil.h
+cupsaddsmb.o: ../cups/transcode.h ../cups/thread-private.h
+cupsaddsmb.o: ../cups/adminutil.h
 cupsctl.o: ../cups/cups-private.h ../cups/cups.h ../cups/file.h
 cupsctl.o: ../cups/versioning.h ../cups/ipp.h ../cups/http.h
 cupsctl.o: ../cups/language.h ../cups/array.h ../cups/string-private.h
@@ -31,7 +32,7 @@ cupsctl.o: ../config.h ../cups/debug-private.h ../cups/ppd-private.h
 cupsctl.o: ../cups/ppd.h ../cups/cups.h ../cups/pwg-private.h
 cupsctl.o: ../cups/http-private.h ../cups/http.h ../cups/md5-private.h
 cupsctl.o: ../cups/ipp-private.h ../cups/ipp.h ../cups/language-private.h
-cupsctl.o: ../cups/transcode.h ../cups/adminutil.h
+cupsctl.o: ../cups/transcode.h ../cups/thread-private.h ../cups/adminutil.h
 cupstestdsc.o: ../cups/cups-private.h ../cups/cups.h ../cups/file.h
 cupstestdsc.o: ../cups/versioning.h ../cups/ipp.h ../cups/http.h
 cupstestdsc.o: ../cups/language.h ../cups/array.h ../cups/string-private.h
@@ -39,7 +40,7 @@ cupstestdsc.o: ../config.h ../cups/debug-private.h ../cups/ppd-private.h
 cupstestdsc.o: ../cups/ppd.h ../cups/cups.h ../cups/pwg-private.h
 cupstestdsc.o: ../cups/http-private.h ../cups/http.h ../cups/md5-private.h
 cupstestdsc.o: ../cups/ipp-private.h ../cups/ipp.h ../cups/language-private.h
-cupstestdsc.o: ../cups/transcode.h
+cupstestdsc.o: ../cups/transcode.h ../cups/thread-private.h
 cupstestppd.o: ../cups/cups-private.h ../cups/cups.h ../cups/file.h
 cupstestppd.o: ../cups/versioning.h ../cups/ipp.h ../cups/http.h
 cupstestppd.o: ../cups/language.h ../cups/array.h ../cups/string-private.h
@@ -47,8 +48,8 @@ cupstestppd.o: ../config.h ../cups/debug-private.h ../cups/ppd-private.h
 cupstestppd.o: ../cups/ppd.h ../cups/cups.h ../cups/pwg-private.h
 cupstestppd.o: ../cups/http-private.h ../cups/http.h ../cups/md5-private.h
 cupstestppd.o: ../cups/ipp-private.h ../cups/ipp.h ../cups/language-private.h
-cupstestppd.o: ../cups/transcode.h ../cups/dir.h ../cups/ppd-private.h
-cupstestppd.o: ../cups/raster.h ../cups/ppd.h
+cupstestppd.o: ../cups/transcode.h ../cups/thread-private.h ../cups/dir.h
+cupstestppd.o: ../cups/ppd-private.h ../cups/raster.h ../cups/ppd.h
 lp.o: ../cups/cups-private.h ../cups/cups.h ../cups/file.h
 lp.o: ../cups/versioning.h ../cups/ipp.h ../cups/http.h ../cups/language.h
 lp.o: ../cups/array.h ../cups/string-private.h ../config.h
@@ -56,6 +57,7 @@ lp.o: ../cups/debug-private.h ../cups/ppd-private.h ../cups/ppd.h
 lp.o: ../cups/cups.h ../cups/pwg-private.h ../cups/http-private.h
 lp.o: ../cups/http.h ../cups/md5-private.h ../cups/ipp-private.h
 lp.o: ../cups/ipp.h ../cups/language-private.h ../cups/transcode.h
+lp.o: ../cups/thread-private.h
 lpadmin.o: ../cups/cups-private.h ../cups/cups.h ../cups/file.h
 lpadmin.o: ../cups/versioning.h ../cups/ipp.h ../cups/http.h
 lpadmin.o: ../cups/language.h ../cups/array.h ../cups/string-private.h
@@ -63,7 +65,7 @@ lpadmin.o: ../config.h ../cups/debug-private.h ../cups/ppd-private.h
 lpadmin.o: ../cups/ppd.h ../cups/cups.h ../cups/pwg-private.h
 lpadmin.o: ../cups/http-private.h ../cups/http.h ../cups/md5-private.h
 lpadmin.o: ../cups/ipp-private.h ../cups/ipp.h ../cups/language-private.h
-lpadmin.o: ../cups/transcode.h
+lpadmin.o: ../cups/transcode.h ../cups/thread-private.h
 lpinfo.o: ../cups/cups-private.h ../cups/cups.h ../cups/file.h
 lpinfo.o: ../cups/versioning.h ../cups/ipp.h ../cups/http.h
 lpinfo.o: ../cups/language.h ../cups/array.h ../cups/string-private.h
@@ -71,7 +73,7 @@ lpinfo.o: ../config.h ../cups/debug-private.h ../cups/ppd-private.h
 lpinfo.o: ../cups/ppd.h ../cups/cups.h ../cups/pwg-private.h
 lpinfo.o: ../cups/http-private.h ../cups/http.h ../cups/md5-private.h
 lpinfo.o: ../cups/ipp-private.h ../cups/ipp.h ../cups/language-private.h
-lpinfo.o: ../cups/transcode.h
+lpinfo.o: ../cups/transcode.h ../cups/thread-private.h
 lpmove.o: ../cups/cups-private.h ../cups/cups.h ../cups/file.h
 lpmove.o: ../cups/versioning.h ../cups/ipp.h ../cups/http.h
 lpmove.o: ../cups/language.h ../cups/array.h ../cups/string-private.h
@@ -79,7 +81,7 @@ lpmove.o: ../config.h ../cups/debug-private.h ../cups/ppd-private.h
 lpmove.o: ../cups/ppd.h ../cups/cups.h ../cups/pwg-private.h
 lpmove.o: ../cups/http-private.h ../cups/http.h ../cups/md5-private.h
 lpmove.o: ../cups/ipp-private.h ../cups/ipp.h ../cups/language-private.h
-lpmove.o: ../cups/transcode.h
+lpmove.o: ../cups/transcode.h ../cups/thread-private.h
 lpoptions.o: ../cups/cups-private.h ../cups/cups.h ../cups/file.h
 lpoptions.o: ../cups/versioning.h ../cups/ipp.h ../cups/http.h
 lpoptions.o: ../cups/language.h ../cups/array.h ../cups/string-private.h
@@ -87,7 +89,7 @@ lpoptions.o: ../config.h ../cups/debug-private.h ../cups/ppd-private.h
 lpoptions.o: ../cups/ppd.h ../cups/cups.h ../cups/pwg-private.h
 lpoptions.o: ../cups/http-private.h ../cups/http.h ../cups/md5-private.h
 lpoptions.o: ../cups/ipp-private.h ../cups/ipp.h ../cups/language-private.h
-lpoptions.o: ../cups/transcode.h
+lpoptions.o: ../cups/transcode.h ../cups/thread-private.h
 lppasswd.o: ../cups/cups-private.h ../cups/cups.h ../cups/file.h
 lppasswd.o: ../cups/versioning.h ../cups/ipp.h ../cups/http.h
 lppasswd.o: ../cups/language.h ../cups/array.h ../cups/string-private.h
@@ -95,7 +97,8 @@ lppasswd.o: ../config.h ../cups/debug-private.h ../cups/ppd-private.h
 lppasswd.o: ../cups/ppd.h ../cups/cups.h ../cups/pwg-private.h
 lppasswd.o: ../cups/http-private.h ../cups/http.h ../cups/md5-private.h
 lppasswd.o: ../cups/ipp-private.h ../cups/ipp.h ../cups/language-private.h
-lppasswd.o: ../cups/transcode.h ../cups/md5-private.h
+lppasswd.o: ../cups/transcode.h ../cups/thread-private.h
+lppasswd.o: ../cups/md5-private.h
 lpstat.o: ../cups/cups-private.h ../cups/cups.h ../cups/file.h
 lpstat.o: ../cups/versioning.h ../cups/ipp.h ../cups/http.h
 lpstat.o: ../cups/language.h ../cups/array.h ../cups/string-private.h
@@ -103,4 +106,4 @@ lpstat.o: ../config.h ../cups/debug-private.h ../cups/ppd-private.h
 lpstat.o: ../cups/ppd.h ../cups/cups.h ../cups/pwg-private.h
 lpstat.o: ../cups/http-private.h ../cups/http.h ../cups/md5-private.h
 lpstat.o: ../cups/ipp-private.h ../cups/ipp.h ../cups/language-private.h
-lpstat.o: ../cups/transcode.h
+lpstat.o: ../cups/transcode.h ../cups/thread-private.h
index 238f28dca351e3877bfab49f4292a0e997ac204a..09a48164f03166072ed19e003618e49e9fb151b6 100644 (file)
@@ -17,7 +17,7 @@ SRC="/images/left.gif" WIDTH="64" HEIGHT="36" BORDER="0" ALT=""></A></TD>
 <TD CLASS="unsel"><A HREF="/">&nbsp;&nbsp;Startseite&nbsp;&nbsp;</A></TD>
 <TD CLASS="{SECTION=admin?:un}sel"><A HREF="/admin">&nbsp;&nbsp;Verwaltung&nbsp;&nbsp;</A></TD>
 <TD CLASS="{SECTION=classes?:un}sel"><A HREF="/classes/">&nbsp;&nbsp;Klassen&nbsp;&nbsp;</A></TD>
-<TD CLASS="{SECTION=help?:un}sel"><A HREF="/help/">&nbsp;&nbsp;Online&nbsp;Hilfe&nbsp;&nbsp;</A></TD>
+<TD CLASS="{SECTION=help?:un}sel"><A HREF="/help/">&nbsp;&nbsp;Online-Hilfe&nbsp;&nbsp;</A></TD>
 <TD CLASS="{SECTION=jobs?:un}sel"><A HREF="/jobs/">&nbsp;&nbsp;Auftr&auml;ge&nbsp;&nbsp;</A></TD>
 <TD CLASS="{SECTION=printers?:un}sel"><A HREF="/printers/">&nbsp;&nbsp;Drucker&nbsp;&nbsp;</A></TD>
 <TD CLASS="unsel" WIDTH="100%"><FORM ACTION="/help/" METHOD="GET"><INPUT
index 6c401c7c50210005cd8198dba7475dffae01a3cd..1487c3aa5a721d90a42433cbc69863c775a62be9 100644 (file)
@@ -1,10 +1,11 @@
 # DO NOT DELETE THIS LINE -- make depend depends on it.
 
-ipptest.o: ../cups/cups-private.h ../cups/cups.h ../cups/file.h
-ipptest.o: ../cups/versioning.h ../cups/ipp.h ../cups/http.h
-ipptest.o: ../cups/language.h ../cups/array.h ../cups/string-private.h
-ipptest.o: ../config.h ../cups/debug-private.h ../cups/ppd-private.h
-ipptest.o: ../cups/ppd.h ../cups/cups.h ../cups/pwg-private.h
-ipptest.o: ../cups/http-private.h ../cups/http.h ../cups/md5-private.h
-ipptest.o: ../cups/ipp-private.h ../cups/ipp.h ../cups/language-private.h
-ipptest.o: ../cups/transcode.h ../cups/file-private.h ../cups/cups-private.h
+ipptool.o: ../cups/cups-private.h ../cups/cups.h ../cups/file.h
+ipptool.o: ../cups/versioning.h ../cups/ipp.h ../cups/http.h
+ipptool.o: ../cups/language.h ../cups/array.h ../cups/string-private.h
+ipptool.o: ../config.h ../cups/debug-private.h ../cups/ppd-private.h
+ipptool.o: ../cups/ppd.h ../cups/cups.h ../cups/pwg-private.h
+ipptool.o: ../cups/http-private.h ../cups/http.h ../cups/md5-private.h
+ipptool.o: ../cups/ipp-private.h ../cups/ipp.h ../cups/language-private.h
+ipptool.o: ../cups/transcode.h ../cups/thread-private.h
+ipptool.o: ../cups/file-private.h ../cups/cups-private.h
index 6bdaa83815521dbebdc49495728a2b28449325e8..a46827928a057cf2aabc974bdaefe58619547903 100644 (file)
        ATTR language attributes-natural-language en
        ATTR uri printer-uri $uri
        ATTR name requesting-user-name $user
-       ATTR mimetype document-format application/postscript
        ATTR keyword job-hold-until indefinite
+       ATTR name job-name $filename
 
-       GROUP job
-       ATTR integer copies 1
-
-       FILE ../data/testprint.ps
+       FILE $filename
 
        # What statuses are OK?
        STATUS ok
index a0c814e534d73876fd73434ccc151072e0f23398..3f89d1626baee3900f87239da67251bbb99d3ed6 100644 (file)
@@ -1,7 +1,7 @@
 # Print a test page using print-job
 {
        # The name of the test...
-       NAME "Print test page using print-job"
+       NAME "Print JPEG file using print-job"
 
        # The resource to use for the POST
        # RESOURCE /admin
        ATTR language attributes-natural-language en
        ATTR uri printer-uri $uri
        ATTR name requesting-user-name $user
-       ATTR mimetype document-format application/postscript
+       ATTR mimetype document-format image/jpeg
 
        GROUP job
        ATTR integer copies 1
 
-       FILE testfile.ps
+       FILE testfile.jpg
 
        # What statuses are OK?
        STATUS successful-ok
index 272724c04b7839734e25b39c6b8f3a293686bf65..f01b30ab869e633ef081b8e92db20e25123afb74 100644 (file)
 #define usleep(X)      Sleep((X)/1000)
 
 
+/*
+ * Map various parameters to Posix style system calls
+ */
+
+#  define F_OK         00
+#  define W_OK         02
+#  define R_OK         04
+#  define O_RDONLY     _O_RDONLY
+#  define O_WRONLY     _O_WRONLY
+#  define O_CREATE     _O_CREAT
+#  define O_TRUNC      _O_TRUNC
+
+
 /*
  * Compiler stuff...
  */
  * Default user and groups...
  */
 
-#define CUPS_DEFAULT_USER      "lp"
-#define CUPS_DEFAULT_GROUP     "sys"
-#define CUPS_DEFAULT_SYSTEM_GROUPS "admin"
-#define CUPS_DEFAULT_PRINTOPERATOR_AUTH "@admin @lpadmin"
+#define CUPS_DEFAULT_USER      ""
+#define CUPS_DEFAULT_GROUP     ""
+#define CUPS_DEFAULT_SYSTEM_GROUPS ""
+#define CUPS_DEFAULT_PRINTOPERATOR_AUTH ""
 
 
 /*
  * Do we have the strXXX() functions?
  */
 
-#define HAVE_STRDUP
-#define HAVE_STRCASECMP
-#define HAVE_STRNCASECMP
+#define HAVE_STRDUP 1
+#define HAVE_STRCASECMP 1
+#define HAVE_STRNCASECMP 1
 /* #undef HAVE_STRLCAT */
 /* #undef HAVE_STRLCPY */
 
  * Do we have DNS Service Discovery (aka Bonjour)?
  */
 
-/* #undef HAVE_DNSSD */
+#define HAVE_DNSSD 1
 
 
 /*
 
 /* #undef HAVE_LAUNCH_H */
 /* #undef HAVE_LAUNCHD */
-#define CUPS_DEFAULT_LAUNCHD_CONF ""
 
 
 /*
 /* #undef HAVE_CFBUNDLEPRIV_H */
 
 
+/*
+ * Do we have ApplicationServices public headers?
+ */
+
+/* #undef HAVE_APPLICATIONSERVICES_H */
+
+
+/*
+ * Do we have the SCDynamicStoreCopyComputerName function?
+ */
+
+/* #undef HAVE_SCDYNAMICSTORECOPYCOMPUTERNAME */
+
+
 /*
  * Do we have MacOSX 10.4's mbr_XXX functions()?
  */