]>
Commit | Line | Data |
---|---|---|
ef416fc2 | 1 | /* |
f2d18633 | 2 | * "$Id$" |
ef416fc2 | 3 | * |
5a1d7a17 | 4 | * Configuration file for CUPS on Windows. |
ef416fc2 | 5 | * |
5a1d7a17 MS |
6 | * Copyright 2007-2013 by Apple Inc. |
7 | * Copyright 1997-2007 by Easy Software Products. | |
ef416fc2 | 8 | * |
5a1d7a17 MS |
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/". | |
ef416fc2 | 14 | */ |
15 | ||
16 | #ifndef _CUPS_CONFIG_H_ | |
17 | #define _CUPS_CONFIG_H_ | |
18 | ||
536bc2c6 MS |
19 | /* |
20 | * Include necessary headers... | |
21 | */ | |
22 | ||
23 | #include <stdio.h> | |
24 | #include <stdlib.h> | |
25 | #include <string.h> | |
26 | #include <stdarg.h> | |
536bc2c6 | 27 | #include <io.h> |
7cf5915e | 28 | #include <direct.h> |
536bc2c6 MS |
29 | |
30 | ||
31 | /* | |
7a0cbd5e | 32 | * Microsoft renames the POSIX functions to _name, and introduces |
536bc2c6 MS |
33 | * a broken compatibility layer using the original names. As a result, |
34 | * random crashes can occur when, for example, strdup() allocates memory | |
35 | * from a different heap than used by malloc() and free(). | |
36 | * | |
37 | * To avoid moronic problems like this, we #define the POSIX function | |
38 | * names to the corresponding non-standard Microsoft names. | |
39 | */ | |
40 | ||
41 | #define access _access | |
42 | #define close _close | |
43 | #define fileno _fileno | |
44 | #define lseek _lseek | |
7cf5915e | 45 | #define mkdir(d,p) _mkdir(d) |
536bc2c6 MS |
46 | #define open _open |
47 | #define read _read | |
7cf5915e | 48 | #define rmdir _rmdir |
536bc2c6 MS |
49 | #define snprintf _snprintf |
50 | #define strdup _strdup | |
51 | #define unlink _unlink | |
52 | #define vsnprintf _vsnprintf | |
53 | #define write _write | |
54 | ||
55 | ||
5180a04c MS |
56 | /* |
57 | * Map the POSIX sleep() and usleep() functions to the Win32 Sleep() function... | |
58 | */ | |
59 | ||
33c9220c | 60 | typedef unsigned long useconds_t; |
5180a04c MS |
61 | #define sleep(X) Sleep(1000 * (X)) |
62 | #define usleep(X) Sleep((X)/1000) | |
63 | ||
64 | ||
6d2f911b MS |
65 | /* |
66 | * Map various parameters to Posix style system calls | |
67 | */ | |
68 | ||
69 | # define F_OK 00 | |
70 | # define W_OK 02 | |
71 | # define R_OK 04 | |
72 | # define O_RDONLY _O_RDONLY | |
73 | # define O_WRONLY _O_WRONLY | |
74 | # define O_CREATE _O_CREAT | |
75 | # define O_TRUNC _O_TRUNC | |
76 | ||
77 | ||
ef416fc2 | 78 | /* |
79 | * Compiler stuff... | |
80 | */ | |
81 | ||
82 | #undef const | |
83 | #undef __CHAR_UNSIGNED__ | |
84 | ||
85 | ||
86 | /* | |
87 | * Version of software... | |
88 | */ | |
89 | ||
5a1d7a17 MS |
90 | #define CUPS_SVERSION "CUPS v2.0.0" |
91 | #define CUPS_MINIMAL "CUPS/2.0.0" | |
ef416fc2 | 92 | |
93 | ||
94 | /* | |
536bc2c6 | 95 | * Default user and groups... |
ef416fc2 | 96 | */ |
97 | ||
6d2f911b MS |
98 | #define CUPS_DEFAULT_USER "" |
99 | #define CUPS_DEFAULT_GROUP "" | |
100 | #define CUPS_DEFAULT_SYSTEM_GROUPS "" | |
101 | #define CUPS_DEFAULT_PRINTOPERATOR_AUTH "" | |
536bc2c6 MS |
102 | |
103 | ||
104 | /* | |
105 | * Default file permissions... | |
106 | */ | |
107 | ||
db8b865d | 108 | #define CUPS_DEFAULT_CONFIG_FILE_PERM 0640 |
536bc2c6 MS |
109 | #define CUPS_DEFAULT_LOG_FILE_PERM 0644 |
110 | ||
111 | ||
112 | /* | |
113 | * Default logging settings... | |
114 | */ | |
115 | ||
116 | #define CUPS_DEFAULT_LOG_LEVEL "warn" | |
117 | #define CUPS_DEFAULT_ACCESS_LOG_LEVEL "actions" | |
118 | ||
119 | ||
120 | /* | |
121 | * Default fatal error settings... | |
122 | */ | |
123 | ||
124 | #define CUPS_DEFAULT_FATAL_ERRORS "config" | |
125 | ||
126 | ||
127 | /* | |
128 | * Default browsing settings... | |
129 | */ | |
130 | ||
131 | #define CUPS_DEFAULT_BROWSING 1 | |
db8b865d | 132 | #define CUPS_DEFAULT_BROWSE_LOCAL_PROTOCOLS "" |
536bc2c6 | 133 | #define CUPS_DEFAULT_DEFAULT_SHARED 1 |
ef416fc2 | 134 | |
135 | ||
136 | /* | |
137 | * Default IPP port... | |
138 | */ | |
139 | ||
536bc2c6 MS |
140 | #define CUPS_DEFAULT_IPP_PORT 631 |
141 | ||
142 | ||
143 | /* | |
144 | * Default printcap file... | |
145 | */ | |
146 | ||
147 | #define CUPS_DEFAULT_PRINTCAP "" | |
ef416fc2 | 148 | |
149 | ||
150 | /* | |
536bc2c6 | 151 | * Default Samba and LPD config files... |
ef416fc2 | 152 | */ |
153 | ||
536bc2c6 MS |
154 | #define CUPS_DEFAULT_SMB_CONFIG_FILE "" |
155 | #define CUPS_DEFAULT_LPD_CONFIG_FILE "" | |
156 | ||
157 | ||
158 | /* | |
159 | * Default MaxCopies value... | |
160 | */ | |
161 | ||
162 | #define CUPS_DEFAULT_MAX_COPIES 9999 | |
ef416fc2 | 163 | |
164 | ||
165 | /* | |
166 | * Do we have domain socket support? | |
167 | */ | |
168 | ||
169 | #undef CUPS_DEFAULT_DOMAINSOCKET | |
170 | ||
171 | ||
db8b865d MS |
172 | /* |
173 | * Default WebInterface value... | |
174 | */ | |
175 | ||
176 | #undef CUPS_DEFAULT_WEBIF | |
177 | ||
178 | ||
ef416fc2 | 179 | /* |
180 | * Where are files stored? | |
181 | * | |
182 | * Note: These are defaults, which can be overridden by environment | |
183 | * variables at run-time... | |
184 | */ | |
185 | ||
536bc2c6 MS |
186 | #define CUPS_BINDIR "C:/CUPS/bin" |
187 | #define CUPS_CACHEDIR "C:/CUPS/cache" | |
188 | #define CUPS_DATADIR "C:/CUPS/share" | |
189 | #define CUPS_DOCROOT "C:/CUPS/share/doc" | |
190 | #define CUPS_FONTPATH "C:/CUPS/share/fonts" | |
191 | #define CUPS_LOCALEDIR "C:/CUPS/locale" | |
192 | #define CUPS_LOGDIR "C:/CUPS/logs" | |
193 | #define CUPS_REQUESTS "C:/CUPS/spool" | |
194 | #define CUPS_SBINDIR "C:/CUPS/sbin" | |
195 | #define CUPS_SERVERBIN "C:/CUPS/lib" | |
196 | #define CUPS_SERVERROOT "C:/CUPS/etc" | |
197 | #define CUPS_STATEDIR "C:/CUPS/run" | |
ef416fc2 | 198 | |
199 | ||
200 | /* | |
db8b865d | 201 | * Do we have ZLIB? |
ef416fc2 | 202 | */ |
203 | ||
db8b865d MS |
204 | #define HAVE_LIBZ 1 |
205 | #define HAVE_INFLATECOPY 1 | |
ef416fc2 | 206 | |
207 | ||
208 | /* | |
209 | * Do we have PAM stuff? | |
210 | */ | |
211 | ||
212 | #ifndef HAVE_LIBPAM | |
213 | #define HAVE_LIBPAM 0 | |
214 | #endif /* !HAVE_LIBPAM */ | |
215 | ||
536bc2c6 MS |
216 | /* #undef HAVE_PAM_PAM_APPL_H */ |
217 | /* #undef HAVE_PAM_SET_ITEM */ | |
218 | /* #undef HAVE_PAM_SETCRED */ | |
ef416fc2 | 219 | |
220 | ||
221 | /* | |
222 | * Do we have <shadow.h>? | |
223 | */ | |
224 | ||
536bc2c6 | 225 | /* #undef HAVE_SHADOW_H */ |
ef416fc2 | 226 | |
227 | ||
228 | /* | |
229 | * Do we have <crypt.h>? | |
230 | */ | |
231 | ||
536bc2c6 | 232 | /* #undef HAVE_CRYPT_H */ |
ef416fc2 | 233 | |
234 | ||
f8b3a85b | 235 | /* |
db8b865d | 236 | * Use <stdint.h>? |
f8b3a85b MS |
237 | */ |
238 | ||
db8b865d | 239 | /* #undef HAVE_STDINT_H */ |
f8b3a85b MS |
240 | |
241 | ||
ef416fc2 | 242 | /* |
243 | * Use <string.h>, <strings.h>, and/or <bstring.h>? | |
244 | */ | |
245 | ||
536bc2c6 MS |
246 | #define HAVE_STRING_H 1 |
247 | /* #undef HAVE_STRINGS_H */ | |
248 | /* #undef HAVE_BSTRING_H */ | |
ef416fc2 | 249 | |
250 | ||
251 | /* | |
252 | * Do we have the long long type? | |
253 | */ | |
254 | ||
536bc2c6 | 255 | /* #undef HAVE_LONG_LONG */ |
ef416fc2 | 256 | |
257 | #ifdef HAVE_LONG_LONG | |
258 | # define CUPS_LLFMT "%lld" | |
259 | # define CUPS_LLCAST (long long) | |
260 | #else | |
261 | # define CUPS_LLFMT "%ld" | |
262 | # define CUPS_LLCAST (long) | |
263 | #endif /* HAVE_LONG_LONG */ | |
264 | ||
265 | ||
266 | /* | |
267 | * Do we have the strtoll() function? | |
268 | */ | |
269 | ||
536bc2c6 | 270 | /* #undef HAVE_STRTOLL */ |
ef416fc2 | 271 | |
272 | #ifndef HAVE_STRTOLL | |
273 | # define strtoll(nptr,endptr,base) strtol((nptr), (endptr), (base)) | |
274 | #endif /* !HAVE_STRTOLL */ | |
275 | ||
276 | ||
277 | /* | |
278 | * Do we have the strXXX() functions? | |
279 | */ | |
280 | ||
6d2f911b | 281 | #define HAVE_STRDUP 1 |
536bc2c6 MS |
282 | /* #undef HAVE_STRLCAT */ |
283 | /* #undef HAVE_STRLCPY */ | |
ef416fc2 | 284 | |
285 | ||
286 | /* | |
287 | * Do we have the geteuid() function? | |
288 | */ | |
289 | ||
536bc2c6 | 290 | /* #undef HAVE_GETEUID */ |
ef416fc2 | 291 | |
292 | ||
88f9aafc MS |
293 | /* |
294 | * Do we have the setpgid() function? | |
295 | */ | |
296 | ||
297 | /* #undef HAVE_SETPGID */ | |
298 | ||
299 | ||
ef416fc2 | 300 | /* |
301 | * Do we have the vsyslog() function? | |
302 | */ | |
303 | ||
536bc2c6 | 304 | /* #undef HAVE_VSYSLOG */ |
ef416fc2 | 305 | |
306 | ||
307 | /* | |
308 | * Do we have the (v)snprintf() functions? | |
309 | */ | |
310 | ||
536bc2c6 MS |
311 | #define HAVE_SNPRINTF 1 |
312 | #define HAVE_VSNPRINTF 1 | |
ef416fc2 | 313 | |
314 | ||
315 | /* | |
316 | * What signal functions to use? | |
317 | */ | |
318 | ||
536bc2c6 MS |
319 | /* #undef HAVE_SIGSET */ |
320 | /* #undef HAVE_SIGACTION */ | |
ef416fc2 | 321 | |
322 | ||
323 | /* | |
324 | * What wait functions to use? | |
325 | */ | |
326 | ||
536bc2c6 MS |
327 | /* #undef HAVE_WAITPID */ |
328 | /* #undef HAVE_WAIT3 */ | |
ef416fc2 | 329 | |
330 | ||
331 | /* | |
332 | * Do we have the mallinfo function and malloc.h? | |
333 | */ | |
334 | ||
536bc2c6 MS |
335 | /* #undef HAVE_MALLINFO */ |
336 | /* #undef HAVE_MALLOC_H */ | |
337 | ||
338 | ||
339 | /* | |
340 | * Do we have the POSIX ACL functions? | |
341 | */ | |
342 | ||
343 | /* #undef HAVE_ACL_INIT */ | |
ef416fc2 | 344 | |
345 | ||
346 | /* | |
347 | * Do we have the langinfo.h header file? | |
348 | */ | |
349 | ||
536bc2c6 | 350 | /* #undef HAVE_LANGINFO_H */ |
ef416fc2 | 351 | |
352 | ||
353 | /* | |
354 | * Which encryption libraries do we have? | |
355 | */ | |
356 | ||
536bc2c6 MS |
357 | /* #undef HAVE_CDSASSL */ |
358 | /* #undef HAVE_GNUTLS */ | |
cc754834 MS |
359 | #define HAVE_SSPISSL |
360 | #define HAVE_SSL | |
536bc2c6 MS |
361 | |
362 | ||
536bc2c6 | 363 | /* |
db8b865d | 364 | * What Security framework headers do we have? |
eac3a0a0 MS |
365 | */ |
366 | ||
db8b865d MS |
367 | /* #undef HAVE_AUTHORIZATION_H */ |
368 | /* #undef HAVE_SECBASEPRIV_H */ | |
369 | /* #undef HAVE_SECCERTIFICATE_H */ | |
370 | /* #undef HAVE_SECIDENTITYSEARCHPRIV_H */ | |
371 | /* #undef HAVE_SECITEM_H */ | |
372 | /* #undef HAVE_SECITEMPRIV_H */ | |
373 | /* #undef HAVE_SECPOLICY_H */ | |
374 | /* #undef HAVE_SECPOLICYPRIV_H */ | |
375 | /* #undef HAVE_SECURETRANSPORTPRIV_H */ | |
eac3a0a0 MS |
376 | |
377 | ||
378 | /* | |
379 | * Do we have the cssmErrorString function? | |
380 | */ | |
381 | ||
382 | /* #undef HAVE_CSSMERRORSTRING */ | |
383 | ||
384 | ||
536bc2c6 | 385 | /* |
db8b865d | 386 | * Do we have libpaper? |
536bc2c6 MS |
387 | */ |
388 | ||
db8b865d | 389 | /* #undef HAVE_LIBPAPER */ |
ef416fc2 | 390 | |
391 | ||
392 | /* | |
db8b865d | 393 | * Do we have mDNSResponder for DNS Service Discovery (aka Bonjour)? |
ef416fc2 | 394 | */ |
395 | ||
db8b865d | 396 | #define HAVE_DNSSD 1 |
ef416fc2 | 397 | |
398 | ||
399 | /* | |
db8b865d | 400 | * Do we have Avahi for DNS Service Discovery (aka Bonjour)? |
ef416fc2 | 401 | */ |
402 | ||
db8b865d | 403 | #undef HAVE_AVAHI |
536bc2c6 MS |
404 | |
405 | ||
406 | /* | |
db8b865d | 407 | * Do we have <sys/ioctl.h>? |
536bc2c6 MS |
408 | */ |
409 | ||
db8b865d | 410 | #undef HAVE_SYS_IOCTL_H |
536bc2c6 MS |
411 | |
412 | ||
eac3a0a0 MS |
413 | /* |
414 | * Does the "stat" structure contain the "st_gen" member? | |
415 | */ | |
416 | ||
417 | /* #undef HAVE_ST_GEN */ | |
418 | ||
419 | ||
ef416fc2 | 420 | /* |
421 | * Does the "tm" structure contain the "tm_gmtoff" member? | |
422 | */ | |
423 | ||
536bc2c6 | 424 | /* #undef HAVE_TM_GMTOFF */ |
ef416fc2 | 425 | |
426 | ||
427 | /* | |
428 | * Do we have rresvport_af()? | |
429 | */ | |
430 | ||
536bc2c6 | 431 | /* #undef HAVE_RRESVPORT_AF */ |
ef416fc2 | 432 | |
433 | ||
434 | /* | |
435 | * Do we have getaddrinfo()? | |
436 | */ | |
437 | ||
536bc2c6 | 438 | #define HAVE_GETADDRINFO 1 |
ef416fc2 | 439 | |
440 | ||
441 | /* | |
442 | * Do we have getnameinfo()? | |
443 | */ | |
444 | ||
536bc2c6 | 445 | #define HAVE_GETNAMEINFO 1 |
ef416fc2 | 446 | |
447 | ||
448 | /* | |
449 | * Do we have getifaddrs()? | |
450 | */ | |
451 | ||
536bc2c6 | 452 | /* #undef HAVE_GETIFADDRS */ |
ef416fc2 | 453 | |
454 | ||
455 | /* | |
456 | * Do we have hstrerror()? | |
457 | */ | |
458 | ||
536bc2c6 MS |
459 | /* #undef HAVE_HSTRERROR */ |
460 | ||
461 | ||
462 | /* | |
463 | * Do we have res_init()? | |
464 | */ | |
465 | ||
466 | /* #undef HAVE_RES_INIT */ | |
467 | ||
468 | ||
469 | /* | |
470 | * Do we have <resolv.h> | |
471 | */ | |
472 | ||
473 | /* #undef HAVE_RESOLV_H */ | |
ef416fc2 | 474 | |
475 | ||
476 | /* | |
477 | * Do we have the <sys/sockio.h> header file? | |
478 | */ | |
479 | ||
536bc2c6 | 480 | /* #undef HAVE_SYS_SOCKIO_H */ |
ef416fc2 | 481 | |
482 | ||
483 | /* | |
484 | * Does the sockaddr structure contain an sa_len parameter? | |
485 | */ | |
486 | ||
536bc2c6 | 487 | /* #undef HAVE_STRUCT_SOCKADDR_SA_LEN */ |
ef416fc2 | 488 | |
489 | ||
ef416fc2 | 490 | /* |
491 | * Do we have pthread support? | |
492 | */ | |
493 | ||
536bc2c6 MS |
494 | /* #undef HAVE_PTHREAD_H */ |
495 | ||
496 | ||
497 | /* | |
498 | * Do we have launchd support? | |
499 | */ | |
500 | ||
501 | /* #undef HAVE_LAUNCH_H */ | |
502 | /* #undef HAVE_LAUNCHD */ | |
ef416fc2 | 503 | |
504 | ||
505 | /* | |
506 | * Various scripting languages... | |
507 | */ | |
508 | ||
536bc2c6 MS |
509 | /* #undef HAVE_JAVA */ |
510 | #define CUPS_JAVA "" | |
511 | /* #undef HAVE_PERL */ | |
512 | #define CUPS_PERL "" | |
513 | /* #undef HAVE_PHP */ | |
514 | #define CUPS_PHP "" | |
515 | /* #undef HAVE_PYTHON */ | |
516 | #define CUPS_PYTHON "" | |
517 | ||
518 | ||
519 | /* | |
520 | * Location of the poppler/Xpdf pdftops program... | |
521 | */ | |
522 | ||
523 | /* #undef HAVE_PDFTOPS */ | |
db8b865d | 524 | /* #undef HAVE_PDFTOPS_WITH_ORIGPAGESIZES */ |
536bc2c6 MS |
525 | #define CUPS_PDFTOPS "" |
526 | ||
527 | ||
528 | /* | |
529 | * Location of the Ghostscript gs program... | |
530 | */ | |
531 | ||
532 | /* #undef HAVE_GHOSTSCRIPT */ | |
533 | #define CUPS_GHOSTSCRIPT "" | |
534 | ||
535 | ||
536bc2c6 MS |
536 | /* |
537 | * Do we have CoreFoundation public and private headers? | |
538 | */ | |
539 | ||
540 | /* #undef HAVE_COREFOUNDATION_H */ | |
541 | /* #undef HAVE_CFPRIV_H */ | |
542 | /* #undef HAVE_CFBUNDLEPRIV_H */ | |
543 | ||
544 | ||
6d2f911b MS |
545 | /* |
546 | * Do we have ApplicationServices public headers? | |
547 | */ | |
548 | ||
549 | /* #undef HAVE_APPLICATIONSERVICES_H */ | |
550 | ||
551 | ||
552 | /* | |
553 | * Do we have the SCDynamicStoreCopyComputerName function? | |
554 | */ | |
555 | ||
556 | /* #undef HAVE_SCDYNAMICSTORECOPYCOMPUTERNAME */ | |
557 | ||
558 | ||
536bc2c6 | 559 | /* |
f3c17241 | 560 | * Do we have OS X 10.4's mbr_XXX functions? |
536bc2c6 MS |
561 | */ |
562 | ||
563 | /* #undef HAVE_MEMBERSHIP_H */ | |
564 | /* #undef HAVE_MEMBERSHIPPRIV_H */ | |
565 | /* #undef HAVE_MBR_UID_TO_UUID */ | |
566 | ||
567 | ||
568 | /* | |
eac3a0a0 | 569 | * Do we have Darwin's notify_post header and function? |
536bc2c6 MS |
570 | */ |
571 | ||
572 | /* #undef HAVE_NOTIFY_H */ | |
573 | /* #undef HAVE_NOTIFY_POST */ | |
574 | ||
575 | ||
536bc2c6 | 576 | /* |
eac3a0a0 | 577 | * Do we have DBUS? |
536bc2c6 MS |
578 | */ |
579 | ||
eac3a0a0 MS |
580 | /* #undef HAVE_DBUS */ |
581 | /* #undef HAVE_DBUS_MESSAGE_ITER_INIT_APPEND */ | |
536bc2c6 MS |
582 | |
583 | ||
584 | /* | |
585 | * Do we have the GSSAPI support library (for Kerberos support)? | |
586 | */ | |
587 | ||
eac3a0a0 MS |
588 | /* #undef HAVE_GSS_ACQUIRE_CRED_EX_F */ |
589 | /* #undef HAVE_GSS_C_NT_HOSTBASED_SERVICE */ | |
590 | /* #undef HAVE_GSS_GSSAPI_H */ | |
591 | /* #undef HAVE_GSS_GSSAPI_SPI_H */ | |
536bc2c6 | 592 | /* #undef HAVE_GSSAPI */ |
536bc2c6 | 593 | /* #undef HAVE_GSSAPI_GSSAPI_H */ |
eac3a0a0 | 594 | /* #undef HAVE_GSSAPI_H */ |
536bc2c6 MS |
595 | |
596 | ||
597 | /* | |
598 | * Default GSS service name... | |
599 | */ | |
600 | ||
f8b3a85b | 601 | #define CUPS_DEFAULT_GSSSERVICENAME "host" |
536bc2c6 MS |
602 | |
603 | ||
604 | /* | |
605 | * Select/poll interfaces... | |
606 | */ | |
607 | ||
608 | /* #undef HAVE_POLL */ | |
609 | /* #undef HAVE_EPOLL */ | |
610 | /* #undef HAVE_KQUEUE */ | |
611 | ||
612 | ||
613 | /* | |
614 | * Do we have the <dlfcn.h> header? | |
615 | */ | |
616 | ||
617 | /* #undef HAVE_DLFCN_H */ | |
618 | ||
619 | ||
620 | /* | |
621 | * Do we have <sys/param.h>? | |
622 | */ | |
623 | ||
624 | /* #undef HAVE_SYS_PARAM_H */ | |
625 | ||
626 | ||
627 | /* | |
628 | * Do we have <sys/ucred.h>? | |
629 | */ | |
630 | ||
631 | /* #undef HAVE_SYS_UCRED_H */ | |
632 | ||
633 | ||
634 | /* | |
635 | * Do we have removefile()? | |
636 | */ | |
637 | ||
638 | /* #undef HAVE_REMOVEFILE */ | |
639 | ||
640 | ||
641 | /* | |
642 | * Do we have <sandbox.h>? | |
643 | */ | |
644 | ||
645 | /* #undef HAVE_SANDBOX_H */ | |
646 | ||
647 | ||
648 | /* | |
649 | * Which random number generator function to use... | |
650 | */ | |
651 | ||
f8b3a85b | 652 | /* #undef HAVE_ARC4RANDOM */ |
536bc2c6 | 653 | /* #undef HAVE_RANDOM */ |
536bc2c6 MS |
654 | /* #undef HAVE_LRAND48 */ |
655 | ||
f8b3a85b MS |
656 | #ifdef HAVE_ARC4RANDOM |
657 | # define CUPS_RAND() arc4random() | |
658 | # define CUPS_SRAND(v) arc4random_stir() | |
659 | #elif defined(HAVE_RANDOM) | |
660 | # define CUPS_RAND() random() | |
661 | # define CUPS_SRAND(v) srandom(v) | |
662 | #elif defined(HAVE_LRAND48) | |
663 | # define CUPS_RAND() lrand48() | |
664 | # define CUPS_SRAND(v) srand48(v) | |
665 | #else | |
666 | # define CUPS_RAND() rand() | |
667 | # define CUPS_SRAND(v) srand(v) | |
668 | #endif /* HAVE_ARC4RANDOM */ | |
669 | ||
536bc2c6 MS |
670 | |
671 | /* | |
672 | * Do we have vproc_transaction_begin/end? | |
673 | */ | |
674 | ||
675 | /* #undef HAVE_VPROC_TRANSACTION_BEGIN */ | |
676 | ||
677 | ||
678 | /* | |
679 | * Do we have libusb? | |
680 | */ | |
681 | ||
db8b865d | 682 | /* #undef HAVE_LIBUSB */ |
536bc2c6 MS |
683 | |
684 | ||
685 | /* | |
686 | * Do we have libwrap and tcpd.h? | |
687 | */ | |
688 | ||
689 | /* #undef HAVE_TCPD_H */ | |
ef416fc2 | 690 | |
691 | ||
eac3a0a0 MS |
692 | /* |
693 | * Do we have <iconv.h>? | |
694 | */ | |
695 | ||
696 | /* #undef HAVE_ICONV_H */ | |
697 | ||
698 | ||
699 | /* | |
700 | * Do we have statfs or statvfs and one of the corresponding headers? | |
701 | */ | |
702 | ||
703 | /* #undef HAVE_STATFS */ | |
704 | /* #undef HAVE_STATVFS */ | |
705 | /* #undef HAVE_SYS_MOUNT_H */ | |
706 | /* #undef HAVE_SYS_STATFS_H */ | |
707 | /* #undef HAVE_SYS_STATVFS_H */ | |
708 | /* #undef HAVE_SYS_VFS_H */ | |
709 | ||
710 | ||
711 | /* | |
f3c17241 | 712 | * Location of OS X localization bundle, if any. |
eac3a0a0 MS |
713 | */ |
714 | ||
715 | /* #undef CUPS_BUNDLEDIR */ | |
716 | ||
717 | ||
718 | /* | |
db8b865d | 719 | * Do we have XPC? |
eac3a0a0 MS |
720 | */ |
721 | ||
db8b865d MS |
722 | /* #undef HAVE_XPC */ |
723 | /* #undef HAVE_XPC_PRIVATE_H */ | |
eac3a0a0 MS |
724 | |
725 | ||
726 | /* | |
db8b865d | 727 | * Do we have Mini-XML? |
eac3a0a0 MS |
728 | */ |
729 | ||
db8b865d MS |
730 | /* #undef HAVE_MXML_H */ |
731 | ||
732 | ||
733 | /* | |
734 | * Do we have the C99 abs() function? | |
735 | */ | |
eac3a0a0 | 736 | |
db8b865d MS |
737 | /* #undef HAVE_ABS */ |
738 | #if !defined(HAVE_ABS) && !defined(abs) | |
739 | # if defined(__GNUC__) || __STDC_VERSION__ >= 199901L | |
740 | # define abs(x) _cups_abs(x) | |
741 | static inline int _cups_abs(int i) { return (i < 0 ? -i : i); } | |
742 | # elif defined(_MSC_VER) | |
743 | # define abs(x) _cups_abs(x) | |
744 | static __inline int _cups_abs(int i) { return (i < 0 ? -i : i); } | |
745 | # else | |
746 | # define abs(x) ((x) < 0 ? -(x) : (x)) | |
747 | # endif /* __GNUC__ || __STDC_VERSION__ */ | |
748 | #endif /* !HAVE_ABS && !abs */ | |
eac3a0a0 | 749 | |
ef416fc2 | 750 | #endif /* !_CUPS_CONFIG_H_ */ |
751 | ||
752 | /* | |
f2d18633 | 753 | * End of "$Id$". |
ef416fc2 | 754 | */ |