]>
git.ipfire.org Git - thirdparty/cups.git/blob - xcode/config.h
4 * Configuration file for CUPS and Xcode.
6 * Copyright 2007-2015 by Apple Inc.
7 * Copyright 1997-2007 by Easy Software Products.
9 * These coded instructions, statements, and computer programs are the
10 * property of Apple Inc. and are protected by Federal copyright
11 * law. Distribution and use rights are outlined in the file "LICENSE.txt"
12 * which should have been included with this file. If this file is
13 * file is missing or damaged, see the license at "http://www.cups.org/".
16 #ifndef _CUPS_CONFIG_H_
17 #define _CUPS_CONFIG_H_
19 #include <AvailabilityMacros.h>
22 * Version of software...
25 #define CUPS_SVERSION "CUPS v2.1svn"
26 #define CUPS_MINIMAL "CUPS/2.1svn"
30 * Default user and groups...
33 #define CUPS_DEFAULT_USER "_lp"
34 #define CUPS_DEFAULT_GROUP "_lp"
35 #define CUPS_DEFAULT_SYSTEM_GROUPS "admin"
36 #define CUPS_DEFAULT_PRINTOPERATOR_AUTH "@AUTHKEY(system.print.operator) @admin @lpadmin"
37 #define CUPS_DEFAULT_SYSTEM_AUTHKEY "system.print.admin"
41 * Default file permissions...
44 #define CUPS_DEFAULT_CONFIG_FILE_PERM 0644
45 #define CUPS_DEFAULT_LOG_FILE_PERM 0644
49 * Default logging settings...
52 #define CUPS_DEFAULT_LOG_LEVEL "warn"
53 #define CUPS_DEFAULT_ACCESS_LOG_LEVEL "actions"
57 * Default fatal error settings...
60 #define CUPS_DEFAULT_FATAL_ERRORS "config"
64 * Default browsing settings...
67 #define CUPS_DEFAULT_BROWSING 1
68 #define CUPS_DEFAULT_BROWSE_LOCAL_PROTOCOLS "dnssd"
69 #define CUPS_DEFAULT_DEFAULT_SHARED 1
76 #define CUPS_DEFAULT_IPP_PORT 631
80 * Default printcap file...
83 #define CUPS_DEFAULT_PRINTCAP "/Library/Preferences/org.cups.printers.plist"
87 * Default Samba and LPD config files...
90 #define CUPS_DEFAULT_SMB_CONFIG_FILE ""
91 #define CUPS_DEFAULT_LPD_CONFIG_FILE "launchd:///System/Library/LaunchDaemons/org.cups.cups-lpd.plist"
95 * Default MaxCopies value...
98 #define CUPS_DEFAULT_MAX_COPIES 9999
102 * Do we have domain socket support, and if so what is the default one?
105 #define CUPS_DEFAULT_DOMAINSOCKET "/private/var/run/cupsd"
109 * Default WebInterface value...
112 #define CUPS_DEFAULT_WEBIF 0
116 * Where are files stored?
118 * Note: These are defaults, which can be overridden by environment
119 * variables at run-time...
122 #define CUPS_BINDIR "/usr/bin"
123 #define CUPS_CACHEDIR "/private/var/spool/cups/cache"
124 #define CUPS_DATADIR "/usr/share/cups"
125 #define CUPS_DOCROOT "/usr/share/doc/cups"
126 #define CUPS_FONTPATH "/usr/share/cups/fonts"
127 #define CUPS_LOCALEDIR "/usr/share/locale"
128 #define CUPS_LOGDIR "/private/var/log/cups"
129 #define CUPS_REQUESTS "/private/var/spool/cups"
130 #define CUPS_SBINDIR "/usr/sbin"
131 #define CUPS_SERVERBIN "/usr/libexec/cups"
132 #define CUPS_SERVERROOT "/private/etc/cups"
133 #define CUPS_STATEDIR "/private/etc/cups"
137 * Do we have posix_spawn?
140 #define HAVE_POSIX_SPAWN 1
148 #define HAVE_INFLATECOPY 1
152 * Do we have PAM stuff?
156 #define HAVE_LIBPAM 1
157 #endif /* !HAVE_LIBPAM */
159 /* #undef HAVE_PAM_PAM_APPL_H */
160 #define HAVE_PAM_SET_ITEM 1
161 #define HAVE_PAM_SETCRED 1
165 * Do we have <shadow.h>?
168 /* #undef HAVE_SHADOW_H */
172 * Do we have <crypt.h>?
175 /* #undef HAVE_CRYPT_H */
182 #define HAVE_STDINT_H 1
186 * Use <string.h>, <strings.h>, and/or <bstring.h>?
189 #define HAVE_STRING_H 1
190 #define HAVE_STRINGS_H 1
191 /* #undef HAVE_BSTRING_H */
195 * Do we have the long long type?
198 #define HAVE_LONG_LONG 1
200 #ifdef HAVE_LONG_LONG
201 # define CUPS_LLFMT "%lld"
202 # define CUPS_LLCAST (long long)
204 # define CUPS_LLFMT "%ld"
205 # define CUPS_LLCAST (long)
206 #endif /* HAVE_LONG_LONG */
210 * Do we have the strtoll() function?
213 #define HAVE_STRTOLL 1
216 # define strtoll(nptr,endptr,base) strtol((nptr), (endptr), (base))
217 #endif /* !HAVE_STRTOLL */
221 * Do we have the strXXX() functions?
224 #define HAVE_STRDUP 1
225 #define HAVE_STRLCAT 1
226 #define HAVE_STRLCPY 1
230 * Do we have the geteuid() function?
233 #define HAVE_GETEUID 1
237 * Do we have the setpgid() function?
240 #define HAVE_SETPGID 1
244 * Do we have the vsyslog() function?
247 #define HAVE_VSYSLOG 1
251 * Do we have the (v)snprintf() functions?
254 #define HAVE_SNPRINTF 1
255 #define HAVE_VSNPRINTF 1
259 * What signal functions to use?
262 #define HAVE_SIGSET 1
263 #define HAVE_SIGACTION 1
267 * What wait functions to use?
270 #define HAVE_WAITPID 1
275 * Do we have the mallinfo function and malloc.h?
278 /* #undef HAVE_MALLINFO */
279 /* #undef HAVE_MALLOC_H */
283 * Do we have the POSIX ACL functions?
286 #define HAVE_ACL_INIT 1
290 * Do we have the langinfo.h header file?
293 #define HAVE_LANGINFO_H 1
297 * Which encryption libraries do we have?
300 #define HAVE_CDSASSL 1
301 /* #undef HAVE_GNUTLS */
306 * Do we have the gnutls_transport_set_pull_timeout_function function?
309 /* #undef HAVE_GNUTLS_TRANSPORT_SET_PULL_TIMEOUT_FUNCTION */
313 * Do we have the gnutls_priority_set_direct function?
316 /* #undef HAVE_GNUTLS_PRIORITY_SET_DIRECT */
320 * What Security framework headers do we have?
323 #define HAVE_AUTHORIZATION_H 1
324 /* #undef HAVE_SECBASEPRIV_H */
325 #define HAVE_SECCERTIFICATE_H 1
326 /* #undef HAVE_SECIDENTITYSEARCHPRIV_H */
327 #define HAVE_SECITEM_H 1
328 /* #undef HAVE_SECITEMPRIV_H */
329 #define HAVE_SECPOLICY_H 1
330 /* #undef HAVE_SECPOLICYPRIV_H */
331 /* #undef HAVE_SECURETRANSPORTPRIV_H */
335 * Do we have the cssmErrorString function?
338 #define HAVE_CSSMERRORSTRING 1
342 * Do we have the SecGenerateSelfSignedCertificate function?
345 /* #undef HAVE_SECGENERATESELFSIGNEDCERTIFICATE */
349 * Do we have the SecKeychainOpen function?
352 #define HAVE_SECKEYCHAINOPEN 1
356 * Do we have (a working) SSLSetEnabledCiphers function?
359 #ifdef AVAILABLE_MAC_OS_X_VERSION_10_11_AND_LATER
360 # define HAVE_SSLSETENABLEDCIPHERS 1
361 #endif /* AVAILABLE_MAC_OS_X_VERSION_10_11_AND_LATER */
365 * Do we have libpaper?
368 /* #undef HAVE_LIBPAPER */
372 * Do we have mDNSResponder for DNS Service Discovery (aka Bonjour)?
379 * Do we have Avahi for DNS Service Discovery (aka Bonjour)?
382 /* #undef HAVE_AVAHI */
386 * Do we have <sys/ioctl.h>?
389 #define HAVE_SYS_IOCTL_H 1
393 * Does the "stat" structure contain the "st_gen" member?
396 #define HAVE_ST_GEN 1
400 * Does the "tm" structure contain the "tm_gmtoff" member?
403 #define HAVE_TM_GMTOFF 1
407 * Do we have rresvport_af()?
410 #define HAVE_RRESVPORT_AF 1
414 * Do we have getaddrinfo()?
417 #define HAVE_GETADDRINFO 1
421 * Do we have getnameinfo()?
424 #define HAVE_GETNAMEINFO 1
428 * Do we have getifaddrs()?
431 #define HAVE_GETIFADDRS 1
435 * Do we have hstrerror()?
438 #define HAVE_HSTRERROR 1
442 * Do we have res_init()?
445 #define HAVE_RES_INIT 1
449 * Do we have <resolv.h>
452 #define HAVE_RESOLV_H 1
456 * Do we have the <sys/sockio.h> header file?
459 #define HAVE_SYS_SOCKIO_H 1
463 * Does the sockaddr structure contain an sa_len parameter?
466 /* #undef HAVE_STRUCT_SOCKADDR_SA_LEN */
470 * Do we have pthread support?
473 #define HAVE_PTHREAD_H 1
477 * Do we have launchd support?
480 #define HAVE_LAUNCH_H 1
481 #define HAVE_LAUNCHD 1
482 #define HAVE_LAUNCH_ACTIVATE_SOCKET 1
486 * Various scripting languages...
490 #define CUPS_JAVA "/usr/bin/java"
492 #define CUPS_PERL "/usr/bin/perl"
494 #define CUPS_PHP "/usr/bin/php"
495 #define HAVE_PYTHON 1
496 #define CUPS_PYTHON "/usr/bin/python"
500 * Location of the poppler/Xpdf pdftops program...
503 /* #undef HAVE_PDFTOPS */
504 /* #undef HAVE_PDFTOPS_WITH_ORIGPAGESIZES */
505 #define CUPS_PDFTOPS "/usr/bin/pdftops"
509 * Location of the Ghostscript gs program...
512 /* #undef HAVE_GHOSTSCRIPT */
513 /* #undef HAVE_GHOSTSCRIPT_PS2WRITE */
514 #define CUPS_GHOSTSCRIPT "/usr/bin/gs"
518 * Do we have CoreFoundation public and private headers?
521 #define HAVE_COREFOUNDATION_H 1
522 /* #undef HAVE_CFPRIV_H */
523 /* #undef HAVE_CFBUNDLEPRIV_H */
527 * Do we have ApplicationServices public headers?
530 #define HAVE_APPLICATIONSERVICES_H 1
534 * Do we have the SCDynamicStoreCopyComputerName function?
537 #define HAVE_SCDYNAMICSTORECOPYCOMPUTERNAME 1
541 * Do we have OS X 10.4's mbr_XXX functions?
544 #define HAVE_MEMBERSHIP_H 1
545 /* #undef HAVE_MEMBERSHIPPRIV_H */
546 #define HAVE_MBR_UID_TO_UUID 1
550 * Do we have Darwin's notify_post header and function?
553 #define HAVE_NOTIFY_H 1
554 #define HAVE_NOTIFY_POST 1
561 /* #undef HAVE_DBUS */
562 /* #undef HAVE_DBUS_MESSAGE_ITER_INIT_APPEND */
566 * Do we have the GSSAPI support library (for Kerberos support)?
569 #define HAVE_GSS_ACQUIRE_CRED_EX_F 1
570 #define HAVE_GSS_C_NT_HOSTBASED_SERVICE 1
571 #define HAVE_GSS_GSSAPI_H 1
572 /* #undef HAVE_GSS_GSSAPI_SPI_H */
573 #define HAVE_GSSAPI 1
574 /* #undef HAVE_GSSAPI_GSSAPI_H */
575 /* #undef HAVE_GSSAPI_H */
579 * Default GSS service name...
582 #define CUPS_DEFAULT_GSSSERVICENAME "host"
586 * Select/poll interfaces...
590 /* #undef HAVE_EPOLL */
591 #define HAVE_KQUEUE 1
595 * Do we have the <dlfcn.h> header?
598 #define HAVE_DLFCN_H 1
602 * Do we have <sys/param.h>?
605 #define HAVE_SYS_PARAM_H 1
609 * Do we have <sys/ucred.h>?
612 #define HAVE_SYS_UCRED_H 1
616 * Do we have removefile()?
619 #define HAVE_REMOVEFILE 1
623 * Do we have <sandbox.h>?
626 #define HAVE_SANDBOX_H 1
630 * Which random number generator function to use...
633 #define HAVE_ARC4RANDOM 1
634 #define HAVE_RANDOM 1
635 #define HAVE_LRAND48 1
637 #ifdef HAVE_ARC4RANDOM
638 # define CUPS_RAND() arc4random()
639 # define CUPS_SRAND(v) arc4random_stir()
640 #elif defined(HAVE_RANDOM)
641 # define CUPS_RAND() random()
642 # define CUPS_SRAND(v) srandom(v)
643 #elif defined(HAVE_LRAND48)
644 # define CUPS_RAND() lrand48()
645 # define CUPS_SRAND(v) srand48(v)
647 # define CUPS_RAND() rand()
648 # define CUPS_SRAND(v) srand(v)
649 #endif /* HAVE_ARC4RANDOM */
656 /* #undef HAVE_LIBUSB */
660 * Do we have libwrap and tcpd.h?
663 /* #undef HAVE_TCPD_H */
667 * Do we have <iconv.h>?
670 #define HAVE_ICONV_H 1
674 * Do we have statfs or statvfs and one of the corresponding headers?
677 #define HAVE_STATFS 1
678 #define HAVE_STATVFS 1
679 #define HAVE_SYS_MOUNT_H 1
680 /* #undef HAVE_SYS_STATFS_H */
681 #define HAVE_SYS_STATVFS_H 1
682 /* #undef HAVE_SYS_VFS_H */
686 * Location of OS X localization bundle, if any.
689 #define CUPS_BUNDLEDIR "/System/Library/Frameworks/ApplicationServices.framework/Versions/A/Frameworks/PrintCore.framework/Versions/A"
697 /* #undef HAVE_XPC_PRIVATE_H */
701 * Do we have Mini-XML?
704 /* #undef HAVE_MXML_H */
708 * Do we have the C99 abs() function?
712 #if !defined(HAVE_ABS) && !defined(abs)
713 # if defined(__GNUC__) || __STDC_VERSION__ >= 199901L
714 # define abs(x) _cups_abs(x)
715 static inline int _cups_abs(int i
) { return (i
< 0 ? -i
: i
); }
716 # elif defined(_MSC_VER)
717 # define abs(x) _cups_abs(x)
718 static __inline
int _cups_abs(int i
) { return (i
< 0 ? -i
: i
); }
720 # define abs(x) ((x) < 0 ? -(x) : (x))
721 # endif /* __GNUC__ || __STDC_VERSION__ */
722 #endif /* !HAVE_ABS && !abs */
724 #endif /* !_CUPS_CONFIG_H_ */