diff options
author | decke <decke@FreeBSD.org> | 2014-01-30 20:36:23 +0800 |
---|---|---|
committer | decke <decke@FreeBSD.org> | 2014-01-30 20:36:23 +0800 |
commit | d32be3b56903ff0a0f87aa021d42d3735a89697a (patch) | |
tree | 39c5b9eee27cdc762580b6de7547c95ff8482dc2 /www | |
parent | 75f8150502aed0a57ae3ba054d5c257f4f811424 (diff) | |
download | freebsd-ports-gnome-d32be3b56903ff0a0f87aa021d42d3735a89697a.tar.gz freebsd-ports-gnome-d32be3b56903ff0a0f87aa021d42d3735a89697a.tar.zst freebsd-ports-gnome-d32be3b56903ff0a0f87aa021d42d3735a89697a.zip |
- Update to 4.1.2
- Build with clang on FreeBSD 10 and remove USE_GCC=any
- added some configuration OPTIONS
- added patch to fix segfault with current tcl
- added patches to avoid crash on i386
- compile with libxml2, hwloc, boost
- add user tserv for owning configuration and log directory
- added stage support
- enabled compiling WCCP and SSD support
- use lua with JIT
- install perl TS module
PR: ports/185669
Submitted by: Radim Kolar <hsn@sendmail.cz>
Approved by: maintainer timeout (3 weeks)
Diffstat (limited to 'www')
27 files changed, 500 insertions, 113 deletions
diff --git a/www/trafficserver/Makefile b/www/trafficserver/Makefile index 5cfd4f3c8210..e42254076121 100644 --- a/www/trafficserver/Makefile +++ b/www/trafficserver/Makefile @@ -2,7 +2,7 @@ # $FreeBSD$ PORTNAME= trafficserver -PORTVERSION= 3.2.5 +PORTVERSION= 4.1.2 CATEGORIES= www MASTER_SITES= APACHE/${PORTNAME} @@ -12,39 +12,71 @@ COMMENT= Fast, scalable and extensible HTTP proxy server LICENSE= APACHE20 LIB_DEPENDS= libexecinfo.so:${PORTSDIR}/devel/libexecinfo \ - libexpat.so:${PORTSDIR}/textproc/expat2 \ - libpcre.so:${PORTSDIR}/devel/pcre + libpcre.so:${PORTSDIR}/devel/pcre \ + libxml2.so:${PORTSDIR}/textproc/libxml2 \ + libboost_system.so:${PORTSDIR}/devel/boost-libs \ + libcurl.so:${PORTSDIR}/ftp/curl \ + libhwloc.so:${PORTSDIR}/devel/hwloc \ + libluajit-${LUA_VER}.so:${PORTSDIR}/lang/luajit -USE_AUTOTOOLS= autoconf automake libtool +USE_AUTOTOOLS= autoconf automake libtool aclocal +GNU_CONFIGURE= yes USE_BZIP2= yes -USES= pkgconfig tcl +USES= pkgconfig tcl gmake perl5 USE_OPENSSL= yes USE_SQLITE= yes USE_RC_SUBR= ${PORTNAME} +USE_LUA= 5.1+ USE_LDCONFIG= yes -USE_GCC= any ONLY_FOR_ARCHS= i386 amd64 +USERS= www +GROUPS= nogroup + +LOGDIR= /var/log/${PORTNAME} + +PLIST_SUB= LOGDIR="${LOGDIR}" LDFLAGS+= -L${LOCALBASE}/lib -CONFIGURE_ARGS= --with-expat=${LOCALBASE} \ +CONFIGURE_ARGS= --with-libxml2=${LOCALBASE} \ --with-pcre=${LOCALBASE} \ - --with-openssl=${OPENSSLBASE} + --with-openssl=${OPENSSLBASE} \ + --with-xml=libxml2 \ + --with-lua=${LOCALBASE} --enable-luajit \ + --with-tcl=${TCL_LIBDIR} \ + --verbose \ + --enable-cppapi \ + --with-user=${USERS} \ + --with-group=${GROUPS} + +ACLOCAL_ARGS= -I build +OPTIONS_DEFINE= WCCP INTERIM +OPTIONS_RADIO= MEMMAN +OPTIONS_RADIO_MEMMAN= ALLOCATORS FREELISTS RECLAIM +OPTIONS_DEFAULT= FREELISTS + +WCCP_DESC= Enable WCCPv2 protocol +INTERIM_DESC= Enable interim cache (SSD) +ALLOCATORS_DESC= Manage memory with allocators +FREELISTS_DESC= Manage memory with freelists +RECLAIM_DESC= Reclaim unused memory in freelists -.include <bsd.port.pre.mk> +WCCP_CONFIGURE_ENABLE= wccp +INTERIM_CONFIGURE_ENABLE= interim-cache -post-patch: - @${REINPLACE_CMD} -e 's,|| mv,|| cp -p,' ${WRKSRC}/proxy/config/Makefile.am +.include <bsd.port.options.mk> -pre-configure: - @${FIND} ${WRKSRC}/example ${WRKSRC}/plugins/conf_remap \ - -name Makefile.am | ${XARGS} ${REINPLACE_CMD} \ - -e 's,CFLAGS+=,AM_CFLAGS=,' \ - -e 's,CXXFLAGS+=,AM_CXXFLAGS=,' - @cd ${WRKSRC} && ${AUTORECONF} -i +.if ${PORT_OPTIONS:MRECLAIM} +CONFIGURE_ARGS+= --enable-reclaimable-freelist --enable-freelist +.elif ${PORT_OPTIONS:MFREELISTS} +CONFIGURE_ARGS+= --enable-freelist +.elif ${PORT_OPTIONS:MALLOCATORS} +CONFIGURE_ARGS+= --disable-freelist +.else +FORBIDDEN= No allocation strategy selected +.endif -post-configure: - @${FIND} ${WRKSRC} -name 'Makefile' | ${XARGS} ${REINPLACE_CMD} \ - -e 's,LIBTOOL_LINK_FLAGS = -R -R,LIBTOOL_LINK_FLAGS = -R,' \ - -e 's,LDFLAGS = -rdynamic *-R -R,LDFLAGS = -rdynamic -R,' +post-install: + @${MKDIR} ${STAGEDIR}${ETCDIR}/snapshots + @cd ${STAGEDIR}${ETCDIR} && for f in *.config *.config.xml; do ${MV} $$f $$f.default; done -.include <bsd.port.post.mk> +.include <bsd.port.mk> diff --git a/www/trafficserver/distinfo b/www/trafficserver/distinfo index c0adba838657..dfa29404074a 100644 --- a/www/trafficserver/distinfo +++ b/www/trafficserver/distinfo @@ -1,2 +1,2 @@ -SHA256 (trafficserver-3.2.5.tar.bz2) = 6cada59cb8d8800d48344fa711aec6964083a182deee21fa445c31227bcd1c90 -SIZE (trafficserver-3.2.5.tar.bz2) = 2535498 +SHA256 (trafficserver-4.1.2.tar.bz2) = 16bf75bd22ed2a1ee2bc6bac38add34feffa9c12e787d73b2721eb3042698ef9 +SIZE (trafficserver-4.1.2.tar.bz2) = 6358857 diff --git a/www/trafficserver/files/patch-build__xml.m4 b/www/trafficserver/files/patch-build__xml.m4 new file mode 100644 index 000000000000..95dc3daf3137 --- /dev/null +++ b/www/trafficserver/files/patch-build__xml.m4 @@ -0,0 +1,11 @@ +--- ./build/xml.m4.orig 2013-12-05 22:07:48.000000000 +0000 ++++ ./build/xml.m4 2014-01-27 08:45:49.000000000 +0000 +@@ -59,7 +59,7 @@ + elif test "$withval" != "no"; then + enable_libxml2=yes + libxml2_include="$withval/include/libxml2" +- libxml2_ldflags="$withval/lib" ++ libxml2_ldflags="-L$withval/lib" + fi + fi + ]) diff --git a/www/trafficserver/files/patch-configure.ac b/www/trafficserver/files/patch-configure.ac deleted file mode 100644 index de29a06ac360..000000000000 --- a/www/trafficserver/files/patch-configure.ac +++ /dev/null @@ -1,30 +0,0 @@ ---- configure.ac.orig 2013-07-03 04:17:28.000000000 +0800 -+++ configure.ac 2013-08-30 05:23:44.089882723 +0800 -@@ -40,7 +40,7 @@ - AC_CONFIG_AUX_DIR([build/aux]) - AC_CONFIG_SRCDIR([proxy/Main.cc]) - AC_CONFIG_MACRO_DIR([build]) --AM_INIT_AUTOMAKE([-Wall -Werror foreign no-installinfo no-installman 1.9.2]) -+AM_INIT_AUTOMAKE([-Wall -Werror foreign no-installinfo no-installman 1.9.2 subdir-objects]) - AM_CONFIG_HEADER([lib/ts/ink_autoconf.h]) - - # Configure with --disable-silent-rules to get verbose output. For more info, see -@@ -497,6 +497,10 @@ - [AM_PROG_AR]) - - -+# required by automake-1.12 -+m4_pattern_allow([AM_PROG_AR]) -+AM_PROG_AR -+ - AC_PROG_CPP - AC_PROG_CXXCPP - AM_PROG_AS -@@ -506,7 +510,6 @@ - AC_PROG_LIBTOOL - AC_CHECK_PROG(RM, rm, rm) - AC_CHECK_PROG(ASCPP, cpp, cpp) --AC_CHECK_TOOL(AR, ar, ar) - AC_ISC_POSIX - AS_IF([test "x$enable_wccp" = "xyes"], - [ diff --git a/www/trafficserver/files/patch-cop__Makefile.am b/www/trafficserver/files/patch-cop__Makefile.am new file mode 100644 index 000000000000..976a74fd40c5 --- /dev/null +++ b/www/trafficserver/files/patch-cop__Makefile.am @@ -0,0 +1,11 @@ +--- ./cop/Makefile.am.orig 2013-12-05 22:07:48.000000000 +0000 ++++ ./cop/Makefile.am 2014-01-27 08:45:49.000000000 +0000 +@@ -17,6 +17,8 @@ + # See the License for the specific language governing permissions and + # limitations under the License. + ++AUTOMAKE_OPTIONS= subdir-objects ++ + AM_CPPFLAGS = $(iocore_include_dirs) \ + -I$(top_srcdir)/lib \ + -I$(top_srcdir)/lib/records \ diff --git a/www/trafficserver/files/patch-cop__TrafficCop.cc b/www/trafficserver/files/patch-cop__TrafficCop.cc new file mode 100644 index 000000000000..efef4ac81fa4 --- /dev/null +++ b/www/trafficserver/files/patch-cop__TrafficCop.cc @@ -0,0 +1,11 @@ +--- ./cop/TrafficCop.cc.orig 2013-12-05 22:07:48.000000000 +0000 ++++ ./cop/TrafficCop.cc 2014-01-27 08:45:49.000000000 +0000 +@@ -813,7 +813,7 @@ + + snprintf(port_str, sizeof(port_str), "%d", port); + memset(&hints, 0, sizeof(hints)); +- hints.ai_family = AF_UNSPEC; ++ hints.ai_family = AF_INET; + hints.ai_socktype = SOCK_STREAM; + + err = getaddrinfo(ip, port_str, &hints, &result); diff --git a/www/trafficserver/files/patch-example__Makefile.am b/www/trafficserver/files/patch-example__Makefile.am new file mode 100644 index 000000000000..5d921fdec7d0 --- /dev/null +++ b/www/trafficserver/files/patch-example__Makefile.am @@ -0,0 +1,10 @@ +--- ./example/Makefile.am.orig 2013-12-05 22:07:48.000000000 +0000 ++++ ./example/Makefile.am 2014-01-27 08:45:49.000000000 +0000 +@@ -13,6 +13,7 @@ + # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + # See the License for the specific language governing permissions and + # limitations under the License. ++AUTOMAKE_OPTIONS= subdir-objects + + include $(top_srcdir)/build/plugins.mk + diff --git a/www/trafficserver/files/patch-example__protocol__Protocol.c b/www/trafficserver/files/patch-example__protocol__Protocol.c new file mode 100644 index 000000000000..3286bea03d86 --- /dev/null +++ b/www/trafficserver/files/patch-example__protocol__Protocol.c @@ -0,0 +1,35 @@ +--- ./example/protocol/Protocol.c.orig 2013-12-05 22:07:48.000000000 +0000 ++++ ./example/protocol/Protocol.c 2014-01-27 08:45:49.000000000 +0000 +@@ -104,6 +104,7 @@ + TSPluginInit(int argc, const char *argv[]) + { + TSPluginRegistrationInfo info; ++ char *end; + + info.plugin_name = "output-header"; + info.vendor_name = "MyCompany"; +@@ -124,17 +125,19 @@ + printf("[protocol_plugin] Usage: protocol.so accept_port server_port\n"); + printf("[protocol_plugin] Wrong arguments. Using deafult ports.\n"); + } else { +- if (!isnan(atoi(argv[1]))) { +- accept_port = atoi(argv[1]); ++ strtol(argv[1], &end, 10); ++ if (*end == '\0') { ++ accept_port = strtol(argv[1], &end, 10); + TSDebug("protocol", "using accept_port %d", accept_port); + printf("[protocol_plugin] using accept_port %d\n", accept_port); + } else { + printf("[protocol_plugin] Wrong argument for accept_port."); + printf("Using deafult port %d\n", accept_port); + } +- +- if (!isnan(atoi(argv[2]))) { +- server_port = atoi(argv[2]); ++ ++ strtol(argv[2], &end, 10); ++ if (*end == '\0') { ++ server_port = strtol(argv[2], &end, 10); + TSDebug("protocol", "using server_port %d", server_port); + printf("[protocol_plugin] using server_port %d\n", server_port); + } else { diff --git a/www/trafficserver/files/patch-iocore__aio__Makefile.am b/www/trafficserver/files/patch-iocore__aio__Makefile.am new file mode 100644 index 000000000000..b14751feb1b2 --- /dev/null +++ b/www/trafficserver/files/patch-iocore__aio__Makefile.am @@ -0,0 +1,10 @@ +--- ./iocore/aio/Makefile.am.orig 2013-12-05 22:07:48.000000000 +0000 ++++ ./iocore/aio/Makefile.am 2014-01-27 08:45:49.000000000 +0000 +@@ -15,6 +15,7 @@ + # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + # See the License for the specific language governing permissions and + # limitations under the License. ++AUTOMAKE_OPTIONS= subdir-objects + + AM_CPPFLAGS = \ + -I$(top_srcdir)/iocore/eventsystem \ diff --git a/www/trafficserver/files/patch-iocore__eventsystem__Makefile.am b/www/trafficserver/files/patch-iocore__eventsystem__Makefile.am new file mode 100644 index 000000000000..ca15bff831ad --- /dev/null +++ b/www/trafficserver/files/patch-iocore__eventsystem__Makefile.am @@ -0,0 +1,10 @@ +--- ./iocore/eventsystem/Makefile.am.orig 2013-12-05 22:07:48.000000000 +0000 ++++ ./iocore/eventsystem/Makefile.am 2014-01-27 08:45:49.000000000 +0000 +@@ -15,6 +15,7 @@ + # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + # See the License for the specific language governing permissions and + # limitations under the License. ++AUTOMAKE_OPTIONS= subdir-objects + + AM_CPPFLAGS = \ + -I$(top_srcdir)/lib \ diff --git a/www/trafficserver/files/patch-lib__atscppapi__src__AsyncHttpFetch.cc b/www/trafficserver/files/patch-lib__atscppapi__src__AsyncHttpFetch.cc new file mode 100644 index 000000000000..959322de3453 --- /dev/null +++ b/www/trafficserver/files/patch-lib__atscppapi__src__AsyncHttpFetch.cc @@ -0,0 +1,11 @@ +--- ./lib/atscppapi/src/AsyncHttpFetch.cc.orig 2013-12-05 22:07:48.000000000 +0000 ++++ ./lib/atscppapi/src/AsyncHttpFetch.cc 2014-01-27 08:45:49.000000000 +0000 +@@ -82,7 +82,7 @@ + state->body_ = data_start; // data_start will now be pointing to body + state->body_size_ = data_end - data_start; + utils::internal::initResponse(state->response_, state->hdr_buf_, state->hdr_loc_); +- LOG_DEBUG("Fetch result had a status code of %d with a body length of %ld", status, state->body_size_); ++ LOG_DEBUG("Fetch result had a status code of %d with a body length of %zu", status, state->body_size_); + } else { + LOG_ERROR("Unable to parse response; Request URL [%s]; transaction %p", + state->request_.getUrl().getUrlString().c_str(), txn); diff --git a/www/trafficserver/files/patch-lib__atscppapi__src__GzipDeflateTransformation.cc b/www/trafficserver/files/patch-lib__atscppapi__src__GzipDeflateTransformation.cc new file mode 100644 index 000000000000..8a3c46eaf4a1 --- /dev/null +++ b/www/trafficserver/files/patch-lib__atscppapi__src__GzipDeflateTransformation.cc @@ -0,0 +1,35 @@ +--- ./lib/atscppapi/src/GzipDeflateTransformation.cc.orig 2013-12-05 22:07:48.000000000 +0000 ++++ ./lib/atscppapi/src/GzipDeflateTransformation.cc 2014-01-27 08:45:49.000000000 +0000 +@@ -97,20 +97,20 @@ + vector<unsigned char> buffer(buffer_size); + + do { +- LOG_DEBUG("Iteration %d: Deflate will compress %ld bytes", ++iteration, data.size()); ++ LOG_DEBUG("Iteration %d: Deflate will compress %zu bytes", ++iteration, data.size()); + state_->z_stream_.avail_out = buffer_size; + state_->z_stream_.next_out = &buffer[0]; + + int err = deflate(&state_->z_stream_, Z_SYNC_FLUSH); + if (Z_OK != err) { +- LOG_ERROR("Iteration %d: Deflate failed to compress %ld bytes with error code '%d'", iteration, data.size(), err); ++ LOG_ERROR("Iteration %d: Deflate failed to compress %zu bytes with error code '%d'", iteration, data.size(), err); + return; + } + + int bytes_to_write = buffer_size - state_->z_stream_.avail_out; + state_->bytes_produced_ += bytes_to_write; + +- LOG_DEBUG("Iteration %d: Deflate compressed %ld bytes to %d bytes, producing output...", iteration, data.size(), bytes_to_write); ++ LOG_DEBUG("Iteration %d: Deflate compressed %zu bytes to %d bytes, producing output...", iteration, data.size(), bytes_to_write); + produce(string(reinterpret_cast<char *>(&buffer[0]), static_cast<size_t>(bytes_to_write))); + } while (state_->z_stream_.avail_out == 0); + +@@ -148,7 +148,7 @@ + + int64_t bytes_written = setOutputComplete(); + if (state_->bytes_produced_ != bytes_written) { +- LOG_ERROR("Gzip bytes produced sanity check failed, deflated bytes = %ld != written bytes = %ld", state_->bytes_produced_, bytes_written); ++ LOG_ERROR("Gzip bytes produced sanity check failed, deflated bytes = %lld != written bytes = %lld", state_->bytes_produced_, bytes_written); + } + } + diff --git a/www/trafficserver/files/patch-lib__atscppapi__src__GzipInflateTransformation.cc b/www/trafficserver/files/patch-lib__atscppapi__src__GzipInflateTransformation.cc new file mode 100644 index 000000000000..e53f40f606d1 --- /dev/null +++ b/www/trafficserver/files/patch-lib__atscppapi__src__GzipInflateTransformation.cc @@ -0,0 +1,11 @@ +--- ./lib/atscppapi/src/GzipInflateTransformation.cc.orig 2013-12-05 22:07:48.000000000 +0000 ++++ ./lib/atscppapi/src/GzipInflateTransformation.cc 2014-01-27 08:45:49.000000000 +0000 +@@ -122,7 +122,7 @@ + void GzipInflateTransformation::handleInputComplete() { + int64_t bytes_written = setOutputComplete(); + if (state_->bytes_produced_ != bytes_written) { +- LOG_ERROR("Gzip bytes produced sanity check failed, inflated bytes = %ld != written bytes = %ld", state_->bytes_produced_, bytes_written); ++ LOG_ERROR("Gzip bytes produced sanity check failed, inflated bytes = %lld != written bytes = %lld", state_->bytes_produced_, bytes_written); + } + } + diff --git a/www/trafficserver/files/patch-lib__atscppapi__src__Logger.cc b/www/trafficserver/files/patch-lib__atscppapi__src__Logger.cc new file mode 100644 index 000000000000..6e209f7a91c7 --- /dev/null +++ b/www/trafficserver/files/patch-lib__atscppapi__src__Logger.cc @@ -0,0 +1,11 @@ +--- ./lib/atscppapi/src/Logger.cc.orig 2013-12-05 22:07:48.000000000 +0000 ++++ ./lib/atscppapi/src/Logger.cc 2014-01-27 08:45:49.000000000 +0000 +@@ -189,7 +189,7 @@ + LOG_DEBUG("logging a " level " to '%s' with length %d", state_->filename_.c_str(), n); \ + TSTextLogObjectWrite(state_->text_log_obj_, const_cast<char*>("[" level "] %s"), buffer); \ + } else { \ +- LOG_ERROR("Unable to log " level " message to '%s' due to size exceeding %lud bytes.", state_->filename_.c_str(), sizeof(buffer)); \ ++ LOG_ERROR("Unable to log " level " message to '%s' due to size exceeding %zu bytes.", state_->filename_.c_str(), sizeof(buffer)); \ + } \ + return; \ + } diff --git a/www/trafficserver/files/patch-lib__atscppapi__src__TransformationPlugin.cc b/www/trafficserver/files/patch-lib__atscppapi__src__TransformationPlugin.cc new file mode 100644 index 000000000000..eab3b11e28b3 --- /dev/null +++ b/www/trafficserver/files/patch-lib__atscppapi__src__TransformationPlugin.cc @@ -0,0 +1,66 @@ +--- ./lib/atscppapi/src/TransformationPlugin.cc.orig 2013-12-05 22:07:48.000000000 +0000 ++++ ./lib/atscppapi/src/TransformationPlugin.cc 2014-01-27 08:45:49.000000000 +0000 +@@ -91,7 +91,7 @@ + TSVIO write_vio = TSVConnWriteVIOGet(contp); + if (write_vio) { + int64_t to_read = TSVIONTodoGet(write_vio); +- LOG_DEBUG("Transformation contp=%p write_vio=%p, to_read=%ld", contp, write_vio, to_read); ++ LOG_DEBUG("Transformation contp=%p write_vio=%p, to_read=%lld", contp, write_vio, to_read); + + if (to_read > 0) { + /* +@@ -99,11 +99,11 @@ + * the amount of data actually in the read buffer. + **/ + int64_t avail = TSIOBufferReaderAvail(TSVIOReaderGet(write_vio)); +- LOG_DEBUG("Transformation contp=%p write_vio=%p, to_read=%ld, buffer reader avail=%ld", contp, write_vio, to_read, avail); ++ LOG_DEBUG("Transformation contp=%p write_vio=%p, to_read=%lld, buffer reader avail=%lld", contp, write_vio, to_read, avail); + + if (to_read > avail) { + to_read = avail; +- LOG_DEBUG("Transformation contp=%p write_vio=%p, to read > avail, fixing to_read to be equal to avail. to_read=%ld, buffer reader avail=%ld", contp, write_vio, to_read, avail); ++ LOG_DEBUG("Transformation contp=%p write_vio=%p, to read > avail, fixing to_read to be equal to avail. to_read=%lld, buffer reader avail=%lld", contp, write_vio, to_read, avail); + } + + if (to_read > 0) { +@@ -122,7 +122,7 @@ + TSVIONDoneSet(write_vio, TSVIONDoneGet(write_vio) + to_read); + + std::string in_data = utils::internal::consumeFromTSIOBufferReader(input_reader); +- LOG_DEBUG("Transformation contp=%p write_vio=%p consumed %ld bytes from bufferreader", contp, write_vio, in_data.length()); ++ LOG_DEBUG("Transformation contp=%p write_vio=%p consumed %zu bytes from bufferreader", contp, write_vio, in_data.length()); + + /* Clean up the buffer and reader */ + TSIOBufferReaderFree(input_reader); +@@ -232,7 +232,7 @@ + } + + size_t TransformationPlugin::produce(const std::string &data) { +- LOG_DEBUG("TransformationPlugin=%p tshttptxn=%p producing output with length=%ld", this, state_->txn_, data.length()); ++ LOG_DEBUG("TransformationPlugin=%p tshttptxn=%p producing output with length=%zu", this, state_->txn_, data.length()); + int64_t write_length = static_cast<int64_t>(data.length()); + if (!write_length) { + return 0; +@@ -261,11 +261,11 @@ + // Finally we can copy this data into the output_buffer + int64_t bytes_written = TSIOBufferWrite(state_->output_buffer_, data.c_str(), write_length); + state_->bytes_written_ += bytes_written; // So we can set BytesDone on outputComplete(). +- LOG_DEBUG("TransformationPlugin=%p tshttptxn=%p write to TSIOBuffer %ld bytes total bytes written %ld", this, state_->txn_, bytes_written, state_->bytes_written_); ++ LOG_DEBUG("TransformationPlugin=%p tshttptxn=%p write to TSIOBuffer %lld bytes total bytes written %lld", this, state_->txn_, bytes_written, state_->bytes_written_); + + // Sanity Checks + if (bytes_written != write_length) { +- LOG_ERROR("TransformationPlugin=%p tshttptxn=%p bytes written < expected. bytes_written=%ld write_length=%ld", this, state_->txn_, bytes_written, write_length); ++ LOG_ERROR("TransformationPlugin=%p tshttptxn=%p bytes written < expected. bytes_written=%lld write_length=%lld", this, state_->txn_, bytes_written, write_length); + } + + int connection_closed = TSVConnClosedGet(state_->vconn_); +@@ -282,7 +282,7 @@ + + size_t TransformationPlugin::setOutputComplete() { + int connection_closed = TSVConnClosedGet(state_->vconn_); +- LOG_DEBUG("OutputComplete TransformationPlugin=%p tshttptxn=%p vconn=%p connection_closed=%d, total bytes written=%ld", this, state_->txn_, state_->vconn_, connection_closed,state_->bytes_written_); ++ LOG_DEBUG("OutputComplete TransformationPlugin=%p tshttptxn=%p vconn=%p connection_closed=%d, total bytes written=%lld", this, state_->txn_, state_->vconn_, connection_closed,state_->bytes_written_); + + if (!connection_closed && !state_->output_vio_) { + LOG_DEBUG("TransformationPlugin=%p tshttptxn=%p output complete without writing any data, initiating write of 0 bytes.", this, state_->txn_); diff --git a/www/trafficserver/files/patch-lib__atscppapi__src__include__atscppapi__shared_ptr.h b/www/trafficserver/files/patch-lib__atscppapi__src__include__atscppapi__shared_ptr.h new file mode 100644 index 000000000000..8ee3d488cff8 --- /dev/null +++ b/www/trafficserver/files/patch-lib__atscppapi__src__include__atscppapi__shared_ptr.h @@ -0,0 +1,30 @@ +--- ./lib/atscppapi/src/include/atscppapi/shared_ptr.h.orig 2013-12-05 22:07:48.000000000 +0000 ++++ ./lib/atscppapi/src/include/atscppapi/shared_ptr.h 2014-01-27 08:45:49.000000000 +0000 +@@ -25,7 +25,14 @@ + #ifndef ASTCPPAPI_SHARED_PTR_H_ + #define ASTCPPAPI_SHARED_PTR_H_ + ++#include <boost/config.hpp> ++#include <boost/tr1/detail/config.hpp> ++ ++#ifndef BOOST_NO_CXX11_SMART_PTR ++#include <memory> ++#else + #include <tr1/memory> ++#endif + + namespace atscppapi { + +@@ -34,8 +41,11 @@ + * \todo Consider adding a simple macro to check if c++0x/11 is enabled + * and if so change it to std::shared_ptr and #include <memory>s + */ ++#ifndef BOOST_NO_CXX11_SMART_PTR ++using std::shared_ptr; ++#else + using std::tr1::shared_ptr; +- ++#endif + } /* atscppapi */ + + #endif /* SHARED_PTR_H_ */ diff --git a/www/trafficserver/files/patch-lib__atscppapi__src__include__atscppapi__utils.h b/www/trafficserver/files/patch-lib__atscppapi__src__include__atscppapi__utils.h new file mode 100644 index 000000000000..d7b9131d1e38 --- /dev/null +++ b/www/trafficserver/files/patch-lib__atscppapi__src__include__atscppapi__utils.h @@ -0,0 +1,10 @@ +--- ./lib/atscppapi/src/include/atscppapi/utils.h.orig 2013-12-05 22:07:48.000000000 +0000 ++++ ./lib/atscppapi/src/include/atscppapi/utils.h 2014-01-27 08:45:49.000000000 +0000 +@@ -27,6 +27,7 @@ + #define ATSCPPAPI_UTILS_H_ + + #include <string> ++#include <netinet/in.h> + #include <arpa/inet.h> + #include <stdint.h> + diff --git a/www/trafficserver/files/patch-lib_ts_Makefile.am b/www/trafficserver/files/patch-lib_ts_Makefile.am deleted file mode 100644 index e8eb43680016..000000000000 --- a/www/trafficserver/files/patch-lib_ts_Makefile.am +++ /dev/null @@ -1,11 +0,0 @@ ---- lib/ts/Makefile.am.orig 2012-12-17 11:28:39.000000000 +0800 -+++ lib/ts/Makefile.am 2012-12-17 11:29:12.000000000 +0800 -@@ -153,7 +153,7 @@ - Version.cc - - # Special hacks to generate the parser rules --$(srcdir)/ParseRules.cc: ParseRulesCType -+ParseRules.cc: ParseRulesCType - - ParseRulesCType: CompileParseRules - ./CompileParseRules diff --git a/www/trafficserver/files/patch-mgmt__Makefile.am b/www/trafficserver/files/patch-mgmt__Makefile.am new file mode 100644 index 000000000000..089dbd75abb8 --- /dev/null +++ b/www/trafficserver/files/patch-mgmt__Makefile.am @@ -0,0 +1,10 @@ +--- ./mgmt/Makefile.am.orig 2013-12-05 22:07:48.000000000 +0000 ++++ ./mgmt/Makefile.am 2014-01-27 08:45:49.000000000 +0000 +@@ -16,6 +16,7 @@ + # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + # See the License for the specific language governing permissions and + # limitations under the License. ++AUTOMAKE_OPTIONS= subdir-objects + + SUBDIRS = cluster preparse utils web2 stats api cli + diff --git a/www/trafficserver/files/patch-mgmt__api__remote__Makefile.am b/www/trafficserver/files/patch-mgmt__api__remote__Makefile.am new file mode 100644 index 000000000000..0d254e446f67 --- /dev/null +++ b/www/trafficserver/files/patch-mgmt__api__remote__Makefile.am @@ -0,0 +1,10 @@ +--- ./mgmt/api/remote/Makefile.am.orig 2013-12-05 22:07:48.000000000 +0000 ++++ ./mgmt/api/remote/Makefile.am 2014-01-27 08:45:49.000000000 +0000 +@@ -13,6 +13,7 @@ + # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + # See the License for the specific language governing permissions and + # limitations under the License. ++AUTOMAKE_OPTIONS= subdir-objects + + AM_CPPFLAGS = \ + $(iocore_include_dirs) \ diff --git a/www/trafficserver/files/patch-mgmt__cli__cliMain.cc b/www/trafficserver/files/patch-mgmt__cli__cliMain.cc new file mode 100644 index 000000000000..3872d89e1d4c --- /dev/null +++ b/www/trafficserver/files/patch-mgmt__cli__cliMain.cc @@ -0,0 +1,10 @@ +--- ./mgmt/cli/cliMain.cc.orig 2013-12-05 22:07:48.000000000 +0000 ++++ ./mgmt/cli/cliMain.cc 2014-01-27 08:45:49.000000000 +0000 +@@ -87,6 +87,7 @@ + register_event_callback(); + + #if HAVE_LIBREADLINE ++ Tcl_FindExecutable(NULL); + Tcl_SetMainLoop(Tcl_ReadlineMain); + #endif + diff --git a/www/trafficserver/files/patch-mgmt_utils_Makefile.am b/www/trafficserver/files/patch-mgmt_utils_Makefile.am deleted file mode 100644 index 6f7770dc64fc..000000000000 --- a/www/trafficserver/files/patch-mgmt_utils_Makefile.am +++ /dev/null @@ -1,13 +0,0 @@ ---- mgmt/utils/Makefile.am.orig 2013-08-30 06:02:17.979883250 +0800 -+++ mgmt/utils/Makefile.am 2013-08-30 06:02:36.918052210 +0800 -@@ -40,8 +40,8 @@ - - libutils_lm_a_CPPFLAGS = $(ink_with_modules_local) $(AM_CPPFLAGS) - libutils_lm_a_SOURCES = \ -- $(top_srcdir)/lib/ts/MatcherUtils.cc \ -- $(top_srcdir)/proxy/DiagsConfig.cc \ -+ ../../lib/ts/MatcherUtils.cc \ -+ ../../proxy/DiagsConfig.cc \ - EnvBlock.cc \ - EnvBlock.h \ - ExpandingArray.cc \ diff --git a/www/trafficserver/files/patch-plugins__experimental__esi__Makefile.am b/www/trafficserver/files/patch-plugins__experimental__esi__Makefile.am new file mode 100644 index 000000000000..9e71c25fbd81 --- /dev/null +++ b/www/trafficserver/files/patch-plugins__experimental__esi__Makefile.am @@ -0,0 +1,10 @@ +--- ./plugins/experimental/esi/Makefile.am.orig 2013-12-05 22:07:48.000000000 +0000 ++++ ./plugins/experimental/esi/Makefile.am 2014-01-27 08:45:49.000000000 +0000 +@@ -13,6 +13,7 @@ + # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + # See the License for the specific language governing permissions and + # limitations under the License. ++AUTOMAKE_OPTIONS= subdir-objects + + include $(top_srcdir)/build/plugins.mk + diff --git a/www/trafficserver/files/patch-plugins__experimental__spdy__Makefile.am b/www/trafficserver/files/patch-plugins__experimental__spdy__Makefile.am new file mode 100644 index 000000000000..a9c5ec271cc3 --- /dev/null +++ b/www/trafficserver/files/patch-plugins__experimental__spdy__Makefile.am @@ -0,0 +1,10 @@ +--- ./plugins/experimental/spdy/Makefile.am.orig 2013-12-05 22:07:48.000000000 +0000 ++++ ./plugins/experimental/spdy/Makefile.am 2014-01-27 08:45:49.000000000 +0000 +@@ -13,6 +13,7 @@ + # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + # See the License for the specific language governing permissions and + # limitations under the License. ++AUTOMAKE_OPTIONS= subdir-objects + + include $(top_srcdir)/build/plugins.mk + diff --git a/www/trafficserver/files/patch-proxy__Makefile.am b/www/trafficserver/files/patch-proxy__Makefile.am new file mode 100644 index 000000000000..4d2408dfe131 --- /dev/null +++ b/www/trafficserver/files/patch-proxy__Makefile.am @@ -0,0 +1,20 @@ +--- ./proxy/Makefile.am.orig 2013-12-05 22:07:48.000000000 +0000 ++++ ./proxy/Makefile.am 2014-01-27 08:45:49.000000000 +0000 +@@ -291,7 +291,7 @@ + versiondir = $(pkgsysconfdir) + + install-data-local: +- if [ `id -un` != "root" ]; then \ ++ if true ; then \ + $(INSTALL) -d $(DESTDIR)$(pkglocalstatedir) $(DESTDIR)$(pkglogdir) $(DESTDIR)$(pkgruntimedir) \ + $(DESTDIR)$(pkgsysconfdir) $(DESTDIR)$(pkgdatadir) $(DESTDIR)$(pkgcachedir); \ + else \ +@@ -302,7 +302,7 @@ + fi + + install-data-hook: +- if [ `id -un` == "root" ]; then \ ++ if false; then \ + chown -R $(pkgsysuser):$(pkgsysgroup) $(DESTDIR)$(pkgsysconfdir) $(DESTDIR)$(pkgdatadir);\ + fi + -echo "<TS_VERSION> $(PACKAGE_VERSION)" > $(DESTDIR)$(pkgsysconfdir)/trafficserver-release diff --git a/www/trafficserver/files/patch-tools__Makefile.am b/www/trafficserver/files/patch-tools__Makefile.am new file mode 100644 index 000000000000..73605ac26fd4 --- /dev/null +++ b/www/trafficserver/files/patch-tools__Makefile.am @@ -0,0 +1,10 @@ +--- ./tools/Makefile.am.orig 2013-12-05 22:07:48.000000000 +0000 ++++ ./tools/Makefile.am 2014-01-27 08:45:49.000000000 +0000 +@@ -16,6 +16,7 @@ + # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + # See the License for the specific language governing permissions and + # limitations under the License. ++AUTOMAKE_OPTIONS= subdir-objects + + bin_SCRIPTS = tsxs tspush + bin_PROGRAMS = diff --git a/www/trafficserver/pkg-plist b/www/trafficserver/pkg-plist index 1f4640d568f5..25be3a869311 100644 --- a/www/trafficserver/pkg-plist +++ b/www/trafficserver/pkg-plist @@ -1,26 +1,26 @@ -@unexec if cmp %D/%%ETCDIR%%/ae_ua.config %D/%%ETCDIR%%/ae_ua.config.default; then rm %D/%%ETCDIR%%/ae_ua.config; fi -@unexec if cmp %D/%%ETCDIR%%/cache.config %D/%%ETCDIR%%/cache.config.default; then rm %D/%%ETCDIR%%/cache.config; fi -@unexec if cmp %D/%%ETCDIR%%/cluster.config %D/%%ETCDIR%%/cluster.config.default; then rm %D/%%ETCDIR%%/cluster.config; fi -@unexec if cmp %D/%%ETCDIR%%/congestion.config %D/%%ETCDIR%%/congestion.config.default; then rm %D/%%ETCDIR%%/congestion.config; fi -@unexec if cmp %D/%%ETCDIR%%/hosting.config %D/%%ETCDIR%%/hosting.config.default; then rm %D/%%ETCDIR%%/hosting.config; fi -@unexec if cmp %D/%%ETCDIR%%/icp.config %D/%%ETCDIR%%/icp.config.default; then rm %D/%%ETCDIR%%/icp.config; fi -@unexec if cmp %D/%%ETCDIR%%/ip_allow.config %D/%%ETCDIR%%/ip_allow.config.default; then rm %D/%%ETCDIR%%/ip_allow.config; fi -@unexec if cmp %D/%%ETCDIR%%/log_hosts.config %D/%%ETCDIR%%/log_hosts.config.default; then rm %D/%%ETCDIR%%/log_hosts.config; fi -@unexec if cmp %D/%%ETCDIR%%/logs_xml.config %D/%%ETCDIR%%/logs_xml.config.default; then rm %D/%%ETCDIR%%/logs_xml.config; fi -@unexec if cmp %D/%%ETCDIR%%/mgr.cnf %D/%%ETCDIR%%/mgr.cnf.default; then rm %D/%%ETCDIR%%/mgr.cnf; fi -@unexec if cmp %D/%%ETCDIR%%/parent.config %D/%%ETCDIR%%/parent.config.default; then rm %D/%%ETCDIR%%/parent.config; fi -@unexec if cmp %D/%%ETCDIR%%/volume.config %D/%%ETCDIR%%/volume.config.default; then rm %D/%%ETCDIR%%/volume.config; fi -@unexec if cmp %D/%%ETCDIR%%/plugin.config %D/%%ETCDIR%%/plugin.config.default; then rm %D/%%ETCDIR%%/plugin.config; fi -@unexec if cmp %D/%%ETCDIR%%/plugin.db %D/%%ETCDIR%%/plugin.db.default; then rm %D/%%ETCDIR%%/plugin.db; fi -@unexec if cmp %D/%%ETCDIR%%/remap.config %D/%%ETCDIR%%/remap.config.default; then rm %D/%%ETCDIR%%/remap.config; fi -@unexec if cmp %D/%%ETCDIR%%/records.config %D/%%ETCDIR%%/records.config.default; then rm %D/%%ETCDIR%%/records.config; fi -@unexec if cmp %D/%%ETCDIR%%/socks.config %D/%%ETCDIR%%/socks.config.default; then rm %D/%%ETCDIR%%/socks.config; fi -@unexec if cmp %D/%%ETCDIR%%/splitdns.config %D/%%ETCDIR%%/splitdns.config.default; then rm %D/%%ETCDIR%%/splitdns.config; fi -@unexec if cmp %D/%%ETCDIR%%/ssl_multicert.config %D/%%ETCDIR%%/ssl_multicert.config.default; then rm %D/%%ETCDIR%%/ssl_multicert.config; fi -@unexec if cmp %D/%%ETCDIR%%/stats.config.xml %D/%%ETCDIR%%/stats.config.xml.default; then rm %D/%%ETCDIR%%/stats.config.xml; fi -@unexec if cmp %D/%%ETCDIR%%/storage.config %D/%%ETCDIR%%/storage.config.default; then rm %D/%%ETCDIR%%/storage.config; fi -@unexec if cmp %D/%%ETCDIR%%/update.config %D/%%ETCDIR%%/update.config.default; then rm %D/%%ETCDIR%%/update.config; fi -@unexec if cmp %D/%%ETCDIR%%/vaddrs.config %D/%%ETCDIR%%/vaddrs.config.default; then rm %D/%%ETCDIR%%/vaddrs.config; fi +@comment $FreeBSD: www/trafficserver/pkg-plist 331378 2013-10-23 12:12:40Z decke $ +@unexec if cmp -s %D/%%ETCDIR%%/cache.config %D/%%ETCDIR%%/cache.config.default; then rm %D/%%ETCDIR%%/cache.config; fi +@unexec if cmp -s %D/%%ETCDIR%%/cluster.config %D/%%ETCDIR%%/cluster.config.default; then rm %D/%%ETCDIR%%/cluster.config; fi +@unexec if cmp -s %D/%%ETCDIR%%/congestion.config %D/%%ETCDIR%%/congestion.config.default; then rm %D/%%ETCDIR%%/congestion.config; fi +@unexec if cmp -s %D/%%ETCDIR%%/hosting.config %D/%%ETCDIR%%/hosting.config.default; then rm %D/%%ETCDIR%%/hosting.config; fi +@unexec if cmp -s %D/%%ETCDIR%%/icp.config %D/%%ETCDIR%%/icp.config.default; then rm %D/%%ETCDIR%%/icp.config; fi +@unexec if cmp -s %D/%%ETCDIR%%/ip_allow.config %D/%%ETCDIR%%/ip_allow.config.default; then rm %D/%%ETCDIR%%/ip_allow.config; fi +@unexec if cmp -s %D/%%ETCDIR%%/log_hosts.config %D/%%ETCDIR%%/log_hosts.config.default; then rm %D/%%ETCDIR%%/log_hosts.config; fi +@unexec if cmp -s %D/%%ETCDIR%%/logs_xml.config %D/%%ETCDIR%%/logs_xml.config.default; then rm %D/%%ETCDIR%%/logs_xml.config; fi +@unexec if cmp -s %D/%%ETCDIR%%/parent.config %D/%%ETCDIR%%/parent.config.default; then rm %D/%%ETCDIR%%/parent.config; fi +@unexec if cmp -s %D/%%ETCDIR%%/plugin.config %D/%%ETCDIR%%/plugin.config.default; then rm %D/%%ETCDIR%%/plugin.config; fi +@unexec if cmp -s %D/%%ETCDIR%%/prefetch.config %D/%%ETCDIR%%/prefetch.config.default; then rm %D/%%ETCDIR%%/prefetch.config; fi +@unexec if cmp -s %D/%%ETCDIR%%/records.config %D/%%ETCDIR%%/records.config.default; then rm %D/%%ETCDIR%%/records.config; fi +@unexec if cmp -s %D/%%ETCDIR%%/remap.config %D/%%ETCDIR%%/remap.config.default; then rm %D/%%ETCDIR%%/remap.config; fi +@unexec if cmp -s %D/%%ETCDIR%%/socks.config %D/%%ETCDIR%%/socks.config.default; then rm %D/%%ETCDIR%%/socks.config; fi +@unexec if cmp -s %D/%%ETCDIR%%/splitdns.config %D/%%ETCDIR%%/splitdns.config.default; then rm %D/%%ETCDIR%%/splitdns.config; fi +@unexec if cmp -s %D/%%ETCDIR%%/ssl_multicert.config %D/%%ETCDIR%%/ssl_multicert.config.default; then rm %D/%%ETCDIR%%/ssl_multicert.config; fi +@unexec if cmp -s %D/%%ETCDIR%%/stats.config.xml %D/%%ETCDIR%%/stats.config.xml.default; then rm %D/%%ETCDIR%%/stats.config.xml; fi +@unexec if cmp -s %D/%%ETCDIR%%/storage.config %D/%%ETCDIR%%/storage.config.default; then rm %D/%%ETCDIR%%/storage.config; fi +@unexec if cmp -s %D/%%ETCDIR%%/update.config %D/%%ETCDIR%%/update.config.default; then rm %D/%%ETCDIR%%/update.config; fi +@unexec if cmp -s %D/%%ETCDIR%%/vaddrs.config %D/%%ETCDIR%%/vaddrs.config.default; then rm %D/%%ETCDIR%%/vaddrs.config; fi +@unexec if cmp -s %D/%%ETCDIR%%/volume.config %D/%%ETCDIR%%/volume.config.default; then rm %D/%%ETCDIR%%/volume.config; fi +@unexec if [ ! -s %D/%%ETCDIR%%/proxy.pac ]; then rm -f %D/%%ETCDIR%%/proxy.pac; fi bin/traffic_cop bin/traffic_line bin/traffic_logcat @@ -30,29 +30,71 @@ bin/traffic_sac bin/traffic_server bin/traffic_shell bin/trafficserver +bin/tspush +bin/tstop bin/tsxs include/ts/experimental.h include/ts/mgmtapi.h include/ts/remap.h include/ts/ts.h -lib/libtsmgmt.a +include/atscppapi/Async.h +include/atscppapi/AsyncHttpFetch.h +include/atscppapi/AsyncTimer.h +include/atscppapi/CaseInsensitiveStringComparator.h +include/atscppapi/ClientRequest.h +include/atscppapi/GlobalPlugin.h +include/atscppapi/GzipDeflateTransformation.h +include/atscppapi/GzipInflateTransformation.h +include/atscppapi/Headers.h +include/atscppapi/HttpMethod.h +include/atscppapi/HttpStatus.h +include/atscppapi/HttpVersion.h +include/atscppapi/Logger.h +include/atscppapi/Mutex.h +include/atscppapi/Plugin.h +include/atscppapi/PluginInit.h +include/atscppapi/RemapPlugin.h +include/atscppapi/Request.h +include/atscppapi/Response.h +include/atscppapi/Stat.h +include/atscppapi/Transaction.h +include/atscppapi/TransactionPlugin.h +include/atscppapi/Url.h +include/atscppapi/noncopyable.h +include/atscppapi/shared_ptr.h +include/atscppapi/utils.h +lib/libatscppapi.la +lib/libatscppapi.so +lib/libatscppapi.so.5 lib/libtsmgmt.la lib/libtsmgmt.so lib/libtsmgmt.so.5 -lib/libtsutil.a lib/libtsutil.la lib/libtsutil.so lib/libtsutil.so.5 +libexec/trafficserver/cacheurl.la +libexec/trafficserver/cacheurl.so libexec/trafficserver/conf_remap.la libexec/trafficserver/conf_remap.so +libexec/trafficserver/gzip.la +libexec/trafficserver/gzip.so libexec/trafficserver/header_filter.la libexec/trafficserver/header_filter.so +libexec/trafficserver/libloader.la +libexec/trafficserver/libloader.so libexec/trafficserver/regex_remap.la libexec/trafficserver/regex_remap.so libexec/trafficserver/stats_over_http.la libexec/trafficserver/stats_over_http.so +%%SITE_PERL%%/Apache/TS.pm +%%SITE_PERL%%/Apache/TS/AdminClient.pm +%%SITE_PERL%%/Apache/TS/Config.pm +%%SITE_PERL%%/Apache/TS/Config/Records.pm +%%PERL5_MAN3%%/Apache::TS.3.gz +%%PERL5_MAN3%%/Apache::TS::AdminClient.3.gz +%%PERL5_MAN3%%/Apache::TS::Config::Records.3.gz man/man1/traffic_shell.1.gz -%%ETCDIR%%/ae_ua.config.default +@owner www %%ETCDIR%%/body_factory/default/.body_factory_info %%ETCDIR%%/body_factory/default/README %%ETCDIR%%/body_factory/default/access#denied @@ -87,10 +129,9 @@ man/man1/traffic_shell.1.gz %%ETCDIR%%/ip_allow.config.default %%ETCDIR%%/log_hosts.config.default %%ETCDIR%%/logs_xml.config.default -%%ETCDIR%%/mgr.cnf.default %%ETCDIR%%/parent.config.default %%ETCDIR%%/plugin.config.default -%%ETCDIR%%/plugin.db.default +%%ETCDIR%%/prefetch.config.default %%ETCDIR%%/records.config.default %%ETCDIR%%/remap.config.default %%ETCDIR%%/socks.config.default @@ -98,10 +139,13 @@ man/man1/traffic_shell.1.gz %%ETCDIR%%/ssl_multicert.config.default %%ETCDIR%%/stats.config.xml.default %%ETCDIR%%/storage.config.default -%%ETCDIR%%/trafficserver-release %%ETCDIR%%/update.config.default %%ETCDIR%%/vaddrs.config.default %%ETCDIR%%/volume.config.default +@exec mkdir -p %D/%%ETCDIR%%/snapshots +@exec chown -f www %D/%%ETCDIR%%/snapshots +@owner root +%%ETCDIR%%/trafficserver-release share/doc/trafficserver/trafficshell/config_alarms.1 share/doc/trafficserver/trafficshell/config_cache.1 share/doc/trafficserver/trafficshell/config_clock.1 @@ -160,16 +204,29 @@ share/doc/trafficserver/trafficshell/show_ssl.1 share/doc/trafficserver/trafficshell/show_status.1 share/doc/trafficserver/trafficshell/show_version.1 share/doc/trafficserver/trafficshell/show_virtual-ip.1 +@dirrm %%SITE_PERL%%/Apache/TS/Config +@dirrm %%SITE_PERL%%/Apache/TS +@dirrm %%SITE_PERL%%/Apache @dirrm share/trafficserver @dirrm share/doc/trafficserver/trafficshell @dirrm share/doc/trafficserver @dirrm libexec/trafficserver @dirrm include/ts -@dirrm %%ETCDIR%%/internal +@dirrm include/atscppapi @dirrm %%ETCDIR%%/body_factory/default -@dirrm %%ETCDIR%%/body_factory +@dirrmtry %%ETCDIR%%/body_factory +@dirrmtry %%ETCDIR%%/snapshots @dirrmtry %%ETCDIR%% -@exec if [ ! -f %D/%%ETCDIR%%/ae_ua.config ]; then cp -p %D/%%ETCDIR%%/ae_ua.config.default %D/%%ETCDIR%%/ae_ua.config; fi +@unexec rmdir "%%LOGDIR%%" 2>/dev/null || true +@exec mkdir -p "%%LOGDIR%%" +@exec chown -f www "%%LOGDIR%%" +@exec chmod 700 "%%LOGDIR%%" +@unexec rmdir "%%VARDIR%%" 2>/dev/null || true +@exec mkdir -p "%%VARDIR%%" +@exec chown -f www "%%VARDIR%%" +@exec chmod 700 "%%VARDIR%%" +@exec chown -f www %D/%%ETCDIR%% +@exec chmod 700 %D/%%ETCDIR%% @exec if [ ! -f %D/%%ETCDIR%%/cache.config ]; then cp -p %D/%%ETCDIR%%/cache.config.default %D/%%ETCDIR%%/cache.config; fi @exec if [ ! -f %D/%%ETCDIR%%/cluster.config ]; then cp -p %D/%%ETCDIR%%/cluster.config.default %D/%%ETCDIR%%/cluster.config; fi @exec if [ ! -f %D/%%ETCDIR%%/congestion.config ]; then cp -p %D/%%ETCDIR%%/congestion.config.default %D/%%ETCDIR%%/congestion.config; fi @@ -178,11 +235,9 @@ share/doc/trafficserver/trafficshell/show_virtual-ip.1 @exec if [ ! -f %D/%%ETCDIR%%/ip_allow.config ]; then cp -p %D/%%ETCDIR%%/ip_allow.config.default %D/%%ETCDIR%%/ip_allow.config; fi @exec if [ ! -f %D/%%ETCDIR%%/log_hosts.config ]; then cp -p %D/%%ETCDIR%%/log_hosts.config.default %D/%%ETCDIR%%/log_hosts.config; fi @exec if [ ! -f %D/%%ETCDIR%%/logs_xml.config ]; then cp -p %D/%%ETCDIR%%/logs_xml.config.default %D/%%ETCDIR%%/logs_xml.config; fi -@exec if [ ! -f %D/%%ETCDIR%%/mgr.cnf ]; then cp -p %D/%%ETCDIR%%/mgr.cnf.default %D/%%ETCDIR%%/mgr.cnf; fi @exec if [ ! -f %D/%%ETCDIR%%/parent.config ]; then cp -p %D/%%ETCDIR%%/parent.config.default %D/%%ETCDIR%%/parent.config; fi -@exec if [ ! -f %D/%%ETCDIR%%/volume.config ]; then cp -p %D/%%ETCDIR%%/volume.config.default %D/%%ETCDIR%%/volume.config; fi @exec if [ ! -f %D/%%ETCDIR%%/plugin.config ]; then cp -p %D/%%ETCDIR%%/plugin.config.default %D/%%ETCDIR%%/plugin.config; fi -@exec if [ ! -f %D/%%ETCDIR%%/plugin.db ]; then cp -p %D/%%ETCDIR%%/plugin.db.default %D/%%ETCDIR%%/plugin.db; fi +@exec if [ ! -f %D/%%ETCDIR%%/prefetch.config ]; then cp -p %D/%%ETCDIR%%/prefetch.config.default %D/%%ETCDIR%%/prefetch.config; fi @exec if [ ! -f %D/%%ETCDIR%%/records.config ]; then cp -p %D/%%ETCDIR%%/records.config.default %D/%%ETCDIR%%/records.config; fi @exec if [ ! -f %D/%%ETCDIR%%/remap.config ]; then cp -p %D/%%ETCDIR%%/remap.config.default %D/%%ETCDIR%%/remap.config; fi @exec if [ ! -f %D/%%ETCDIR%%/socks.config ]; then cp -p %D/%%ETCDIR%%/socks.config.default %D/%%ETCDIR%%/socks.config; fi @@ -192,3 +247,5 @@ share/doc/trafficserver/trafficshell/show_virtual-ip.1 @exec if [ ! -f %D/%%ETCDIR%%/storage.config ]; then cp -p %D/%%ETCDIR%%/storage.config.default %D/%%ETCDIR%%/storage.config; fi @exec if [ ! -f %D/%%ETCDIR%%/update.config ]; then cp -p %D/%%ETCDIR%%/update.config.default %D/%%ETCDIR%%/update.config; fi @exec if [ ! -f %D/%%ETCDIR%%/vaddrs.config ]; then cp -p %D/%%ETCDIR%%/vaddrs.config.default %D/%%ETCDIR%%/vaddrs.config; fi +@exec if [ ! -f %D/%%ETCDIR%%/volume.config ]; then cp -p %D/%%ETCDIR%%/volume.config.default %D/%%ETCDIR%%/volume.config; fi +@exec chmod -f 600 %D/%%ETCDIR%%/*.config |