]> git.ipfire.org Git - thirdparty/squid.git/blob - include/squid.h
Removed CVS $ markers
[thirdparty/squid.git] / include / squid.h
1 /*
2 * AUTHOR: Duane Wessels
3 *
4 * SQUID Web Proxy Cache http://www.squid-cache.org/
5 * ----------------------------------------------------------
6 *
7 * Squid is the result of efforts by numerous individuals from
8 * the Internet community; see the CONTRIBUTORS file for full
9 * details. Many organizations have provided support for Squid's
10 * development; see the SPONSORS file for full details. Squid is
11 * Copyrighted (C) 2001 by the Regents of the University of
12 * California; see the COPYRIGHT file for full details. Squid
13 * incorporates software developed and/or copyrighted by other
14 * sources; see the CREDITS file for full details.
15 *
16 * This program is free software; you can redistribute it and/or modify
17 * it under the terms of the GNU General Public License as published by
18 * the Free Software Foundation; either version 2 of the License, or
19 * (at your option) any later version.
20 *
21 * This program is distributed in the hope that it will be useful,
22 * but WITHOUT ANY WARRANTY; without even the implied warranty of
23 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
24 * GNU General Public License for more details.
25 *
26 * You should have received a copy of the GNU General Public License
27 * along with this program; if not, write to the Free Software
28 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111, USA.
29 *
30 */
31
32 #ifndef SQUID_CONFIG_H
33 #define SQUID_CONFIG_H
34
35 #include "autoconf.h" /* For GNU autoconf variables */
36
37 #if !defined(HAVE_SQUID)
38 /* sub-packages define their own version details */
39 #include "version.h"
40
41 #endif
42
43 /* default values for listen ports. Usually specified in squid.conf really */
44 #define CACHE_HTTP_PORT 3128
45 #define CACHE_ICP_PORT 3130
46
47 /* To keep API definitions clear */
48 #ifdef __cplusplus
49 #define SQUIDCEXTERN extern "C"
50 #else
51 #define SQUIDCEXTERN extern
52 #endif
53
54 #if _USE_INLINE_
55 #define _SQUID_INLINE_ inline
56 #else
57 #define _SQUID_INLINE_
58 #endif
59
60 /****************************************************************************
61 *--------------------------------------------------------------------------*
62 * DO *NOT* MAKE ANY CHANGES below here unless you know what you're doing...*
63 *--------------------------------------------------------------------------*
64 ****************************************************************************/
65
66 #include "compat/compat.h"
67
68 #ifdef USE_POSIX_REGEX
69 #ifndef USE_RE_SYNTAX
70 #define USE_RE_SYNTAX REG_EXTENDED /* default Syntax */
71 #endif
72 #endif
73
74 #if !defined(CACHEMGR_HOSTNAME)
75 #define CACHEMGR_HOSTNAME ""
76 #else
77 #define CACHEMGR_HOSTNAME_DEFINED 1
78 #endif
79
80 #if SQUID_DETECT_UDP_SO_SNDBUF > 16384
81 #define SQUID_UDP_SO_SNDBUF 16384
82 #else
83 #define SQUID_UDP_SO_SNDBUF SQUID_DETECT_UDP_SO_SNDBUF
84 #endif
85
86 #if SQUID_DETECT_UDP_SO_RCVBUF > 16384
87 #define SQUID_UDP_SO_RCVBUF 16384
88 #else
89 #define SQUID_UDP_SO_RCVBUF SQUID_DETECT_UDP_SO_RCVBUF
90 #endif
91
92 #if HAVE_RANDOM
93 #define squid_random random
94 #define squid_srandom srandom
95 #elif HAVE_LRAND48
96 #define squid_random lrand48
97 #define squid_srandom srand48
98 #else
99 #define squid_random rand
100 #define squid_srandom srand
101 #endif
102
103 /*
104 * Determine if this is a leak check build or standard
105 */
106 #if PURIFY
107 #define LEAK_CHECK_MODE 1
108 #elif WITH_VALGRIND
109 #define LEAK_CHECK_MODE 1
110 #elif XMALLOC_TRACE
111 #define LEAK_CHECK_MODE 1
112 #endif
113
114 /* temp hack: needs to be pre-defined for now. */
115 #define SQUID_MAXPATHLEN 256
116
117 // TODO: determine if this is required. OR if compat/os/mswin.h works
118 #if _SQUID_MSWIN_
119 /** \cond AUTODOCS-IGNORE */
120 using namespace Squid;
121 /** \endcond */
122 #endif
123
124 // temporary for the definition of LOCAL_ARRAY
125 #include "leakcheck.h"
126
127 #endif /* SQUID_CONFIG_H */