From: wessels <> Date: Fri, 16 Nov 2007 01:48:27 +0000 (+0000) Subject: Change 'ESI' define to 'SQUID_ESI' X-Git-Tag: SQUID_3_0_STABLE1~37 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=8c87d1887705928ed1f185718ac3111c808c168c;p=thirdparty%2Fsquid.git Change 'ESI' define to 'SQUID_ESI' On Solaris, something else defines the preprocessor symbol ESI, which confuses Squid compliation. Now we use a name less likely to cause a collision. --- diff --git a/configure.in b/configure.in index fd59a83058..934d8ce1f3 100644 --- a/configure.in +++ b/configure.in @@ -1,7 +1,7 @@ dnl Configuration input file for Squid dnl -dnl $Id: configure.in,v 1.485 2007/11/11 20:10:09 amosjeffries Exp $ +dnl $Id: configure.in,v 1.486 2007/11/15 18:48:27 wessels Exp $ dnl dnl dnl @@ -11,7 +11,7 @@ AM_CONFIG_HEADER(include/autoconf.h) AC_CONFIG_AUX_DIR(cfgaux) AC_CONFIG_SRCDIR([src/main.cc]) AM_INIT_AUTOMAKE([tar-ustar]) -AC_REVISION($Revision: 1.485 $)dnl +AC_REVISION($Revision: 1.486 $)dnl AC_PREFIX_DEFAULT(/usr/local/squid) AM_MAINTAINER_MODE @@ -695,11 +695,11 @@ AC_ARG_ENABLE(esi, AC_HELP_STRING([--enable-esi],[Enable ESI for accelerators. Requires libexpat. Enabling ESI will cause squid to follow the Edge Acceleration Specification (www.esi.org). This causes squid to IGNORE client Cache-Control headers. DO NOT use this in a squid configured as a web proxy, ONLY use it in a squid configured for webserver acceleration.]), use_esi=$enableval, use_esi=no) if test "$use_esi" = "yes" ; then - AC_DEFINE(ESI,1,[Compile the ESI processor and Surrogate header support]) + AC_DEFINE(SQUID_ESI,1,[Compile the ESI processor and Surrogate header support]) AM_CONDITIONAL(USE_ESI, true) XTRA_LIBS="$XTRA_LIBS -lexpat -lxml2" else - AC_DEFINE(ESI,0,[Compile the ESI processor and Surrogate header support]) + AC_DEFINE(SQUID_ESI,0,[Compile the ESI processor and Surrogate header support]) fi AM_CONDITIONAL(USE_ICAP_CLIENT, false) diff --git a/include/profiling.h b/include/profiling.h index 0986f85e64..eeb8881982 100644 --- a/include/profiling.h +++ b/include/profiling.h @@ -116,7 +116,7 @@ typedef enum { XPROF_file_read, XPROF_file_write, XPROF_file_close, -#ifdef ESI +#if SQUID_ESI XPROF_esiExpressionEval, XPROF_esiProcessing, XPROF_esiParsing, diff --git a/src/Store.h b/src/Store.h index 5020befedb..d7e2857a00 100644 --- a/src/Store.h +++ b/src/Store.h @@ -1,6 +1,6 @@ /* - * $Id: Store.h,v 1.37 2007/09/28 00:22:37 hno Exp $ + * $Id: Store.h,v 1.38 2007/11/15 18:48:30 wessels Exp $ * * * SQUID Web Proxy Cache http://www.squid-cache.org/ @@ -45,7 +45,8 @@ #include "Packer.h" #include "RemovalPolicy.h" -#if ESI +#if SQUID_ESI +ESI #include "ESIElement.h" #endif @@ -165,7 +166,7 @@ public: void *operator new(size_t byteCount); void operator delete(void *address); void setReleaseFlag(); -#if ESI +#if SQUID_ESI ESIElement::Pointer cachedESITree; #endif diff --git a/src/cache_cf.cc b/src/cache_cf.cc index ab9ba3e527..aa1ea5a4a7 100644 --- a/src/cache_cf.cc +++ b/src/cache_cf.cc @@ -1,6 +1,6 @@ /* - * $Id: cache_cf.cc,v 1.526 2007/11/13 23:06:01 rousskov Exp $ + * $Id: cache_cf.cc,v 1.527 2007/11/15 18:48:30 wessels Exp $ * * DEBUG: section 3 Configuration File Parsing * AUTHOR: Harvest Derived @@ -50,7 +50,7 @@ #if SQUID_SNMP #include "snmp.h" #endif -#if ESI +#if SQUID_ESI #include "ESIParser.h" #endif diff --git a/src/cf.data.pre b/src/cf.data.pre index 4a8de17b5e..c440c70560 100644 --- a/src/cf.data.pre +++ b/src/cf.data.pre @@ -1,6 +1,6 @@ # -# $Id: cf.data.pre,v 1.486 2007/11/06 21:19:30 wessels Exp $ +# $Id: cf.data.pre,v 1.487 2007/11/15 18:48:30 wessels Exp $ # # SQUID Web Proxy Cache http://www.squid-cache.org/ # ---------------------------------------------------------- @@ -3375,7 +3375,7 @@ COMMENT_START COMMENT_END NAME: httpd_accel_surrogate_id -IFDEF: ESI +IFDEF: SQUID_ESI TYPE: string LOC: Config.Accel.surrogate_id DEFAULT: unset-id @@ -3387,7 +3387,7 @@ DOC_START DOC_END NAME: http_accel_surrogate_remote -IFDEF: ESI +IFDEF: SQUID_ESI COMMENT: on|off TYPE: onoff DEFAULT: off @@ -3398,7 +3398,7 @@ DOC_START DOC_END NAME: esi_parser -IFDEF: ESI +IFDEF: SQUID_ESI COMMENT: libxml2|expat|custom TYPE: string LOC: ESIParser::Type diff --git a/src/client_side_reply.cc b/src/client_side_reply.cc index 24a5023d9a..86e060b367 100644 --- a/src/client_side_reply.cc +++ b/src/client_side_reply.cc @@ -1,6 +1,6 @@ /* - * $Id: client_side_reply.cc,v 1.140 2007/10/30 21:43:45 rousskov Exp $ + * $Id: client_side_reply.cc,v 1.141 2007/11/15 18:48:30 wessels Exp $ * * DEBUG: section 88 Client-side Reply Routines * AUTHOR: Robert Collins (Originally Duane Wessels in client_side.c) @@ -44,7 +44,7 @@ #include "clientStream.h" #include "AuthUserRequest.h" -#if ESI +#if SQUID_ESI #include "ESI.h" #endif #include "MemObject.h" @@ -1840,7 +1840,8 @@ clientReplyContext::processReplyAccessResult(bool accessAllowed) (int) body_size << " bytes after " << reply->hdr_sz << " bytes of headers"); -#if ESI +#if SQUID_ESI +#warning foo if (http->flags.accel && reply->sline.status != HTTP_FORBIDDEN && !alwaysAllowResponse(reply->sline.status) && diff --git a/src/client_side_request.cc b/src/client_side_request.cc index 5f79676f49..37c5ad4cc8 100644 --- a/src/client_side_request.cc +++ b/src/client_side_request.cc @@ -1,6 +1,6 @@ /* - * $Id: client_side_request.cc,v 1.94 2007/10/16 15:57:28 rousskov Exp $ + * $Id: client_side_request.cc,v 1.95 2007/11/15 18:48:30 wessels Exp $ * * DEBUG: section 85 Client-side Request Routines * AUTHOR: Robert Collins (Originally Duane Wessels in client_side.c) @@ -601,7 +601,7 @@ clientInterpretRequestHeaders(ClientHttpRequest * http) HttpRequest *request = http->request; HttpHeader *req_hdr = &request->header; int no_cache = 0; -#if !(ESI) || defined(USE_USERAGENT_LOG) || defined(USE_REFERER_LOG) +#if !(SQUID_ESI) || defined(USE_USERAGENT_LOG) || defined(USE_REFERER_LOG) const char *str; #endif @@ -612,7 +612,7 @@ clientInterpretRequestHeaders(ClientHttpRequest * http) if (request->ims > 0) request->flags.ims = 1; -#if ESI +#if SQUID_ESI /* * We ignore Cache-Control as per the Edge Architecture Section 3. See * www.esi.org for more information. diff --git a/src/http.cc b/src/http.cc index 4399965337..d5c728be16 100644 --- a/src/http.cc +++ b/src/http.cc @@ -1,6 +1,6 @@ /* - * $Id: http.cc,v 1.538 2007/09/27 14:34:06 rousskov Exp $ + * $Id: http.cc,v 1.539 2007/11/15 18:48:30 wessels Exp $ * * DEBUG: section 11 Hypertext Transfer Protocol (HTTP) * AUTHOR: Harvest Derived @@ -325,7 +325,7 @@ httpMaybeRemovePublic(StoreEntry * e, http_status status) void HttpStateData::processSurrogateControl(HttpReply *reply) { -#if ESI +#if SQUID_ESI if (request->flags.accelerated && reply->surrogate_control) { HttpHdrScTarget *sctusable = @@ -1342,7 +1342,7 @@ HttpStateData::httpBuildRequestHeader(HttpRequest * request, strVia.clean(); } -#if ESI +#if SQUID_ESI { /* Append Surrogate-Capabilities */ String strSurrogate (hdr_in->getList(HDR_SURROGATE_CAPABILITY)); diff --git a/src/structs.h b/src/structs.h index 1f8a278c48..9d48c447a5 100644 --- a/src/structs.h +++ b/src/structs.h @@ -1,6 +1,6 @@ /* - * $Id: structs.h,v 1.565 2007/09/28 00:22:38 hno Exp $ + * $Id: structs.h,v 1.566 2007/11/15 18:48:30 wessels Exp $ * * * SQUID Web Proxy Cache http://www.squid-cache.org/ @@ -399,7 +399,7 @@ struct _SquidConfig struct { -#if ESI +#if SQUID_ESI char *surrogate_id; #endif @@ -538,7 +538,7 @@ struct _SquidConfig int ie_refresh; int vary_ignore_expire; int pipeline_prefetch; -#if ESI +#if SQUID_ESI int surrogate_is_remote; #endif