diff --git a/.gitignore b/.gitignore index c487305e3da..5753a0aab04 100644 --- a/.gitignore +++ b/.gitignore @@ -68,30 +68,29 @@ src/traffic_wccp/traffic_wccp lib/stamp-h1 lib/ink_autoconf.h lib/ink_autoconf.h.in -lib/ts/stamp-h1 -lib/ts/ink_autoconf.h -lib/ts/ink_autoconf.h.in -lib/ts/ink_config.h -lib/ts/apidefs.h -lib/ts/CompileParseRules -lib/ts/ParseRulesCType -lib/ts/ParseRulesCTypeToLower -lib/ts/ParseRulesCTypeToUpper -lib/ts/mkdfa -lib/ts/test_List -lib/ts/test_arena -lib/ts/test_atomic -lib/ts/test_freelist -lib/ts/test_Map -lib/ts/test_Vec -lib/ts/test_geometry -lib/ts/test_Regex -lib/ts/test_PriorityQueue -lib/ts/test_X509HostnameValidator -lib/ts/test_tsutil -lib/ts/test_MemView -lib/ts/test_Scalar -lib/ts/test_tslib +src/tscore/stamp-h1 +src/tscore/ink_autoconf.h +src/tscore/ink_autoconf.h.in +include/tscore/ink_config.h +include/ts/apidefs.h +src/tscore/CompileParseRules +src/tscore/ParseRulesCType +src/tscore/ParseRulesCTypeToLower +src/tscore/ParseRulesCTypeToUpper +src/tscore/mkdfa +src/tscore/test_List +src/tscore/test_arena +src/tscore/test_atomic +src/tscore/test_freelist +src/tscore/test_Map +src/tscore/test_Vec +src/tscore/test_geometry +src/tscore/test_Regex +src/tscore/test_PriorityQueue +src/tscore/test_X509HostnameValidator +src/tscore/test_tscore +src/tscpp/util/test_tscpputil +src/tscore/test_libtscore lib/perl/lib/Apache/TS.pm iocore/net/test_certlookup diff --git a/CMakeLists.txt b/CMakeLists.txt index 6dd571957a5..fe88519644e 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -40,7 +40,6 @@ include_directories(lib proxy/shared lib/records lib/wccp - lib/cppapi/include lib/yamlcpp/include iocore/eventsystem iocore/net @@ -202,7 +201,7 @@ add_executable(ats iocore/dns/SRV.h iocore/dns/test_I_DNS.cc iocore/dns/test_P_DNS.cc - iocore/eventsystem/unit-tests/test_MIOBufferWriter.cc + iocore/eventsystem/unit_tests/test_MIOBufferWriter.cc iocore/eventsystem/EventSystem.cc iocore/eventsystem/I_Action.h iocore/eventsystem/I_Continuation.h @@ -352,57 +351,6 @@ add_executable(ats iocore/utils/Machine.cc iocore/utils/OneWayMultiTunnel.cc iocore/utils/OneWayTunnel.cc - lib/cppapi/include/atscppapi/Async.h - lib/cppapi/include/atscppapi/AsyncHttpFetch.h - lib/cppapi/include/atscppapi/AsyncTimer.h - lib/cppapi/include/atscppapi/CaseInsensitiveStringComparator.h - lib/cppapi/include/atscppapi/ClientRequest.h - lib/cppapi/include/atscppapi/GlobalPlugin.h - lib/cppapi/include/atscppapi/GzipDeflateTransformation.h - lib/cppapi/include/atscppapi/GzipInflateTransformation.h - lib/cppapi/include/atscppapi/Headers.h - lib/cppapi/include/atscppapi/HttpMethod.h - lib/cppapi/include/atscppapi/HttpStatus.h - lib/cppapi/include/atscppapi/HttpVersion.h - lib/cppapi/include/atscppapi/InterceptPlugin.h - lib/cppapi/include/atscppapi/Logger.h - lib/cppapi/include/atscppapi/noncopyable.h - lib/cppapi/include/atscppapi/Plugin.h - lib/cppapi/include/atscppapi/PluginInit.h - lib/cppapi/include/atscppapi/RemapPlugin.h - lib/cppapi/include/atscppapi/Request.h - lib/cppapi/include/atscppapi/Response.h - lib/cppapi/include/atscppapi/Stat.h - lib/cppapi/include/atscppapi/Transaction.h - lib/cppapi/include/atscppapi/TransactionPlugin.h - lib/cppapi/include/atscppapi/TransformationPlugin.h - lib/cppapi/include/atscppapi/Url.h - lib/cppapi/include/atscppapi/utils.h - lib/cppapi/include/logging_internal.h - lib/cppapi/include/utils_internal.h - lib/cppapi/AsyncHttpFetch.cc - lib/cppapi/AsyncTimer.cc - lib/cppapi/CaseInsensitiveStringComparator.cc - lib/cppapi/ClientRequest.cc - lib/cppapi/GlobalPlugin.cc - lib/cppapi/GzipDeflateTransformation.cc - lib/cppapi/GzipInflateTransformation.cc - lib/cppapi/Headers.cc - lib/cppapi/HttpMethod.cc - lib/cppapi/HttpVersion.cc - lib/cppapi/InterceptPlugin.cc - lib/cppapi/Logger.cc - lib/cppapi/Plugin.cc - lib/cppapi/RemapPlugin.cc - lib/cppapi/Request.cc - lib/cppapi/Response.cc - lib/cppapi/Stat.cc - lib/cppapi/Transaction.cc - lib/cppapi/TransactionPlugin.cc - lib/cppapi/TransformationPlugin.cc - lib/cppapi/Url.cc - lib/cppapi/utils.cc - lib/cppapi/utils_internal.cc lib/records/I_RecAlarms.h lib/records/I_RecCore.h lib/records/I_RecDefs.h @@ -438,15 +386,15 @@ add_executable(ats lib/records/test_RecordsConfig.h lib/records/test_RecProcess.i lib/records/test_RecTree.cc - lib/wccp/wccp-test-router.cc - lib/wccp/Wccp.h - lib/wccp/WccpConfig.cc - lib/wccp/WccpEndPoint.cc - lib/wccp/WccpLocal.h - lib/wccp/WccpMeta.h - lib/wccp/WccpMsg.cc - lib/wccp/WccpStatic.cc - lib/wccp/WccpUtil.h + src/wccp/wccp-test-router.cc + include/wccp/Wccp.h + src/wccp/WccpConfig.cc + src/wccp/WccpEndPoint.cc + src/wccp/WccpLocal.h + src/wccp/WccpMeta.h + src/wccp/WccpMsg.cc + src/wccp/WccpStatic.cc + src/wccp/WccpUtil.h lib/ink_autoconf.h mgmt/api/include/mgmtapi.h mgmt/api/APITestCliRemote.cc @@ -640,9 +588,6 @@ add_executable(ats plugins/experimental/remap_purge/remap_purge.c plugins/experimental/remap_stats/remap_stats.c plugins/experimental/server_push_preload/server_push_preload.cc - plugins/experimental/ssl_cert_loader/domain-tree.cc - plugins/experimental/ssl_cert_loader/domain-tree.h - plugins/experimental/ssl_cert_loader/ssl-cert-loader.cc plugins/experimental/sslheaders/expand.cc plugins/experimental/sslheaders/sslheaders.cc plugins/experimental/sslheaders/sslheaders.h @@ -758,8 +703,8 @@ add_executable(ats plugins/lua/ts_lua_util.h plugins/regex_remap/regex_remap.cc plugins/regex_revalidate/regex_revalidate.c - plugins/s3_auth/unit-tests/test_aws_auth_v4.cc - plugins/s3_auth/unit-tests/test_aws_auth_v4.h + plugins/s3_auth/unit_tests/test_aws_auth_v4.cc + plugins/s3_auth/unit_tests/test_aws_auth_v4.h plugins/s3_auth/aws_auth_v4.cc plugins/s3_auth/aws_auth_v4.h plugins/s3_auth/aws_auth_v4_wrap.h @@ -767,11 +712,11 @@ add_executable(ats plugins/stats_over_http/stats_over_http.c plugins/tcpinfo/tcpinfo.cc plugins/xdebug/xdebug.cc - proxy/api/ts/experimental.h - proxy/api/ts/InkAPIPrivateIOCore.h - proxy/api/ts/remap.h - proxy/api/ts/ts.h - proxy/api/ts/TsException.h + include/ts/experimental.h + include/ts/InkAPIPrivateIOCore.h + include/ts/remap.h + include/ts/ts.h + include/ts/TsException.h proxy/hdrs/HdrHeap.cc proxy/hdrs/HdrHeap.h proxy/hdrs/HdrTest.cc @@ -808,8 +753,8 @@ add_executable(ats proxy/http/remap/UrlMappingPathIndex.h proxy/http/remap/UrlRewrite.cc proxy/http/remap/UrlRewrite.h - proxy/http/unit-tests/test_ForwardedConfig.cc - proxy/http/unit-tests/test_ForwardedConfig_mocks.cc + proxy/http/unit_tests/test_ForwardedConfig.cc + proxy/http/unit_tests/test_ForwardedConfig_mocks.cc proxy/http/ForwardedConfig.cc proxy/http/Http1ClientSession.cc proxy/http/Http1ClientSession.h @@ -968,205 +913,203 @@ add_executable(ats tools/http_load/timers.h tools/jtest/jtest.cc) -add_library(libtsutil SHARED - lib/ts/Allocator.h - lib/ts/apidefs.h - lib/ts/Arena.cc - lib/ts/Arena.h - lib/ts/BaseLogFile.cc - lib/ts/BaseLogFile.h - lib/ts/Bitops.cc - lib/ts/Bitops.h - lib/ts/bwf_std_format.h - lib/ts/BufferWriter.h - lib/ts/BufferWriterForward.h - lib/ts/BufferWriterFormat.cc - lib/ts/CompileParseRules.cc - lib/ts/ConsistentHash.cc - lib/ts/ConsistentHash.h - lib/ts/ContFlags.cc - lib/ts/ContFlags.h - lib/ts/CryptoHash.cc - lib/ts/CryptoHash.h - lib/ts/defalloc.h - lib/ts/Diags.cc - lib/ts/Diags.h - lib/ts/DynArray.h - lib/ts/EventNotify.cc - lib/ts/EventNotify.h - lib/ts/fastlz.c - lib/ts/fastlz.h - lib/ts/Hash.cc - lib/ts/Hash.h - lib/ts/HashFNV.cc - lib/ts/HashFNV.h - lib/ts/HashMD5.cc - lib/ts/HashMD5.h - lib/ts/HashSip.cc - lib/ts/HashSip.h - lib/ts/History.h - lib/ts/HostLookup.cc - lib/ts/HostLookup.h - lib/ts/hugepages.cc - lib/ts/hugepages.h - lib/ts/I_Layout.h - lib/ts/I_Version.h - lib/ts/ink_aiocb.h - lib/ts/ink_align.h - lib/ts/ink_apidefs.h - lib/ts/ink_args.cc - lib/ts/ink_args.h - lib/ts/ink_assert.cc - lib/ts/ink_assert.h - lib/ts/ink_atomic.h - lib/ts/ink_base64.cc - lib/ts/ink_base64.h - lib/ts/ink_cap.cc - lib/ts/ink_cap.h - lib/ts/ink_code.cc - lib/ts/ink_code.h - lib/ts/ink_config.h - lib/ts/ink_defs.cc - lib/ts/ink_defs.h - lib/ts/ink_error.cc - lib/ts/ink_error.h - lib/ts/ink_exception.h - lib/ts/ink_file.cc - lib/ts/ink_file.h - lib/ts/ink_hash_table.cc - lib/ts/ink_hash_table.h - lib/ts/ink_hrtime.cc - lib/ts/ink_hrtime.h - lib/ts/ink_inet.cc - lib/ts/ink_inet.h - lib/ts/ink_inout.h - lib/ts/ink_llqueue.h - lib/ts/ink_lockfile.h - lib/ts/INK_MD5.h - lib/ts/ink_memory.cc - lib/ts/ink_memory.h - lib/ts/ink_mutex.cc - lib/ts/ink_mutex.h - lib/ts/ink_platform.h - lib/ts/ink_queue.cc - lib/ts/ink_queue.h - lib/ts/ink_queue_utils.cc - lib/ts/ink_rand.cc - lib/ts/ink_rand.h - lib/ts/ink_res_init.cc - lib/ts/ink_res_mkquery.cc - lib/ts/ink_resolver.h - lib/ts/ink_resource.cc - lib/ts/ink_resource.h - lib/ts/ink_rwlock.cc - lib/ts/ink_rwlock.h - lib/ts/ink_sock.cc - lib/ts/ink_sock.h - lib/ts/ink_sprintf.cc - lib/ts/ink_sprintf.h - lib/ts/ink_stack_trace.cc - lib/ts/ink_stack_trace.h - lib/ts/ink_string++.cc - lib/ts/ink_string++.h - lib/ts/ink_string.cc - lib/ts/ink_string.h - lib/ts/ink_sys_control.cc - lib/ts/ink_sys_control.h - lib/ts/ink_syslog.cc - lib/ts/ink_syslog.h - lib/ts/ink_thread.cc - lib/ts/ink_thread.h - lib/ts/ink_time.cc - lib/ts/ink_time.h - lib/ts/ink_uuid.cc - lib/ts/ink_uuid.h - lib/ts/InkErrno.cc - lib/ts/InkErrno.h - lib/ts/IntrusiveDList.h - lib/ts/IntrusivePtrTest.cc - lib/ts/IpMap.cc - lib/ts/IpMap.h - lib/ts/IpMapConf.cc - lib/ts/IpMapConf.h - lib/ts/Layout.cc - lib/ts/List.h - lib/ts/llqueue.cc - lib/ts/load_http_hdr.cc - lib/ts/lockfile.cc - lib/ts/Map.h - lib/ts/MatcherUtils.cc - lib/ts/MatcherUtils.h - lib/ts/MemArena.h - lib/ts/MemArena.cc - lib/ts/MemSpan.h - lib/ts/mkdfa.c - lib/ts/MMH.cc - lib/ts/MMH.h - lib/ts/MT_hashtable.h - lib/ts/ParseRules.cc - lib/ts/ParseRules.h - lib/ts/PriorityQueue.h - lib/ts/Ptr.h - lib/ts/RawHashTable.cc - lib/ts/RawHashTable.h - lib/ts/RbTree.cc - lib/ts/RbTree.h - lib/ts/Regex.cc - lib/ts/Regex.h - lib/ts/Regression.cc - lib/ts/Regression.h - lib/ts/Result.h - lib/ts/runroot.cc - lib/ts/runroot.h - lib/ts/Scalar.h - lib/ts/SHA256.h - lib/ts/signals.cc - lib/ts/signals.h - lib/ts/SimpleTokenizer.h - lib/ts/SourceLocation.cc - lib/ts/SourceLocation.h - lib/ts/test_arena.cc - lib/ts/test_atomic.cc - lib/ts/test_freelist.cc - lib/ts/test_geometry.cc - lib/ts/test_History.cc - lib/ts/test_List.cc - lib/ts/test_Map.cc - lib/ts/test_PriorityQueue.cc - lib/ts/test_Ptr.cc - lib/ts/test_Regex.cc - lib/ts/test_Vec.cc - lib/ts/test_X509HostnameValidator.cc - lib/ts/TestBox.h - lib/ts/TestHttpHeader.cc - lib/ts/tests.cc - lib/ts/TextBuffer.cc - lib/ts/TextBuffer.h - lib/ts/TextView.cc - lib/ts/TextView.h - lib/ts/Tokenizer.cc - lib/ts/Tokenizer.h - lib/ts/Trie.h - lib/ts/TsBuffer.h - lib/ts/Version.cc - lib/ts/X509HostnameValidator.cc - lib/ts/X509HostnameValidator.h +add_library(libtscore SHARED + include/tscore/Allocator.h + include/tscore/apidefs.h + src/tscore/Arena.cc + include/tscore/Arena.h + src/tscore/BaseLogFile.cc + include/tscore/BaseLogFile.h + src/tscore/Bitops.cc + include/tscore/Bitops.h + include/tscore/bwf_std_format.h + include/tscore/BufferWriter.h + include/tscore/BufferWriterForward.h + src/tscore/BufferWriterFormat.cc + src/tscore/CompileParseRules.cc + src/tscore/ConsistentHash.cc + include/tscore/ConsistentHash.h + src/tscore/ContFlags.cc + include/tscore/ContFlags.h + src/tscore/CryptoHash.cc + include/tscore/CryptoHash.h + include/tscore/defalloc.h + src/tscore/Diags.cc + include/tscore/Diags.h + include/tscore/DynArray.h + src/tscore/EventNotify.cc + include/tscore/EventNotify.h + src/tscore/fastlz.c + include/tscore/fastlz.h + src/tscore/Hash.cc + include/tscore/Hash.h + src/tscore/HashFNV.cc + include/tscore/HashFNV.h + src/tscore/HashMD5.cc + include/tscore/HashMD5.h + src/tscore/HashSip.cc + include/tscore/HashSip.h + include/tscore/History.h + src/tscore/HostLookup.cc + include/tscore/HostLookup.h + src/tscore/hugepages.cc + include/tscore/hugepages.h + include/tscore/I_Layout.h + include/tscore/I_Version.h + include/tscore/ink_aiocb.h + include/tscore/ink_align.h + include/tscore/ink_apidefs.h + src/tscore/ink_args.cc + include/tscore/ink_args.h + src/tscore/ink_assert.cc + include/tscore/ink_assert.h + include/tscore/ink_atomic.h + src/tscore/ink_base64.cc + include/tscore/ink_base64.h + src/tscore/ink_cap.cc + include/tscore/ink_cap.h + src/tscore/ink_code.cc + include/tscore/ink_code.h + include/tscore/ink_config.h + src/tscore/ink_defs.cc + include/tscore/ink_defs.h + src/tscore/ink_error.cc + include/tscore/ink_error.h + include/tscore/ink_exception.h + src/tscore/ink_file.cc + include/tscore/ink_file.h + src/tscore/ink_hash_table.cc + include/tscore/ink_hash_table.h + src/tscore/ink_hrtime.cc + include/tscore/ink_hrtime.h + src/tscore/ink_inet.cc + include/tscore/ink_inet.h + include/tscore/ink_inout.h + include/tscore/ink_llqueue.h + include/tscore/ink_lockfile.h + include/tscore/INK_MD5.h + src/tscore/ink_memory.cc + include/tscore/ink_memory.h + src/tscore/ink_mutex.cc + include/tscore/ink_mutex.h + include/tscore/ink_platform.h + src/tscore/ink_queue.cc + include/tscore/ink_queue.h + src/tscore/ink_queue_utils.cc + src/tscore/ink_rand.cc + include/tscore/ink_rand.h + src/tscore/ink_res_init.cc + src/tscore/ink_res_mkquery.cc + include/tscore/ink_resolver.h + src/tscore/ink_resource.cc + include/tscore/ink_resource.h + src/tscore/ink_rwlock.cc + include/tscore/ink_rwlock.h + src/tscore/ink_sock.cc + include/tscore/ink_sock.h + src/tscore/ink_sprintf.cc + include/tscore/ink_sprintf.h + src/tscore/ink_stack_trace.cc + include/tscore/ink_stack_trace.h + src/tscore/ink_string++.cc + include/tscore/ink_string++.h + src/tscore/ink_string.cc + include/tscore/ink_string.h + src/tscore/ink_sys_control.cc + include/tscore/ink_sys_control.h + src/tscore/ink_syslog.cc + include/tscore/ink_syslog.h + src/tscore/ink_thread.cc + include/tscore/ink_thread.h + src/tscore/ink_time.cc + include/tscore/ink_time.h + src/tscore/ink_uuid.cc + include/tscore/ink_uuid.h + src/tscore/InkErrno.cc + include/tscore/InkErrno.h + include/tscore/IntrusiveDList.h + src/tscore/IntrusivePtrTest.cc + src/tscore/IpMap.cc + include/tscore/IpMap.h + src/tscore/IpMapConf.cc + include/tscore/IpMapConf.h + src/tscore/Layout.cc + include/tscore/List.h + src/tscore/llqueue.cc + src/tscore/load_http_hdr.cc + src/tscore/lockfile.cc + include/tscore/Map.h + src/tscore/MatcherUtils.cc + include/tscore/MatcherUtils.h + include/tscore/MemArena.h + src/tscore/MemArena.cc + include/tscore/MemSpan.h + src/tscore/mkdfa.c + src/tscore/MMH.cc + include/tscore/MMH.h + include/tscore/MT_hashtable.h + src/tscore/ParseRules.cc + include/tscore/ParseRules.h + include/tscore/PriorityQueue.h + include/tscore/Ptr.h + src/tscore/RawHashTable.cc + include/tscore/RawHashTable.h + src/tscore/RbTree.cc + include/tscore/RbTree.h + src/tscore/Regex.cc + include/tscore/Regex.h + src/tscore/Regression.cc + include/tscore/Regression.h + include/tscore/Result.h + src/tscore/runroot.cc + include/tscore/runroot.h + include/tscore/Scalar.h + include/tscore/SHA256.h + src/tscore/signals.cc + include/tscore/signals.h + include/tscore/SimpleTokenizer.h + src/tscore/SourceLocation.cc + include/tscore/SourceLocation.h + src/tscore/test_arena.cc + src/tscore/test_atomic.cc + src/tscore/test_freelist.cc + src/tscore/test_geometry.cc + src/tscore/test_History.cc + src/tscore/test_List.cc + src/tscore/test_Map.cc + src/tscore/test_PriorityQueue.cc + src/tscore/test_Ptr.cc + src/tscore/test_Regex.cc + src/tscore/test_Vec.cc + src/tscore/test_X509HostnameValidator.cc + include/tscore/TestBox.h + src/tscore/TestHttpHeader.cc + src/tscore/tests.cc + src/tscore/TextBuffer.cc + include/tscore/TextBuffer.h + include/tscore/TextView.h + src/tscore/Tokenizer.cc + include/tscore/Tokenizer.h + include/tscore/Trie.h + include/tscore/TsBuffer.h + src/tscore/Version.cc + src/tscore/X509HostnameValidator.cc + include/tscore/X509HostnameValidator.h ) -add_executable(test_tslib - lib/ts/unit-tests/unit_test_main.cc - lib/ts/unit-tests/test_BufferWriter.cc - lib/ts/unit-tests/test_BufferWriterFormat.cc - lib/ts/unit-tests/test_ink_inet.cc - lib/ts/unit-tests/test_IntrusivePtr.cc - lib/ts/unit-tests/test_IpMap.cc - lib/ts/unit-tests/test_layout.cc - lib/ts/unit-tests/test_MemArena.cc - lib/ts/unit-tests/test_MemSpan.cc - lib/ts/unit-tests/test_MT_hashtable.cc - lib/ts/unit-tests/test_Scalar.cc - lib/ts/unit-tests/test_scoped_resource.cc - lib/ts/unit-tests/test_TextView.cc +add_executable(test_tscore + src/tscore/unit_tests/unit_test_main.cc + src/tscore/unit_tests/test_BufferWriter.cc + src/tscore/unit_tests/test_BufferWriterFormat.cc + src/tscore/unit_tests/test_ink_inet.cc + src/tscore/unit_tests/test_IntrusivePtr.cc + src/tscore/unit_tests/test_IpMap.cc + src/tscore/unit_tests/test_layout.cc + src/tscore/unit_tests/test_MemArena.cc + src/tscore/unit_tests/test_MemSpan.cc + src/tscore/unit_tests/test_MT_hashtable.cc + src/tscore/unit_tests/test_Scalar.cc + src/tscore/unit_tests/test_scoped_resource.cc ) # iocore/cache diff --git a/Makefile.am b/Makefile.am index 9ba8548877d..9b541b243e4 100644 --- a/Makefile.am +++ b/Makefile.am @@ -26,12 +26,11 @@ export CCACHE_BASEDIR # TODO: There's still some weirdness in the dependencies between proxy # and mgmt, hence we have to build proxy/hdrs first. -# proxy/api/ts has to be built first, since so much of libraries and "core # depends on the generates ts/ts.h include file. -SUBDIRS = proxy/api/ts lib iocore proxy mgmt src plugins tools example rc configs +SUBDIRS = src/tscpp/util lib src/tscore iocore proxy mgmt src plugins tools example rc configs include if BUILD_DOCS -SUBDIRS += doc +SUBDIRS += doc include endif DIST_BUILD_USER=`id -nu` diff --git a/build/plugins.mk b/build/plugins.mk index 30d48828e72..5dcf2126303 100644 --- a/build/plugins.mk +++ b/build/plugins.mk @@ -27,9 +27,9 @@ TS_PLUGIN_LD_FLAGS = \ TS_PLUGIN_CPPFLAGS = \ -I$(abs_top_builddir)/proxy/api \ -I$(abs_top_srcdir)/proxy/api \ - -I$(abs_top_srcdir)/lib/cppapi/include \ + -I$(abs_top_srcdir)/include/cppapi/include \ -I$(abs_top_builddir)/lib/cppapi/include \ - -I$(abs_top_srcdir)/lib + -I$(abs_top_srcdir)/include # Provide a default AM_CPPFLAGS. Automake handles this correctly, but libtool # throws an error if we try to do the same with AM_LDFLAGS. Hence, we provide diff --git a/configure.ac b/configure.ac index 9ec51e0cac4..44cd6674e08 100644 --- a/configure.ac +++ b/configure.ac @@ -2006,6 +2006,10 @@ AC_CONFIG_FILES([ doc/ext/local-config.py doc/uml/Makefile example/Makefile + include/Makefile + include/ts/Makefile + include/tscpp/api/Makefile + include/tscpp/util/Makefile iocore/Makefile iocore/aio/Makefile iocore/cache/Makefile @@ -2015,15 +2019,14 @@ AC_CONFIG_FILES([ iocore/net/Makefile iocore/utils/Makefile lib/Makefile - lib/cppapi/Makefile + src/tscpp/api/Makefile lib/perl/Makefile lib/perl/lib/Apache/TS.pm lib/records/Makefile - lib/ts/Makefile - lib/ts/apidefs.h - lib/ts/ink_config.h + include/ts/apidefs.h + include/tscore/ink_config.h lib/tsconfig/Makefile - lib/wccp/Makefile + src/wccp/Makefile lib/yamlcpp/Makefile mgmt/Makefile mgmt/api/Makefile @@ -2031,7 +2034,6 @@ AC_CONFIG_FILES([ mgmt/utils/Makefile plugins/Makefile proxy/Makefile - proxy/api/ts/Makefile proxy/hdrs/Makefile proxy/http/Makefile proxy/http/remap/Makefile @@ -2043,6 +2045,8 @@ AC_CONFIG_FILES([ rc/trafficserver.conf rc/trafficserver.service rc/trafficserver.xml + src/tscpp/util/Makefile + src/tscore/Makefile tools/Makefile tools/trafficserver.pc tools/tsxs diff --git a/doc/developer-guide/introduction/header-file-structure.en.rst b/doc/developer-guide/introduction/header-file-structure.en.rst new file mode 100644 index 00000000000..edee3b16665 --- /dev/null +++ b/doc/developer-guide/introduction/header-file-structure.en.rst @@ -0,0 +1,71 @@ +.. Licensed to the Apache Software Foundation (ASF) under one or more contributor license + agreements. See the NOTICE file distributed with this work for additional information regarding + copyright ownership. The ASF licenses this file to you under the Apache License, Version 2.0 (the + "License"); you may not use this file except in compliance with the License. You may obtain a + copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software distributed under the License + is distributed on an "AS IS" BASIS, 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. + +.. include:: ../../common.defs + +.. _developer-header-files: + +Header Files +************ + +There are four header directories, each containing header files for different purposes. Three of these +are available to plugins. + +"ts" + The C Plugin API. These call functions directly embedded in ``traffic_server`` and therefore have + no explicit linkage. + +"tscpp/api" + The C++ Plugin API. These call functions in the ``libtscppapi.so`` library to directly interact with + the running |TS| instance. + +"tscpp/util" + C++ utilities. These are standalone headers (although they may depend on other headers in the + same directory). These provide functionality that is used inside the |TS| core logic but has been + demonstrated to be useful for plugins as well [#]_. The functions are in the library + ``libtscpputil.so``, although many of the utilities are header only. This library is linked in to + the ``traffic_server`` and ``traffic_manager`` binaries and so linkage may not be needed for a plugin. + + This library is independent of the C++ API and can be used with or without that library. + +"tscore" + |TS| core header files. These can only be used inside |TS| itself because they either depend on internal + data structures either directly or operationally. This is linked in to the ``traffic_server`` and + ``traffic_manager`` binaries therefore has no explicit linkage when used in the core. + +Historical +========== + +This was a major restructuring the source code layout. The primary goal of this was to unify the include paths +for the core and plugins for these headers, and to make C++ support code used in the core also available to plugins. +Previously plugins in the |TS| codebase used these headers because they could reach over and include them, but +third party plugins could not because the headers were not installed. + +"proxy/api/ts" was moved to "include/ts", along with a couple headers from "lib/ts". This consolidates the C plugin API. + +The C++ API headers were split from the source and moved to "include/tscpp/api". The source files +were moved to "src/tscpp/api". + +The contents of "lib/ts" were broken up and moved to different locations. The headers were moved to +"include/tscore" for core only headers, while headers to be made available to plugins were moved to +"include/tscpp/util". The corresponding source files were moved to "src/tscore" and "src/tscpp/util" +respectively. "libtsutil" was split in to "libtscore" for the core code and "libtscpputil" for shared +code. + +Appendix +======== + +.. rubric:: Footnotes + +.. [#] + Primarily by use in the plugins in the |TS| code base. diff --git a/doc/developer-guide/introduction/index.en.rst b/doc/developer-guide/introduction/index.en.rst index 3c3609e485e..2994bb0df9d 100644 --- a/doc/developer-guide/introduction/index.en.rst +++ b/doc/developer-guide/introduction/index.en.rst @@ -46,6 +46,9 @@ refer to the :ref:`developer-api-reference`. Below is a section-by-section breakdown of this guide: +:ref:`developer-header-files` + The header file directory structure, where to find headers for particular tasks. + :ref:`developer-plugins-getting-started` How to compile and load plugins. Walks through a simple "hello world" example; explains how to initialize and register plugins. Basic structures @@ -113,3 +116,8 @@ function type: :ref:`developer-api-ref-functions` Traffic Server API Function Documentation. + +.. toctree:: + :hidden: + + header-file-structure.en diff --git a/example/Makefile.am b/example/Makefile.am index 5e2a90ffc2e..6067bfcda56 100644 --- a/example/Makefile.am +++ b/example/Makefile.am @@ -20,7 +20,7 @@ include $(top_srcdir)/build/tidy.mk AM_CXXFLAGS += -Wno-unused-variable AM_LDFLAGS = $(TS_PLUGIN_LD_FLAGS) -libatscppapi = $(top_builddir)/lib/cppapi/libatscppapi.la +libtscppapi = $(top_builddir)/src/tscpp/api/libtscppapi.la libtsconfig = $(top_builddir)/lib/tsconfig/libtsconfig.la if BUILD_EXAMPLE_PLUGINS diff --git a/example/add_header/add_header.c b/example/add_header/add_header.c index 404b184bc74..993a856afc5 100644 --- a/example/add_header/add_header.c +++ b/example/add_header/add_header.c @@ -37,7 +37,7 @@ #include #include "ts/ts.h" -#include "ts/ink_defs.h" +#include "tscore/ink_defs.h" #define PLUGIN_NAME "add_header" diff --git a/example/append_transform/append_transform.c b/example/append_transform/append_transform.c index 67922f246ab..873d1c530fe 100644 --- a/example/append_transform/append_transform.c +++ b/example/append_transform/append_transform.c @@ -41,7 +41,7 @@ #include #include "ts/ts.h" -#include "ts/ink_defs.h" +#include "tscore/ink_defs.h" #define PLUGIN_NAME "append_transform" diff --git a/example/basic_auth/basic_auth.c b/example/basic_auth/basic_auth.c index 1743465c2ea..95a87edc1a4 100644 --- a/example/basic_auth/basic_auth.c +++ b/example/basic_auth/basic_auth.c @@ -27,7 +27,7 @@ #include #include "ts/ts.h" -#include "ts/ink_defs.h" +#include "tscore/ink_defs.h" #define PLUGIN_NAME "basic_auth" diff --git a/example/blacklist_1/blacklist_1.c b/example/blacklist_1/blacklist_1.c index 6443d9526d7..34703a2e8ec 100644 --- a/example/blacklist_1/blacklist_1.c +++ b/example/blacklist_1/blacklist_1.c @@ -25,7 +25,7 @@ #include #include "ts/ts.h" -#include "ts/ink_defs.h" +#include "tscore/ink_defs.h" #define PLUGIN_NAME "blacklist_1" diff --git a/example/bnull_transform/bnull_transform.c b/example/bnull_transform/bnull_transform.c index 372268d8d6b..09af6218704 100644 --- a/example/bnull_transform/bnull_transform.c +++ b/example/bnull_transform/bnull_transform.c @@ -37,7 +37,7 @@ #include #include "ts/ts.h" -#include "ts/ink_defs.h" +#include "tscore/ink_defs.h" #define PLUGIN_NAME "bnull_transform" diff --git a/example/cache_scan/cache_scan.cc b/example/cache_scan/cache_scan.cc index b787789115b..f889fb880a3 100644 --- a/example/cache_scan/cache_scan.cc +++ b/example/cache_scan/cache_scan.cc @@ -32,7 +32,7 @@ #include "ts/ts.h" #include "ts/experimental.h" -#include "ts/ink_defs.h" +#include "tscore/ink_defs.h" #define PLUGIN_NAME "cache_scan" diff --git a/example/cppapi/async_http_fetch/AsyncHttpFetch.cc b/example/cppapi/async_http_fetch/AsyncHttpFetch.cc index a74cef8d20c..b6622183057 100644 --- a/example/cppapi/async_http_fetch/AsyncHttpFetch.cc +++ b/example/cppapi/async_http_fetch/AsyncHttpFetch.cc @@ -16,13 +16,13 @@ limitations under the License. */ -#include -#include -#include -#include -#include -#include -#include +#include "tscpp/api/GlobalPlugin.h" +#include "tscpp/api/TransactionPlugin.h" +#include "tscpp/api/Logger.h" +#include "tscpp/api/Async.h" +#include "tscpp/api/AsyncHttpFetch.h" +#include "tscpp/api/AsyncTimer.h" +#include "tscpp/api/PluginInit.h" #include #include #include diff --git a/example/cppapi/async_http_fetch_streaming/AsyncHttpFetchStreaming.cc b/example/cppapi/async_http_fetch_streaming/AsyncHttpFetchStreaming.cc index 3dd4041d5ea..1389e9c277c 100644 --- a/example/cppapi/async_http_fetch_streaming/AsyncHttpFetchStreaming.cc +++ b/example/cppapi/async_http_fetch_streaming/AsyncHttpFetchStreaming.cc @@ -16,13 +16,13 @@ limitations under the License. */ -#include -#include -#include -#include -#include -#include -#include +#include "tscpp/api/GlobalPlugin.h" +#include "tscpp/api/InterceptPlugin.h" +#include "tscpp/api/Logger.h" +#include "tscpp/api/Async.h" +#include "tscpp/api/AsyncHttpFetch.h" +#include "tscpp/api/AsyncTimer.h" +#include "tscpp/api/PluginInit.h" #include #include #include diff --git a/example/cppapi/async_timer/AsyncTimer.cc b/example/cppapi/async_timer/AsyncTimer.cc index 229f21981fc..7242dc4fb56 100644 --- a/example/cppapi/async_timer/AsyncTimer.cc +++ b/example/cppapi/async_timer/AsyncTimer.cc @@ -16,10 +16,10 @@ limitations under the License. */ -#include -#include -#include -#include +#include "tscpp/api/Logger.h" +#include "tscpp/api/PluginInit.h" +#include "tscpp/api/AsyncTimer.h" +#include "tscpp/api/GlobalPlugin.h" using namespace atscppapi; using std::string; diff --git a/example/cppapi/boom/boom.cc b/example/cppapi/boom/boom.cc index 4ac36d253b2..be58fca7d6a 100644 --- a/example/cppapi/boom/boom.cc +++ b/example/cppapi/boom/boom.cc @@ -61,14 +61,14 @@ #include #include -#include - -#include -#include -#include -#include -#include -#include +#include "tscpp/api/Transaction.h" + +#include "tscpp/api/GlobalPlugin.h" +#include "tscpp/api/TransactionPlugin.h" +#include "tscpp/api/PluginInit.h" +#include "tscpp/api/Headers.h" +#include "tscpp/api/Stat.h" +#include "tscpp/api/Logger.h" using namespace atscppapi; #define TAG "boom" diff --git a/example/cppapi/clientredirect/ClientRedirect.cc b/example/cppapi/clientredirect/ClientRedirect.cc index 8206c48cb1b..7cfb7e3ff89 100644 --- a/example/cppapi/clientredirect/ClientRedirect.cc +++ b/example/cppapi/clientredirect/ClientRedirect.cc @@ -17,9 +17,9 @@ */ #include -#include -#include -#include +#include "tscpp/api/GlobalPlugin.h" +#include "tscpp/api/TransactionPlugin.h" +#include "tscpp/api/PluginInit.h" using namespace atscppapi; diff --git a/example/cppapi/clientrequest/ClientRequest.cc b/example/cppapi/clientrequest/ClientRequest.cc index 93baaa22820..7b96e73ac51 100644 --- a/example/cppapi/clientrequest/ClientRequest.cc +++ b/example/cppapi/clientrequest/ClientRequest.cc @@ -17,9 +17,9 @@ */ #include -#include -#include -#include +#include "tscpp/api/GlobalPlugin.h" +#include "tscpp/api/PluginInit.h" +#include "tscpp/api/utils.h" using namespace atscppapi; diff --git a/example/cppapi/custom_error_remap_plugin/CustomErrorRemapPlugin.cc b/example/cppapi/custom_error_remap_plugin/CustomErrorRemapPlugin.cc index dea2fab51bf..f6cb20c7425 100644 --- a/example/cppapi/custom_error_remap_plugin/CustomErrorRemapPlugin.cc +++ b/example/cppapi/custom_error_remap_plugin/CustomErrorRemapPlugin.cc @@ -16,8 +16,8 @@ limitations under the License. */ -#include -#include +#include "tscpp/api/RemapPlugin.h" +#include "tscpp/api/PluginInit.h" #include using namespace std; diff --git a/example/cppapi/customresponse/CustomResponse.cc b/example/cppapi/customresponse/CustomResponse.cc index d422482df11..72701634b28 100644 --- a/example/cppapi/customresponse/CustomResponse.cc +++ b/example/cppapi/customresponse/CustomResponse.cc @@ -18,9 +18,9 @@ #include #include -#include -#include -#include +#include "tscpp/api/GlobalPlugin.h" +#include "tscpp/api/TransactionPlugin.h" +#include "tscpp/api/PluginInit.h" using namespace atscppapi; diff --git a/example/cppapi/delay_transformation_plugin/DelayTransformationPlugin.cc b/example/cppapi/delay_transformation_plugin/DelayTransformationPlugin.cc index 7c410a45d9c..66c80c04103 100644 --- a/example/cppapi/delay_transformation_plugin/DelayTransformationPlugin.cc +++ b/example/cppapi/delay_transformation_plugin/DelayTransformationPlugin.cc @@ -18,11 +18,11 @@ #include #include -#include -#include -#include -#include -#include +#include "tscpp/api/GlobalPlugin.h" +#include "tscpp/api/TransactionPlugin.h" +#include "tscpp/api/TransformationPlugin.h" +#include "tscpp/api/PluginInit.h" +#include "tscpp/api/Logger.h" #include "ts/ts.h" diff --git a/example/cppapi/globalhook/GlobalHookPlugin.cc b/example/cppapi/globalhook/GlobalHookPlugin.cc index d3efecdd331..9fd245e491f 100644 --- a/example/cppapi/globalhook/GlobalHookPlugin.cc +++ b/example/cppapi/globalhook/GlobalHookPlugin.cc @@ -17,8 +17,8 @@ */ #include -#include -#include +#include "tscpp/api/GlobalPlugin.h" +#include "tscpp/api/PluginInit.h" //#include<../ts/Diags.h> using namespace atscppapi; diff --git a/example/cppapi/gzip_transformation/GzipTransformationPlugin.cc b/example/cppapi/gzip_transformation/GzipTransformationPlugin.cc index f0219b16e51..a2d7ba0c15c 100644 --- a/example/cppapi/gzip_transformation/GzipTransformationPlugin.cc +++ b/example/cppapi/gzip_transformation/GzipTransformationPlugin.cc @@ -18,13 +18,13 @@ #include #include -#include -#include -#include -#include -#include -#include -#include +#include "tscpp/api/GlobalPlugin.h" +#include "tscpp/api/TransactionPlugin.h" +#include "tscpp/api/TransformationPlugin.h" +#include "tscpp/api/GzipInflateTransformation.h" +#include "tscpp/api/GzipDeflateTransformation.h" +#include "tscpp/api/PluginInit.h" +#include "tscpp/api/Logger.h" using namespace atscppapi; using namespace atscppapi::transformations; diff --git a/example/cppapi/helloworld/HelloWorldPlugin.cc b/example/cppapi/helloworld/HelloWorldPlugin.cc index 3532f8584f6..26f568814d5 100644 --- a/example/cppapi/helloworld/HelloWorldPlugin.cc +++ b/example/cppapi/helloworld/HelloWorldPlugin.cc @@ -17,8 +17,8 @@ */ #include -#include -#include +#include "tscpp/api/GlobalPlugin.h" +#include "tscpp/api/PluginInit.h" using namespace atscppapi; namespace diff --git a/example/cppapi/intercept/intercept.cc b/example/cppapi/intercept/intercept.cc index 51ee42ee2ec..ec3c747ea64 100644 --- a/example/cppapi/intercept/intercept.cc +++ b/example/cppapi/intercept/intercept.cc @@ -16,9 +16,9 @@ limitations under the License. */ -#include -#include -#include +#include "tscpp/api/GlobalPlugin.h" +#include "tscpp/api/InterceptPlugin.h" +#include "tscpp/api/PluginInit.h" #include diff --git a/example/cppapi/internal_transaction_handling/InternalTransactionHandling.cc b/example/cppapi/internal_transaction_handling/InternalTransactionHandling.cc index dc85afd9b98..65b7e8e0e03 100644 --- a/example/cppapi/internal_transaction_handling/InternalTransactionHandling.cc +++ b/example/cppapi/internal_transaction_handling/InternalTransactionHandling.cc @@ -16,10 +16,10 @@ limitations under the License. */ -#include -#include -#include -#include +#include "tscpp/api/GlobalPlugin.h" +#include "tscpp/api/Logger.h" +#include "tscpp/api/PluginInit.h" +#include "tscpp/api/AsyncHttpFetch.h" using namespace atscppapi; using std::string; diff --git a/example/cppapi/logger_example/LoggerExample.cc b/example/cppapi/logger_example/LoggerExample.cc index 14403aedca1..f6b1bfe3e74 100644 --- a/example/cppapi/logger_example/LoggerExample.cc +++ b/example/cppapi/logger_example/LoggerExample.cc @@ -22,10 +22,10 @@ * TS-1813 to correct log rolling in 3.2.x */ -#include -#include -#include -#include +#include "tscpp/api/GlobalPlugin.h" +#include "tscpp/api/TransactionPlugin.h" +#include "tscpp/api/Logger.h" +#include "tscpp/api/PluginInit.h" #include using namespace atscppapi; diff --git a/example/cppapi/multiple_transaction_hooks/MultipleTransactionHookPlugins.cc b/example/cppapi/multiple_transaction_hooks/MultipleTransactionHookPlugins.cc index bfcdde1fbd4..d96712f94f9 100644 --- a/example/cppapi/multiple_transaction_hooks/MultipleTransactionHookPlugins.cc +++ b/example/cppapi/multiple_transaction_hooks/MultipleTransactionHookPlugins.cc @@ -18,9 +18,9 @@ #include #include -#include -#include -#include +#include "tscpp/api/GlobalPlugin.h" +#include "tscpp/api/TransactionPlugin.h" +#include "tscpp/api/PluginInit.h" using namespace atscppapi; namespace diff --git a/example/cppapi/null_transformation_plugin/NullTransformationPlugin.cc b/example/cppapi/null_transformation_plugin/NullTransformationPlugin.cc index 67a7020ebb4..5eeec99c453 100644 --- a/example/cppapi/null_transformation_plugin/NullTransformationPlugin.cc +++ b/example/cppapi/null_transformation_plugin/NullTransformationPlugin.cc @@ -18,11 +18,11 @@ #include #include -#include -#include -#include -#include -#include +#include "tscpp/api/GlobalPlugin.h" +#include "tscpp/api/TransactionPlugin.h" +#include "tscpp/api/TransformationPlugin.h" +#include "tscpp/api/PluginInit.h" +#include "tscpp/api/Logger.h" using namespace atscppapi; diff --git a/example/cppapi/post_buffer/PostBuffer.cc b/example/cppapi/post_buffer/PostBuffer.cc index 984d10594df..1d67f8b1908 100644 --- a/example/cppapi/post_buffer/PostBuffer.cc +++ b/example/cppapi/post_buffer/PostBuffer.cc @@ -18,10 +18,10 @@ #include #include -#include -#include -#include -#include +#include "tscpp/api/GlobalPlugin.h" +#include "tscpp/api/TransactionPlugin.h" +#include "tscpp/api/TransformationPlugin.h" +#include "tscpp/api/PluginInit.h" using namespace atscppapi; using std::cerr; diff --git a/example/cppapi/remap_plugin/RemapPlugin.cc b/example/cppapi/remap_plugin/RemapPlugin.cc index 455a805f80c..aed34a91d37 100644 --- a/example/cppapi/remap_plugin/RemapPlugin.cc +++ b/example/cppapi/remap_plugin/RemapPlugin.cc @@ -16,9 +16,9 @@ limitations under the License. */ -#include -#include -#include +#include "tscpp/api/RemapPlugin.h" +#include "tscpp/api/PluginInit.h" +#include "tscpp/api/Logger.h" #include #include #include diff --git a/example/cppapi/serverresponse/ServerResponse.cc b/example/cppapi/serverresponse/ServerResponse.cc index 0f9c9019bcd..5e84febd423 100644 --- a/example/cppapi/serverresponse/ServerResponse.cc +++ b/example/cppapi/serverresponse/ServerResponse.cc @@ -17,9 +17,9 @@ */ #include -#include -#include -#include +#include "tscpp/api/GlobalPlugin.h" +#include "tscpp/api/PluginInit.h" +#include "tscpp/api/utils.h" using namespace atscppapi; diff --git a/example/cppapi/stat_example/StatExample.cc b/example/cppapi/stat_example/StatExample.cc index bdc3d19c569..a37107b127b 100644 --- a/example/cppapi/stat_example/StatExample.cc +++ b/example/cppapi/stat_example/StatExample.cc @@ -16,10 +16,10 @@ limitations under the License. */ -#include -#include -#include -#include +#include "tscpp/api/GlobalPlugin.h" +#include "tscpp/api/Logger.h" +#include "tscpp/api/Stat.h" +#include "tscpp/api/PluginInit.h" #include using namespace atscppapi; diff --git a/example/cppapi/timeout_example/TimeoutExamplePlugin.cc b/example/cppapi/timeout_example/TimeoutExamplePlugin.cc index 3cd54ff5c6f..1edddfc8dad 100644 --- a/example/cppapi/timeout_example/TimeoutExamplePlugin.cc +++ b/example/cppapi/timeout_example/TimeoutExamplePlugin.cc @@ -17,9 +17,9 @@ */ #include -#include -#include -#include +#include "tscpp/api/GlobalPlugin.h" +#include "tscpp/api/Logger.h" +#include "tscpp/api/PluginInit.h" using namespace atscppapi; diff --git a/example/cppapi/transactionhook/TransactionHookPlugin.cc b/example/cppapi/transactionhook/TransactionHookPlugin.cc index add9164f674..d2b09a183f8 100644 --- a/example/cppapi/transactionhook/TransactionHookPlugin.cc +++ b/example/cppapi/transactionhook/TransactionHookPlugin.cc @@ -17,9 +17,9 @@ */ #include -#include -#include -#include +#include "tscpp/api/GlobalPlugin.h" +#include "tscpp/api/TransactionPlugin.h" +#include "tscpp/api/PluginInit.h" using namespace atscppapi; diff --git a/example/cppapi/websocket/WSBuffer.cc b/example/cppapi/websocket/WSBuffer.cc index 49773c1274a..66e4f8079b0 100644 --- a/example/cppapi/websocket/WSBuffer.cc +++ b/example/cppapi/websocket/WSBuffer.cc @@ -24,7 +24,7 @@ #include "WSBuffer.h" #include -#include +#include "tscore/ink_config.h" #include "openssl/evp.h" #include #include diff --git a/example/cppapi/websocket/WebSocket.cc b/example/cppapi/websocket/WebSocket.cc index 4b14b8c2746..6e5e29f3741 100644 --- a/example/cppapi/websocket/WebSocket.cc +++ b/example/cppapi/websocket/WebSocket.cc @@ -23,7 +23,7 @@ #include "WebSocket.h" -#include +#include "tscpp/api/Logger.h" // DISCLAIMER: this is intended for demonstration purposes only and // does not pretend to implement a complete (or useful) server. diff --git a/example/cppapi/websocket/WebSocket.h b/example/cppapi/websocket/WebSocket.h index 01f835e3d57..ad4adccbefd 100644 --- a/example/cppapi/websocket/WebSocket.h +++ b/example/cppapi/websocket/WebSocket.h @@ -23,8 +23,8 @@ #pragma once -#include -#include +#include "tscpp/api/GlobalPlugin.h" +#include "tscpp/api/InterceptPlugin.h" #include #include diff --git a/example/output_header/output_header.c b/example/output_header/output_header.c index eb66aae25b3..ea4de980a3c 100644 --- a/example/output_header/output_header.c +++ b/example/output_header/output_header.c @@ -36,7 +36,7 @@ #include #include "ts/ts.h" -#include "ts/ink_defs.h" +#include "tscore/ink_defs.h" #define PLUGIN_NAME "output_header" diff --git a/example/protocol/Protocol.c b/example/protocol/Protocol.c index 3e85e86e058..c5062721582 100644 --- a/example/protocol/Protocol.c +++ b/example/protocol/Protocol.c @@ -23,7 +23,7 @@ #include "Protocol.h" #include "TxnSM.h" -#include "ts/ink_defs.h" +#include "tscore/ink_defs.h" #include /* global variable */ diff --git a/example/protocol/TxnSM.c b/example/protocol/TxnSM.c index b61c7468f23..10d3724cad6 100644 --- a/example/protocol/TxnSM.c +++ b/example/protocol/TxnSM.c @@ -23,7 +23,7 @@ #include #include -#include "ts/ink_defs.h" +#include "tscore/ink_defs.h" #include "TxnSM.h" diff --git a/example/protocol_stack/protocol_stack.cc b/example/protocol_stack/protocol_stack.cc index 24fa6868f2a..758ca452ef8 100644 --- a/example/protocol_stack/protocol_stack.cc +++ b/example/protocol_stack/protocol_stack.cc @@ -24,7 +24,7 @@ #include #include "ts/ts.h" -#include "ts/ink_defs.h" +#include "tscore/ink_defs.h" #define PLUGIN_NAME "protocol_stack" diff --git a/example/query_remap/query_remap.c b/example/query_remap/query_remap.c index 558f4fd2213..8bd6910179a 100644 --- a/example/query_remap/query_remap.c +++ b/example/query_remap/query_remap.c @@ -27,7 +27,7 @@ #include "ts/ts.h" #include "ts/remap.h" -#include "ts/ink_defs.h" +#include "tscore/ink_defs.h" #define PLUGIN_NAME "query_remap" diff --git a/example/remap/remap.cc b/example/remap/remap.cc index 26aeb86cd51..359e03867fa 100644 --- a/example/remap/remap.cc +++ b/example/remap/remap.cc @@ -38,7 +38,7 @@ #include #include -#include "ts/ink_defs.h" +#include "tscore/ink_defs.h" #include "ts/ts.h" #include "ts/remap.h" diff --git a/example/replace_header/replace_header.c b/example/replace_header/replace_header.c index f69116b2f16..7832d9e1133 100644 --- a/example/replace_header/replace_header.c +++ b/example/replace_header/replace_header.c @@ -37,7 +37,7 @@ #include #include "ts/ts.h" -#include "ts/ink_defs.h" +#include "tscore/ink_defs.h" #define PLUGIN_NAME "replace_header" diff --git a/example/request_buffer/request_buffer.c b/example/request_buffer/request_buffer.c index a75650fd067..69ab0c6269d 100644 --- a/example/request_buffer/request_buffer.c +++ b/example/request_buffer/request_buffer.c @@ -26,8 +26,8 @@ #include #include "ts/ts.h" -#include "ts/ink_assert.h" -#include "ts/ink_defs.h" +#include "tscore/ink_assert.h" +#include "tscore/ink_defs.h" #define PLUGIN_NAME "request_buffer" diff --git a/example/response_header_1/response_header_1.c b/example/response_header_1/response_header_1.c index 6da077c3ebf..a96afaa9fe3 100644 --- a/example/response_header_1/response_header_1.c +++ b/example/response_header_1/response_header_1.c @@ -42,7 +42,7 @@ #include #include "ts/ts.h" -#include "ts/ink_defs.h" +#include "tscore/ink_defs.h" #define PLUGIN_NAME "response_header_1" diff --git a/example/server_push/server_push.c b/example/server_push/server_push.c index 657b26269af..717d373bcf0 100644 --- a/example/server_push/server_push.c +++ b/example/server_push/server_push.c @@ -37,7 +37,7 @@ #include "ts/ts.h" #include "ts/experimental.h" -#include "ts/ink_defs.h" +#include "tscore/ink_defs.h" const char *PLUGIN_NAME = "server_push"; diff --git a/example/server_transform/server_transform.c b/example/server_transform/server_transform.c index 0c93be1bcde..ec93e5303e4 100644 --- a/example/server_transform/server_transform.c +++ b/example/server_transform/server_transform.c @@ -47,7 +47,7 @@ #include #include "ts/ts.h" -#include "ts/ink_defs.h" +#include "tscore/ink_defs.h" #define PLUGIN_NAME "server-transform" diff --git a/example/session_hooks/session_hooks.c b/example/session_hooks/session_hooks.c index bd62b98c94c..a10c17dd4e9 100644 --- a/example/session_hooks/session_hooks.c +++ b/example/session_hooks/session_hooks.c @@ -23,7 +23,7 @@ #include #include "ts/ts.h" -#include "ts/ink_defs.h" +#include "tscore/ink_defs.h" #define PLUGIN_NAME "session_hooks" diff --git a/example/ssl_preaccept/ssl_preaccept.cc b/example/ssl_preaccept/ssl_preaccept.cc index 58fef8e96e4..7b3e1536b35 100644 --- a/example/ssl_preaccept/ssl_preaccept.cc +++ b/example/ssl_preaccept/ssl_preaccept.cc @@ -31,7 +31,7 @@ #include #include #include -#include +#include "tscore/ink_inet.h" #include #include diff --git a/example/ssl_sni_whitelist/ssl_sni_whitelist.cc b/example/ssl_sni_whitelist/ssl_sni_whitelist.cc index 731372fa2bd..9d2db9ecc49 100644 --- a/example/ssl_sni_whitelist/ssl_sni_whitelist.cc +++ b/example/ssl_sni_whitelist/ssl_sni_whitelist.cc @@ -27,7 +27,7 @@ #include #include #include -#include "ts/ink_config.h" +#include "tscore/ink_config.h" #include #include #include diff --git a/example/thread_1/thread_1.c b/example/thread_1/thread_1.c index b7979d42a6a..84e1156845f 100644 --- a/example/thread_1/thread_1.c +++ b/example/thread_1/thread_1.c @@ -27,7 +27,7 @@ #include #include "ts/ts.h" -#include "ts/ink_defs.h" +#include "tscore/ink_defs.h" #define PLUGIN_NAME "thread_1" diff --git a/example/thread_pool/psi.c b/example/thread_pool/psi.c index 6b1a986f671..fa465b2c1f2 100644 --- a/example/thread_pool/psi.c +++ b/example/thread_pool/psi.c @@ -39,7 +39,7 @@ #include "ts/ts.h" #include "thread.h" -#include "ts/ink_defs.h" +#include "tscore/ink_defs.h" /* This is the number of threads spawned by the plugin. Should be tuned based on performance requirements, diff --git a/example/thread_pool/thread.c b/example/thread_pool/thread.c index 38003883364..79347bcf178 100644 --- a/example/thread_pool/thread.c +++ b/example/thread_pool/thread.c @@ -26,7 +26,7 @@ #include "ts/ts.h" #include "thread.h" -#include "ts/ink_defs.h" +#include "tscore/ink_defs.h" struct timespec tp1; struct timespec tp2; diff --git a/include/Makefile.am b/include/Makefile.am new file mode 100644 index 00000000000..a7f7eeb4565 --- /dev/null +++ b/include/Makefile.am @@ -0,0 +1,19 @@ +# include Makefile.am +# +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# 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. + +SUBDIRS = ts tscpp/api tscpp/util diff --git a/proxy/api/ts/InkAPIPrivateIOCore.h b/include/ts/InkAPIPrivateIOCore.h similarity index 100% rename from proxy/api/ts/InkAPIPrivateIOCore.h rename to include/ts/InkAPIPrivateIOCore.h diff --git a/proxy/api/ts/Makefile.am b/include/ts/Makefile.am similarity index 96% rename from proxy/api/ts/Makefile.am rename to include/ts/Makefile.am index bcf8f9ef440..b53837ef84d 100644 --- a/proxy/api/ts/Makefile.am +++ b/include/ts/Makefile.am @@ -1,4 +1,4 @@ -# api/ts Makefile.am +# include/ts Makefile.am # # Licensed to the Apache Software Foundation (ASF) under one # or more contributor license agreements. See the NOTICE file @@ -19,6 +19,7 @@ library_includedir=$(includedir)/ts library_include_HEADERS = \ + apidefs.h \ ts.h \ remap.h \ experimental.h diff --git a/proxy/api/ts/TsException.h b/include/ts/TsException.h similarity index 100% rename from proxy/api/ts/TsException.h rename to include/ts/TsException.h diff --git a/lib/ts/apidefs.h.in b/include/ts/apidefs.h.in similarity index 100% rename from lib/ts/apidefs.h.in rename to include/ts/apidefs.h.in diff --git a/proxy/api/ts/experimental.h b/include/ts/experimental.h similarity index 100% rename from proxy/api/ts/experimental.h rename to include/ts/experimental.h diff --git a/proxy/api/ts/remap.h b/include/ts/remap.h similarity index 100% rename from proxy/api/ts/remap.h rename to include/ts/remap.h diff --git a/proxy/api/ts/ts.h b/include/ts/ts.h similarity index 100% rename from proxy/api/ts/ts.h rename to include/ts/ts.h diff --git a/lib/ts/Allocator.h b/include/tscore/Allocator.h similarity index 98% rename from lib/ts/Allocator.h rename to include/tscore/Allocator.h index 3b9671c2030..4ed9094e449 100644 --- a/lib/ts/Allocator.h +++ b/include/tscore/Allocator.h @@ -41,9 +41,9 @@ #include #include -#include "ts/ink_queue.h" -#include "ts/ink_defs.h" -#include "ts/ink_resource.h" +#include "tscore/ink_queue.h" +#include "tscore/ink_defs.h" +#include "tscore/ink_resource.h" #include #define RND16(_x) (((_x) + 15) & ~15) diff --git a/lib/ts/Arena.h b/include/tscore/Arena.h similarity index 99% rename from lib/ts/Arena.h rename to include/tscore/Arena.h index a76bd0c407d..c885c980212 100644 --- a/lib/ts/Arena.h +++ b/include/tscore/Arena.h @@ -25,7 +25,7 @@ #include #include -#include "ts/ink_assert.h" +#include "tscore/ink_assert.h" struct ArenaBlock { ArenaBlock *next; diff --git a/lib/ts/BaseLogFile.h b/include/tscore/BaseLogFile.h similarity index 100% rename from lib/ts/BaseLogFile.h rename to include/tscore/BaseLogFile.h diff --git a/lib/ts/Bitops.h b/include/tscore/Bitops.h similarity index 100% rename from lib/ts/Bitops.h rename to include/tscore/Bitops.h diff --git a/lib/ts/BufferWriter.h b/include/tscore/BufferWriter.h similarity index 99% rename from lib/ts/BufferWriter.h rename to include/tscore/BufferWriter.h index b459ee17c9a..d3731995279 100644 --- a/lib/ts/BufferWriter.h +++ b/include/tscore/BufferWriter.h @@ -31,9 +31,9 @@ #include #include -#include -#include -#include +#include "tscpp/util/TextView.h" +#include "tscore/MemSpan.h" +#include "tscore/BufferWriterForward.h" namespace ts { diff --git a/lib/ts/BufferWriterForward.h b/include/tscore/BufferWriterForward.h similarity index 98% rename from lib/ts/BufferWriterForward.h rename to include/tscore/BufferWriterForward.h index 7f164043514..9bc874c57df 100644 --- a/lib/ts/BufferWriterForward.h +++ b/include/tscore/BufferWriterForward.h @@ -29,8 +29,8 @@ #include #include -#include -#include +#include "tscpp/util/TextView.h" +#include "tscore/ink_assert.h" namespace ts { diff --git a/lib/ts/ConsistentHash.h b/include/tscore/ConsistentHash.h similarity index 100% rename from lib/ts/ConsistentHash.h rename to include/tscore/ConsistentHash.h diff --git a/lib/ts/ContFlags.h b/include/tscore/ContFlags.h similarity index 100% rename from lib/ts/ContFlags.h rename to include/tscore/ContFlags.h diff --git a/lib/ts/CryptoHash.h b/include/tscore/CryptoHash.h similarity index 98% rename from lib/ts/CryptoHash.h rename to include/tscore/CryptoHash.h index 037a726658f..b3334c03984 100644 --- a/lib/ts/CryptoHash.h +++ b/include/tscore/CryptoHash.h @@ -22,16 +22,16 @@ #pragma once -#include +#include "tscore/BufferWriter.h" #include /// Apache Traffic Server commons. #if TS_ENABLE_FIPS == 1 -// #include "ts/SHA256.h" +// #include "tscore/SHA256.h" #define CRYPTO_HASH_SIZE (256 / 8) #else -// #include "ts/ink_code.h" +// #include "tscore/ink_code.h" #define CRYPTO_HASH_SIZE (128 / 8) #endif #define CRYPTO_HEX_SIZE ((CRYPTO_HASH_SIZE * 2) + 1) diff --git a/lib/ts/Diags.h b/include/tscore/Diags.h similarity index 100% rename from lib/ts/Diags.h rename to include/tscore/Diags.h diff --git a/lib/ts/DynArray.h b/include/tscore/DynArray.h similarity index 100% rename from lib/ts/DynArray.h rename to include/tscore/DynArray.h diff --git a/lib/ts/EnumDescriptor.h b/include/tscore/EnumDescriptor.h similarity index 98% rename from lib/ts/EnumDescriptor.h rename to include/tscore/EnumDescriptor.h index 274ba925e36..485a5c3db59 100644 --- a/lib/ts/EnumDescriptor.h +++ b/include/tscore/EnumDescriptor.h @@ -22,7 +22,7 @@ #include #include -#include "ts/HashFNV.h" +#include "tscore/HashFNV.h" /// Hash functor for @c string_view inline size_t diff --git a/lib/ts/EventNotify.h b/include/tscore/EventNotify.h similarity index 97% rename from lib/ts/EventNotify.h rename to include/tscore/EventNotify.h index 418c6120c00..2ac068923de 100644 --- a/lib/ts/EventNotify.h +++ b/include/tscore/EventNotify.h @@ -30,7 +30,7 @@ #pragma once -#include "ts/ink_thread.h" +#include "tscore/ink_thread.h" class EventNotify { diff --git a/lib/ts/Hash.h b/include/tscore/Hash.h similarity index 100% rename from lib/ts/Hash.h rename to include/tscore/Hash.h diff --git a/lib/ts/HashFNV.h b/include/tscore/HashFNV.h similarity index 98% rename from lib/ts/HashFNV.h rename to include/tscore/HashFNV.h index a5480692bc0..e113d0cd012 100644 --- a/lib/ts/HashFNV.h +++ b/include/tscore/HashFNV.h @@ -27,7 +27,7 @@ #pragma once -#include "ts/Hash.h" +#include "tscore/Hash.h" #include struct ATSHash32FNV1a : ATSHash32 { diff --git a/lib/ts/HashMD5.h b/include/tscore/HashMD5.h similarity index 98% rename from lib/ts/HashMD5.h rename to include/tscore/HashMD5.h index 8c1e6b4bdcc..bad5a90cc80 100644 --- a/lib/ts/HashMD5.h +++ b/include/tscore/HashMD5.h @@ -21,7 +21,7 @@ #pragma once -#include "ts/Hash.h" +#include "tscore/Hash.h" #include struct ATSHashMD5 : ATSHash { diff --git a/lib/ts/HashSip.h b/include/tscore/HashSip.h similarity index 98% rename from lib/ts/HashSip.h rename to include/tscore/HashSip.h index eeb7c08ae03..837289848dc 100644 --- a/lib/ts/HashSip.h +++ b/include/tscore/HashSip.h @@ -21,7 +21,7 @@ #pragma once -#include "ts/Hash.h" +#include "tscore/Hash.h" #include /* diff --git a/lib/ts/History.h b/include/tscore/History.h similarity index 98% rename from lib/ts/History.h rename to include/tscore/History.h index ff7125aca06..685813cbcc9 100644 --- a/lib/ts/History.h +++ b/include/tscore/History.h @@ -23,7 +23,7 @@ #pragma once -#include "ts/SourceLocation.h" +#include "tscore/SourceLocation.h" #define NO_REENTRANT 99999 #define NO_EVENT NO_REENTRANT diff --git a/lib/ts/HostLookup.h b/include/tscore/HostLookup.h similarity index 100% rename from lib/ts/HostLookup.h rename to include/tscore/HostLookup.h diff --git a/lib/ts/INK_MD5.h b/include/tscore/INK_MD5.h similarity index 93% rename from lib/ts/INK_MD5.h rename to include/tscore/INK_MD5.h index 86637880024..baed4c59204 100644 --- a/lib/ts/INK_MD5.h +++ b/include/tscore/INK_MD5.h @@ -23,9 +23,9 @@ #pragma once -#include "ts/ink_code.h" -#include "ts/ink_defs.h" -#include "ts/CryptoHash.h" +#include "tscore/ink_code.h" +#include "tscore/ink_defs.h" +#include "tscore/CryptoHash.h" class MD5Context : public ats::CryptoContextBase { diff --git a/lib/ts/I_Layout.h b/include/tscore/I_Layout.h similarity index 100% rename from lib/ts/I_Layout.h rename to include/tscore/I_Layout.h diff --git a/lib/ts/I_Version.h b/include/tscore/I_Version.h similarity index 100% rename from lib/ts/I_Version.h rename to include/tscore/I_Version.h diff --git a/lib/ts/InkErrno.h b/include/tscore/InkErrno.h similarity index 100% rename from lib/ts/InkErrno.h rename to include/tscore/InkErrno.h diff --git a/lib/ts/IntrusiveDList.h b/include/tscore/IntrusiveDList.h similarity index 100% rename from lib/ts/IntrusiveDList.h rename to include/tscore/IntrusiveDList.h diff --git a/lib/ts/IpMap.h b/include/tscore/IpMap.h similarity index 98% rename from lib/ts/IpMap.h rename to include/tscore/IpMap.h index cab828f71c2..33179307105 100644 --- a/lib/ts/IpMap.h +++ b/include/tscore/IpMap.h @@ -23,12 +23,12 @@ #pragma once -#include "ts/ink_platform.h" -#include "ts/ink_defs.h" -#include "ts/RbTree.h" -#include "ts/ink_inet.h" -#include "ts/IntrusiveDList.h" -#include "ts/ink_assert.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_defs.h" +#include "tscore/RbTree.h" +#include "tscore/ink_inet.h" +#include "tscore/IntrusiveDList.h" +#include "tscore/ink_assert.h" namespace ts { diff --git a/lib/ts/IpMapConf.h b/include/tscore/IpMapConf.h similarity index 100% rename from lib/ts/IpMapConf.h rename to include/tscore/IpMapConf.h diff --git a/lib/ts/JeAllocator.h b/include/tscore/JeAllocator.h similarity index 97% rename from lib/ts/JeAllocator.h rename to include/tscore/JeAllocator.h index 749955bc3d6..7d1b678fdcc 100644 --- a/lib/ts/JeAllocator.h +++ b/include/tscore/JeAllocator.h @@ -19,8 +19,8 @@ #pragma once -#include "ts/ink_config.h" -#include "ts/ink_queue.h" +#include "tscore/ink_config.h" +#include "tscore/ink_queue.h" #include #include diff --git a/lib/ts/List.h b/include/tscore/List.h similarity index 99% rename from lib/ts/List.h rename to include/tscore/List.h index f58b5a372c2..cc6278165d9 100644 --- a/lib/ts/List.h +++ b/include/tscore/List.h @@ -55,9 +55,9 @@ #include -#include "ts/ink_assert.h" -#include "ts/ink_queue.h" -#include "ts/defalloc.h" +#include "tscore/ink_assert.h" +#include "tscore/ink_queue.h" +#include "tscore/defalloc.h" // // Link cell for singly-linked list of objects of type C. diff --git a/lib/ts/MMH.h b/include/tscore/MMH.h similarity index 97% rename from lib/ts/MMH.h rename to include/tscore/MMH.h index f387781ea52..e5f02402467 100644 --- a/lib/ts/MMH.h +++ b/include/tscore/MMH.h @@ -23,9 +23,9 @@ #pragma once -#include "ts/ink_code.h" -#include "ts/ink_defs.h" -#include "ts/CryptoHash.h" +#include "tscore/ink_code.h" +#include "tscore/ink_defs.h" +#include "tscore/CryptoHash.h" struct MMH_CTX { uint64_t state[4]; diff --git a/lib/ts/MT_hashtable.h b/include/tscore/MT_hashtable.h similarity index 100% rename from lib/ts/MT_hashtable.h rename to include/tscore/MT_hashtable.h diff --git a/lib/ts/Map.h b/include/tscore/Map.h similarity index 99% rename from lib/ts/Map.h rename to include/tscore/Map.h index e68cf2bcc29..5114bbf7a70 100644 --- a/lib/ts/Map.h +++ b/include/tscore/Map.h @@ -28,11 +28,11 @@ #include #include -#include "ts/defalloc.h" -#include "ts/ink_assert.h" -#include "ts/Diags.h" +#include "tscore/defalloc.h" +#include "tscore/ink_assert.h" +#include "tscore/Diags.h" -#include "ts/List.h" +#include "tscore/List.h" #define MAP_INTEGRAL_SIZE (1 << (2)) //#define MAP_INITIAL_SHIFT ((2)+1) diff --git a/lib/ts/MatcherUtils.h b/include/tscore/MatcherUtils.h similarity index 97% rename from lib/ts/MatcherUtils.h rename to include/tscore/MatcherUtils.h index b7cb3dfc0fb..383c77c2c3f 100644 --- a/lib/ts/MatcherUtils.h +++ b/include/tscore/MatcherUtils.h @@ -31,9 +31,9 @@ #pragma once -#include "ts/ParseRules.h" -#include "ts/Result.h" -#include "ts/ink_inet.h" +#include "tscore/ParseRules.h" +#include "tscore/Result.h" +#include "tscore/ink_inet.h" // Look in MatcherUtils.cc for comments on function usage char *readIntoBuffer(const char *file_path, const char *module_name, int *read_size_ptr); diff --git a/lib/ts/MemArena.h b/include/tscore/MemArena.h similarity index 99% rename from lib/ts/MemArena.h rename to include/tscore/MemArena.h index ad10cee7835..d623ab6b4ab 100644 --- a/lib/ts/MemArena.h +++ b/include/tscore/MemArena.h @@ -26,8 +26,8 @@ #include #include #include -#include -#include +#include "tscore/MemSpan.h" +#include "tscore/Scalar.h" #include /// Apache Traffic Server commons. diff --git a/lib/ts/MemSpan.h b/include/tscore/MemSpan.h similarity index 100% rename from lib/ts/MemSpan.h rename to include/tscore/MemSpan.h diff --git a/lib/ts/ParseRules.h b/include/tscore/ParseRules.h similarity index 99% rename from lib/ts/ParseRules.h rename to include/tscore/ParseRules.h index 166f6c32bb7..d8fe31e51a7 100644 --- a/lib/ts/ParseRules.h +++ b/include/tscore/ParseRules.h @@ -25,9 +25,9 @@ #include -#include "ts/ink_defs.h" -#include "ts/ink_apidefs.h" -#include "ts/ink_platform.h" +#include "tscore/ink_defs.h" +#include "tscore/ink_apidefs.h" +#include "tscore/ink_platform.h" typedef unsigned int CTypeResult; diff --git a/lib/ts/PriorityQueue.h b/include/tscore/PriorityQueue.h similarity index 99% rename from lib/ts/PriorityQueue.h rename to include/tscore/PriorityQueue.h index 43ba07e38cb..3d2c0d3dc82 100644 --- a/lib/ts/PriorityQueue.h +++ b/include/tscore/PriorityQueue.h @@ -23,7 +23,7 @@ #pragma once -#include "ts/ink_assert.h" +#include "tscore/ink_assert.h" #include #include diff --git a/lib/ts/Ptr.h b/include/tscore/Ptr.h similarity index 99% rename from lib/ts/Ptr.h rename to include/tscore/Ptr.h index b78ee363b6e..d067604a9ef 100644 --- a/lib/ts/Ptr.h +++ b/include/tscore/Ptr.h @@ -23,7 +23,7 @@ #pragma once -#include "ts/ink_atomic.h" +#include "tscore/ink_atomic.h" //////////////////////////////////////////////////////////////////// //////////////////////////////////////////////////////////////////// diff --git a/lib/ts/RawHashTable.h b/include/tscore/RawHashTable.h similarity index 99% rename from lib/ts/RawHashTable.h rename to include/tscore/RawHashTable.h index de41b2418f4..4d0cb5141d8 100644 --- a/lib/ts/RawHashTable.h +++ b/include/tscore/RawHashTable.h @@ -30,8 +30,8 @@ #pragma once -#include "ts/ink_apidefs.h" -#include "ts/ink_hash_table.h" +#include "tscore/ink_apidefs.h" +#include "tscore/ink_hash_table.h" ////////////////////////////////////////////////////////////////////////////// // diff --git a/lib/ts/RbTree.h b/include/tscore/RbTree.h similarity index 100% rename from lib/ts/RbTree.h rename to include/tscore/RbTree.h diff --git a/lib/ts/Regex.h b/include/tscore/Regex.h similarity index 98% rename from lib/ts/Regex.h rename to include/tscore/Regex.h index ded7e39aefd..6c1572c837f 100644 --- a/lib/ts/Regex.h +++ b/include/tscore/Regex.h @@ -23,7 +23,7 @@ #pragma once -#include "ts/ink_config.h" +#include "tscore/ink_config.h" #ifdef HAVE_PCRE_PCRE_H #include diff --git a/lib/ts/Regression.h b/include/tscore/Regression.h similarity index 97% rename from lib/ts/Regression.h rename to include/tscore/Regression.h index 43808a74c41..e34a497df4e 100644 --- a/lib/ts/Regression.h +++ b/include/tscore/Regression.h @@ -23,9 +23,9 @@ #pragma once -#include "ts/ink_platform.h" -#include "ts/Regex.h" -#include "ts/Diags.h" +#include "tscore/ink_platform.h" +#include "tscore/Regex.h" +#include "tscore/Diags.h" // Each module should provide one or more regression tests // diff --git a/lib/ts/Result.h b/include/tscore/Result.h similarity index 100% rename from lib/ts/Result.h rename to include/tscore/Result.h diff --git a/lib/ts/SHA256.h b/include/tscore/SHA256.h similarity index 93% rename from lib/ts/SHA256.h rename to include/tscore/SHA256.h index d4f2a146cae..987a64cd76f 100644 --- a/lib/ts/SHA256.h +++ b/include/tscore/SHA256.h @@ -23,9 +23,9 @@ #pragma once -#include "ts/ink_code.h" -#include "ts/ink_defs.h" -#include "ts/CryptoHash.h" +#include "tscore/ink_code.h" +#include "tscore/ink_defs.h" +#include "tscore/CryptoHash.h" #include class SHA256Context : public ats::CryptoContextBase diff --git a/lib/ts/Scalar.h b/include/tscore/Scalar.h similarity index 99% rename from lib/ts/Scalar.h rename to include/tscore/Scalar.h index ef8c3cb5a23..e71a0824da0 100644 --- a/lib/ts/Scalar.h +++ b/include/tscore/Scalar.h @@ -31,7 +31,7 @@ #include #include #include -#include +#include "tscore/BufferWriter.h" namespace tag { diff --git a/lib/ts/SimpleTokenizer.h b/include/tscore/SimpleTokenizer.h similarity index 99% rename from lib/ts/SimpleTokenizer.h rename to include/tscore/SimpleTokenizer.h index cebf6f3d26e..3f0e7fad3d0 100644 --- a/lib/ts/SimpleTokenizer.h +++ b/include/tscore/SimpleTokenizer.h @@ -26,7 +26,7 @@ #include #include #include -#include "ts/ink_memory.h" +#include "tscore/ink_memory.h" /*----------------------------------------------------------------------------- SimpleTokenizer diff --git a/lib/ts/SourceLocation.h b/include/tscore/SourceLocation.h similarity index 100% rename from lib/ts/SourceLocation.h rename to include/tscore/SourceLocation.h diff --git a/lib/ts/TestBox.h b/include/tscore/TestBox.h similarity index 97% rename from lib/ts/TestBox.h rename to include/tscore/TestBox.h index bbb9a039b28..6071713eb75 100644 --- a/lib/ts/TestBox.h +++ b/include/tscore/TestBox.h @@ -24,8 +24,8 @@ #pragma once #include -#include "ts/ink_apidefs.h" -#include "ts/Regression.h" +#include "tscore/ink_apidefs.h" +#include "tscore/Regression.h" namespace { diff --git a/lib/ts/TextBuffer.h b/include/tscore/TextBuffer.h similarity index 96% rename from lib/ts/TextBuffer.h rename to include/tscore/TextBuffer.h index 2be7c11513a..8ef01debe41 100644 --- a/lib/ts/TextBuffer.h +++ b/include/tscore/TextBuffer.h @@ -31,9 +31,9 @@ * ****************************************************************************/ -#include "ts/ink_platform.h" -#include "ts/ink_memory.h" -#include "ts/ink_apidefs.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_memory.h" +#include "tscore/ink_apidefs.h" #include class TextBuffer diff --git a/lib/ts/Tokenizer.h b/include/tscore/Tokenizer.h similarity index 99% rename from lib/ts/Tokenizer.h rename to include/tscore/Tokenizer.h index 86b1c0323ad..562279b0f1f 100644 --- a/lib/ts/Tokenizer.h +++ b/include/tscore/Tokenizer.h @@ -101,7 +101,7 @@ * *******************************************************************/ -#include "ts/ink_apidefs.h" +#include "tscore/ink_apidefs.h" #define COPY_TOKS (1u << 0) #define SHARE_TOKS (1u << 1) diff --git a/lib/ts/Trie.h b/include/tscore/Trie.h similarity index 99% rename from lib/ts/Trie.h rename to include/tscore/Trie.h index e371c954cd4..2bcc6daaa1b 100644 --- a/lib/ts/Trie.h +++ b/include/tscore/Trie.h @@ -26,7 +26,7 @@ #include #include -#include "ts/List.h" +#include "tscore/List.h" // Note that you should provide the class to use here, but we'll store // pointers to such objects internally. diff --git a/lib/ts/TsBuffer.h b/include/tscore/TsBuffer.h similarity index 100% rename from lib/ts/TsBuffer.h rename to include/tscore/TsBuffer.h diff --git a/lib/ts/X509HostnameValidator.h b/include/tscore/X509HostnameValidator.h similarity index 100% rename from lib/ts/X509HostnameValidator.h rename to include/tscore/X509HostnameValidator.h diff --git a/lib/ts/bwf_std_format.h b/include/tscore/bwf_std_format.h similarity index 97% rename from lib/ts/bwf_std_format.h rename to include/tscore/bwf_std_format.h index d90da571c82..2a0ad80b357 100644 --- a/lib/ts/bwf_std_format.h +++ b/include/tscore/bwf_std_format.h @@ -25,8 +25,8 @@ #include #include -#include -#include +#include "tscpp/util/TextView.h" +#include "tscore/BufferWriterForward.h" namespace std { diff --git a/lib/ts/defalloc.h b/include/tscore/defalloc.h similarity index 97% rename from lib/ts/defalloc.h rename to include/tscore/defalloc.h index feca710659d..29baec007d3 100644 --- a/lib/ts/defalloc.h +++ b/include/tscore/defalloc.h @@ -22,7 +22,7 @@ */ #pragma once -#include "ts/ink_memory.h" +#include "tscore/ink_memory.h" class DefaultAlloc { diff --git a/lib/ts/fastlz.h b/include/tscore/fastlz.h similarity index 100% rename from lib/ts/fastlz.h rename to include/tscore/fastlz.h diff --git a/lib/ts/hugepages.h b/include/tscore/hugepages.h similarity index 100% rename from lib/ts/hugepages.h rename to include/tscore/hugepages.h diff --git a/lib/ts/ink_aiocb.h b/include/tscore/ink_aiocb.h similarity index 98% rename from lib/ts/ink_aiocb.h rename to include/tscore/ink_aiocb.h index f0e878e0e67..ac50fbd9cd0 100644 --- a/lib/ts/ink_aiocb.h +++ b/include/tscore/ink_aiocb.h @@ -31,7 +31,7 @@ #pragma once -#include "ts/ink_defs.h" +#include "tscore/ink_defs.h" /* TODO use native aiocb where possible */ diff --git a/lib/ts/ink_align.h b/include/tscore/ink_align.h similarity index 98% rename from lib/ts/ink_align.h rename to include/tscore/ink_align.h index 9c84fe7a14c..387852d577c 100644 --- a/lib/ts/ink_align.h +++ b/include/tscore/ink_align.h @@ -24,7 +24,7 @@ //-*-c++-*- #pragma once -#include "ts/ink_time.h" +#include "tscore/ink_time.h" union Alias32 { uint8_t byte[4]; diff --git a/lib/ts/ink_apidefs.h b/include/tscore/ink_apidefs.h similarity index 100% rename from lib/ts/ink_apidefs.h rename to include/tscore/ink_apidefs.h diff --git a/lib/ts/ink_args.h b/include/tscore/ink_args.h similarity index 98% rename from lib/ts/ink_args.h rename to include/tscore/ink_args.h index 7176cca3d38..f3b4eedd592 100644 --- a/lib/ts/ink_args.h +++ b/include/tscore/ink_args.h @@ -27,8 +27,8 @@ Process arguments ****************************************************************************/ #pragma once -#include "ts/ink_defs.h" -#include "ts/ink_apidefs.h" +#include "tscore/ink_defs.h" +#include "tscore/ink_apidefs.h" #if HAVE_SYSEXITS_H #include diff --git a/lib/ts/ink_assert.h b/include/tscore/ink_assert.h similarity index 98% rename from lib/ts/ink_assert.h rename to include/tscore/ink_assert.h index 21c0db53082..b9c2861dec2 100644 --- a/lib/ts/ink_assert.h +++ b/include/tscore/ink_assert.h @@ -27,7 +27,7 @@ Assertions ***************************************************************************/ #pragma once -#include "ts/ink_apidefs.h" +#include "tscore/ink_apidefs.h" #ifdef __cplusplus extern "C" { diff --git a/lib/ts/ink_atomic.h b/include/tscore/ink_atomic.h similarity index 98% rename from lib/ts/ink_atomic.h rename to include/tscore/ink_atomic.h index 683bb9616a4..fda512c4538 100644 --- a/lib/ts/ink_atomic.h +++ b/include/tscore/ink_atomic.h @@ -41,9 +41,9 @@ #include #include -#include "ts/ink_defs.h" -#include "ts/ink_apidefs.h" -#include "ts/ink_mutex.h" +#include "tscore/ink_defs.h" +#include "tscore/ink_apidefs.h" +#include "tscore/ink_mutex.h" /* GCC compiler >= 4.1 */ #if defined(__GNUC__) && (((__GNUC__ == 4) && (__GNUC_MINOR__ >= 1)) || (__GNUC__ >= 5)) diff --git a/lib/ts/ink_base64.h b/include/tscore/ink_base64.h similarity index 100% rename from lib/ts/ink_base64.h rename to include/tscore/ink_base64.h diff --git a/lib/ts/ink_cap.h b/include/tscore/ink_cap.h similarity index 99% rename from lib/ts/ink_cap.h rename to include/tscore/ink_cap.h index 8a242106d22..c5ed681ef57 100644 --- a/lib/ts/ink_cap.h +++ b/include/tscore/ink_cap.h @@ -26,7 +26,7 @@ #include #include -#include "ts/ink_mutex.h" +#include "tscore/ink_mutex.h" /// Generate a debug message with the current capabilities for the process. extern void DebugCapabilities(const char *tag ///< Debug message tag. diff --git a/lib/ts/ink_code.h b/include/tscore/ink_code.h similarity index 96% rename from lib/ts/ink_code.h rename to include/tscore/ink_code.h index a421ccc289b..2b08574f064 100644 --- a/lib/ts/ink_code.h +++ b/include/tscore/ink_code.h @@ -23,8 +23,8 @@ #pragma once -#include "ts/ink_apidefs.h" -#include "ts/ink_defs.h" +#include "tscore/ink_apidefs.h" +#include "tscore/ink_defs.h" #if TS_ENABLE_FIPS == 0 #include diff --git a/lib/ts/ink_config.h.in b/include/tscore/ink_config.h.in similarity index 100% rename from lib/ts/ink_config.h.in rename to include/tscore/ink_config.h.in diff --git a/lib/ts/ink_defs.h b/include/tscore/ink_defs.h similarity index 98% rename from lib/ts/ink_defs.h rename to include/tscore/ink_defs.h index c0177d4d07e..20c80b53487 100644 --- a/lib/ts/ink_defs.h +++ b/include/tscore/ink_defs.h @@ -23,7 +23,7 @@ #pragma once -#include "ts/ink_config.h" +#include "tscore/ink_config.h" #include #include diff --git a/lib/ts/ink_endian.h b/include/tscore/ink_endian.h similarity index 100% rename from lib/ts/ink_endian.h rename to include/tscore/ink_endian.h diff --git a/lib/ts/ink_error.h b/include/tscore/ink_error.h similarity index 97% rename from lib/ts/ink_error.h rename to include/tscore/ink_error.h index d686ce078a7..8f0b2df9c7c 100644 --- a/lib/ts/ink_error.h +++ b/include/tscore/ink_error.h @@ -33,8 +33,8 @@ #include #include -#include "ts/ink_platform.h" -#include "ts/ink_apidefs.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_apidefs.h" // throw isn't available in every libc (musl, ..) #ifndef __THROW diff --git a/lib/ts/ink_exception.h b/include/tscore/ink_exception.h similarity index 100% rename from lib/ts/ink_exception.h rename to include/tscore/ink_exception.h diff --git a/lib/ts/ink_file.h b/include/tscore/ink_file.h similarity index 99% rename from lib/ts/ink_file.h rename to include/tscore/ink_file.h index 2ec514cb0db..fb0487c6985 100644 --- a/lib/ts/ink_file.h +++ b/include/tscore/ink_file.h @@ -31,7 +31,7 @@ #pragma once -#include "ts/ink_config.h" +#include "tscore/ink_config.h" #include #include diff --git a/lib/ts/ink_hash_table.h b/include/tscore/ink_hash_table.h similarity index 99% rename from lib/ts/ink_hash_table.h rename to include/tscore/ink_hash_table.h index 487b9ed2efb..e85df7a124e 100644 --- a/lib/ts/ink_hash_table.h +++ b/include/tscore/ink_hash_table.h @@ -35,7 +35,7 @@ #ifdef __cplusplus extern "C" { #endif /* __cplusplus */ -#include "ts/ink_apidefs.h" +#include "tscore/ink_apidefs.h" /*===========================================================================* diff --git a/lib/ts/ink_hrtime.h b/include/tscore/ink_hrtime.h similarity index 99% rename from lib/ts/ink_hrtime.h rename to include/tscore/ink_hrtime.h index 7acc2965461..a1405a98c74 100644 --- a/lib/ts/ink_hrtime.h +++ b/include/tscore/ink_hrtime.h @@ -30,8 +30,8 @@ #pragma once -#include "ts/ink_config.h" -#include "ts/ink_assert.h" +#include "tscore/ink_config.h" +#include "tscore/ink_assert.h" #include #include #include diff --git a/lib/ts/ink_inet.h b/include/tscore/ink_inet.h similarity index 99% rename from lib/ts/ink_inet.h rename to include/tscore/ink_inet.h index a0e74a6f060..d5d810d3138 100644 --- a/lib/ts/ink_inet.h +++ b/include/tscore/ink_inet.h @@ -29,9 +29,9 @@ #include #include -#include -#include -#include +#include "tscore/ink_memory.h" +#include "tscore/ink_apidefs.h" +#include "tscore/BufferWriterForward.h" #if !TS_HAS_IN6_IS_ADDR_UNSPECIFIED #if defined(IN6_IS_ADDR_UNSPECIFIED) diff --git a/lib/ts/ink_inout.h b/include/tscore/ink_inout.h similarity index 100% rename from lib/ts/ink_inout.h rename to include/tscore/ink_inout.h diff --git a/lib/ts/ink_llqueue.h b/include/tscore/ink_llqueue.h similarity index 96% rename from lib/ts/ink_llqueue.h rename to include/tscore/ink_llqueue.h index eb337620b46..4f86901f6c8 100644 --- a/lib/ts/ink_llqueue.h +++ b/include/tscore/ink_llqueue.h @@ -28,8 +28,8 @@ A simple linked list queue. ****************************************************************************/ -#include "ts/ink_mutex.h" -#include "ts/ink_thread.h" +#include "tscore/ink_mutex.h" +#include "tscore/ink_thread.h" typedef struct llqrec_s { struct llqrec_s *next; diff --git a/lib/ts/ink_lockfile.h b/include/tscore/ink_lockfile.h similarity index 97% rename from lib/ts/ink_lockfile.h rename to include/tscore/ink_lockfile.h index a16daffb7d3..dea4d97dae6 100644 --- a/lib/ts/ink_lockfile.h +++ b/include/tscore/ink_lockfile.h @@ -23,8 +23,8 @@ #pragma once -#include "ts/ink_defs.h" -#include "ts/ink_string.h" +#include "tscore/ink_defs.h" +#include "tscore/ink_string.h" #define COP_LOCK "cop.lock" #define MANAGER_LOCK "manager.lock" diff --git a/lib/ts/ink_memory.h b/include/tscore/ink_memory.h similarity index 99% rename from lib/ts/ink_memory.h rename to include/tscore/ink_memory.h index cb63cd55d85..cf850c0b9be 100644 --- a/lib/ts/ink_memory.h +++ b/include/tscore/ink_memory.h @@ -29,7 +29,7 @@ #include #include -#include "ts/ink_config.h" +#include "tscore/ink_config.h" #if HAVE_UNISTD_H #include diff --git a/lib/ts/ink_mutex.h b/include/tscore/ink_mutex.h similarity index 97% rename from lib/ts/ink_mutex.h rename to include/tscore/ink_mutex.h index c54a4b8cba0..025e69fab9d 100644 --- a/lib/ts/ink_mutex.h +++ b/include/tscore/ink_mutex.h @@ -32,8 +32,8 @@ ***********************************************************************/ -#include "ts/ink_defs.h" -#include "ts/ink_error.h" +#include "tscore/ink_defs.h" +#include "tscore/ink_error.h" #include #include diff --git a/lib/ts/ink_platform.h b/include/tscore/ink_platform.h similarity index 99% rename from lib/ts/ink_platform.h rename to include/tscore/ink_platform.h index 2c9a88366c8..321bfdf2801 100644 --- a/lib/ts/ink_platform.h +++ b/include/tscore/ink_platform.h @@ -24,7 +24,7 @@ #pragma once -#include "ts/ink_config.h" +#include "tscore/ink_config.h" // Gnu C++ doesn't define __STDC__ == 0 as needed to // have ip_hl be defined. diff --git a/lib/ts/ink_queue.h b/include/tscore/ink_queue.h similarity index 98% rename from lib/ts/ink_queue.h rename to include/tscore/ink_queue.h index a55720dc852..7f75ad9dfa9 100644 --- a/lib/ts/ink_queue.h +++ b/include/tscore/ink_queue.h @@ -33,9 +33,9 @@ ***********************************************************************/ -#include "ts/ink_platform.h" -#include "ts/ink_defs.h" -#include "ts/ink_apidefs.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_defs.h" +#include "tscore/ink_apidefs.h" /* For information on the structure of the x86_64 memory map: diff --git a/lib/ts/ink_rand.h b/include/tscore/ink_rand.h similarity index 97% rename from lib/ts/ink_rand.h rename to include/tscore/ink_rand.h index 5fd336d0ad5..05198744a67 100644 --- a/lib/ts/ink_rand.h +++ b/include/tscore/ink_rand.h @@ -60,8 +60,8 @@ #pragma once -#include "ts/ink_defs.h" -#include "ts/ink_apidefs.h" +#include "tscore/ink_defs.h" +#include "tscore/ink_apidefs.h" class InkRand { diff --git a/lib/ts/ink_resolver.h b/include/tscore/ink_resolver.h similarity index 99% rename from lib/ts/ink_resolver.h rename to include/tscore/ink_resolver.h index b549b5caef4..fee408470ed 100644 --- a/lib/ts/ink_resolver.h +++ b/include/tscore/ink_resolver.h @@ -68,8 +68,8 @@ #pragma once -#include "ts/ink_platform.h" -#include "ts/ink_inet.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_inet.h" #include #include diff --git a/lib/ts/ink_resource.h b/include/tscore/ink_resource.h similarity index 98% rename from lib/ts/ink_resource.h rename to include/tscore/ink_resource.h index e789e620d4d..578fb5785d9 100644 --- a/lib/ts/ink_resource.h +++ b/include/tscore/ink_resource.h @@ -23,7 +23,7 @@ #pragma once -#include "ts/ink_mutex.h" +#include "tscore/ink_mutex.h" #include #include diff --git a/lib/ts/ink_rwlock.h b/include/tscore/ink_rwlock.h similarity index 96% rename from lib/ts/ink_rwlock.h rename to include/tscore/ink_rwlock.h index 98c491b94da..5b3dcb36982 100644 --- a/lib/ts/ink_rwlock.h +++ b/include/tscore/ink_rwlock.h @@ -29,8 +29,8 @@ #pragma once -#include "ts/ink_mutex.h" -#include "ts/ink_thread.h" +#include "tscore/ink_mutex.h" +#include "tscore/ink_thread.h" #define RW_MAGIC 0x19283746 diff --git a/lib/ts/ink_sock.h b/include/tscore/ink_sock.h similarity index 95% rename from lib/ts/ink_sock.h rename to include/tscore/ink_sock.h index d95623b2ab8..d87b049b3bc 100644 --- a/lib/ts/ink_sock.h +++ b/include/tscore/ink_sock.h @@ -29,10 +29,10 @@ ***************************************************************************/ #pragma once -#include "ts/ink_platform.h" -#include "ts/ink_defs.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_defs.h" -#include "ts/ink_apidefs.h" +#include "tscore/ink_apidefs.h" int safe_setsockopt(int s, int level, int optname, char *optval, int optlevel); int safe_getsockopt(int s, int level, int optname, char *optval, int *optlevel); diff --git a/lib/ts/ink_sprintf.h b/include/tscore/ink_sprintf.h similarity index 95% rename from lib/ts/ink_sprintf.h rename to include/tscore/ink_sprintf.h index fd67c1f5139..39b8fdedd75 100644 --- a/lib/ts/ink_sprintf.h +++ b/include/tscore/ink_sprintf.h @@ -35,8 +35,8 @@ #include #include -#include "ts/ink_apidefs.h" -#include "ts/ink_defs.h" +#include "tscore/ink_apidefs.h" +#include "tscore/ink_defs.h" int ink_bsprintf(char *buffer, const char *format, ...) TS_PRINTFLIKE(2, 3); int ink_bvsprintf(char *buffer, const char *format, va_list ap); diff --git a/lib/ts/ink_stack_trace.h b/include/tscore/ink_stack_trace.h similarity index 100% rename from lib/ts/ink_stack_trace.h rename to include/tscore/ink_stack_trace.h diff --git a/lib/ts/ink_string++.h b/include/tscore/ink_string++.h similarity index 100% rename from lib/ts/ink_string++.h rename to include/tscore/ink_string++.h diff --git a/lib/ts/ink_string.h b/include/tscore/ink_string.h similarity index 98% rename from lib/ts/ink_string.h rename to include/tscore/ink_string.h index 7ba8c4c2f18..72a9f922571 100644 --- a/lib/ts/ink_string.h +++ b/include/tscore/ink_string.h @@ -36,10 +36,10 @@ #include #include -#include "ts/ink_assert.h" -#include "ts/ink_error.h" -#include "ts/ParseRules.h" -#include "ts/ink_apidefs.h" +#include "tscore/ink_assert.h" +#include "tscore/ink_error.h" +#include "tscore/ParseRules.h" +#include "tscore/ink_apidefs.h" /*===========================================================================* diff --git a/lib/ts/ink_sys_control.h b/include/tscore/ink_sys_control.h similarity index 100% rename from lib/ts/ink_sys_control.h rename to include/tscore/ink_sys_control.h diff --git a/lib/ts/ink_syslog.h b/include/tscore/ink_syslog.h similarity index 100% rename from lib/ts/ink_syslog.h rename to include/tscore/ink_syslog.h diff --git a/lib/ts/ink_thread.h b/include/tscore/ink_thread.h similarity index 98% rename from lib/ts/ink_thread.h rename to include/tscore/ink_thread.h index d9484f6e99c..4e321316e2b 100644 --- a/lib/ts/ink_thread.h +++ b/include/tscore/ink_thread.h @@ -28,8 +28,8 @@ #pragma once -#include "ts/ink_hrtime.h" -#include "ts/ink_defs.h" +#include "tscore/ink_hrtime.h" +#include "tscore/ink_defs.h" #include ////////////////////////////////////////////////////////////////////////////// @@ -92,8 +92,8 @@ typedef timestruc_t ink_timestruc; #endif #include -#include "ts/ink_mutex.h" -#include "ts/ink_assert.h" +#include "tscore/ink_mutex.h" +#include "tscore/ink_assert.h" ////////////////////////////////////////////////////////////////////////////// // diff --git a/lib/ts/ink_time.h b/include/tscore/ink_time.h similarity index 96% rename from lib/ts/ink_time.h rename to include/tscore/ink_time.h index 22425bfbf99..19f8cef9142 100644 --- a/lib/ts/ink_time.h +++ b/include/tscore/ink_time.h @@ -33,9 +33,9 @@ #pragma once -#include "ts/ink_platform.h" -#include "ts/ink_defs.h" -#include "ts/ink_hrtime.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_defs.h" +#include "tscore/ink_hrtime.h" /*===========================================================================* diff --git a/lib/ts/ink_uuid.h b/include/tscore/ink_uuid.h similarity index 99% rename from lib/ts/ink_uuid.h rename to include/tscore/ink_uuid.h index b0164031f72..fe6f3a9e8eb 100644 --- a/lib/ts/ink_uuid.h +++ b/include/tscore/ink_uuid.h @@ -26,7 +26,7 @@ #include #include "ts/apidefs.h" -#include "ts/ink_memory.h" +#include "tscore/ink_memory.h" // This is the C++ portions of things, which will need to get wrapped in C-helper APIs. class ATSUuid diff --git a/lib/ts/runroot.h b/include/tscore/runroot.h similarity index 100% rename from lib/ts/runroot.h rename to include/tscore/runroot.h diff --git a/lib/ts/signals.h b/include/tscore/signals.h similarity index 100% rename from lib/ts/signals.h rename to include/tscore/signals.h diff --git a/lib/cppapi/include/atscppapi/Async.h b/include/tscpp/api/Async.h similarity index 99% rename from lib/cppapi/include/atscppapi/Async.h rename to include/tscpp/api/Async.h index 7fc9ad760b0..d5227f0b0fb 100644 --- a/lib/cppapi/include/atscppapi/Async.h +++ b/include/tscpp/api/Async.h @@ -27,7 +27,7 @@ #include #include -#include +#include "tscpp/api/noncopyable.h" namespace atscppapi { diff --git a/lib/cppapi/include/atscppapi/AsyncHttpFetch.h b/include/tscpp/api/AsyncHttpFetch.h similarity index 97% rename from lib/cppapi/include/atscppapi/AsyncHttpFetch.h rename to include/tscpp/api/AsyncHttpFetch.h index 6a749973ba6..4c805cc1e17 100644 --- a/lib/cppapi/include/atscppapi/AsyncHttpFetch.h +++ b/include/tscpp/api/AsyncHttpFetch.h @@ -24,9 +24,9 @@ #include #include -#include -#include -#include +#include "tscpp/api/Async.h" +#include "tscpp/api/Request.h" +#include "tscpp/api/Response.h" namespace atscppapi { diff --git a/lib/cppapi/include/atscppapi/AsyncTimer.h b/include/tscpp/api/AsyncTimer.h similarity index 96% rename from lib/cppapi/include/atscppapi/AsyncTimer.h rename to include/tscpp/api/AsyncTimer.h index c8308dea3af..1dbfe618682 100644 --- a/lib/cppapi/include/atscppapi/AsyncTimer.h +++ b/include/tscpp/api/AsyncTimer.h @@ -24,9 +24,9 @@ #include #include -#include -#include -#include +#include "tscpp/api/Async.h" +#include "tscpp/api/Request.h" +#include "tscpp/api/Response.h" namespace atscppapi { diff --git a/lib/cppapi/include/atscppapi/CaseInsensitiveStringComparator.h b/include/tscpp/api/CaseInsensitiveStringComparator.h similarity index 100% rename from lib/cppapi/include/atscppapi/CaseInsensitiveStringComparator.h rename to include/tscpp/api/CaseInsensitiveStringComparator.h diff --git a/lib/cppapi/include/atscppapi/ClientRequest.h b/include/tscpp/api/ClientRequest.h similarity index 97% rename from lib/cppapi/include/atscppapi/ClientRequest.h rename to include/tscpp/api/ClientRequest.h index 40dc4bd2de2..79a37b0165b 100644 --- a/lib/cppapi/include/atscppapi/ClientRequest.h +++ b/include/tscpp/api/ClientRequest.h @@ -22,7 +22,7 @@ #pragma once -#include +#include "tscpp/api/Request.h" namespace atscppapi { diff --git a/lib/cppapi/include/atscppapi/Continuation.h b/include/tscpp/api/Continuation.h similarity index 100% rename from lib/cppapi/include/atscppapi/Continuation.h rename to include/tscpp/api/Continuation.h diff --git a/lib/cppapi/include/atscppapi/GlobalPlugin.h b/include/tscpp/api/GlobalPlugin.h similarity index 98% rename from lib/cppapi/include/atscppapi/GlobalPlugin.h rename to include/tscpp/api/GlobalPlugin.h index 412a3c7364c..1df60bddc6c 100644 --- a/lib/cppapi/include/atscppapi/GlobalPlugin.h +++ b/include/tscpp/api/GlobalPlugin.h @@ -23,7 +23,7 @@ #pragma once -#include +#include "tscpp/api/Plugin.h" namespace atscppapi { diff --git a/lib/cppapi/include/atscppapi/GzipDeflateTransformation.h b/include/tscpp/api/GzipDeflateTransformation.h similarity index 98% rename from lib/cppapi/include/atscppapi/GzipDeflateTransformation.h rename to include/tscpp/api/GzipDeflateTransformation.h index e86913cff7b..039965eded4 100644 --- a/lib/cppapi/include/atscppapi/GzipDeflateTransformation.h +++ b/include/tscpp/api/GzipDeflateTransformation.h @@ -25,7 +25,7 @@ #include #include -#include "atscppapi/TransformationPlugin.h" +#include "tscpp/api/TransformationPlugin.h" namespace atscppapi { diff --git a/lib/cppapi/include/atscppapi/GzipInflateTransformation.h b/include/tscpp/api/GzipInflateTransformation.h similarity index 98% rename from lib/cppapi/include/atscppapi/GzipInflateTransformation.h rename to include/tscpp/api/GzipInflateTransformation.h index dbe7648e665..c664c182e0d 100644 --- a/lib/cppapi/include/atscppapi/GzipInflateTransformation.h +++ b/include/tscpp/api/GzipInflateTransformation.h @@ -24,7 +24,7 @@ #pragma once #include -#include "atscppapi/TransformationPlugin.h" +#include "tscpp/api/TransformationPlugin.h" namespace atscppapi { diff --git a/lib/cppapi/include/atscppapi/Headers.h b/include/tscpp/api/Headers.h similarity index 99% rename from lib/cppapi/include/atscppapi/Headers.h rename to include/tscpp/api/Headers.h index 231dbbd9432..ebc7ecff2dd 100644 --- a/lib/cppapi/include/atscppapi/Headers.h +++ b/include/tscpp/api/Headers.h @@ -22,7 +22,7 @@ #pragma once -#include +#include "tscpp/api/noncopyable.h" #include namespace atscppapi diff --git a/lib/cppapi/include/atscppapi/HttpMethod.h b/include/tscpp/api/HttpMethod.h similarity index 100% rename from lib/cppapi/include/atscppapi/HttpMethod.h rename to include/tscpp/api/HttpMethod.h diff --git a/lib/cppapi/include/atscppapi/HttpStatus.h b/include/tscpp/api/HttpStatus.h similarity index 100% rename from lib/cppapi/include/atscppapi/HttpStatus.h rename to include/tscpp/api/HttpStatus.h diff --git a/lib/cppapi/include/atscppapi/HttpVersion.h b/include/tscpp/api/HttpVersion.h similarity index 100% rename from lib/cppapi/include/atscppapi/HttpVersion.h rename to include/tscpp/api/HttpVersion.h diff --git a/lib/cppapi/include/atscppapi/InterceptPlugin.h b/include/tscpp/api/InterceptPlugin.h similarity index 97% rename from lib/cppapi/include/atscppapi/InterceptPlugin.h rename to include/tscpp/api/InterceptPlugin.h index 54d9fe347ca..62eb2340115 100644 --- a/lib/cppapi/include/atscppapi/InterceptPlugin.h +++ b/include/tscpp/api/InterceptPlugin.h @@ -23,8 +23,8 @@ #pragma once #include -#include -#include +#include "tscpp/api/Transaction.h" +#include "tscpp/api/TransactionPlugin.h" namespace atscppapi { diff --git a/lib/cppapi/include/atscppapi/Logger.h b/include/tscpp/api/Logger.h similarity index 99% rename from lib/cppapi/include/atscppapi/Logger.h rename to include/tscpp/api/Logger.h index a2bc0badbbf..8bd2e4e94ce 100644 --- a/lib/cppapi/include/atscppapi/Logger.h +++ b/include/tscpp/api/Logger.h @@ -29,7 +29,7 @@ #pragma once #include -#include +#include "tscpp/api/noncopyable.h" #if !defined(ATSCPPAPI_PRINTFLIKE) #if defined(__GNUC__) || defined(__clang__) diff --git a/include/tscpp/api/Makefile.am b/include/tscpp/api/Makefile.am new file mode 100644 index 00000000000..c2f4e1c1193 --- /dev/null +++ b/include/tscpp/api/Makefile.am @@ -0,0 +1,47 @@ +# +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# 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. + +library_includedir = $(includedir)/tscpp/api + +library_include_HEADERS = \ + Async.h \ + AsyncHttpFetch.h \ + AsyncTimer.h \ + CaseInsensitiveStringComparator.h \ + ClientRequest.h \ + Continuation.h \ + GlobalPlugin.h \ + GzipDeflateTransformation.h \ + GzipInflateTransformation.h \ + Headers.h \ + HttpMethod.h \ + HttpStatus.h \ + HttpVersion.h \ + InterceptPlugin.h \ + Logger.h \ + Plugin.h \ + PluginInit.h \ + RemapPlugin.h \ + Request.h \ + Response.h \ + Stat.h \ + Transaction.h \ + TransactionPlugin.h \ + TransformationPlugin.h \ + Url.h \ + noncopyable.h \ + utils.h diff --git a/lib/cppapi/include/atscppapi/Plugin.h b/include/tscpp/api/Plugin.h similarity index 98% rename from lib/cppapi/include/atscppapi/Plugin.h rename to include/tscpp/api/Plugin.h index fce1daeb7b6..59e755ad522 100644 --- a/lib/cppapi/include/atscppapi/Plugin.h +++ b/include/tscpp/api/Plugin.h @@ -25,9 +25,9 @@ #pragma once -#include -#include -#include +#include "tscpp/api/Request.h" +#include "tscpp/api/Transaction.h" +#include "tscpp/api/noncopyable.h" namespace atscppapi { diff --git a/lib/cppapi/include/atscppapi/PluginInit.h b/include/tscpp/api/PluginInit.h similarity index 98% rename from lib/cppapi/include/atscppapi/PluginInit.h rename to include/tscpp/api/PluginInit.h index 991a43b2887..626f99b6289 100644 --- a/lib/cppapi/include/atscppapi/PluginInit.h +++ b/include/tscpp/api/PluginInit.h @@ -22,7 +22,7 @@ #pragma once #include -#include +#include "tscpp/api/utils.h" extern "C" { /** diff --git a/lib/cppapi/include/atscppapi/RemapPlugin.h b/include/tscpp/api/RemapPlugin.h similarity index 95% rename from lib/cppapi/include/atscppapi/RemapPlugin.h rename to include/tscpp/api/RemapPlugin.h index c7bc7b46207..8b0840c06cc 100644 --- a/lib/cppapi/include/atscppapi/RemapPlugin.h +++ b/include/tscpp/api/RemapPlugin.h @@ -22,9 +22,9 @@ #pragma once -#include "atscppapi/Transaction.h" -#include "atscppapi/Url.h" -#include "atscppapi/utils.h" +#include "tscpp/api/Transaction.h" +#include "tscpp/api/Url.h" +#include "tscpp/api/utils.h" namespace atscppapi { diff --git a/lib/cppapi/include/atscppapi/Request.h b/include/tscpp/api/Request.h similarity index 93% rename from lib/cppapi/include/atscppapi/Request.h rename to include/tscpp/api/Request.h index 35a5b3ccb66..515ec32f348 100644 --- a/lib/cppapi/include/atscppapi/Request.h +++ b/include/tscpp/api/Request.h @@ -21,11 +21,11 @@ #pragma once -#include -#include -#include -#include -#include +#include "tscpp/api/Headers.h" +#include "tscpp/api/HttpVersion.h" +#include "tscpp/api/HttpMethod.h" +#include "tscpp/api/Url.h" +#include "tscpp/api/noncopyable.h" namespace atscppapi { diff --git a/lib/cppapi/include/atscppapi/Response.h b/include/tscpp/api/Response.h similarity index 94% rename from lib/cppapi/include/atscppapi/Response.h rename to include/tscpp/api/Response.h index 7928694f9fe..f96890b37ab 100644 --- a/lib/cppapi/include/atscppapi/Response.h +++ b/include/tscpp/api/Response.h @@ -21,9 +21,9 @@ #pragma once -#include -#include -#include +#include "tscpp/api/Headers.h" +#include "tscpp/api/HttpVersion.h" +#include "tscpp/api/HttpStatus.h" namespace atscppapi { diff --git a/lib/cppapi/include/atscppapi/Stat.h b/include/tscpp/api/Stat.h similarity index 98% rename from lib/cppapi/include/atscppapi/Stat.h rename to include/tscpp/api/Stat.h index 856a20b408c..25d633ddbdd 100644 --- a/lib/cppapi/include/atscppapi/Stat.h +++ b/include/tscpp/api/Stat.h @@ -21,7 +21,7 @@ #pragma once -#include +#include "tscpp/api/noncopyable.h" #include #include diff --git a/lib/cppapi/include/atscppapi/Transaction.h b/include/tscpp/api/Transaction.h similarity index 99% rename from lib/cppapi/include/atscppapi/Transaction.h rename to include/tscpp/api/Transaction.h index ccd6c5b3f34..e70bb7ad03b 100644 --- a/lib/cppapi/include/atscppapi/Transaction.h +++ b/include/tscpp/api/Transaction.h @@ -25,10 +25,10 @@ #include #include #include -#include "atscppapi/Request.h" -#include "atscppapi/ClientRequest.h" -#include "atscppapi/Response.h" -#include "atscppapi/HttpStatus.h" +#include "tscpp/api/Request.h" +#include "tscpp/api/ClientRequest.h" +#include "tscpp/api/Response.h" +#include "tscpp/api/HttpStatus.h" #include namespace atscppapi { diff --git a/lib/cppapi/include/atscppapi/TransactionPlugin.h b/include/tscpp/api/TransactionPlugin.h similarity index 98% rename from lib/cppapi/include/atscppapi/TransactionPlugin.h rename to include/tscpp/api/TransactionPlugin.h index f863ce6f7ee..8f59c223542 100644 --- a/lib/cppapi/include/atscppapi/TransactionPlugin.h +++ b/include/tscpp/api/TransactionPlugin.h @@ -25,8 +25,8 @@ #include #include -#include -#include +#include "tscpp/api/Plugin.h" +#include "tscpp/api/Transaction.h" namespace atscppapi { diff --git a/lib/cppapi/include/atscppapi/TransformationPlugin.h b/include/tscpp/api/TransformationPlugin.h similarity index 98% rename from lib/cppapi/include/atscppapi/TransformationPlugin.h rename to include/tscpp/api/TransformationPlugin.h index 9258c4b0b29..fd09607277a 100644 --- a/lib/cppapi/include/atscppapi/TransformationPlugin.h +++ b/include/tscpp/api/TransformationPlugin.h @@ -23,8 +23,8 @@ #pragma once #include -#include -#include +#include "tscpp/api/Transaction.h" +#include "tscpp/api/TransactionPlugin.h" namespace atscppapi { diff --git a/lib/cppapi/include/atscppapi/Url.h b/include/tscpp/api/Url.h similarity index 99% rename from lib/cppapi/include/atscppapi/Url.h rename to include/tscpp/api/Url.h index 1e81e894619..8f4fe61722b 100644 --- a/lib/cppapi/include/atscppapi/Url.h +++ b/include/tscpp/api/Url.h @@ -23,7 +23,7 @@ #include #include -#include +#include "tscpp/api/noncopyable.h" namespace atscppapi { diff --git a/lib/cppapi/include/atscppapi/noncopyable.h b/include/tscpp/api/noncopyable.h similarity index 100% rename from lib/cppapi/include/atscppapi/noncopyable.h rename to include/tscpp/api/noncopyable.h diff --git a/lib/cppapi/include/atscppapi/utils.h b/include/tscpp/api/utils.h similarity index 100% rename from lib/cppapi/include/atscppapi/utils.h rename to include/tscpp/api/utils.h diff --git a/include/tscpp/util/Makefile.am b/include/tscpp/util/Makefile.am new file mode 100644 index 00000000000..55b0351ef37 --- /dev/null +++ b/include/tscpp/util/Makefile.am @@ -0,0 +1,22 @@ +# include/tscpp/util Makefile.am +# +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# 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. + +library_includedir=$(includedir)/tscpp/util + +library_include_HEADERS = \ + TextView.h diff --git a/lib/ts/TextView.h b/include/tscpp/util/TextView.h similarity index 100% rename from lib/ts/TextView.h rename to include/tscpp/util/TextView.h diff --git a/lib/wccp/Wccp.h b/include/wccp/Wccp.h similarity index 99% rename from lib/wccp/Wccp.h rename to include/wccp/Wccp.h index 617fd4502eb..ebb07639b16 100644 --- a/lib/wccp/Wccp.h +++ b/include/wccp/Wccp.h @@ -22,11 +22,11 @@ #pragma once -#include +#include "tscore/TsBuffer.h" #include #include -#include "ts/ink_defs.h" -#include "ts/ink_memory.h" +#include "tscore/ink_defs.h" +#include "tscore/ink_memory.h" // Nasty, defining this with no prefix. The value is still available // in TS_VERSION_STRING. #undef VERSION diff --git a/iocore/aio/I_AIO.h b/iocore/aio/I_AIO.h index b4f87a5e02a..8222ba1a59c 100644 --- a/iocore/aio/I_AIO.h +++ b/iocore/aio/I_AIO.h @@ -30,9 +30,9 @@ ****************************************************************************/ #pragma once -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #include "I_EventSystem.h" -#include "I_RecProcess.h" +#include "records/I_RecProcess.h" #define AIO_MODULE_MAJOR_VERSION 1 #define AIO_MODULE_MINOR_VERSION 0 diff --git a/iocore/aio/Makefile.am b/iocore/aio/Makefile.am index 5b69872a226..3d2f9f35431 100644 --- a/iocore/aio/Makefile.am +++ b/iocore/aio/Makefile.am @@ -18,8 +18,8 @@ AM_CPPFLAGS += \ -I$(abs_top_srcdir)/iocore/eventsystem \ - -I$(abs_top_srcdir)/lib \ - -I$(abs_top_srcdir)/lib/records \ + -I$(abs_top_srcdir)/include \ + -I$(abs_top_srcdir)/include/records \ $(TS_INCLUDES) TESTS = test_AIO.sample @@ -56,7 +56,8 @@ test_AIO_LDADD = \ $(top_builddir)/lib/records/librecords_p.a \ $(top_builddir)/mgmt/libmgmt_p.la \ $(top_builddir)/iocore/eventsystem/libinkevent.a \ - $(top_builddir)/lib/ts/libtsutil.la \ + $(top_builddir)/src/tscore/libtscore.la \ + $(top_builddir)/src/tscpp/util/libtscpputil.la \ $(top_builddir)/proxy/shared/libUglyLogStubs.a \ @LIBTCL@ @HWLOC_LIBS@ diff --git a/iocore/aio/test_AIO.cc b/iocore/aio/test_AIO.cc index b6ec75d6d63..33a972179b8 100644 --- a/iocore/aio/test_AIO.cc +++ b/iocore/aio/test_AIO.cc @@ -23,7 +23,7 @@ #include "P_AIO.h" #include "InkAPIInternal.h" -#include "ts/I_Layout.h" +#include "tscore/I_Layout.h" #include #include diff --git a/iocore/cache/Cache.cc b/iocore/cache/Cache.cc index 1e06c5891de..64bb1e62dbb 100644 --- a/iocore/cache/Cache.cc +++ b/iocore/cache/Cache.cc @@ -27,7 +27,7 @@ #include "P_CacheTest.h" #include "StatPages.h" -#include "ts/I_Layout.h" +#include "tscore/I_Layout.h" #include "HttpTransactCache.h" #include "HttpSM.h" @@ -35,7 +35,7 @@ #include "InkAPIInternal.h" #include "P_CacheBC.h" -#include "ts/hugepages.h" +#include "tscore/hugepages.h" const VersionNumber CACHE_DB_VERSION(CACHE_DB_MAJOR_VERSION, CACHE_DB_MINOR_VERSION); diff --git a/iocore/cache/CacheDir.cc b/iocore/cache/CacheDir.cc index fb045f2b266..427ce31ffd6 100644 --- a/iocore/cache/CacheDir.cc +++ b/iocore/cache/CacheDir.cc @@ -23,14 +23,14 @@ #include "P_Cache.h" -#include "ts/hugepages.h" -#include "ts/Regression.h" +#include "tscore/hugepages.h" +#include "tscore/Regression.h" // #define LOOP_CHECK_MODE 1 #ifdef LOOP_CHECK_MODE #define DIR_LOOP_THRESHOLD 1000 #endif -#include "ts/ink_stack_trace.h" +#include "tscore/ink_stack_trace.h" #define CACHE_INC_DIR_USED(_m) \ do { \ diff --git a/iocore/cache/CacheHosting.cc b/iocore/cache/CacheHosting.cc index f670289b39d..292d0a52078 100644 --- a/iocore/cache/CacheHosting.cc +++ b/iocore/cache/CacheHosting.cc @@ -22,10 +22,10 @@ */ #include "P_Cache.h" -#include "ts/I_Layout.h" -#include "ts/HostLookup.h" -#include "ts/Tokenizer.h" -#include "ts/Regression.h" +#include "tscore/I_Layout.h" +#include "tscore/HostLookup.h" +#include "tscore/Tokenizer.h" +#include "tscore/Regression.h" extern int gndisks; diff --git a/iocore/cache/CacheHttp.cc b/iocore/cache/CacheHttp.cc index 6492f6989b9..e78845f71fb 100644 --- a/iocore/cache/CacheHttp.cc +++ b/iocore/cache/CacheHttp.cc @@ -21,7 +21,7 @@ limitations under the License. */ -#include "ts/ink_config.h" +#include "tscore/ink_config.h" #include #include "P_Cache.h" diff --git a/iocore/cache/I_Cache.h b/iocore/cache/I_Cache.h index 415a10b2633..14e19d90241 100644 --- a/iocore/cache/I_Cache.h +++ b/iocore/cache/I_Cache.h @@ -23,7 +23,7 @@ #pragma once -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #include "I_EventSystem.h" #include "I_AIO.h" #include "I_CacheDefs.h" diff --git a/iocore/cache/I_CacheDefs.h b/iocore/cache/I_CacheDefs.h index 42b48235507..c4529745fd3 100644 --- a/iocore/cache/I_CacheDefs.h +++ b/iocore/cache/I_CacheDefs.h @@ -23,7 +23,7 @@ #pragma once -#include "ts/CryptoHash.h" +#include "tscore/CryptoHash.h" #define CACHE_INIT_FAILED -1 #define CACHE_INITIALIZING 0 diff --git a/iocore/cache/I_Store.h b/iocore/cache/I_Store.h index a48bbaf64b0..fbb48b87bfb 100644 --- a/iocore/cache/I_Store.h +++ b/iocore/cache/I_Store.h @@ -30,8 +30,8 @@ #pragma once -#include "ts/ink_platform.h" -#include "ts/Result.h" +#include "tscore/ink_platform.h" +#include "tscore/Result.h" #define STORE_BLOCK_SIZE 8192 #define STORE_BLOCK_SHIFT 13 diff --git a/iocore/cache/Makefile.am b/iocore/cache/Makefile.am index 3700d2cba32..66345cc8b4d 100644 --- a/iocore/cache/Makefile.am +++ b/iocore/cache/Makefile.am @@ -18,8 +18,8 @@ AM_CPPFLAGS += \ $(iocore_include_dirs) \ - -I$(abs_top_srcdir)/lib \ - -I$(abs_top_srcdir)/lib/records \ + -I$(abs_top_srcdir)/include \ + -I$(abs_top_srcdir)/include/records \ -I$(abs_top_srcdir)/proxy \ -I$(abs_top_srcdir)/proxy/hdrs \ -I$(abs_top_srcdir)/proxy/http \ diff --git a/iocore/cache/P_Cache.h b/iocore/cache/P_Cache.h index f3ae4d23813..832d7d282c8 100644 --- a/iocore/cache/P_Cache.h +++ b/iocore/cache/P_Cache.h @@ -23,10 +23,10 @@ #pragma once -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #include "P_EventSystem.h" #include "P_AIO.h" -#include "I_RecProcess.h" +#include "records/I_RecProcess.h" #include "HTTP.h" #include "MIME.h" diff --git a/iocore/cache/P_CacheHosting.h b/iocore/cache/P_CacheHosting.h index e8b4df7f2f9..87afc045517 100644 --- a/iocore/cache/P_CacheHosting.h +++ b/iocore/cache/P_CacheHosting.h @@ -23,8 +23,8 @@ #pragma once #include "P_Cache.h" -#include "ts/MatcherUtils.h" -#include "ts/HostLookup.h" +#include "tscore/MatcherUtils.h" +#include "tscore/HostLookup.h" #define CACHE_MEM_FREE_TIMEOUT HRTIME_SECONDS(1) diff --git a/iocore/cache/P_CacheInternal.h b/iocore/cache/P_CacheInternal.h index 5199d10cca8..d82aa347324 100644 --- a/iocore/cache/P_CacheInternal.h +++ b/iocore/cache/P_CacheInternal.h @@ -23,8 +23,8 @@ #pragma once -#include "ts/ink_platform.h" -#include "ts/InkErrno.h" +#include "tscore/ink_platform.h" +#include "tscore/InkErrno.h" #include "HTTP.h" #include "P_CacheHttp.h" diff --git a/iocore/cache/RamCacheCLFUS.cc b/iocore/cache/RamCacheCLFUS.cc index 833756e5531..9cb4c44d9b1 100644 --- a/iocore/cache/RamCacheCLFUS.cc +++ b/iocore/cache/RamCacheCLFUS.cc @@ -26,7 +26,7 @@ #include "P_Cache.h" #include "I_Tasks.h" -#include "ts/fastlz.h" +#include "tscore/fastlz.h" #ifdef HAVE_ZLIB_H #include #endif diff --git a/iocore/cache/Store.cc b/iocore/cache/Store.cc index 442c948aa93..1c4c396c436 100644 --- a/iocore/cache/Store.cc +++ b/iocore/cache/Store.cc @@ -21,12 +21,12 @@ limitations under the License. */ -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #include "P_Cache.h" -#include "ts/I_Layout.h" -#include "ts/ink_file.h" -#include "ts/Tokenizer.h" -#include "ts/SimpleTokenizer.h" +#include "tscore/I_Layout.h" +#include "tscore/ink_file.h" +#include "tscore/Tokenizer.h" +#include "tscore/SimpleTokenizer.h" #if HAVE_LINUX_MAJOR_H #include diff --git a/iocore/dns/DNS.cc b/iocore/dns/DNS.cc index fc381277b28..d49dd17a7dd 100644 --- a/iocore/dns/DNS.cc +++ b/iocore/dns/DNS.cc @@ -22,7 +22,7 @@ */ #include "P_DNS.h" /* MAGIC_EDITING_TAG */ -#include +#include "tscore/ink_inet.h" #ifdef SPLIT_DNS #include "I_SplitDNS.h" diff --git a/iocore/dns/Makefile.am b/iocore/dns/Makefile.am index e4fa076c5a7..2713af7830e 100644 --- a/iocore/dns/Makefile.am +++ b/iocore/dns/Makefile.am @@ -18,8 +18,8 @@ AM_CPPFLAGS += \ $(iocore_include_dirs) \ - -I$(abs_top_srcdir)/lib \ - -I$(abs_top_srcdir)/lib/records \ + -I$(abs_top_srcdir)/include \ + -I$(abs_top_srcdir)/include/records \ -I$(abs_top_srcdir)/proxy \ -I$(abs_top_srcdir)/proxy/http \ -I$(abs_top_srcdir)/proxy/hdrs \ diff --git a/iocore/dns/P_DNS.h b/iocore/dns/P_DNS.h index 87a08cdd4ad..8420a0a8ebb 100644 --- a/iocore/dns/P_DNS.h +++ b/iocore/dns/P_DNS.h @@ -29,7 +29,7 @@ ****************************************************************************/ #pragma once -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #include "I_DNS.h" #include "P_EventSystem.h" #include "I_Cache.h" diff --git a/iocore/dns/SRV.h b/iocore/dns/SRV.h index 78f6f552369..ff75689e74e 100644 --- a/iocore/dns/SRV.h +++ b/iocore/dns/SRV.h @@ -24,7 +24,7 @@ #pragma once #include -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #include "I_HostDBProcessor.h" struct HostDBInfo; diff --git a/iocore/dns/SplitDNS.cc b/iocore/dns/SplitDNS.cc index 6697a6466c4..8e076af1a78 100644 --- a/iocore/dns/SplitDNS.cc +++ b/iocore/dns/SplitDNS.cc @@ -28,14 +28,14 @@ * ****************************************************************************/ -#include "ts/ink_platform.h" -#include "ts/Tokenizer.h" +#include "tscore/ink_platform.h" +#include "tscore/Tokenizer.h" #ifdef SPLIT_DNS #include #include "P_SplitDNS.h" -#include "ts/MatcherUtils.h" -#include "ts/HostLookup.h" +#include "tscore/MatcherUtils.h" +#include "tscore/HostLookup.h" /* -------------------------------------------------------------- this file is built using "ParentSelection.cc as a template. diff --git a/iocore/eventsystem/IOBuffer.cc b/iocore/eventsystem/IOBuffer.cc index e92dc94e648..d5f52077ac5 100644 --- a/iocore/eventsystem/IOBuffer.cc +++ b/iocore/eventsystem/IOBuffer.cc @@ -25,7 +25,7 @@ UIOBuffer.cc **************************************************************************/ -#include "ts/ink_defs.h" +#include "tscore/ink_defs.h" #include "I_MIOBufferWriter.h" #include "P_EventSystem.h" diff --git a/iocore/eventsystem/I_Action.h b/iocore/eventsystem/I_Action.h index 07981163348..444e2115d08 100644 --- a/iocore/eventsystem/I_Action.h +++ b/iocore/eventsystem/I_Action.h @@ -24,7 +24,7 @@ #pragma once -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #include "I_Thread.h" #include "I_Continuation.h" diff --git a/iocore/eventsystem/I_Continuation.h b/iocore/eventsystem/I_Continuation.h index a14ba1cb34d..4e8eaa7bcfd 100644 --- a/iocore/eventsystem/I_Continuation.h +++ b/iocore/eventsystem/I_Continuation.h @@ -35,10 +35,10 @@ #pragma once -#include "ts/ink_platform.h" -#include "ts/List.h" +#include "tscore/ink_platform.h" +#include "tscore/List.h" #include "I_Lock.h" -#include "ts/ContFlags.h" +#include "tscore/ContFlags.h" class Continuation; class ContinuationQueue; diff --git a/iocore/eventsystem/I_EThread.h b/iocore/eventsystem/I_EThread.h index 3b27f709739..7f625451245 100644 --- a/iocore/eventsystem/I_EThread.h +++ b/iocore/eventsystem/I_EThread.h @@ -24,9 +24,9 @@ #pragma once -#include "ts/ink_platform.h" -#include "ts/ink_rand.h" -#include "ts/I_Version.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_rand.h" +#include "tscore/I_Version.h" #include "I_Thread.h" #include "I_PriorityEventQueue.h" #include "I_ProtectedQueue.h" diff --git a/iocore/eventsystem/I_Event.h b/iocore/eventsystem/I_Event.h index e9646366df7..07cce08b568 100644 --- a/iocore/eventsystem/I_Event.h +++ b/iocore/eventsystem/I_Event.h @@ -24,7 +24,7 @@ #pragma once -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #include "I_Action.h" // diff --git a/iocore/eventsystem/I_EventProcessor.h b/iocore/eventsystem/I_EventProcessor.h index c95a97dfe12..28dbd012ba9 100644 --- a/iocore/eventsystem/I_EventProcessor.h +++ b/iocore/eventsystem/I_EventProcessor.h @@ -23,7 +23,7 @@ #pragma once -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #include "I_Continuation.h" #include "I_Processor.h" #include "I_Event.h" diff --git a/iocore/eventsystem/I_EventSystem.h b/iocore/eventsystem/I_EventSystem.h index d4f3967666d..8d51a93bb9b 100644 --- a/iocore/eventsystem/I_EventSystem.h +++ b/iocore/eventsystem/I_EventSystem.h @@ -25,7 +25,7 @@ #pragma once #define _I_EventSystem_h -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #include "I_IOBuffer.h" #include "I_Action.h" @@ -41,7 +41,7 @@ #include "I_Thread.h" #include "I_VIO.h" #include "I_VConnection.h" -#include "I_RecProcess.h" +#include "records/I_RecProcess.h" #include "I_SocketManager.h" #define EVENT_SYSTEM_MODULE_MAJOR_VERSION 1 diff --git a/iocore/eventsystem/I_IOBuffer.h b/iocore/eventsystem/I_IOBuffer.h index 2105d7d1991..ac652e36aab 100644 --- a/iocore/eventsystem/I_IOBuffer.h +++ b/iocore/eventsystem/I_IOBuffer.h @@ -39,12 +39,12 @@ #pragma once #define I_IOBuffer_h -#include "ts/ink_platform.h" -#include "ts/ink_apidefs.h" -#include "ts/Allocator.h" -#include "ts/Ptr.h" -#include "ts/ink_assert.h" -#include "ts/ink_resource.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_apidefs.h" +#include "tscore/Allocator.h" +#include "tscore/Ptr.h" +#include "tscore/ink_assert.h" +#include "tscore/ink_resource.h" struct MIOBufferAccessor; diff --git a/iocore/eventsystem/I_Lock.h b/iocore/eventsystem/I_Lock.h index e97c7f8ff0c..99e72d05908 100644 --- a/iocore/eventsystem/I_Lock.h +++ b/iocore/eventsystem/I_Lock.h @@ -23,8 +23,8 @@ #pragma once -#include "ts/ink_platform.h" -#include "ts/Diags.h" +#include "tscore/ink_platform.h" +#include "tscore/Diags.h" #include "I_Thread.h" #define MAX_LOCK_TIME HRTIME_MSECONDS(200) diff --git a/iocore/eventsystem/I_MIOBufferWriter.h b/iocore/eventsystem/I_MIOBufferWriter.h index ac73f442d7c..639f4615482 100644 --- a/iocore/eventsystem/I_MIOBufferWriter.h +++ b/iocore/eventsystem/I_MIOBufferWriter.h @@ -26,8 +26,8 @@ #include #include -#include -#include +#include "tscore/ink_assert.h" +#include "tscore/BufferWriter.h" #if !defined(UNIT_TEST_BUFFER_WRITER) #include diff --git a/iocore/eventsystem/I_PriorityEventQueue.h b/iocore/eventsystem/I_PriorityEventQueue.h index 1e1c0867e82..4488123f4b1 100644 --- a/iocore/eventsystem/I_PriorityEventQueue.h +++ b/iocore/eventsystem/I_PriorityEventQueue.h @@ -23,7 +23,7 @@ #pragma once -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #include "I_Event.h" // <5ms, 10, 20, 40, 80, 160, 320, 640, 1280, 2560, 5120 diff --git a/iocore/eventsystem/I_Processor.h b/iocore/eventsystem/I_Processor.h index ec497e1dfaf..cce9a01cf64 100644 --- a/iocore/eventsystem/I_Processor.h +++ b/iocore/eventsystem/I_Processor.h @@ -24,7 +24,7 @@ #pragma once -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #define PROCESSOR_RECONFIGURE 0x01 #define PROCESSOR_CHECK 0x02 diff --git a/iocore/eventsystem/I_ProtectedQueue.h b/iocore/eventsystem/I_ProtectedQueue.h index eab2de420b5..7742fac61fb 100644 --- a/iocore/eventsystem/I_ProtectedQueue.h +++ b/iocore/eventsystem/I_ProtectedQueue.h @@ -34,7 +34,7 @@ ****************************************************************************/ #pragma once -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #include "I_Event.h" struct ProtectedQueue { void enqueue(Event *e, bool fast_signal = false); diff --git a/iocore/eventsystem/I_ProxyAllocator.h b/iocore/eventsystem/I_ProxyAllocator.h index fec0ef947d5..4cf8eaeb3cf 100644 --- a/iocore/eventsystem/I_ProxyAllocator.h +++ b/iocore/eventsystem/I_ProxyAllocator.h @@ -30,7 +30,7 @@ *****************************************************************************/ #pragma once -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" class EThread; diff --git a/iocore/eventsystem/I_SocketManager.h b/iocore/eventsystem/I_SocketManager.h index 47ec70c8ebe..2f01f791784 100644 --- a/iocore/eventsystem/I_SocketManager.h +++ b/iocore/eventsystem/I_SocketManager.h @@ -32,7 +32,7 @@ #pragma once -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #include "I_EventSystem.h" #include "I_Thread.h" diff --git a/iocore/eventsystem/I_Thread.h b/iocore/eventsystem/I_Thread.h index b3ba652f31c..5ffea6ecafc 100644 --- a/iocore/eventsystem/I_Thread.h +++ b/iocore/eventsystem/I_Thread.h @@ -64,8 +64,8 @@ #include -#include "ts/ink_platform.h" -#include "ts/ink_thread.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_thread.h" #include "I_ProxyAllocator.h" class ProxyMutex; diff --git a/iocore/eventsystem/I_VConnection.h b/iocore/eventsystem/I_VConnection.h index bec971fbbf1..5c5b083f18d 100644 --- a/iocore/eventsystem/I_VConnection.h +++ b/iocore/eventsystem/I_VConnection.h @@ -24,7 +24,7 @@ #pragma once -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #include "I_EventSystem.h" #if !defined(I_VIO_h) diff --git a/iocore/eventsystem/I_VIO.h b/iocore/eventsystem/I_VIO.h index e688717a0e3..6e7748c6640 100644 --- a/iocore/eventsystem/I_VIO.h +++ b/iocore/eventsystem/I_VIO.h @@ -25,13 +25,13 @@ #pragma once #define I_VIO_h -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #include "I_EventSystem.h" #if !defined(I_IOBuffer_h) #error "include I_IOBuffer.h" ---include I_IOBuffer.h #endif -#include "ts/ink_apidefs.h" +#include "tscore/ink_apidefs.h" class Continuation; class VConnection; class IOVConnection; diff --git a/iocore/eventsystem/Lock.cc b/iocore/eventsystem/Lock.cc index 401532ae16c..2567b39d692 100644 --- a/iocore/eventsystem/Lock.cc +++ b/iocore/eventsystem/Lock.cc @@ -29,7 +29,7 @@ **************************************************************************/ #include "P_EventSystem.h" -#include "ts/Diags.h" +#include "tscore/Diags.h" ClassAllocator mutexAllocator("mutexAllocator"); diff --git a/iocore/eventsystem/Makefile.am b/iocore/eventsystem/Makefile.am index 5e4d95ec0d7..17d0ea95a08 100644 --- a/iocore/eventsystem/Makefile.am +++ b/iocore/eventsystem/Makefile.am @@ -17,8 +17,8 @@ # limitations under the License. AM_CPPFLAGS += \ - -I$(abs_top_srcdir)/lib \ - -I$(abs_top_srcdir)/lib/records \ + -I$(abs_top_srcdir)/include \ + -I$(abs_top_srcdir)/include/records \ $(TS_INCLUDES) TESTS = $(check_PROGRAMS) @@ -92,7 +92,7 @@ test_LD_ADD = \ $(top_builddir)/lib/records/librecords_p.a \ $(top_builddir)/mgmt/libmgmt_p.la \ $(top_builddir)/iocore/eventsystem/libinkevent.a \ - $(top_builddir)/lib/ts/libtsutil.la \ + $(top_builddir)/src/tscore/libtscore.la $(top_builddir)/src/tscpp/util/libtscpputil.la \ $(top_builddir)/proxy/shared/libUglyLogStubs.a \ @LIBTCL@ @HWLOC_LIBS@ @@ -120,7 +120,7 @@ test_Buffer_LDADD = $(test_LD_ADD) test_Event_LDADD = $(test_LD_ADD) -test_MIOBufferWriter_SOURCES = unit-tests/test_MIOBufferWriter.cc +test_MIOBufferWriter_SOURCES = unit_tests/test_MIOBufferWriter.cc test_MIOBufferWriter_CPPFLAGS = $(test_CPP_FLAGS) -I$(abs_top_srcdir)/tests/include test_MIOBufferWriter_LDFLAGS = $(test_LD_FLAGS) diff --git a/iocore/eventsystem/P_EventSystem.h b/iocore/eventsystem/P_EventSystem.h index 972c58921cc..006fa3d95c8 100644 --- a/iocore/eventsystem/P_EventSystem.h +++ b/iocore/eventsystem/P_EventSystem.h @@ -31,7 +31,7 @@ #pragma once #define _P_EventSystem_h -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #include "I_EventSystem.h" diff --git a/iocore/eventsystem/P_Freer.h b/iocore/eventsystem/P_Freer.h index 19b16a99e4c..c620c573d31 100644 --- a/iocore/eventsystem/P_Freer.h +++ b/iocore/eventsystem/P_Freer.h @@ -23,7 +23,7 @@ #pragma once -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #include "I_Tasks.h" // Note that these should not be used for memory that wishes to retain diff --git a/iocore/eventsystem/P_IOBuffer.h b/iocore/eventsystem/P_IOBuffer.h index b348c74459a..0820859f7df 100644 --- a/iocore/eventsystem/P_IOBuffer.h +++ b/iocore/eventsystem/P_IOBuffer.h @@ -23,8 +23,8 @@ #pragma once -#include "ts/ink_platform.h" -#include "ts/ink_resource.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_resource.h" // TODO: I think we're overly aggressive here on making MIOBuffer 64-bit // but not sure it's worthwhile changing anything to 32-bit honestly. diff --git a/iocore/eventsystem/P_UnixEventProcessor.h b/iocore/eventsystem/P_UnixEventProcessor.h index b03a5b265d5..5beac844e9f 100644 --- a/iocore/eventsystem/P_UnixEventProcessor.h +++ b/iocore/eventsystem/P_UnixEventProcessor.h @@ -23,7 +23,7 @@ #pragma once -#include "ts/ink_align.h" +#include "tscore/ink_align.h" #include "I_EventProcessor.h" const int LOAD_BALANCE_INTERVAL = 1; diff --git a/iocore/eventsystem/P_UnixSocketManager.h b/iocore/eventsystem/P_UnixSocketManager.h index 1c9f540ad0c..b90b2b1a13b 100644 --- a/iocore/eventsystem/P_UnixSocketManager.h +++ b/iocore/eventsystem/P_UnixSocketManager.h @@ -31,8 +31,8 @@ ****************************************************************************/ #pragma once -#include "ts/ink_platform.h" -#include "ts/ink_sock.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_sock.h" #include "I_SocketManager.h" // diff --git a/iocore/eventsystem/SocketManager.cc b/iocore/eventsystem/SocketManager.cc index e51aa6951cd..24bc38bc20a 100644 --- a/iocore/eventsystem/SocketManager.cc +++ b/iocore/eventsystem/SocketManager.cc @@ -25,11 +25,11 @@ SocketManager.cc ****************************************************************************/ -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #include "P_EventSystem.h" -#include "ts/TextBuffer.h" -#include "ts/TestBox.h" +#include "tscore/TextBuffer.h" +#include "tscore/TestBox.h" SocketManager socketManager; diff --git a/iocore/eventsystem/Thread.cc b/iocore/eventsystem/Thread.cc index 131426d377c..eb063225555 100644 --- a/iocore/eventsystem/Thread.cc +++ b/iocore/eventsystem/Thread.cc @@ -29,7 +29,7 @@ **************************************************************************/ #include "P_EventSystem.h" -#include "ts/ink_string.h" +#include "tscore/ink_string.h" /////////////////////////////////////////////// // Common Interface impl // diff --git a/iocore/eventsystem/UnixEventProcessor.cc b/iocore/eventsystem/UnixEventProcessor.cc index af38b8a541a..894f2e583c6 100644 --- a/iocore/eventsystem/UnixEventProcessor.cc +++ b/iocore/eventsystem/UnixEventProcessor.cc @@ -29,8 +29,8 @@ #endif #include #endif -#include "ts/ink_defs.h" -#include "ts/hugepages.h" +#include "tscore/ink_defs.h" +#include "tscore/hugepages.h" /// Global singleton. class EventProcessor eventProcessor; diff --git a/iocore/eventsystem/test_Buffer.cc b/iocore/eventsystem/test_Buffer.cc index c14a228ee0a..3e31a496fd3 100644 --- a/iocore/eventsystem/test_Buffer.cc +++ b/iocore/eventsystem/test_Buffer.cc @@ -22,8 +22,8 @@ */ #include "I_EventSystem.h" -#include "ts/I_Layout.h" -#include "ts/ink_string.h" +#include "tscore/I_Layout.h" +#include "tscore/ink_string.h" #include "diags.i" diff --git a/iocore/eventsystem/test_Event.cc b/iocore/eventsystem/test_Event.cc index 2a0a3430d40..6f52da1c47a 100644 --- a/iocore/eventsystem/test_Event.cc +++ b/iocore/eventsystem/test_Event.cc @@ -22,7 +22,7 @@ */ #include "I_EventSystem.h" -#include "ts/I_Layout.h" +#include "tscore/I_Layout.h" #include "diags.i" diff --git a/iocore/eventsystem/unit-tests/test_MIOBufferWriter.cc b/iocore/eventsystem/unit_tests/test_MIOBufferWriter.cc similarity index 97% rename from iocore/eventsystem/unit-tests/test_MIOBufferWriter.cc rename to iocore/eventsystem/unit_tests/test_MIOBufferWriter.cc index 7a15e0b0b48..fd78899e702 100644 --- a/iocore/eventsystem/unit-tests/test_MIOBufferWriter.cc +++ b/iocore/eventsystem/unit_tests/test_MIOBufferWriter.cc @@ -28,8 +28,8 @@ #include #include "I_EventSystem.h" -#include "ts/I_Layout.h" -//#include "ts/ink_string.h" +#include "tscore/I_Layout.h" +//#include "tscore/ink_string.h" #include "diags.i" #include "I_MIOBufferWriter.h" diff --git a/iocore/hostdb/HostDB.cc b/iocore/hostdb/HostDB.cc index 2726e7c9612..db1139e28c8 100644 --- a/iocore/hostdb/HostDB.cc +++ b/iocore/hostdb/HostDB.cc @@ -23,10 +23,10 @@ #include "P_HostDB.h" #include "P_RefCountCacheSerializer.h" -#include "ts/I_Layout.h" +#include "tscore/I_Layout.h" #include "Show.h" -#include "ts/Tokenizer.h" -#include "ts/ink_apidefs.h" +#include "tscore/Tokenizer.h" +#include "tscore/ink_apidefs.h" #include #include diff --git a/iocore/hostdb/I_HostDBProcessor.h b/iocore/hostdb/I_HostDBProcessor.h index b2dc76810bd..3c4c64263cd 100644 --- a/iocore/hostdb/I_HostDBProcessor.h +++ b/iocore/hostdb/I_HostDBProcessor.h @@ -23,11 +23,11 @@ #pragma once -#include "ts/HashFNV.h" -#include "ts/ink_time.h" -#include "ts/CryptoHash.h" -#include "ts/ink_align.h" -#include "ts/ink_resolver.h" +#include "tscore/HashFNV.h" +#include "tscore/ink_time.h" +#include "tscore/CryptoHash.h" +#include "tscore/ink_align.h" +#include "tscore/ink_resolver.h" #include "I_EventSystem.h" #include "SRV.h" #include "P_RefCountCache.h" diff --git a/iocore/hostdb/Makefile.am b/iocore/hostdb/Makefile.am index e4a453a669e..3b0e9103e47 100644 --- a/iocore/hostdb/Makefile.am +++ b/iocore/hostdb/Makefile.am @@ -18,8 +18,8 @@ AM_CPPFLAGS += \ $(iocore_include_dirs) \ - -I$(abs_top_srcdir)/lib \ - -I$(abs_top_srcdir)/lib/records \ + -I$(abs_top_srcdir)/include \ + -I$(abs_top_srcdir)/include/records \ -I$(abs_top_srcdir)/proxy \ -I$(abs_top_srcdir)/proxy/hdrs \ -I$(abs_top_srcdir)/proxy/http \ @@ -71,7 +71,8 @@ test_LD_ADD = \ $(top_builddir)/lib/records/librecords_p.a \ $(top_builddir)/mgmt/libmgmt_p.la \ $(top_builddir)/iocore/eventsystem/libinkevent.a \ - $(top_builddir)/lib/ts/libtsutil.la \ + $(top_builddir)/src/tscore/libtscore.la \ + $(top_builddir)/src/tscpp/util/libtscpputil.la \ $(top_builddir)/proxy/shared/libUglyLogStubs.a \ @LIBTCL@ @HWLOC_LIBS@ diff --git a/iocore/hostdb/P_HostDB.h b/iocore/hostdb/P_HostDB.h index bc3f481a1c3..0e7e281e3fa 100644 --- a/iocore/hostdb/P_HostDB.h +++ b/iocore/hostdb/P_HostDB.h @@ -30,7 +30,7 @@ #pragma once -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #ifdef SPLIT_DNS #include "P_SplitDNS.h" diff --git a/iocore/hostdb/P_HostDBProcessor.h b/iocore/hostdb/P_HostDBProcessor.h index 1acc9cd9092..15d1c47f704 100644 --- a/iocore/hostdb/P_HostDBProcessor.h +++ b/iocore/hostdb/P_HostDBProcessor.h @@ -28,7 +28,7 @@ #pragma once #include "I_HostDBProcessor.h" -#include +#include "tscore/TsBuffer.h" // // Data diff --git a/iocore/hostdb/P_RefCountCache.h b/iocore/hostdb/P_RefCountCache.h index 34686b3cdd9..f876897c033 100644 --- a/iocore/hostdb/P_RefCountCache.h +++ b/iocore/hostdb/P_RefCountCache.h @@ -25,13 +25,13 @@ #include #include // TODO: less? just need ET_TASK -#include -#include +#include "tscore/Map.h" +#include "tscore/PriorityQueue.h" -#include -#include +#include "tscore/List.h" +#include "tscore/ink_hrtime.h" -#include +#include "tscore/I_Version.h" #include #define REFCOUNT_CACHE_EVENT_SYNC REFCOUNT_CACHE_EVENT_EVENTS_START diff --git a/iocore/hostdb/test_RefCountCache.cc b/iocore/hostdb/test_RefCountCache.cc index a709690999a..b02ac604822 100644 --- a/iocore/hostdb/test_RefCountCache.cc +++ b/iocore/hostdb/test_RefCountCache.cc @@ -24,7 +24,7 @@ #include #include #include -#include +#include "tscore/I_Layout.h" #include #include diff --git a/iocore/net/BIO_fastopen.cc b/iocore/net/BIO_fastopen.cc index c471b5b7db2..78af8fab3c7 100644 --- a/iocore/net/BIO_fastopen.cc +++ b/iocore/net/BIO_fastopen.cc @@ -23,7 +23,7 @@ #include "P_Net.h" #include "I_SocketManager.h" -#include "ts/ink_assert.h" +#include "tscore/ink_assert.h" #include "BIO_fastopen.h" diff --git a/iocore/net/Connection.cc b/iocore/net/Connection.cc index 9d8e136c14b..1595bb9791a 100644 --- a/iocore/net/Connection.cc +++ b/iocore/net/Connection.cc @@ -27,7 +27,7 @@ Commonality across all platforms -- move out as required. **************************************************************************/ -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #include "P_Net.h" diff --git a/iocore/net/I_Net.h b/iocore/net/I_Net.h index ef122b86062..29cf0cb8a74 100644 --- a/iocore/net/I_Net.h +++ b/iocore/net/I_Net.h @@ -40,7 +40,7 @@ */ #pragma once -#include "ts/I_Version.h" +#include "tscore/I_Version.h" #include "I_EventSystem.h" #include diff --git a/iocore/net/I_NetProcessor.h b/iocore/net/I_NetProcessor.h index 031b96aa8d3..03934ec61d6 100644 --- a/iocore/net/I_NetProcessor.h +++ b/iocore/net/I_NetProcessor.h @@ -24,7 +24,7 @@ #pragma once -#include "ts/IpMap.h" +#include "tscore/IpMap.h" #include "I_EventSystem.h" #include "I_Socks.h" struct socks_conf_struct; diff --git a/iocore/net/I_NetVConnection.h b/iocore/net/I_NetVConnection.h index e00a3457f34..e0819039ba4 100644 --- a/iocore/net/I_NetVConnection.h +++ b/iocore/net/I_NetVConnection.h @@ -24,17 +24,17 @@ #pragma once -#include "ts/ink_inet.h" +#include "tscore/ink_inet.h" #include "I_Action.h" #include "I_VConnection.h" #include "I_Event.h" -#include "ts/List.h" +#include "tscore/List.h" #include "I_IOBuffer.h" #include "I_Socks.h" -#include +#include "ts/apidefs.h" #include -#include "ts/TextView.h" -#include "ts/IpMap.h" +#include "tscpp/util/TextView.h" +#include "tscore/IpMap.h" #define CONNECT_SUCCESS 1 #define CONNECT_FAILURE 0 diff --git a/iocore/net/I_UDPNet.h b/iocore/net/I_UDPNet.h index ff890334961..9e4667dc38c 100644 --- a/iocore/net/I_UDPNet.h +++ b/iocore/net/I_UDPNet.h @@ -31,9 +31,9 @@ #pragma once -#include "ts/I_Version.h" +#include "tscore/I_Version.h" #include "I_EventSystem.h" -#include "ts/ink_inet.h" +#include "tscore/ink_inet.h" /** UDP service diff --git a/iocore/net/Makefile.am b/iocore/net/Makefile.am index f8e6e0bb1ad..82d03effa3d 100644 --- a/iocore/net/Makefile.am +++ b/iocore/net/Makefile.am @@ -18,8 +18,8 @@ AM_CPPFLAGS += \ $(iocore_include_dirs) \ - -I$(abs_top_srcdir)/lib \ - -I$(abs_top_srcdir)/lib/records \ + -I$(abs_top_srcdir)/include \ + -I$(abs_top_srcdir)/include/records \ -I$(abs_top_srcdir)/proxy \ -I$(abs_top_srcdir)/proxy/hdrs \ -I$(abs_top_srcdir)/proxy/shared \ @@ -47,7 +47,7 @@ test_certlookup_SOURCES = \ test_certlookup_LDADD = \ @OPENSSL_LIBS@ \ - $(top_builddir)/lib/ts/libtsutil.la \ + $(top_builddir)/src/tscore/libtscore.la $(top_builddir)/src/tscpp/util/libtscpputil.la \ $(top_builddir)/iocore/eventsystem/libinkevent.a \ $(top_builddir)/proxy/ParentSelectionStrategy.o \ @YAMLCPP_LIBS@ @@ -73,7 +73,7 @@ test_UDPNet_LDADD = \ $(top_builddir)/iocore/eventsystem/libinkevent.a \ $(top_builddir)/mgmt/libmgmt_p.la \ $(top_builddir)/lib/records/librecords_p.a \ - $(top_builddir)/lib/ts/libtsutil.la \ + $(top_builddir)/src/tscore/libtscore.la $(top_builddir)/src/tscpp/util/libtscpputil.la \ $(top_builddir)/proxy/ParentSelectionStrategy.o \ $(top_builddir)/lib/tsconfig/libtsconfig.la \ @LIBTCL@ @HWLOC_LIBS@ @OPENSSL_LIBS@ @YAMLCPP_LIBS@ diff --git a/iocore/net/P_Connection.h b/iocore/net/P_Connection.h index ba826f0d588..f7d4d687515 100644 --- a/iocore/net/P_Connection.h +++ b/iocore/net/P_Connection.h @@ -49,7 +49,7 @@ #pragma once -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" struct NetVCOptions; diff --git a/iocore/net/P_Net.h b/iocore/net/P_Net.h index c237b7ee126..c59250be3b9 100644 --- a/iocore/net/P_Net.h +++ b/iocore/net/P_Net.h @@ -91,7 +91,7 @@ extern RecRawStatBlock *net_rsb; #define NET_SUM_GLOBAL_DYN_STAT(_x, _r) RecIncrGlobalRawStatSum(net_rsb, (_x), (_r)) #define NET_READ_GLOBAL_DYN_SUM(_x, _sum) RecGetGlobalRawStatSum(net_rsb, _x, &_sum) -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #include "P_EventSystem.h" #include "I_Net.h" #include "P_NetVConnection.h" diff --git a/iocore/net/P_NetAccept.h b/iocore/net/P_NetAccept.h index 151753b5ce3..a2338bc355c 100644 --- a/iocore/net/P_NetAccept.h +++ b/iocore/net/P_NetAccept.h @@ -39,7 +39,7 @@ #pragma once #include -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #include "P_Connection.h" struct NetAccept; diff --git a/iocore/net/P_NetVCTest.h b/iocore/net/P_NetVCTest.h index 3e73599ecd5..99c26be715e 100644 --- a/iocore/net/P_NetVCTest.h +++ b/iocore/net/P_NetVCTest.h @@ -36,7 +36,7 @@ #pragma once -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" class VIO; class MIOBuffer; diff --git a/iocore/net/P_OCSPStapling.h b/iocore/net/P_OCSPStapling.h index fc303c90c99..e3d5a6f63dc 100644 --- a/iocore/net/P_OCSPStapling.h +++ b/iocore/net/P_OCSPStapling.h @@ -21,7 +21,7 @@ #pragma once -#include "ts/ink_config.h" +#include "tscore/ink_config.h" #if TS_USE_TLS_OCSP #include diff --git a/iocore/net/P_SNIActionPerformer.h b/iocore/net/P_SNIActionPerformer.h index c40091e4190..c8fce5dd647 100644 --- a/iocore/net/P_SNIActionPerformer.h +++ b/iocore/net/P_SNIActionPerformer.h @@ -31,11 +31,11 @@ #pragma once #include "I_EventSystem.h" -#include "ts/Map.h" +#include "tscore/Map.h" //#include"P_UnixNetProcessor.h" #include #include "P_SSLNextProtocolAccept.h" -#include "ts/ink_inet.h" +#include "tscore/ink_inet.h" extern Map snpsMap; // enum of all the actions diff --git a/iocore/net/P_SSLClientUtils.h b/iocore/net/P_SSLClientUtils.h index 84d17d90f18..ff997333ca0 100644 --- a/iocore/net/P_SSLClientUtils.h +++ b/iocore/net/P_SSLClientUtils.h @@ -21,8 +21,8 @@ #pragma once -#include "ts/ink_config.h" -#include "ts/Diags.h" +#include "tscore/ink_config.h" +#include "tscore/Diags.h" #include "P_SSLUtils.h" #include "P_SSLConfig.h" diff --git a/iocore/net/P_SSLConfig.h b/iocore/net/P_SSLConfig.h index 9fbb07ec080..c91f2f85047 100644 --- a/iocore/net/P_SSLConfig.h +++ b/iocore/net/P_SSLConfig.h @@ -32,10 +32,10 @@ #include "ProxyConfig.h" #include "SSLSessionCache.h" -#include "ts/ink_inet.h" +#include "tscore/ink_inet.h" #include #include "P_SSLCertLookup.h" -#include +#include "tscore/IpMap.h" struct SSLCertLookup; struct ssl_ticket_key_block; diff --git a/iocore/net/P_SSLNetAccept.h b/iocore/net/P_SSLNetAccept.h index ea10c2f98cd..3a2b8b5fa49 100644 --- a/iocore/net/P_SSLNetAccept.h +++ b/iocore/net/P_SSLNetAccept.h @@ -38,7 +38,7 @@ ****************************************************************************/ #pragma once -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #include "P_Connection.h" #include "P_NetAccept.h" diff --git a/iocore/net/P_SSLNetProcessor.h b/iocore/net/P_SSLNetProcessor.h index 9837f61dff2..b90266bfce9 100644 --- a/iocore/net/P_SSLNetProcessor.h +++ b/iocore/net/P_SSLNetProcessor.h @@ -38,11 +38,11 @@ #pragma once -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #include "P_Net.h" #include "P_SSLConfig.h" #include -#include "ts/Map.h" +#include "tscore/Map.h" class UnixNetVConnection; struct NetAccept; diff --git a/iocore/net/P_SSLNetVConnection.h b/iocore/net/P_SSLNetVConnection.h index b3b22c444d8..66505fd799e 100644 --- a/iocore/net/P_SSLNetVConnection.h +++ b/iocore/net/P_SSLNetVConnection.h @@ -31,8 +31,8 @@ ****************************************************************************/ #pragma once -#include -#include +#include "tscore/ink_platform.h" +#include "ts/apidefs.h" #include #include diff --git a/iocore/net/P_SSLNextProtocolSet.h b/iocore/net/P_SSLNextProtocolSet.h index c12aaa1fe19..067690666e6 100644 --- a/iocore/net/P_SSLNextProtocolSet.h +++ b/iocore/net/P_SSLNextProtocolSet.h @@ -23,7 +23,7 @@ #pragma once -#include "ts/List.h" +#include "tscore/List.h" #include "I_Net.h" class Continuation; diff --git a/iocore/net/P_SSLSNI.h b/iocore/net/P_SSLSNI.h index 06b7f2f5e7d..fc4ed030b01 100644 --- a/iocore/net/P_SSLSNI.h +++ b/iocore/net/P_SSLSNI.h @@ -31,9 +31,9 @@ #pragma once #include "ProxyConfig.h" -#include "ts/Map.h" +#include "tscore/Map.h" #include "P_SNIActionPerformer.h" -#include "ts/MatcherUtils.h" +#include "tscore/MatcherUtils.h" #include "openssl/ossl_typ.h" #include #include diff --git a/iocore/net/P_SSLUtils.h b/iocore/net/P_SSLUtils.h index 9f21fe240cf..4f829d11ab0 100644 --- a/iocore/net/P_SSLUtils.h +++ b/iocore/net/P_SSLUtils.h @@ -21,8 +21,8 @@ #pragma once -#include "ts/ink_config.h" -#include "ts/Diags.h" +#include "tscore/ink_config.h" +#include "tscore/Diags.h" #include "P_SSLClientUtils.h" #define OPENSSL_THREAD_DEFINES diff --git a/iocore/net/P_Socks.h b/iocore/net/P_Socks.h index 90dfd0afa65..aba0a0b867b 100644 --- a/iocore/net/P_Socks.h +++ b/iocore/net/P_Socks.h @@ -27,7 +27,7 @@ #ifdef SOCKS_WITH_TS #include "ParentSelection.h" -#include +#include "tscore/IpMap.h" #endif enum { diff --git a/iocore/net/P_UDPNet.h b/iocore/net/P_UDPNet.h index 1c8131c1cf6..8d803a022ad 100644 --- a/iocore/net/P_UDPNet.h +++ b/iocore/net/P_UDPNet.h @@ -30,7 +30,7 @@ #pragma once -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #include "I_UDPNet.h" #include "P_UDPPacket.h" diff --git a/iocore/net/P_UnixNet.h b/iocore/net/P_UnixNet.h index c981e2669c9..0440b7238dc 100644 --- a/iocore/net/P_UnixNet.h +++ b/iocore/net/P_UnixNet.h @@ -25,7 +25,7 @@ #include -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #define USE_EDGE_TRIGGER_EPOLL 1 #define USE_EDGE_TRIGGER_KQUEUE 1 diff --git a/iocore/net/P_UnixNetState.h b/iocore/net/P_UnixNetState.h index 9b2656c6e7c..10cbf4c75e7 100644 --- a/iocore/net/P_UnixNetState.h +++ b/iocore/net/P_UnixNetState.h @@ -36,7 +36,7 @@ ****************************************************************************/ #pragma once -#include "ts/List.h" +#include "tscore/List.h" #include "I_VIO.h" class Event; diff --git a/iocore/net/P_UnixNetVConnection.h b/iocore/net/P_UnixNetVConnection.h index b3d82f33de4..67e99c1a248 100644 --- a/iocore/net/P_UnixNetVConnection.h +++ b/iocore/net/P_UnixNetVConnection.h @@ -31,7 +31,7 @@ #pragma once -#include "ts/ink_sock.h" +#include "tscore/ink_sock.h" #include "I_NetVConnection.h" #include "P_UnixNetState.h" #include "P_Connection.h" diff --git a/iocore/net/P_UnixPollDescriptor.h b/iocore/net/P_UnixPollDescriptor.h index 51706d0840f..f377cbdcf48 100644 --- a/iocore/net/P_UnixPollDescriptor.h +++ b/iocore/net/P_UnixPollDescriptor.h @@ -29,7 +29,7 @@ *****************************************************************************/ #pragma once -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #if TS_USE_KQUEUE #include diff --git a/iocore/net/ProxyProtocol.cc b/iocore/net/ProxyProtocol.cc index c63ccf9becd..83c3bcf9dfe 100644 --- a/iocore/net/ProxyProtocol.cc +++ b/iocore/net/ProxyProtocol.cc @@ -21,8 +21,8 @@ * limitations under the License. */ -#include "ts/ink_assert.h" -#include "ts/TextView.h" +#include "tscore/ink_assert.h" +#include "tscpp/util/TextView.h" #include "ProxyProtocol.h" #include "I_NetVConnection.h" diff --git a/iocore/net/ProxyProtocol.h b/iocore/net/ProxyProtocol.h index 60395cee7b7..f6f78f42541 100644 --- a/iocore/net/ProxyProtocol.h +++ b/iocore/net/ProxyProtocol.h @@ -26,10 +26,10 @@ #ifndef ProxyProtocol_H_ #define ProxyProtocol_H_ -#include "ts/ink_defs.h" -#include "ts/ink_memory.h" -#include -#include +#include "tscore/ink_defs.h" +#include "tscore/ink_memory.h" +#include "tscore/ink_resolver.h" +#include "tscore/ink_platform.h" #include "I_VConnection.h" #include "I_NetVConnection.h" #include "I_IOBuffer.h" diff --git a/iocore/net/SNIActionPerformer.cc b/iocore/net/SNIActionPerformer.cc index 05610964bc8..d381e061009 100644 --- a/iocore/net/SNIActionPerformer.cc +++ b/iocore/net/SNIActionPerformer.cc @@ -29,7 +29,7 @@ SNI based Configuration in ATS ****************************************************************************/ #include "P_SNIActionPerformer.h" -#include "ts/ink_memory.h" +#include "tscore/ink_memory.h" #include "P_SSLSNI.h" #include "P_Net.h" #include "P_SSLNextProtocolAccept.h" diff --git a/iocore/net/SSLCertLookup.cc b/iocore/net/SSLCertLookup.cc index 06c29a0136f..5cf5ca199fa 100644 --- a/iocore/net/SSLCertLookup.cc +++ b/iocore/net/SSLCertLookup.cc @@ -21,17 +21,17 @@ limitations under the License. */ -#include "ts/ink_config.h" +#include "tscore/ink_config.h" #include "P_SSLCertLookup.h" #include "P_SSLUtils.h" #include "P_SSLConfig.h" #include "I_EventSystem.h" -#include "ts/I_Layout.h" -#include "ts/MatcherUtils.h" -#include "ts/Regex.h" -#include "ts/Trie.h" -#include "ts/TestBox.h" +#include "tscore/I_Layout.h" +#include "tscore/MatcherUtils.h" +#include "tscore/Regex.h" +#include "tscore/Trie.h" +#include "tscore/TestBox.h" // Check if the ticket_key callback #define is available, and if so, enable session tickets. #ifdef SSL_CTX_set_tlsext_ticket_key_cb diff --git a/iocore/net/SSLClientUtils.cc b/iocore/net/SSLClientUtils.cc index bb478df7391..ea0788171c0 100644 --- a/iocore/net/SSLClientUtils.cc +++ b/iocore/net/SSLClientUtils.cc @@ -19,10 +19,10 @@ limitations under the License. */ -#include "ts/ink_config.h" +#include "tscore/ink_config.h" #include "records/I_RecHttp.h" -#include "ts/ink_platform.h" -#include "ts/X509HostnameValidator.h" +#include "tscore/ink_platform.h" +#include "tscore/X509HostnameValidator.h" #include "P_Net.h" #include "P_SSLClientUtils.h" diff --git a/iocore/net/SSLConfig.cc b/iocore/net/SSLConfig.cc index 9cb6bb242b3..f55e9ccafea 100644 --- a/iocore/net/SSLConfig.cc +++ b/iocore/net/SSLConfig.cc @@ -29,8 +29,8 @@ SSL Configurations ****************************************************************************/ -#include "ts/ink_platform.h" -#include "ts/I_Layout.h" +#include "tscore/ink_platform.h" +#include "tscore/I_Layout.h" #include #include diff --git a/iocore/net/SSLDynlock.cc b/iocore/net/SSLDynlock.cc index 5c8763717d1..720a3673bea 100644 --- a/iocore/net/SSLDynlock.cc +++ b/iocore/net/SSLDynlock.cc @@ -21,10 +21,10 @@ #include -#include "ts/ink_platform.h" -#include "ts/ink_mutex.h" -#include "ts/ink_assert.h" -#include "ts/Diags.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_mutex.h" +#include "tscore/ink_assert.h" +#include "tscore/Diags.h" struct CRYPTO_dynlock_value { CRYPTO_dynlock_value(const char *f, int l) : file(f), line(l) { ink_mutex_init(&mutex); } diff --git a/iocore/net/SSLInternal.cc b/iocore/net/SSLInternal.cc index 196c38b96bd..7e9b475b57b 100644 --- a/iocore/net/SSLInternal.cc +++ b/iocore/net/SSLInternal.cc @@ -21,7 +21,7 @@ See the License for the specific language governing permissions and limitations under the License. */ -#include "ts/ink_config.h" +#include "tscore/ink_config.h" #if TS_USE_SET_RBIO // No need to do anything, this version of openssl provides the SSL_set0_rbio function #else diff --git a/iocore/net/SSLNetAccept.cc b/iocore/net/SSLNetAccept.cc index 61700cbf6e1..b5f8e43acc4 100644 --- a/iocore/net/SSLNetAccept.cc +++ b/iocore/net/SSLNetAccept.cc @@ -19,7 +19,7 @@ limitations under the License. */ -#include "ts/ink_config.h" +#include "tscore/ink_config.h" #include "P_Net.h" SSLNetAccept::SSLNetAccept(const NetProcessor::AcceptOptions &opt) : NetAccept(opt) {} diff --git a/iocore/net/SSLNetProcessor.cc b/iocore/net/SSLNetProcessor.cc index c56c1d9fe4e..a79fd0fe667 100644 --- a/iocore/net/SSLNetProcessor.cc +++ b/iocore/net/SSLNetProcessor.cc @@ -19,11 +19,11 @@ limitations under the License. */ -#include "ts/ink_config.h" +#include "tscore/ink_config.h" #include "P_Net.h" -#include "ts/I_Layout.h" -#include "I_RecHttp.h" +#include "tscore/I_Layout.h" +#include "records/I_RecHttp.h" #include "P_SSLUtils.h" #include "P_OCSPStapling.h" #include "P_SSLSNI.h" diff --git a/iocore/net/SSLNetVConnection.cc b/iocore/net/SSLNetVConnection.cc index f6944a44fc2..f9500c12eca 100644 --- a/iocore/net/SSLNetVConnection.cc +++ b/iocore/net/SSLNetVConnection.cc @@ -20,8 +20,8 @@ See the License for the specific language governing permissions and limitations under the License. */ -#include "ts/ink_config.h" -#include "ts/EventNotify.h" +#include "tscore/ink_config.h" +#include "tscore/EventNotify.h" #include "records/I_RecHttp.h" #include "P_Net.h" #include "P_SSLNextProtocolSet.h" diff --git a/iocore/net/SSLNextProtocolSet.cc b/iocore/net/SSLNextProtocolSet.cc index 0ee4a1d752a..6c9d4df6a44 100644 --- a/iocore/net/SSLNextProtocolSet.cc +++ b/iocore/net/SSLNextProtocolSet.cc @@ -21,9 +21,9 @@ limitations under the License. */ -#include "ts/ink_config.h" +#include "tscore/ink_config.h" #include "ts/apidefs.h" -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #include "P_SSLNextProtocolSet.h" // For currently defined protocol strings, see diff --git a/iocore/net/SSLSNIConfig.cc b/iocore/net/SSLSNIConfig.cc index 1dd50369454..7366eff7bde 100644 --- a/iocore/net/SSLSNIConfig.cc +++ b/iocore/net/SSLSNIConfig.cc @@ -30,11 +30,11 @@ ****************************************************************************/ #include "P_SSLSNI.h" -#include "ts/Diags.h" -#include "ts/SimpleTokenizer.h" +#include "tscore/Diags.h" +#include "tscore/SimpleTokenizer.h" #include "P_SSLConfig.h" -#include "ts/ink_memory.h" -#include +#include "tscore/ink_memory.h" +#include "tscpp/util/TextView.h" static ConfigUpdateHandler *sniConfigUpdate; struct NetAccept; diff --git a/iocore/net/SSLSessionCache.h b/iocore/net/SSLSessionCache.h index 8443da7ee7e..548359bc92f 100644 --- a/iocore/net/SSLSessionCache.h +++ b/iocore/net/SSLSessionCache.h @@ -21,12 +21,12 @@ #pragma once -#include "ts/Map.h" -#include "ts/List.h" -#include "ts/ink_mutex.h" +#include "tscore/Map.h" +#include "tscore/List.h" +#include "tscore/ink_mutex.h" #include "P_EventSystem.h" -#include "I_RecProcess.h" -#include "ts/ink_platform.h" +#include "records/I_RecProcess.h" +#include "tscore/ink_platform.h" #include "P_SSLUtils.h" #include "ts/apidefs.h" #include diff --git a/iocore/net/SSLUtils.cc b/iocore/net/SSLUtils.cc index 562e8264288..60b462a69fc 100644 --- a/iocore/net/SSLUtils.cc +++ b/iocore/net/SSLUtils.cc @@ -19,13 +19,13 @@ limitations under the License. */ -#include "ts/ink_platform.h" -#include "ts/SimpleTokenizer.h" +#include "tscore/ink_platform.h" +#include "tscore/SimpleTokenizer.h" #include "records/I_RecHttp.h" -#include "ts/I_Layout.h" +#include "tscore/I_Layout.h" #include "P_Net.h" -#include "ts/ink_cap.h" -#include "ts/ink_mutex.h" +#include "tscore/ink_cap.h" +#include "tscore/ink_mutex.h" #include "P_OCSPStapling.h" #include "SSLSessionCache.h" #include "InkAPIInternal.h" diff --git a/iocore/net/Socks.cc b/iocore/net/Socks.cc index 33ff5b268a1..e1915f2dc95 100644 --- a/iocore/net/Socks.cc +++ b/iocore/net/Socks.cc @@ -31,10 +31,10 @@ */ #include "P_Net.h" -#include "ts/I_Layout.h" -#include "ts/ink_sock.h" -#include "ts/InkErrno.h" -#include +#include "tscore/I_Layout.h" +#include "tscore/ink_sock.h" +#include "tscore/InkErrno.h" +#include "tscore/IpMapConf.h" socks_conf_struct *g_socks_conf_stuff = nullptr; diff --git a/iocore/net/UnixNetPages.cc b/iocore/net/UnixNetPages.cc index 72cf0713b81..34a35202b2a 100644 --- a/iocore/net/UnixNetPages.cc +++ b/iocore/net/UnixNetPages.cc @@ -21,7 +21,7 @@ limitations under the License. */ -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #include "P_Net.h" #include "Show.h" #include "I_Tasks.h" diff --git a/iocore/net/UnixNetProcessor.cc b/iocore/net/UnixNetProcessor.cc index 07d58e16d40..589c843eaa0 100644 --- a/iocore/net/UnixNetProcessor.cc +++ b/iocore/net/UnixNetProcessor.cc @@ -22,8 +22,8 @@ */ #include "P_Net.h" -#include "ts/InkErrno.h" -#include "ts/ink_sock.h" +#include "tscore/InkErrno.h" +#include "tscore/ink_sock.h" #include "P_SSLNextProtocolAccept.h" // For Stat Pages diff --git a/iocore/net/UnixNetVConnection.cc b/iocore/net/UnixNetVConnection.cc index 3b12995ed4e..2fd30a76b9b 100644 --- a/iocore/net/UnixNetVConnection.cc +++ b/iocore/net/UnixNetVConnection.cc @@ -22,8 +22,8 @@ */ #include "P_Net.h" -#include "ts/ink_platform.h" -#include "ts/InkErrno.h" +#include "tscore/ink_platform.h" +#include "tscore/InkErrno.h" #include "Log.h" #include diff --git a/iocore/net/YamlSNIConfig.cc b/iocore/net/YamlSNIConfig.cc index da53fe22a1a..6f31777e4d5 100644 --- a/iocore/net/YamlSNIConfig.cc +++ b/iocore/net/YamlSNIConfig.cc @@ -27,8 +27,8 @@ #include -#include "ts/Diags.h" -#include "ts/EnumDescriptor.h" +#include "tscore/Diags.h" +#include "tscore/EnumDescriptor.h" #include "tsconfig/Errata.h" ts::Errata diff --git a/iocore/net/test_I_UDPNet.cc b/iocore/net/test_I_UDPNet.cc index 672c9d065d4..355a917b276 100644 --- a/iocore/net/test_I_UDPNet.cc +++ b/iocore/net/test_I_UDPNet.cc @@ -25,8 +25,8 @@ #include #include -#include "ts/I_Layout.h" -#include "ts/TestBox.h" +#include "tscore/I_Layout.h" +#include "tscore/TestBox.h" #include "I_EventSystem.h" #include "I_Net.h" diff --git a/iocore/net/test_certlookup.cc b/iocore/net/test_certlookup.cc index d5930817481..31913b6593f 100644 --- a/iocore/net/test_certlookup.cc +++ b/iocore/net/test_certlookup.cc @@ -22,7 +22,7 @@ */ #include "P_SSLCertLookup.h" -#include "ts/TestBox.h" +#include "tscore/TestBox.h" #include static IpEndpoint diff --git a/iocore/utils/I_Machine.h b/iocore/utils/I_Machine.h index c6730615201..74bd30033fc 100644 --- a/iocore/utils/I_Machine.h +++ b/iocore/utils/I_Machine.h @@ -31,9 +31,9 @@ #ifndef _I_Machine_h #define _I_Machine_h -#include "ts/ink_inet.h" -#include "ts/ink_uuid.h" -#include "ts/ink_hash_table.h" +#include "tscore/ink_inet.h" +#include "tscore/ink_uuid.h" +#include "tscore/ink_hash_table.h" /** The Machine is a simple place holder for the hostname and the ip diff --git a/iocore/utils/Machine.cc b/iocore/utils/Machine.cc index 6fd8c44b650..0c47d28835b 100644 --- a/iocore/utils/Machine.cc +++ b/iocore/utils/Machine.cc @@ -21,10 +21,10 @@ limitations under the License. */ -#include "ts/ink_platform.h" -#include "ts/ink_inet.h" -#include "ts/ink_assert.h" -#include "ts/Diags.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_inet.h" +#include "tscore/ink_assert.h" +#include "tscore/Diags.h" #include "I_Machine.h" #if HAVE_IFADDRS_H diff --git a/iocore/utils/Makefile.am b/iocore/utils/Makefile.am index b13816d2489..471d3803028 100644 --- a/iocore/utils/Makefile.am +++ b/iocore/utils/Makefile.am @@ -17,8 +17,8 @@ # limitations under the License. AM_CPPFLAGS += \ - -I$(abs_top_srcdir)/lib \ - -I$(abs_top_srcdir)/lib/records \ + -I$(abs_top_srcdir)/include \ + -I$(abs_top_srcdir)/include/records \ -I$(abs_top_srcdir)/iocore/eventsystem \ $(TS_INCLUDES) diff --git a/lib/Makefile.am b/lib/Makefile.am index 42f187a6c19..3db8fd765af 100644 --- a/lib/Makefile.am +++ b/lib/Makefile.am @@ -16,16 +16,12 @@ # See the License for the specific language governing permissions and # limitations under the License. -SUBDIRS = . ts records tsconfig cppapi +SUBDIRS = . records tsconfig if BUILD_PERL_LIB SUBDIRS += perl endif -if BUILD_WCCP -SUBDIRS += wccp -endif - # to prevent Clang Analyzer warning LOCAL = diff --git a/lib/cppapi/Makefile.am b/lib/cppapi/Makefile.am deleted file mode 100644 index 63be22c944a..00000000000 --- a/lib/cppapi/Makefile.am +++ /dev/null @@ -1,84 +0,0 @@ -# -# Licensed to the Apache Software Foundation (ASF) under one -# or more contributor license agreements. See the NOTICE file -# distributed with this work for additional information -# regarding copyright ownership. The ASF licenses this file -# to you under the Apache License, Version 2.0 (the -# "License"); you may not use this file except in compliance -# with the License. You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# 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. - -include $(top_srcdir)/build/plugins.mk - -lib_LTLIBRARIES = libatscppapi.la -libatscppapi_la_LDFLAGS=-lz -lpthread -version-info @TS_LIBTOOL_VERSION@ - -libatscppapi_la_SOURCES = \ - AsyncHttpFetch.cc \ - AsyncTimer.cc \ - CaseInsensitiveStringComparator.cc \ - ClientRequest.cc \ - Continuation.cc \ - GlobalPlugin.cc \ - GzipDeflateTransformation.cc \ - GzipInflateTransformation.cc \ - Headers.cc \ - HttpMethod.cc \ - HttpVersion.cc \ - InterceptPlugin.cc \ - Logger.cc \ - Plugin.cc \ - RemapPlugin.cc \ - Request.cc \ - Response.cc \ - Stat.cc \ - Transaction.cc \ - TransactionPlugin.cc \ - TransformationPlugin.cc \ - Url.cc \ - utils.cc \ - utils_internal.cc - -library_includedir=$(includedir)/atscppapi -base_include_folder = $(top_srcdir)/$(subdir)/include/atscppapi - -library_include_HEADERS = \ - $(base_include_folder)/Async.h \ - $(base_include_folder)/AsyncHttpFetch.h \ - $(base_include_folder)/AsyncTimer.h \ - $(base_include_folder)/CaseInsensitiveStringComparator.h \ - $(base_include_folder)/ClientRequest.h \ - $(base_include_folder)/Continuation.h \ - $(base_include_folder)/GlobalPlugin.h \ - $(base_include_folder)/GzipDeflateTransformation.h \ - $(base_include_folder)/GzipInflateTransformation.h \ - $(base_include_folder)/Headers.h \ - $(base_include_folder)/HttpMethod.h \ - $(base_include_folder)/HttpStatus.h \ - $(base_include_folder)/HttpVersion.h \ - $(base_include_folder)/InterceptPlugin.h \ - $(base_include_folder)/Logger.h \ - $(base_include_folder)/Plugin.h \ - $(base_include_folder)/PluginInit.h \ - $(base_include_folder)/RemapPlugin.h \ - $(base_include_folder)/Request.h \ - $(base_include_folder)/Response.h \ - $(base_include_folder)/Stat.h \ - $(base_include_folder)/Transaction.h \ - $(base_include_folder)/TransactionPlugin.h \ - $(base_include_folder)/TransformationPlugin.h \ - $(base_include_folder)/Url.h \ - $(base_include_folder)/noncopyable.h \ - $(base_include_folder)/utils.h - -include $(top_srcdir)/build/tidy.mk - -clang-tidy-local: $(DIST_SOURCES) - $(CXX_Clang_Tidy) diff --git a/lib/records/I_RecCore.h b/lib/records/I_RecCore.h index b2a6ebacd49..cddde017968 100644 --- a/lib/records/I_RecCore.h +++ b/lib/records/I_RecCore.h @@ -23,7 +23,7 @@ #pragma once -#include "ts/Diags.h" +#include "tscore/Diags.h" #include "I_RecDefs.h" #include "I_RecAlarms.h" diff --git a/lib/records/I_RecDefs.h b/lib/records/I_RecDefs.h index aa7e9ded411..04f5f5e6533 100644 --- a/lib/records/I_RecDefs.h +++ b/lib/records/I_RecDefs.h @@ -23,8 +23,8 @@ #pragma once -#include "ts/ink_mutex.h" -#include "ts/ink_rwlock.h" +#include "tscore/ink_mutex.h" +#include "tscore/ink_rwlock.h" #include "I_RecMutex.h" //------------------------------------------------------------------------- diff --git a/lib/records/I_RecHttp.h b/lib/records/I_RecHttp.h index a216f724a05..df3672e602d 100644 --- a/lib/records/I_RecHttp.h +++ b/lib/records/I_RecHttp.h @@ -23,12 +23,12 @@ #pragma once -#include -#include -#include -#include -#include -#include "ts/IpMap.h" +#include "tscore/ink_inet.h" +#include "tscore/ink_resolver.h" +#include "ts/apidefs.h" +#include "ts/apidefs.h" +#include "tscore/ink_assert.h" +#include "tscore/IpMap.h" #include #include diff --git a/lib/records/I_RecMutex.h b/lib/records/I_RecMutex.h index 68efd3405cd..29f5a3a7c2b 100644 --- a/lib/records/I_RecMutex.h +++ b/lib/records/I_RecMutex.h @@ -23,8 +23,8 @@ #pragma once -#include "ts/ink_mutex.h" -#include "ts/ink_thread.h" +#include "tscore/ink_mutex.h" +#include "tscore/ink_thread.h" /** A wrapper to ink_mutex class. It allows multiple acquire of mutex lock diff --git a/lib/records/Makefile.am b/lib/records/Makefile.am index d87515f9dc0..fb99be22b77 100644 --- a/lib/records/Makefile.am +++ b/lib/records/Makefile.am @@ -24,7 +24,7 @@ AM_CPPFLAGS += \ -I$(abs_top_srcdir)/mgmt \ -I$(abs_top_srcdir)/mgmt/api/include \ -I$(abs_top_srcdir)/mgmt/utils \ - -I$(abs_top_srcdir)/lib \ + -I$(abs_top_srcdir)/include \ $(TS_INCLUDES) noinst_LIBRARIES = librecords_lm.a librecords_p.a diff --git a/lib/records/P_RecCore.cc b/lib/records/P_RecCore.cc index 2fe78c9e912..7307a4d1d82 100644 --- a/lib/records/P_RecCore.cc +++ b/lib/records/P_RecCore.cc @@ -21,13 +21,13 @@ limitations under the License. */ -#include "ts/ink_platform.h" -#include "ts/ink_memory.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_memory.h" -#include "ts/TextBuffer.h" -#include "ts/Tokenizer.h" -#include "ts/ink_defs.h" -#include "ts/ink_string.h" +#include "tscore/TextBuffer.h" +#include "tscore/Tokenizer.h" +#include "tscore/ink_defs.h" +#include "tscore/ink_string.h" #include "P_RecFile.h" #include "P_RecUtils.h" diff --git a/lib/records/P_RecCore.h b/lib/records/P_RecCore.h index 6ece225b65b..60f640631b0 100644 --- a/lib/records/P_RecCore.h +++ b/lib/records/P_RecCore.h @@ -23,11 +23,11 @@ #pragma once -#include "ts/ink_thread.h" -#include "ts/ink_hash_table.h" -#include "ts/ink_llqueue.h" -#include "ts/ink_rwlock.h" -#include "ts/TextBuffer.h" +#include "tscore/ink_thread.h" +#include "tscore/ink_hash_table.h" +#include "tscore/ink_llqueue.h" +#include "tscore/ink_rwlock.h" +#include "tscore/TextBuffer.h" #include "I_RecCore.h" #include "P_RecDefs.h" diff --git a/lib/records/P_RecUtils.h b/lib/records/P_RecUtils.h index c810144d667..7da594bda5b 100644 --- a/lib/records/P_RecUtils.h +++ b/lib/records/P_RecUtils.h @@ -23,8 +23,8 @@ #pragma once -#include "ts/Diags.h" -#include "ts/ink_atomic.h" +#include "tscore/Diags.h" +#include "tscore/ink_atomic.h" #include "P_RecDefs.h" diff --git a/lib/records/RecConfigParse.cc b/lib/records/RecConfigParse.cc index b690375ac09..db26961bbd8 100644 --- a/lib/records/RecConfigParse.cc +++ b/lib/records/RecConfigParse.cc @@ -21,20 +21,20 @@ limitations under the License. */ -#include "ts/ink_platform.h" -#include "ts/ink_memory.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_memory.h" -#include "ts/TextBuffer.h" -#include "ts/Tokenizer.h" -#include "ts/ink_defs.h" -#include "ts/ink_string.h" -#include "ts/runroot.h" +#include "tscore/TextBuffer.h" +#include "tscore/Tokenizer.h" +#include "tscore/ink_defs.h" +#include "tscore/ink_string.h" +#include "tscore/runroot.h" #include "P_RecFile.h" #include "P_RecUtils.h" #include "P_RecMessage.h" #include "P_RecCore.h" -#include "ts/I_Layout.h" +#include "tscore/I_Layout.h" const char *g_rec_config_fpath = nullptr; LLQ *g_rec_config_contents_llq = nullptr; diff --git a/lib/records/RecCore.cc b/lib/records/RecCore.cc index aa2557a9b5f..687c6d9194c 100644 --- a/lib/records/RecCore.cc +++ b/lib/records/RecCore.cc @@ -21,14 +21,14 @@ limitations under the License. */ -#include "ts/ink_platform.h" -#include "ts/ink_memory.h" -#include "ts/ink_string.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_memory.h" +#include "tscore/ink_string.h" #include "P_RecFile.h" #include "P_RecCore.h" #include "P_RecUtils.h" -#include "ts/I_Layout.h" +#include "tscore/I_Layout.h" static bool g_initialized = false; diff --git a/lib/records/RecFile.cc b/lib/records/RecFile.cc index 466864b2690..755bc1eb009 100644 --- a/lib/records/RecFile.cc +++ b/lib/records/RecFile.cc @@ -21,8 +21,8 @@ limitations under the License. */ -#include "ts/ink_platform.h" -#include "ts/ink_string.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_string.h" #include "P_RecFile.h" #include "P_RecDefs.h" #include "P_RecUtils.h" diff --git a/lib/records/RecHttp.cc b/lib/records/RecHttp.cc index abfbe7b2637..abb14397e68 100644 --- a/lib/records/RecHttp.cc +++ b/lib/records/RecHttp.cc @@ -23,13 +23,13 @@ #include #include -#include -#include -#include +#include "tscore/ink_defs.h" +#include "tscore/ink_hash_table.h" +#include "tscore/Tokenizer.h" #include -#include +#include "tscore/ink_inet.h" #include -#include +#include "tscore/IpMapConf.h" SessionProtocolNameRegistry globalSessionProtocolNameRegistry; diff --git a/lib/records/RecLocal.cc b/lib/records/RecLocal.cc index c27a13aac1c..ad927e526fb 100644 --- a/lib/records/RecLocal.cc +++ b/lib/records/RecLocal.cc @@ -21,9 +21,9 @@ limitations under the License. */ -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #include "Rollback.h" -#include "ts/ParseRules.h" +#include "tscore/ParseRules.h" #include "P_RecCore.h" #include "P_RecLocal.h" #include "P_RecMessage.h" diff --git a/lib/records/RecMessage.cc b/lib/records/RecMessage.cc index bcb35cf211a..95f8c99c444 100644 --- a/lib/records/RecMessage.cc +++ b/lib/records/RecMessage.cc @@ -21,16 +21,16 @@ limitations under the License. */ -#include "ts/ink_platform.h" -#include "ts/ink_memory.h" -#include "ts/ink_align.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_memory.h" +#include "tscore/ink_align.h" #include "P_RecCore.h" #include "P_RecFile.h" #include "P_RecMessage.h" #include "P_RecUtils.h" #include "P_RecCore.h" -#include "ts/I_Layout.h" +#include "tscore/I_Layout.h" static RecMessageRecvCb g_recv_cb = nullptr; static void *g_recv_cookie = nullptr; diff --git a/lib/records/RecMutex.cc b/lib/records/RecMutex.cc index d08e503dc94..619d778b997 100644 --- a/lib/records/RecMutex.cc +++ b/lib/records/RecMutex.cc @@ -21,7 +21,7 @@ limitations under the License. */ -#include "ts/ink_config.h" +#include "tscore/ink_config.h" #include "I_RecMutex.h" void diff --git a/lib/records/RecProcess.cc b/lib/records/RecProcess.cc index 58593809e28..08848f46cc3 100644 --- a/lib/records/RecProcess.cc +++ b/lib/records/RecProcess.cc @@ -21,8 +21,8 @@ limitations under the License. */ -#include "ts/ink_platform.h" -#include "ts/EventNotify.h" +#include "tscore/ink_platform.h" +#include "tscore/EventNotify.h" #include "I_Tasks.h" diff --git a/lib/records/RecUtils.cc b/lib/records/RecUtils.cc index cba7a68965a..4a380b9bada 100644 --- a/lib/records/RecUtils.cc +++ b/lib/records/RecUtils.cc @@ -21,9 +21,9 @@ limitations under the License. */ -#include "ts/ink_platform.h" -#include "ts/ink_memory.h" -#include "ts/ParseRules.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_memory.h" +#include "tscore/ParseRules.h" #include "P_RecUtils.h" #include "P_RecCore.h" diff --git a/lib/tsconfig/Makefile.am b/lib/tsconfig/Makefile.am index e8ad48831d1..4e32acfb4aa 100644 --- a/lib/tsconfig/Makefile.am +++ b/lib/tsconfig/Makefile.am @@ -24,7 +24,7 @@ AM_CFLAGS += @FLEX_CFLAGS@ AM_YFLAGS = --yacc -d -p tsconfig AM_CPPFLAGS += \ - -I$(abs_top_srcdir)/lib \ + -I$(abs_top_srcdir)/include \ $(TS_INCLUDES) BUILT_SOURCES = \ @@ -63,7 +63,7 @@ endif test_tsconfig_SOURCES = test-tsconfig.cc -test_tsconfig_LDADD = libtsconfig.la ../ts/libtsutil.la +test_tsconfig_LDADD = libtsconfig.la $(top_builddir)/src/tscore/libtscore.la $(top_builddir)/src/tscpp/util/libtscpputil.la # Strip to just the enum in the ts::config namespace so we can use # it more easily in C++. diff --git a/lib/tsconfig/TsConfigGrammar.c b/lib/tsconfig/TsConfigGrammar.c index 23e5e35f744..025b4f98713 100644 --- a/lib/tsconfig/TsConfigGrammar.c +++ b/lib/tsconfig/TsConfigGrammar.c @@ -1,8 +1,8 @@ -/* A Bison parser, made by GNU Bison 2.7. */ +/* A Bison parser, made by GNU Bison 3.0.4. */ /* Bison implementation for Yacc-like parsers in C - Copyright (C) 1984, 1989-1990, 2000-2012 Free Software Foundation, Inc. + Copyright (C) 1984, 1989-1990, 2000-2015 Free Software Foundation, Inc. This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -44,7 +44,7 @@ #define YYBISON 1 /* Bison version. */ -#define YYBISON_VERSION "2.7" +#define YYBISON_VERSION "3.0.4" /* Skeleton name. */ #define YYSKELETON_NAME "yacc.c" @@ -59,8 +59,7 @@ #define YYPULL 1 /* "%code top" blocks. */ -/* Line 349 of yacc.c */ -#line 26 "TsConfigGrammar.y" +#line 26 "TsConfigGrammar.y" /* yacc.c:316 */ # if ! (defined(__clang_analyzer__) || defined(__COVERITY__)) # include "TsConfigTypes.h" @@ -71,36 +70,32 @@ # define YYFREE free # include "TsConfigParseEvents.h" -# include "ts/ink_defs.h" +# include "tscore/ink_defs.h" // Types we need for the lexer. typedef void* yyscan_t; extern int tsconfiglex(YYSTYPE* yylval, yyscan_t lexer); - -/* Line 349 of yacc.c */ -#line 84 "TsConfigGrammar.c" +#line 81 "TsConfigGrammar.c" /* yacc.c:316 */ /* Substitute the variable and function names. */ #define yyparse tsconfigparse #define yylex tsconfiglex #define yyerror tsconfigerror -#define yylval tsconfiglval -#define yychar tsconfigchar #define yydebug tsconfigdebug #define yynerrs tsconfignerrs + /* Copy the first part of user declarations. */ -/* Line 371 of yacc.c */ -#line 98 "TsConfigGrammar.c" +#line 93 "TsConfigGrammar.c" /* yacc.c:339 */ -# ifndef YY_NULL +# ifndef YY_NULLPTR # if defined __cplusplus && 201103L <= __cplusplus -# define YY_NULL nullptr +# define YY_NULLPTR nullptr # else -# define YY_NULL 0 +# define YY_NULLPTR 0 # endif # endif @@ -116,7 +111,7 @@ extern int tsconfiglex(YYSTYPE* yylval, yyscan_t lexer); by #include "y.tab.h". */ #ifndef YY_TSCONFIG_TSCONFIGGRAMMAR_H_INCLUDED # define YY_TSCONFIG_TSCONFIGGRAMMAR_H_INCLUDED -/* Enabling traces. */ +/* Debug traces. */ #ifndef YYDEBUG # define YYDEBUG 0 #endif @@ -124,8 +119,7 @@ extern int tsconfiglex(YYSTYPE* yylval, yyscan_t lexer); extern int tsconfigdebug; #endif /* "%code requires" blocks. */ -/* Line 387 of yacc.c */ -#line 1 "TsConfigGrammar.y" +#line 1 "TsConfigGrammar.y" /* yacc.c:355 */ /** @file @@ -150,29 +144,26 @@ extern int tsconfigdebug; limitations under the License. */ +#line 148 "TsConfigGrammar.c" /* yacc.c:355 */ -/* Line 387 of yacc.c */ -#line 156 "TsConfigGrammar.c" - -/* Tokens. */ +/* Token type. */ #ifndef YYTOKENTYPE # define YYTOKENTYPE - /* Put the tokens into the symbol table, so that GDB and other debuggers - know about them. */ - enum yytokentype { - STRING = 258, - IDENT = 259, - INTEGER = 260, - LIST_OPEN = 261, - LIST_CLOSE = 262, - GROUP_OPEN = 263, - GROUP_CLOSE = 264, - PATH_OPEN = 265, - PATH_CLOSE = 266, - PATH_SEPARATOR = 267, - SEPARATOR = 268, - ASSIGN = 269 - }; + enum yytokentype + { + STRING = 258, + IDENT = 259, + INTEGER = 260, + LIST_OPEN = 261, + LIST_CLOSE = 262, + GROUP_OPEN = 263, + GROUP_CLOSE = 264, + PATH_OPEN = 265, + PATH_CLOSE = 266, + PATH_SEPARATOR = 267, + SEPARATOR = 268, + ASSIGN = 269 + }; #endif /* Tokens. */ #define STRING 258 @@ -188,39 +179,24 @@ extern int tsconfigdebug; #define SEPARATOR 268 #define ASSIGN 269 - - +/* Value type. */ #if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED typedef int YYSTYPE; # define YYSTYPE_IS_TRIVIAL 1 -# define yystype YYSTYPE /* obsolescent; will be withdrawn */ # define YYSTYPE_IS_DECLARED 1 #endif -#ifdef YYPARSE_PARAM -#if defined __STDC__ || defined __cplusplus -int tsconfigparse (void *YYPARSE_PARAM); -#else -int tsconfigparse (); -#endif -#else /* ! YYPARSE_PARAM */ -#if defined __STDC__ || defined __cplusplus + int tsconfigparse (yyscan_t lexer, struct TsConfigHandlers* handlers); -#else -int tsconfigparse (); -#endif -#endif /* ! YYPARSE_PARAM */ #endif /* !YY_TSCONFIG_TSCONFIGGRAMMAR_H_INCLUDED */ /* Copy the second part of user declarations. */ -/* Line 390 of yacc.c */ -#line 221 "TsConfigGrammar.c" +#line 198 "TsConfigGrammar.c" /* yacc.c:358 */ /* Unqualified %code blocks. */ -/* Line 391 of yacc.c */ -#line 44 "TsConfigGrammar.y" +#line 44 "TsConfigGrammar.y" /* yacc.c:359 */ # define HANDLE_EVENT(x,y) \ @@ -232,7 +208,7 @@ int tsconfigparse (); int tsconfigerror( yyscan_t lexer ATS_UNUSED, struct TsConfigHandlers* handlers, - const char* text + char const* text ) { return (handlers && handlers->error._f) ? handlers->error._f(handlers->error._data, text) @@ -241,9 +217,7 @@ int tsconfigerror( } - -/* Line 391 of yacc.c */ -#line 247 "TsConfigGrammar.c" +#line 221 "TsConfigGrammar.c" /* yacc.c:359 */ #ifdef short # undef short @@ -257,11 +231,8 @@ typedef unsigned char yytype_uint8; #ifdef YYTYPE_INT8 typedef YYTYPE_INT8 yytype_int8; -#elif (defined __STDC__ || defined __C99__FUNC__ \ - || defined __cplusplus || defined _MSC_VER) -typedef signed char yytype_int8; #else -typedef short int yytype_int8; +typedef signed char yytype_int8; #endif #ifdef YYTYPE_UINT16 @@ -281,8 +252,7 @@ typedef short int yytype_int16; # define YYSIZE_T __SIZE_TYPE__ # elif defined size_t # define YYSIZE_T size_t -# elif ! defined YYSIZE_T && (defined __STDC__ || defined __C99__FUNC__ \ - || defined __cplusplus || defined _MSC_VER) +# elif ! defined YYSIZE_T # include /* INFRINGES ON USER NAME SPACE */ # define YYSIZE_T size_t # else @@ -304,6 +274,33 @@ typedef short int yytype_int16; # endif #endif +#ifndef YY_ATTRIBUTE +# if (defined __GNUC__ \ + && (2 < __GNUC__ || (__GNUC__ == 2 && 96 <= __GNUC_MINOR__))) \ + || defined __SUNPRO_C && 0x5110 <= __SUNPRO_C +# define YY_ATTRIBUTE(Spec) __attribute__(Spec) +# else +# define YY_ATTRIBUTE(Spec) /* empty */ +# endif +#endif + +#ifndef YY_ATTRIBUTE_PURE +# define YY_ATTRIBUTE_PURE YY_ATTRIBUTE ((__pure__)) +#endif + +#ifndef YY_ATTRIBUTE_UNUSED +# define YY_ATTRIBUTE_UNUSED YY_ATTRIBUTE ((__unused__)) +#endif + +#if !defined _Noreturn \ + && (!defined __STDC_VERSION__ || __STDC_VERSION__ < 201112) +# if defined _MSC_VER && 1200 <= _MSC_VER +# define _Noreturn __declspec (noreturn) +# else +# define _Noreturn YY_ATTRIBUTE ((__noreturn__)) +# endif +#endif + /* Suppress unused-variable warnings by "using" E. */ #if ! defined lint || defined __GNUC__ # define YYUSE(E) ((void) (E)) @@ -311,24 +308,26 @@ typedef short int yytype_int16; # define YYUSE(E) /* empty */ #endif -/* Identity function, used to suppress warnings about constant conditions. */ -#ifndef lint -# define YYID(N) (N) -#else -#if (defined __STDC__ || defined __C99__FUNC__ \ - || defined __cplusplus || defined _MSC_VER) -static int -YYID (int yyi) +#if defined __GNUC__ && 407 <= __GNUC__ * 100 + __GNUC_MINOR__ +/* Suppress an incorrect diagnostic about yylval being uninitialized. */ +# define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN \ + _Pragma ("GCC diagnostic push") \ + _Pragma ("GCC diagnostic ignored \"-Wuninitialized\"")\ + _Pragma ("GCC diagnostic ignored \"-Wmaybe-uninitialized\"") +# define YY_IGNORE_MAYBE_UNINITIALIZED_END \ + _Pragma ("GCC diagnostic pop") #else -static int -YYID (yyi) - int yyi; +# define YY_INITIAL_VALUE(Value) Value #endif -{ - return yyi; -} +#ifndef YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN +# define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN +# define YY_IGNORE_MAYBE_UNINITIALIZED_END +#endif +#ifndef YY_INITIAL_VALUE +# define YY_INITIAL_VALUE(Value) /* Nothing. */ #endif + #if ! defined yyoverflow || YYERROR_VERBOSE /* The parser invokes alloca or malloc; define the necessary symbols. */ @@ -346,8 +345,7 @@ YYID (yyi) # define alloca _alloca # else # define YYSTACK_ALLOC alloca -# if ! defined _ALLOCA_H && ! defined EXIT_SUCCESS && (defined __STDC__ || defined __C99__FUNC__ \ - || defined __cplusplus || defined _MSC_VER) +# if ! defined _ALLOCA_H && ! defined EXIT_SUCCESS # include /* INFRINGES ON USER NAME SPACE */ /* Use EXIT_SUCCESS as a witness for stdlib.h. */ # ifndef EXIT_SUCCESS @@ -359,8 +357,8 @@ YYID (yyi) # endif # ifdef YYSTACK_ALLOC - /* Pacify GCC's `empty if-body' warning. */ -# define YYSTACK_FREE(Ptr) do { /* empty */; } while (YYID (0)) + /* Pacify GCC's 'empty if-body' warning. */ +# define YYSTACK_FREE(Ptr) do { /* empty */; } while (0) # ifndef YYSTACK_ALLOC_MAXIMUM /* The OS might guarantee only one guard page at the bottom of the stack, and a page size can be as small as 4096 bytes. So we cannot safely @@ -376,7 +374,7 @@ YYID (yyi) # endif # if (defined __cplusplus && ! defined EXIT_SUCCESS \ && ! ((defined YYMALLOC || defined malloc) \ - && (defined YYFREE || defined free))) + && (defined YYFREE || defined free))) # include /* INFRINGES ON USER NAME SPACE */ # ifndef EXIT_SUCCESS # define EXIT_SUCCESS 0 @@ -384,15 +382,13 @@ YYID (yyi) # endif # ifndef YYMALLOC # define YYMALLOC malloc -# if ! defined malloc && ! defined EXIT_SUCCESS && (defined __STDC__ || defined __C99__FUNC__ \ - || defined __cplusplus || defined _MSC_VER) +# if ! defined malloc && ! defined EXIT_SUCCESS void *malloc (YYSIZE_T); /* INFRINGES ON USER NAME SPACE */ # endif # endif # ifndef YYFREE # define YYFREE free -# if ! defined free && ! defined EXIT_SUCCESS && (defined __STDC__ || defined __C99__FUNC__ \ - || defined __cplusplus || defined _MSC_VER) +# if ! defined free && ! defined EXIT_SUCCESS void free (void *); /* INFRINGES ON USER NAME SPACE */ # endif # endif @@ -402,7 +398,7 @@ void free (void *); /* INFRINGES ON USER NAME SPACE */ #if (! defined yyoverflow \ && (! defined __cplusplus \ - || (defined YYSTYPE_IS_TRIVIAL && YYSTYPE_IS_TRIVIAL))) + || (defined YYSTYPE_IS_TRIVIAL && YYSTYPE_IS_TRIVIAL))) /* A type that is properly aligned for any stack member. */ union yyalloc @@ -427,16 +423,16 @@ union yyalloc elements in the stack, and YYPTR gives the new location of the stack. Advance YYPTR to a properly aligned location for the next stack. */ -# define YYSTACK_RELOCATE(Stack_alloc, Stack) \ - do \ - { \ - YYSIZE_T yynewbytes; \ - YYCOPY (&yyptr->Stack_alloc, Stack, yysize); \ - Stack = &yyptr->Stack_alloc; \ - yynewbytes = yystacksize * sizeof (*Stack) + YYSTACK_GAP_MAXIMUM; \ - yyptr += yynewbytes / sizeof (*yyptr); \ - } \ - while (YYID (0)) +# define YYSTACK_RELOCATE(Stack_alloc, Stack) \ + do \ + { \ + YYSIZE_T yynewbytes; \ + YYCOPY (&yyptr->Stack_alloc, Stack, yysize); \ + Stack = &yyptr->Stack_alloc; \ + yynewbytes = yystacksize * sizeof (*Stack) + YYSTACK_GAP_MAXIMUM; \ + yyptr += yynewbytes / sizeof (*yyptr); \ + } \ + while (0) #endif @@ -455,7 +451,7 @@ union yyalloc for (yyi = 0; yyi < (Count); yyi++) \ (Dst)[yyi] = (Src)[yyi]; \ } \ - while (YYID (0)) + while (0) # endif # endif #endif /* !YYCOPY_NEEDED */ @@ -471,17 +467,19 @@ union yyalloc #define YYNNTS 20 /* YYNRULES -- Number of rules. */ #define YYNRULES 32 -/* YYNRULES -- Number of states. */ +/* YYNSTATES -- Number of states. */ #define YYNSTATES 44 -/* YYTRANSLATE(YYLEX) -- Bison symbol number corresponding to YYLEX. */ +/* YYTRANSLATE[YYX] -- Symbol number corresponding to YYX as returned + by yylex, with out-of-bounds checking. */ #define YYUNDEFTOK 2 #define YYMAXUTOK 269 -#define YYTRANSLATE(YYX) \ +#define YYTRANSLATE(YYX) \ ((unsigned int) (YYX) <= YYMAXUTOK ? yytranslate[YYX] : YYUNDEFTOK) -/* YYTRANSLATE[YYLEX] -- Bison symbol number corresponding to YYLEX. */ +/* YYTRANSLATE[TOKEN-NUM] -- Symbol number corresponding to TOKEN-NUM + as returned by yylex, without out-of-bounds checking. */ static const yytype_uint8 yytranslate[] = { 0, 2, 2, 2, 2, 2, 2, 2, 2, 2, @@ -514,30 +512,7 @@ static const yytype_uint8 yytranslate[] = }; #if YYDEBUG -/* YYPRHS[YYN] -- Index of the first RHS symbol of rule number YYN in - YYRHS. */ -static const yytype_uint8 yyprhs[] = -{ - 0, 0, 3, 5, 9, 11, 13, 14, 18, 22, - 23, 28, 32, 34, 36, 37, 41, 45, 47, 49, - 51, 53, 55, 57, 59, 60, 62, 66, 68, 70, - 72, 76, 78 -}; - -/* YYRHS -- A `-1'-separated list of the rules' RHS. */ -static const yytype_int8 yyrhs[] = -{ - 16, 0, -1, 20, -1, 18, 20, 19, -1, 8, - -1, 9, -1, -1, 20, 21, 29, -1, 20, 1, - 29, -1, -1, 4, 14, 22, 27, -1, 24, 26, - 25, -1, 6, -1, 7, -1, -1, 26, 27, 29, - -1, 26, 1, 29, -1, 28, -1, 23, -1, 17, - -1, 30, -1, 3, -1, 4, -1, 5, -1, -1, - 13, -1, 31, 33, 32, -1, 10, -1, 11, -1, - 34, -1, 33, 12, 34, -1, 4, -1, 5, -1 -}; - -/* YYRLINE[YYN] -- source line where rule number YYN was defined. */ + /* YYRLINE[YYN] -- Source line where rule number YYN was defined. */ static const yytype_uint8 yyrline[] = { 0, 86, 86, 88, 90, 92, 94, 94, 94, 96, @@ -558,13 +533,13 @@ static const char *const yytname[] = "config", "group", "group_open", "group_close", "group_items", "assign", "$@1", "list", "list_open", "list_close", "list_items", "value", "literal", "separator", "path", "path_open", "path_close", "path_item", - "path_tag", YY_NULL + "path_tag", YY_NULLPTR }; #endif # ifdef YYPRINT -/* YYTOKNUM[YYLEX-NUM] -- Internal token number corresponding to - token YYLEX-NUM. */ +/* YYTOKNUM[NUM] -- (External) token number corresponding to the + (internal) symbol number NUM (which must be that of a token). */ static const yytype_uint16 yytoknum[] = { 0, 256, 257, 258, 259, 260, 261, 262, 263, 264, @@ -572,46 +547,18 @@ static const yytype_uint16 yytoknum[] = }; # endif -/* YYR1[YYN] -- Symbol number of symbol that rule YYN derives. */ -static const yytype_uint8 yyr1[] = -{ - 0, 15, 16, 17, 18, 19, 20, 20, 20, 22, - 21, 23, 24, 25, 26, 26, 26, 27, 27, 27, - 27, 28, 28, 28, 29, 29, 30, 31, 32, 33, - 33, 34, 34 -}; +#define YYPACT_NINF -11 -/* YYR2[YYN] -- Number of symbols composing right hand side of rule YYN. */ -static const yytype_uint8 yyr2[] = -{ - 0, 2, 1, 3, 1, 1, 0, 3, 3, 0, - 4, 3, 1, 1, 0, 3, 3, 1, 1, 1, - 1, 1, 1, 1, 0, 1, 3, 1, 1, 1, - 3, 1, 1 -}; +#define yypact_value_is_default(Yystate) \ + (!!((Yystate) == (-11))) -/* YYDEFACT[STATE-NAME] -- Default reduction number in state STATE-NUM. - Performed when YYTABLE doesn't specify something else to do. Zero - means the default is an error. */ -static const yytype_uint8 yydefact[] = -{ - 6, 0, 0, 1, 24, 0, 24, 25, 8, 9, - 7, 0, 21, 22, 23, 12, 4, 27, 19, 6, - 18, 14, 10, 17, 20, 0, 0, 0, 31, 32, - 0, 29, 5, 3, 24, 13, 11, 24, 28, 0, - 26, 16, 15, 30 -}; +#define YYTABLE_NINF -3 -/* YYDEFGOTO[NTERM-NUM]. */ -static const yytype_int8 yydefgoto[] = -{ - -1, 1, 18, 19, 33, 2, 6, 11, 20, 21, - 36, 27, 22, 23, 8, 24, 25, 40, 30, 31 -}; +#define yytable_value_is_error(Yytable_value) \ + 0 -/* YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing - STATE-NUM. */ -#define YYPACT_NINF -11 + /* YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing + STATE-NUM. */ static const yytype_int8 yypact[] = { -11, 2, 21, -11, -2, 5, -2, -11, -11, -11, @@ -621,17 +568,35 @@ static const yytype_int8 yypact[] = -11, -11, -11, -11 }; -/* YYPGOTO[NTERM-NUM]. */ + /* YYDEFACT[STATE-NUM] -- Default reduction number in state STATE-NUM. + Performed when YYTABLE does not specify something else to do. Zero + means the default is an error. */ +static const yytype_uint8 yydefact[] = +{ + 6, 0, 0, 1, 24, 0, 24, 25, 8, 9, + 7, 0, 21, 22, 23, 12, 4, 27, 19, 6, + 18, 14, 10, 17, 20, 0, 0, 0, 31, 32, + 0, 29, 5, 3, 24, 13, 11, 24, 28, 0, + 26, 16, 15, 30 +}; + + /* YYPGOTO[NTERM-NUM]. */ static const yytype_int8 yypgoto[] = { -11, -11, -11, -11, -11, 11, -11, -11, -11, -11, -11, -11, 6, -11, -6, -11, -11, -11, -11, -10 }; -/* YYTABLE[YYPACT[STATE-NUM]]. What to do in state STATE-NUM. If - positive, shift that token. If negative, reduce the rule which - number is the opposite. If YYTABLE_NINF, syntax error. */ -#define YYTABLE_NINF -3 + /* YYDEFGOTO[NTERM-NUM]. */ +static const yytype_int8 yydefgoto[] = +{ + -1, 1, 18, 19, 33, 2, 6, 11, 20, 21, + 36, 27, 22, 23, 8, 24, 25, 40, 30, 31 +}; + + /* YYTABLE[YYPACT[STATE-NUM]] -- What to do in state STATE-NUM. If + positive, shift that token. If negative, reduce the rule whose + number is the opposite. If YYTABLE_NINF, syntax error. */ static const yytype_int8 yytable[] = { 10, 34, 3, 12, 13, 14, 15, 35, 16, 4, @@ -640,12 +605,6 @@ static const yytype_int8 yytable[] = 26, 42, 0, 37 }; -#define yypact_value_is_default(Yystate) \ - (!!((Yystate) == (-11))) - -#define yytable_value_is_error(Yytable_value) \ - YYID (0) - static const yytype_int8 yycheck[] = { 6, 1, 0, 3, 4, 5, 6, 7, 8, 1, @@ -654,8 +613,8 @@ static const yytype_int8 yycheck[] = 19, 37, -1, 27 }; -/* YYSTOS[STATE-NUM] -- The (internal number of the) accessing - symbol of state STATE-NUM. */ + /* YYSTOS[STATE-NUM] -- The (internal number of the) accessing + symbol of state STATE-NUM. */ static const yytype_uint8 yystos[] = { 0, 16, 20, 0, 1, 4, 21, 13, 29, 14, @@ -665,30 +624,34 @@ static const yytype_uint8 yystos[] = 32, 29, 29, 34 }; -#define yyerrok (yyerrstatus = 0) -#define yyclearin (yychar = YYEMPTY) -#define YYEMPTY (-2) -#define YYEOF 0 - -#define YYACCEPT goto yyacceptlab -#define YYABORT goto yyabortlab -#define YYERROR goto yyerrorlab - - -/* Like YYERROR except do call yyerror. This remains here temporarily - to ease the transition to the new meaning of YYERROR, for GCC. - Once GCC version 2 has supplanted version 1, this can go. However, - YYFAIL appears to be in use. Nevertheless, it is formally deprecated - in Bison 2.4.2's NEWS entry, where a plan to phase it out is - discussed. */ - -#define YYFAIL goto yyerrlab -#if defined YYFAIL - /* This is here to suppress warnings from the GCC cpp's - -Wunused-macros. Normally we don't worry about that warning, but - some users do, and we want to make it easy for users to remove - YYFAIL uses, which will produce warnings from Bison 2.5. */ -#endif + /* YYR1[YYN] -- Symbol number of symbol that rule YYN derives. */ +static const yytype_uint8 yyr1[] = +{ + 0, 15, 16, 17, 18, 19, 20, 20, 20, 22, + 21, 23, 24, 25, 26, 26, 26, 27, 27, 27, + 27, 28, 28, 28, 29, 29, 30, 31, 32, 33, + 33, 34, 34 +}; + + /* YYR2[YYN] -- Number of symbols on the right hand side of rule YYN. */ +static const yytype_uint8 yyr2[] = +{ + 0, 2, 1, 3, 1, 1, 0, 3, 3, 0, + 4, 3, 1, 1, 0, 3, 3, 1, 1, 1, + 1, 1, 1, 1, 0, 1, 3, 1, 1, 1, + 3, 1, 1 +}; + + +#define yyerrok (yyerrstatus = 0) +#define yyclearin (yychar = YYEMPTY) +#define YYEMPTY (-2) +#define YYEOF 0 + +#define YYACCEPT goto yyacceptlab +#define YYABORT goto yyabortlab +#define YYERROR goto yyerrorlab + #define YYRECOVERING() (!!yyerrstatus) @@ -705,27 +668,15 @@ do \ else \ { \ yyerror (lexer, handlers, YY_("syntax error: cannot back up")); \ - YYERROR; \ - } \ -while (YYID (0)) + YYERROR; \ + } \ +while (0) /* Error token number */ -#define YYTERROR 1 -#define YYERRCODE 256 - - -/* This macro is provided for backward compatibility. */ -#ifndef YY_LOCATION_PRINT -# define YY_LOCATION_PRINT(File, Loc) ((void) 0) -#endif +#define YYTERROR 1 +#define YYERRCODE 256 -/* YYLEX -- calling `yylex' with the right arguments. */ -#ifdef YYLEX_PARAM -# define YYLEX yylex (&yylval, YYLEX_PARAM) -#else -# define YYLEX yylex (&yylval, lexer) -#endif /* Enable debugging if requested. */ #if YYDEBUG @@ -735,60 +686,48 @@ while (YYID (0)) # define YYFPRINTF fprintf # endif -# define YYDPRINTF(Args) \ -do { \ - if (yydebug) \ - YYFPRINTF Args; \ -} while (YYID (0)) +# define YYDPRINTF(Args) \ +do { \ + if (yydebug) \ + YYFPRINTF Args; \ +} while (0) + +/* This macro is provided for backward compatibility. */ +#ifndef YY_LOCATION_PRINT +# define YY_LOCATION_PRINT(File, Loc) ((void) 0) +#endif + -# define YY_SYMBOL_PRINT(Title, Type, Value, Location) \ -do { \ - if (yydebug) \ - { \ - YYFPRINTF (stderr, "%s ", Title); \ - yy_symbol_print (stderr, \ - Type, Value, lexer, handlers); \ - YYFPRINTF (stderr, "\n"); \ - } \ -} while (YYID (0)) +# define YY_SYMBOL_PRINT(Title, Type, Value, Location) \ +do { \ + if (yydebug) \ + { \ + YYFPRINTF (stderr, "%s ", Title); \ + yy_symbol_print (stderr, \ + Type, Value, lexer, handlers); \ + YYFPRINTF (stderr, "\n"); \ + } \ +} while (0) -/*--------------------------------. -| Print this symbol on YYOUTPUT. | -`--------------------------------*/ +/*----------------------------------------. +| Print this symbol's value on YYOUTPUT. | +`----------------------------------------*/ -/*ARGSUSED*/ -#if (defined __STDC__ || defined __C99__FUNC__ \ - || defined __cplusplus || defined _MSC_VER) static void yy_symbol_value_print (FILE *yyoutput, int yytype, YYSTYPE const * const yyvaluep, yyscan_t lexer, struct TsConfigHandlers* handlers) -#else -static void -yy_symbol_value_print (yyoutput, yytype, yyvaluep, lexer, handlers) - FILE *yyoutput; - int yytype; - YYSTYPE const * const yyvaluep; - yyscan_t lexer; - struct TsConfigHandlers* handlers; -#endif { FILE *yyo = yyoutput; YYUSE (yyo); - if (!yyvaluep) - return; YYUSE (lexer); YYUSE (handlers); + if (!yyvaluep) + return; # ifdef YYPRINT if (yytype < YYNTOKENS) YYPRINT (yyoutput, yytoknum[yytype], *yyvaluep); -# else - YYUSE (yyoutput); # endif - switch (yytype) - { - default: - break; - } + YYUSE (yytype); } @@ -796,24 +735,11 @@ yy_symbol_value_print (yyoutput, yytype, yyvaluep, lexer, handlers) | Print this symbol on YYOUTPUT. | `--------------------------------*/ -#if (defined __STDC__ || defined __C99__FUNC__ \ - || defined __cplusplus || defined _MSC_VER) static void yy_symbol_print (FILE *yyoutput, int yytype, YYSTYPE const * const yyvaluep, yyscan_t lexer, struct TsConfigHandlers* handlers) -#else -static void -yy_symbol_print (yyoutput, yytype, yyvaluep, lexer, handlers) - FILE *yyoutput; - int yytype; - YYSTYPE const * const yyvaluep; - yyscan_t lexer; - struct TsConfigHandlers* handlers; -#endif { - if (yytype < YYNTOKENS) - YYFPRINTF (yyoutput, "token %s (", yytname[yytype]); - else - YYFPRINTF (yyoutput, "nterm %s (", yytname[yytype]); + YYFPRINTF (yyoutput, "%s %s (", + yytype < YYNTOKENS ? "token" : "nterm", yytname[yytype]); yy_symbol_value_print (yyoutput, yytype, yyvaluep, lexer, handlers); YYFPRINTF (yyoutput, ")"); @@ -824,16 +750,8 @@ yy_symbol_print (yyoutput, yytype, yyvaluep, lexer, handlers) | TOP (included). | `------------------------------------------------------------------*/ -#if (defined __STDC__ || defined __C99__FUNC__ \ - || defined __cplusplus || defined _MSC_VER) static void yy_stack_print (yytype_int16 *yybottom, yytype_int16 *yytop) -#else -static void -yy_stack_print (yybottom, yytop) - yytype_int16 *yybottom; - yytype_int16 *yytop; -#endif { YYFPRINTF (stderr, "Stack now"); for (; yybottom <= yytop; yybottom++) @@ -844,51 +762,42 @@ yy_stack_print (yybottom, yytop) YYFPRINTF (stderr, "\n"); } -# define YY_STACK_PRINT(Bottom, Top) \ -do { \ - if (yydebug) \ - yy_stack_print ((Bottom), (Top)); \ -} while (YYID (0)) +# define YY_STACK_PRINT(Bottom, Top) \ +do { \ + if (yydebug) \ + yy_stack_print ((Bottom), (Top)); \ +} while (0) /*------------------------------------------------. | Report that the YYRULE is going to be reduced. | `------------------------------------------------*/ -#if (defined __STDC__ || defined __C99__FUNC__ \ - || defined __cplusplus || defined _MSC_VER) -static void -yy_reduce_print (YYSTYPE *yyvsp, int yyrule, yyscan_t lexer, struct TsConfigHandlers* handlers) -#else static void -yy_reduce_print (yyvsp, yyrule, lexer, handlers) - YYSTYPE *yyvsp; - int yyrule; - yyscan_t lexer; - struct TsConfigHandlers* handlers; -#endif +yy_reduce_print (yytype_int16 *yyssp, YYSTYPE *yyvsp, int yyrule, yyscan_t lexer, struct TsConfigHandlers* handlers) { + unsigned long int yylno = yyrline[yyrule]; int yynrhs = yyr2[yyrule]; int yyi; - unsigned long int yylno = yyrline[yyrule]; YYFPRINTF (stderr, "Reducing stack by rule %d (line %lu):\n", - yyrule - 1, yylno); + yyrule - 1, yylno); /* The symbols being reduced. */ for (yyi = 0; yyi < yynrhs; yyi++) { YYFPRINTF (stderr, " $%d = ", yyi + 1); - yy_symbol_print (stderr, yyrhs[yyprhs[yyrule] + yyi], - &(yyvsp[(yyi + 1) - (yynrhs)]) - , lexer, handlers); + yy_symbol_print (stderr, + yystos[yyssp[yyi + 1 - yynrhs]], + &(yyvsp[(yyi + 1) - (yynrhs)]) + , lexer, handlers); YYFPRINTF (stderr, "\n"); } } -# define YY_REDUCE_PRINT(Rule) \ -do { \ - if (yydebug) \ - yy_reduce_print (yyvsp, Rule, lexer, handlers); \ -} while (YYID (0)) +# define YY_REDUCE_PRINT(Rule) \ +do { \ + if (yydebug) \ + yy_reduce_print (yyssp, yyvsp, Rule, lexer, handlers); \ +} while (0) /* Nonzero means print parse trace. It is left uninitialized so that multiple parsers can coexist. */ @@ -902,7 +811,7 @@ int yydebug; /* YYINITDEPTH -- initial size of the parser's stacks. */ -#ifndef YYINITDEPTH +#ifndef YYINITDEPTH # define YYINITDEPTH 200 #endif @@ -925,15 +834,8 @@ int yydebug; # define yystrlen strlen # else /* Return the length of YYSTR. */ -#if (defined __STDC__ || defined __C99__FUNC__ \ - || defined __cplusplus || defined _MSC_VER) static YYSIZE_T yystrlen (const char *yystr) -#else -static YYSIZE_T -yystrlen (yystr) - const char *yystr; -#endif { YYSIZE_T yylen; for (yylen = 0; yystr[yylen]; yylen++) @@ -949,16 +851,8 @@ yystrlen (yystr) # else /* Copy YYSRC to YYDEST, returning the address of the terminating '\0' in YYDEST. */ -#if (defined __STDC__ || defined __C99__FUNC__ \ - || defined __cplusplus || defined _MSC_VER) static char * yystpcpy (char *yydest, const char *yysrc) -#else -static char * -yystpcpy (yydest, yysrc) - char *yydest; - const char *yysrc; -#endif { char *yyd = yydest; const char *yys = yysrc; @@ -985,30 +879,30 @@ yytnamerr (char *yyres, const char *yystr) if (*yystr == '"') { YYSIZE_T yyn = 0; - const char *yyp = yystr; + char const *yyp = yystr; for (;;) - switch (*++yyp) - { - case '\'': - case ',': - goto do_not_strip_quotes; - - case '\\': - if (*++yyp != '\\') - goto do_not_strip_quotes; - /* Fall through. */ - default: - if (yyres) - yyres[yyn] = *yyp; - yyn++; - break; - - case '"': - if (yyres) - yyres[yyn] = '\0'; - return yyn; - } + switch (*++yyp) + { + case '\'': + case ',': + goto do_not_strip_quotes; + + case '\\': + if (*++yyp != '\\') + goto do_not_strip_quotes; + /* Fall through. */ + default: + if (yyres) + yyres[yyn] = *yyp; + yyn++; + break; + + case '"': + if (yyres) + yyres[yyn] = '\0'; + return yyn; + } do_not_strip_quotes: ; } @@ -1031,22 +925,18 @@ static int yysyntax_error (YYSIZE_T *yymsg_alloc, char **yymsg, yytype_int16 *yyssp, int yytoken) { - YYSIZE_T yysize0 = yytnamerr (YY_NULL, yytname[yytoken]); + YYSIZE_T yysize0 = yytnamerr (YY_NULLPTR, yytname[yytoken]); YYSIZE_T yysize = yysize0; enum { YYERROR_VERBOSE_ARGS_MAXIMUM = 5 }; /* Internationalized format string. */ - const char *yyformat = YY_NULL; + const char *yyformat = YY_NULLPTR; /* Arguments of yyformat. */ - const char *yyarg[YYERROR_VERBOSE_ARGS_MAXIMUM]; + char const *yyarg[YYERROR_VERBOSE_ARGS_MAXIMUM]; /* Number of reported tokens (one for the "unexpected", one per "expected"). */ int yycount = 0; /* There are many possibilities here to consider: - - Assume YYFAIL is not used. It's too flawed to consider. See - - for details. YYERROR is fine as it does not invoke this - function. - If this state is a consistent state with a default action, then the only way this function was invoked is if the default action is an error action. In that case, don't check for expected @@ -1096,7 +986,7 @@ yysyntax_error (YYSIZE_T *yymsg_alloc, char **yymsg, } yyarg[yycount++] = yytname[yyx]; { - YYSIZE_T yysize1 = yysize + yytnamerr (YY_NULL, yytname[yyx]); + YYSIZE_T yysize1 = yysize + yytnamerr (YY_NULLPTR, yytname[yyx]); if (! (yysize <= yysize1 && yysize1 <= YYSTACK_ALLOC_MAXIMUM)) return 2; @@ -1163,35 +1053,19 @@ yysyntax_error (YYSIZE_T *yymsg_alloc, char **yymsg, | Release the memory associated to this symbol. | `-----------------------------------------------*/ -/*ARGSUSED*/ -#if (defined __STDC__ || defined __C99__FUNC__ \ - || defined __cplusplus || defined _MSC_VER) static void yydestruct (const char *yymsg, int yytype, YYSTYPE *yyvaluep, yyscan_t lexer, struct TsConfigHandlers* handlers) -#else -static void -yydestruct (yymsg, yytype, yyvaluep, lexer, handlers) - const char *yymsg; - int yytype; - YYSTYPE *yyvaluep; - yyscan_t lexer; - struct TsConfigHandlers* handlers; -#endif { YYUSE (yyvaluep); YYUSE (lexer); YYUSE (handlers); - if (!yymsg) yymsg = "Deleting"; YY_SYMBOL_PRINT (yymsg, yytype, yyvaluep, yylocationp); - switch (yytype) - { - - default: - break; - } + YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN + YYUSE (yytype); + YY_IGNORE_MAYBE_UNINITIALIZED_END } @@ -1201,57 +1075,18 @@ yydestruct (yymsg, yytype, yyvaluep, lexer, handlers) | yyparse. | `----------*/ -#ifdef YYPARSE_PARAM -#if (defined __STDC__ || defined __C99__FUNC__ \ - || defined __cplusplus || defined _MSC_VER) -int -yyparse (void *YYPARSE_PARAM) -#else -int -yyparse (YYPARSE_PARAM) - void *YYPARSE_PARAM; -#endif -#else /* ! YYPARSE_PARAM */ -#if (defined __STDC__ || defined __C99__FUNC__ \ - || defined __cplusplus || defined _MSC_VER) int yyparse (yyscan_t lexer, struct TsConfigHandlers* handlers) -#else -int -yyparse (lexer, handlers) - yyscan_t lexer; - struct TsConfigHandlers* handlers; -#endif -#endif { /* The lookahead symbol. */ int yychar; -#if defined __GNUC__ && 407 <= __GNUC__ * 100 + __GNUC_MINOR__ -/* Suppress an incorrect diagnostic about yylval being uninitialized. */ -# define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN \ - _Pragma ("GCC diagnostic push") \ - _Pragma ("GCC diagnostic ignored \"-Wuninitialized\"")\ - _Pragma ("GCC diagnostic ignored \"-Wmaybe-uninitialized\"") -# define YY_IGNORE_MAYBE_UNINITIALIZED_END \ - _Pragma ("GCC diagnostic pop") -#else +/* The semantic value of the lookahead symbol. */ /* Default value used for initialization, for pacifying older GCCs or non-GCC compilers. */ -static YYSTYPE yyval_default; -# define YY_INITIAL_VALUE(Value) = Value -#endif -#ifndef YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN -# define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN -# define YY_IGNORE_MAYBE_UNINITIALIZED_END -#endif -#ifndef YY_INITIAL_VALUE -# define YY_INITIAL_VALUE(Value) /* Nothing. */ -#endif - -/* The semantic value of the lookahead symbol. */ -YYSTYPE yylval YY_INITIAL_VALUE(yyval_default); +YY_INITIAL_VALUE (static YYSTYPE yyval_default;) +YYSTYPE yylval YY_INITIAL_VALUE (= yyval_default); /* Number of syntax errors so far. */ int yynerrs; @@ -1261,8 +1096,8 @@ YYSTYPE yylval YY_INITIAL_VALUE(yyval_default); int yyerrstatus; /* The stacks and their tools: - `yyss': related to states. - `yyvs': related to semantic values. + 'yyss': related to states. + 'yyvs': related to semantic values. Refer to the stacks through separate pointers, to allow yyoverflow to reallocate them elsewhere. */ @@ -1330,23 +1165,23 @@ YYSTYPE yylval YY_INITIAL_VALUE(yyval_default); #ifdef yyoverflow { - /* Give user a chance to reallocate the stack. Use copies of - these so that the &'s don't force the real ones into - memory. */ - YYSTYPE *yyvs1 = yyvs; - yytype_int16 *yyss1 = yyss; - - /* Each stack pointer address is followed by the size of the - data in use in that stack, in bytes. This used to be a - conditional around just the two extra args, but that might - be undefined if yyoverflow is a macro. */ - yyoverflow (YY_("memory exhausted"), - &yyss1, yysize * sizeof (*yyssp), - &yyvs1, yysize * sizeof (*yyvsp), - &yystacksize); - - yyss = yyss1; - yyvs = yyvs1; + /* Give user a chance to reallocate the stack. Use copies of + these so that the &'s don't force the real ones into + memory. */ + YYSTYPE *yyvs1 = yyvs; + yytype_int16 *yyss1 = yyss; + + /* Each stack pointer address is followed by the size of the + data in use in that stack, in bytes. This used to be a + conditional around just the two extra args, but that might + be undefined if yyoverflow is a macro. */ + yyoverflow (YY_("memory exhausted"), + &yyss1, yysize * sizeof (*yyssp), + &yyvs1, yysize * sizeof (*yyvsp), + &yystacksize); + + yyss = yyss1; + yyvs = yyvs1; } #else /* no yyoverflow */ # ifndef YYSTACK_RELOCATE @@ -1354,22 +1189,22 @@ YYSTYPE yylval YY_INITIAL_VALUE(yyval_default); # else /* Extend the stack our own way. */ if (YYMAXDEPTH <= yystacksize) - goto yyexhaustedlab; + goto yyexhaustedlab; yystacksize *= 2; if (YYMAXDEPTH < yystacksize) - yystacksize = YYMAXDEPTH; + yystacksize = YYMAXDEPTH; { - yytype_int16 *yyss1 = yyss; - union yyalloc *yyptr = - (union yyalloc *) YYSTACK_ALLOC (YYSTACK_BYTES (yystacksize)); - if (! yyptr) - goto yyexhaustedlab; - YYSTACK_RELOCATE (yyss_alloc, yyss); - YYSTACK_RELOCATE (yyvs_alloc, yyvs); + yytype_int16 *yyss1 = yyss; + union yyalloc *yyptr = + (union yyalloc *) YYSTACK_ALLOC (YYSTACK_BYTES (yystacksize)); + if (! yyptr) + goto yyexhaustedlab; + YYSTACK_RELOCATE (yyss_alloc, yyss); + YYSTACK_RELOCATE (yyvs_alloc, yyvs); # undef YYSTACK_RELOCATE - if (yyss1 != yyssa) - YYSTACK_FREE (yyss1); + if (yyss1 != yyssa) + YYSTACK_FREE (yyss1); } # endif #endif /* no yyoverflow */ @@ -1378,10 +1213,10 @@ YYSTYPE yylval YY_INITIAL_VALUE(yyval_default); yyvsp = yyvs + yysize - 1; YYDPRINTF ((stderr, "Stack size increased to %lu\n", - (unsigned long int) yystacksize)); + (unsigned long int) yystacksize)); if (yyss + yystacksize - 1 <= yyssp) - YYABORT; + YYABORT; } YYDPRINTF ((stderr, "Entering state %d\n", yystate)); @@ -1410,7 +1245,7 @@ YYSTYPE yylval YY_INITIAL_VALUE(yyval_default); if (yychar == YYEMPTY) { YYDPRINTF ((stderr, "Reading a token: ")); - yychar = YYLEX; + yychar = yylex (&yylval, lexer); } if (yychar <= YYEOF) @@ -1475,7 +1310,7 @@ YYSTYPE yylval YY_INITIAL_VALUE(yyval_default); yylen = yyr2[yyn]; /* If YYLEN is nonzero, implement the default value of the action: - `$$ = $1'. + '$$ = $1'. Otherwise, the following line sets YYVAL to garbage. This behavior is undocumented and Bison @@ -1489,68 +1324,67 @@ YYSTYPE yylval YY_INITIAL_VALUE(yyval_default); switch (yyn) { case 4: -/* Line 1792 of yacc.c */ -#line 90 "TsConfigGrammar.y" - { HANDLE_EVENT(GroupOpen, (yyvsp[(1) - (1)])); } +#line 90 "TsConfigGrammar.y" /* yacc.c:1646 */ + { HANDLE_EVENT(GroupOpen, (yyvsp[0])); } +#line 1330 "TsConfigGrammar.c" /* yacc.c:1646 */ break; case 5: -/* Line 1792 of yacc.c */ -#line 92 "TsConfigGrammar.y" - { HANDLE_EVENT(GroupClose, (yyvsp[(1) - (1)])); } +#line 92 "TsConfigGrammar.y" /* yacc.c:1646 */ + { HANDLE_EVENT(GroupClose, (yyvsp[0])); } +#line 1336 "TsConfigGrammar.c" /* yacc.c:1646 */ break; case 9: -/* Line 1792 of yacc.c */ -#line 96 "TsConfigGrammar.y" - { HANDLE_EVENT(GroupName, (yyvsp[(1) - (2)])); } +#line 96 "TsConfigGrammar.y" /* yacc.c:1646 */ + { HANDLE_EVENT(GroupName, (yyvsp[-1])); } +#line 1342 "TsConfigGrammar.c" /* yacc.c:1646 */ break; case 12: -/* Line 1792 of yacc.c */ -#line 100 "TsConfigGrammar.y" - { HANDLE_EVENT(ListOpen, (yyvsp[(1) - (1)])); } +#line 100 "TsConfigGrammar.y" /* yacc.c:1646 */ + { HANDLE_EVENT(ListOpen, (yyvsp[0])); } +#line 1348 "TsConfigGrammar.c" /* yacc.c:1646 */ break; case 13: -/* Line 1792 of yacc.c */ -#line 102 "TsConfigGrammar.y" - { HANDLE_EVENT(ListClose, (yyvsp[(1) - (1)])); } +#line 102 "TsConfigGrammar.y" /* yacc.c:1646 */ + { HANDLE_EVENT(ListClose, (yyvsp[0])); } +#line 1354 "TsConfigGrammar.c" /* yacc.c:1646 */ break; case 17: -/* Line 1792 of yacc.c */ -#line 106 "TsConfigGrammar.y" - { HANDLE_EVENT(LiteralValue, (yyvsp[(1) - (1)])); } +#line 106 "TsConfigGrammar.y" /* yacc.c:1646 */ + { HANDLE_EVENT(LiteralValue, (yyvsp[0])); } +#line 1360 "TsConfigGrammar.c" /* yacc.c:1646 */ break; case 27: -/* Line 1792 of yacc.c */ -#line 114 "TsConfigGrammar.y" - { HANDLE_EVENT(PathOpen, (yyvsp[(1) - (1)])); } +#line 114 "TsConfigGrammar.y" /* yacc.c:1646 */ + { HANDLE_EVENT(PathOpen, (yyvsp[0])); } +#line 1366 "TsConfigGrammar.c" /* yacc.c:1646 */ break; case 28: -/* Line 1792 of yacc.c */ -#line 116 "TsConfigGrammar.y" - { HANDLE_EVENT(PathClose, (yyvsp[(1) - (1)])); } +#line 116 "TsConfigGrammar.y" /* yacc.c:1646 */ + { HANDLE_EVENT(PathClose, (yyvsp[0])); } +#line 1372 "TsConfigGrammar.c" /* yacc.c:1646 */ break; case 31: -/* Line 1792 of yacc.c */ -#line 120 "TsConfigGrammar.y" - { HANDLE_EVENT(PathTag, (yyvsp[(1) - (1)])); } +#line 120 "TsConfigGrammar.y" /* yacc.c:1646 */ + { HANDLE_EVENT(PathTag, (yyvsp[0])); } +#line 1378 "TsConfigGrammar.c" /* yacc.c:1646 */ break; case 32: -/* Line 1792 of yacc.c */ -#line 120 "TsConfigGrammar.y" - { HANDLE_EVENT(PathIndex, (yyvsp[(1) - (1)])); } +#line 120 "TsConfigGrammar.y" /* yacc.c:1646 */ + { HANDLE_EVENT(PathIndex, (yyvsp[0])); } +#line 1384 "TsConfigGrammar.c" /* yacc.c:1646 */ break; -/* Line 1792 of yacc.c */ -#line 1554 "TsConfigGrammar.c" +#line 1388 "TsConfigGrammar.c" /* yacc.c:1646 */ default: break; } /* User semantic actions sometimes alter yychar, and that requires @@ -1572,7 +1406,7 @@ YYSTYPE yylval YY_INITIAL_VALUE(yyval_default); *++yyvsp = yyval; - /* Now `shift' the result of the reduction. Determine what state + /* Now 'shift' the result of the reduction. Determine what state that goes to, based on the state we popped back to and the rule number reduced by. */ @@ -1587,9 +1421,9 @@ YYSTYPE yylval YY_INITIAL_VALUE(yyval_default); goto yynewstate; -/*------------------------------------. -| yyerrlab -- here on detecting error | -`------------------------------------*/ +/*--------------------------------------. +| yyerrlab -- here on detecting error. | +`--------------------------------------*/ yyerrlab: /* Make sure we have latest lookahead translation. See comments at user semantic actions for why this is necessary. */ @@ -1605,7 +1439,7 @@ YYSTYPE yylval YY_INITIAL_VALUE(yyval_default); # define YYSYNTAX_ERROR yysyntax_error (&yymsg_alloc, &yymsg, \ yyssp, yytoken) { - const char *yymsgp = YY_("syntax error"); + char const *yymsgp = YY_("syntax error"); int yysyntax_error_status; yysyntax_error_status = YYSYNTAX_ERROR; if (yysyntax_error_status == 0) @@ -1640,20 +1474,20 @@ YYSTYPE yylval YY_INITIAL_VALUE(yyval_default); if (yyerrstatus == 3) { /* If just tried and failed to reuse lookahead token after an - error, discard it. */ + error, discard it. */ if (yychar <= YYEOF) - { - /* Return failure if at end of input. */ - if (yychar == YYEOF) - YYABORT; - } + { + /* Return failure if at end of input. */ + if (yychar == YYEOF) + YYABORT; + } else - { - yydestruct ("Error: discarding", - yytoken, &yylval, lexer, handlers); - yychar = YYEMPTY; - } + { + yydestruct ("Error: discarding", + yytoken, &yylval, lexer, handlers); + yychar = YYEMPTY; + } } /* Else will try to reuse lookahead token after shifting the error @@ -1672,7 +1506,7 @@ YYSTYPE yylval YY_INITIAL_VALUE(yyval_default); if (/*CONSTCOND*/ 0) goto yyerrorlab; - /* Do not reclaim the symbols of the rule which action triggered + /* Do not reclaim the symbols of the rule whose action triggered this YYERROR. */ YYPOPSTACK (yylen); yylen = 0; @@ -1685,29 +1519,29 @@ YYSTYPE yylval YY_INITIAL_VALUE(yyval_default); | yyerrlab1 -- common code for both syntax error and YYERROR. | `-------------------------------------------------------------*/ yyerrlab1: - yyerrstatus = 3; /* Each real token shifted decrements this. */ + yyerrstatus = 3; /* Each real token shifted decrements this. */ for (;;) { yyn = yypact[yystate]; if (!yypact_value_is_default (yyn)) - { - yyn += YYTERROR; - if (0 <= yyn && yyn <= YYLAST && yycheck[yyn] == YYTERROR) - { - yyn = yytable[yyn]; - if (0 < yyn) - break; - } - } + { + yyn += YYTERROR; + if (0 <= yyn && yyn <= YYLAST && yycheck[yyn] == YYTERROR) + { + yyn = yytable[yyn]; + if (0 < yyn) + break; + } + } /* Pop the current state because it cannot handle the error token. */ if (yyssp == yyss) - YYABORT; + YYABORT; yydestruct ("Error: popping", - yystos[yystate], yyvsp, lexer, handlers); + yystos[yystate], yyvsp, lexer, handlers); YYPOPSTACK (1); yystate = *yyssp; YY_STACK_PRINT (yyss, yyssp); @@ -1758,14 +1592,14 @@ YYSTYPE yylval YY_INITIAL_VALUE(yyval_default); yydestruct ("Cleanup: discarding lookahead", yytoken, &yylval, lexer, handlers); } - /* Do not reclaim the symbols of the rule which action triggered + /* Do not reclaim the symbols of the rule whose action triggered this YYABORT or YYACCEPT. */ YYPOPSTACK (yylen); YY_STACK_PRINT (yyss, yyssp); while (yyssp != yyss) { yydestruct ("Cleanup: popping", - yystos[*yyssp], yyvsp, lexer, handlers); + yystos[*yyssp], yyvsp, lexer, handlers); YYPOPSTACK (1); } #ifndef yyoverflow @@ -1776,13 +1610,9 @@ YYSTYPE yylval YY_INITIAL_VALUE(yyval_default); if (yymsg != yymsgbuf) YYSTACK_FREE (yymsg); #endif - /* Make sure YYID is used. */ - return YYID (yyresult); + return yyresult; } - - -/* Line 2055 of yacc.c */ -#line 122 "TsConfigGrammar.y" +#line 122 "TsConfigGrammar.y" /* yacc.c:1906 */ # endif // __clang_analyzer__ diff --git a/lib/tsconfig/TsConfigGrammar.h b/lib/tsconfig/TsConfigGrammar.h index 604738b32ea..4d98d3ad2fe 100644 --- a/lib/tsconfig/TsConfigGrammar.h +++ b/lib/tsconfig/TsConfigGrammar.h @@ -1,8 +1,8 @@ -/* A Bison parser, made by GNU Bison 2.7. */ +/* A Bison parser, made by GNU Bison 3.0.4. */ /* Bison interface for Yacc-like parsers in C - Copyright (C) 1984, 1989-1990, 2000-2012 Free Software Foundation, Inc. + Copyright (C) 1984, 1989-1990, 2000-2015 Free Software Foundation, Inc. This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -30,8 +30,9 @@ This special exception was added by the Free Software Foundation in version 2.2 of Bison. */ -#pragma once -/* Enabling traces. */ +#ifndef YY_TSCONFIG_TSCONFIGGRAMMAR_H_INCLUDED +# define YY_TSCONFIG_TSCONFIGGRAMMAR_H_INCLUDED +/* Debug traces. */ #ifndef YYDEBUG # define YYDEBUG 0 #endif @@ -39,8 +40,7 @@ extern int tsconfigdebug; #endif /* "%code requires" blocks. */ -/* Line 2058 of yacc.c */ -#line 1 "TsConfigGrammar.y" +#line 1 "TsConfigGrammar.y" /* yacc.c:1909 */ /** @file @@ -65,29 +65,26 @@ extern int tsconfigdebug; limitations under the License. */ +#line 69 "TsConfigGrammar.h" /* yacc.c:1909 */ -/* Line 2058 of yacc.c */ -#line 72 "TsConfigGrammar.h" - -/* Tokens. */ +/* Token type. */ #ifndef YYTOKENTYPE # define YYTOKENTYPE - /* Put the tokens into the symbol table, so that GDB and other debuggers - know about them. */ - enum yytokentype { - STRING = 258, - IDENT = 259, - INTEGER = 260, - LIST_OPEN = 261, - LIST_CLOSE = 262, - GROUP_OPEN = 263, - GROUP_CLOSE = 264, - PATH_OPEN = 265, - PATH_CLOSE = 266, - PATH_SEPARATOR = 267, - SEPARATOR = 268, - ASSIGN = 269 - }; + enum yytokentype + { + STRING = 258, + IDENT = 259, + INTEGER = 260, + LIST_OPEN = 261, + LIST_CLOSE = 262, + GROUP_OPEN = 263, + GROUP_CLOSE = 264, + PATH_OPEN = 265, + PATH_CLOSE = 266, + PATH_SEPARATOR = 267, + SEPARATOR = 268, + ASSIGN = 269 + }; #endif /* Tokens. */ #define STRING 258 @@ -103,26 +100,15 @@ extern int tsconfigdebug; #define SEPARATOR 268 #define ASSIGN 269 - - +/* Value type. */ #if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED typedef int YYSTYPE; # define YYSTYPE_IS_TRIVIAL 1 -# define yystype YYSTYPE /* obsolescent; will be withdrawn */ # define YYSTYPE_IS_DECLARED 1 #endif -#ifdef YYPARSE_PARAM -#if defined __STDC__ || defined __cplusplus -int tsconfigparse (void *YYPARSE_PARAM); -#else -int tsconfigparse (); -#endif -#else /* ! YYPARSE_PARAM */ -#if defined __STDC__ || defined __cplusplus + int tsconfigparse (yyscan_t lexer, struct TsConfigHandlers* handlers); -#else -int tsconfigparse (); -#endif -#endif /* ! YYPARSE_PARAM */ + +#endif /* !YY_TSCONFIG_TSCONFIGGRAMMAR_H_INCLUDED */ diff --git a/lib/tsconfig/TsConfigGrammar.y b/lib/tsconfig/TsConfigGrammar.y index 7dcfc874d84..a1e65a1c8c6 100644 --- a/lib/tsconfig/TsConfigGrammar.y +++ b/lib/tsconfig/TsConfigGrammar.y @@ -33,7 +33,7 @@ # define YYFREE free # include "TsConfigParseEvents.h" -# include "ts/ink_defs.h" +# include "tscore/ink_defs.h" // Types we need for the lexer. typedef void* yyscan_t; diff --git a/lib/tsconfig/TsErrataUtil.cc b/lib/tsconfig/TsErrataUtil.cc index d9b3373d937..1f8fbed8eea 100644 --- a/lib/tsconfig/TsErrataUtil.cc +++ b/lib/tsconfig/TsErrataUtil.cc @@ -28,8 +28,8 @@ # include # include # include -# include "ts/ink_string.h" -# include "ts/ink_defs.h" +# include "tscore/ink_string.h" +# include "tscore/ink_defs.h" namespace ts { namespace msg { diff --git a/lib/tsconfig/TsValue.cc b/lib/tsconfig/TsValue.cc index de0298f90e5..0cccc5655d5 100644 --- a/lib/tsconfig/TsValue.cc +++ b/lib/tsconfig/TsValue.cc @@ -23,7 +23,7 @@ # include "TsValue.h" # include "TsBuilder.h" -# include "ts/ink_defs.h" +# include "tscore/ink_defs.h" # include # include diff --git a/lib/tsconfig/TsValue.h b/lib/tsconfig/TsValue.h index f8fc4e148b5..59d7d4e30b8 100644 --- a/lib/tsconfig/TsValue.h +++ b/lib/tsconfig/TsValue.h @@ -25,7 +25,7 @@ */ #include -#include +#include "tscore/TsBuffer.h" #include #include #include diff --git a/mgmt/Alarms.cc b/mgmt/Alarms.cc index 0f02a1c4c44..0ab514ddff3 100644 --- a/mgmt/Alarms.cc +++ b/mgmt/Alarms.cc @@ -21,16 +21,16 @@ limitations under the License. */ -#include "ts/ink_platform.h" -#include "ts/ink_string.h" -#include "ts/ink_file.h" -#include "ts/ink_time.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_string.h" +#include "tscore/ink_file.h" +#include "tscore/ink_time.h" #include "LocalManager.h" #include "MgmtUtils.h" #include "Alarms.h" -#include "ts/Diags.h" +#include "tscore/Diags.h" -#include "P_RecCore.h" +#include "records/P_RecCore.h" const char *alarmText[] = { "Unknown Alarm", diff --git a/mgmt/Alarms.h b/mgmt/Alarms.h index 229df0ffc43..5b83f1eba8e 100644 --- a/mgmt/Alarms.h +++ b/mgmt/Alarms.h @@ -37,8 +37,8 @@ #include #include -#include "ts/ink_hash_table.h" -#include "ts/ink_mutex.h" +#include "tscore/ink_hash_table.h" +#include "tscore/ink_mutex.h" class AppVersionInfo; diff --git a/mgmt/BaseManager.cc b/mgmt/BaseManager.cc index e2209f706b7..2a8c03013f6 100644 --- a/mgmt/BaseManager.cc +++ b/mgmt/BaseManager.cc @@ -31,9 +31,9 @@ * */ -#include "ts/ink_platform.h" -#include "ts/ink_hash_table.h" -#include "ts/ink_memory.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_hash_table.h" +#include "tscore/ink_memory.h" #include "BaseManager.h" BaseManager::BaseManager() diff --git a/mgmt/BaseManager.h b/mgmt/BaseManager.h index 238ffe5f40f..79bf60c5f92 100644 --- a/mgmt/BaseManager.h +++ b/mgmt/BaseManager.h @@ -33,10 +33,10 @@ #pragma once -#include "ts/ink_thread.h" -#include "ts/ink_mutex.h" -#include "ts/ink_llqueue.h" -#include "ts/ink_hash_table.h" +#include "tscore/ink_thread.h" +#include "tscore/ink_mutex.h" +#include "tscore/ink_llqueue.h" +#include "tscore/ink_hash_table.h" #include "MgmtDefs.h" #include "MgmtMarshall.h" diff --git a/mgmt/DerivativeMetrics.cc b/mgmt/DerivativeMetrics.cc index e0a425944bb..ca85c8afcb2 100644 --- a/mgmt/DerivativeMetrics.cc +++ b/mgmt/DerivativeMetrics.cc @@ -26,7 +26,7 @@ // ToDo: It's a little bizarre that we include this here, but it's the only way to get to RecSetRecord(). We should // move that elsewhere... But other places in our core does the same thing. -#include "P_RecCore.h" +#include "records/P_RecCore.h" /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// // This currently only supports one type of derivative metrics: Sums() of other, existing metrics. It's ok to add diff --git a/mgmt/DerivativeMetrics.h b/mgmt/DerivativeMetrics.h index 0ddf8b93220..2109f02ee87 100644 --- a/mgmt/DerivativeMetrics.h +++ b/mgmt/DerivativeMetrics.h @@ -25,7 +25,7 @@ #include -#include "I_RecLocal.h" +#include "records/I_RecLocal.h" using DerivativeSum = std::tuple>; diff --git a/mgmt/FileManager.cc b/mgmt/FileManager.cc index ad2de622e42..451d23fb452 100644 --- a/mgmt/FileManager.cc +++ b/mgmt/FileManager.cc @@ -21,9 +21,9 @@ limitations under the License. */ -#include "ts/ink_platform.h" -#include "ts/ink_file.h" -#include "ts/I_Layout.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_file.h" +#include "tscore/I_Layout.h" #include "FileManager.h" #include "Main.h" #include "Rollback.h" diff --git a/mgmt/FileManager.h b/mgmt/FileManager.h index b81efc3a430..3b2bf48639d 100644 --- a/mgmt/FileManager.h +++ b/mgmt/FileManager.h @@ -32,8 +32,8 @@ #include -#include "ts/ink_hash_table.h" -#include "ts/List.h" +#include "tscore/ink_hash_table.h" +#include "tscore/List.h" #include "Rollback.h" class Rollback; diff --git a/mgmt/LocalManager.cc b/mgmt/LocalManager.cc index 441a303c4f9..e0e590d7ab8 100644 --- a/mgmt/LocalManager.cc +++ b/mgmt/LocalManager.cc @@ -21,22 +21,22 @@ limitations under the License. */ -#include "ts/ink_platform.h" -#include "ts/ink_sock.h" -#include "ts/ink_file.h" -#include "ts/ink_error.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_sock.h" +#include "tscore/ink_file.h" +#include "tscore/ink_error.h" #include "MgmtUtils.h" -#include "ts/I_Layout.h" -#include "ts/runroot.h" +#include "tscore/I_Layout.h" +#include "tscore/runroot.h" #include "LocalManager.h" #include "MgmtSocket.h" -#include "ts/ink_cap.h" +#include "tscore/ink_cap.h" #include "FileManager.h" #include #include -#include -#include -#include +#include "tscpp/util/TextView.h" +#include "tscore/BufferWriter.h" +#include "tscore/bwf_std_format.h" #if TS_USE_POSIX_CAP #include diff --git a/mgmt/Makefile.am b/mgmt/Makefile.am index e5afebf3cbe..d209f265196 100644 --- a/mgmt/Makefile.am +++ b/mgmt/Makefile.am @@ -32,8 +32,8 @@ AM_CPPFLAGS += \ -I$(abs_top_srcdir)/proxy \ -I$(abs_top_srcdir)/proxy/http \ -I$(abs_top_srcdir)/proxy/hdrs \ - -I$(abs_top_srcdir)/lib/records \ - -I$(abs_top_srcdir)/lib \ + -I$(abs_top_srcdir)/include/records \ + -I$(abs_top_srcdir)/include \ $(TS_INCLUDES) libmgmt_c_la_SOURCES = \ diff --git a/mgmt/MgmtDefs.h b/mgmt/MgmtDefs.h index 64b7109135e..d7337ff99f0 100644 --- a/mgmt/MgmtDefs.h +++ b/mgmt/MgmtDefs.h @@ -36,8 +36,8 @@ /* * Type definitions. */ -#include "ts/ink_defs.h" -//#include "ts/ink_hrtime.h" +#include "tscore/ink_defs.h" +//#include "tscore/ink_hrtime.h" typedef int64_t MgmtIntCounter; typedef int64_t MgmtInt; diff --git a/mgmt/ProcessManager.cc b/mgmt/ProcessManager.cc index f2f851e12a1..86fe41c537b 100644 --- a/mgmt/ProcessManager.cc +++ b/mgmt/ProcessManager.cc @@ -21,15 +21,15 @@ limitations under the License. */ -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #include "InkAPIInternal.h" #include "MgmtUtils.h" #include "ProcessManager.h" -#include "ts/ink_apidefs.h" +#include "tscore/ink_apidefs.h" #include "MgmtSocket.h" -#include "ts/I_Layout.h" +#include "tscore/I_Layout.h" /* * Global ProcessManager diff --git a/mgmt/ProcessManager.h b/mgmt/ProcessManager.h index e1e0178fdb9..f523a0d9fe4 100644 --- a/mgmt/ProcessManager.h +++ b/mgmt/ProcessManager.h @@ -37,9 +37,9 @@ #include "MgmtUtils.h" #include "BaseManager.h" -#include "ts/ink_sock.h" +#include "tscore/ink_sock.h" -#include "ts/ink_apidefs.h" +#include "tscore/ink_apidefs.h" #include #if HAVE_EVENTFD diff --git a/mgmt/ProxyConfig.cc b/mgmt/ProxyConfig.cc index 3b403a4af12..4c885dab87e 100644 --- a/mgmt/ProxyConfig.cc +++ b/mgmt/ProxyConfig.cc @@ -21,10 +21,10 @@ limitations under the License. */ -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #include "ProxyConfig.h" #include "P_EventSystem.h" -#include "ts/TestBox.h" +#include "tscore/TestBox.h" ConfigProcessor configProcessor; diff --git a/mgmt/ProxyConfig.h b/mgmt/ProxyConfig.h index a9d33528d1f..999fa936f66 100644 --- a/mgmt/ProxyConfig.h +++ b/mgmt/ProxyConfig.h @@ -31,8 +31,8 @@ #ifndef _Proxy_Config_h #define _Proxy_Config_h -#include "ts/ink_platform.h" -#include "ts/ink_memory.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_memory.h" #include "ProcessManager.h" #include "I_EventSystem.h" #include "I_Tasks.h" diff --git a/mgmt/RecordsConfig.cc b/mgmt/RecordsConfig.cc index 88d14827ac1..c3818b3c3db 100644 --- a/mgmt/RecordsConfig.cc +++ b/mgmt/RecordsConfig.cc @@ -21,7 +21,7 @@ limitations under the License. */ -#include "ts/ink_config.h" +#include "tscore/ink_config.h" #include "RecordsConfig.h" #if TS_USE_REMOTE_UNWINDING diff --git a/mgmt/RecordsConfig.h b/mgmt/RecordsConfig.h index 4a40f645ef0..75a9a7480cd 100644 --- a/mgmt/RecordsConfig.h +++ b/mgmt/RecordsConfig.h @@ -24,7 +24,7 @@ #pragma once //#include "MgmtDefs.h" -#include "P_RecCore.h" +#include "records/P_RecCore.h" enum RecordRequiredType { RR_NULL, // config is _not_ required to be defined in records.config diff --git a/mgmt/RecordsConfigUtils.cc b/mgmt/RecordsConfigUtils.cc index a7f555786bd..76684f83120 100644 --- a/mgmt/RecordsConfigUtils.cc +++ b/mgmt/RecordsConfigUtils.cc @@ -21,9 +21,9 @@ limitations under the License. */ -#include "ts/ink_config.h" +#include "tscore/ink_config.h" #include "RecordsConfig.h" -#include "ts/ParseRules.h" +#include "tscore/ParseRules.h" //------------------------------------------------------------------------- // RecordsConfigOverrideFromEnvironment diff --git a/mgmt/Rollback.cc b/mgmt/Rollback.cc index 6203ea11160..11321dff668 100644 --- a/mgmt/Rollback.cc +++ b/mgmt/Rollback.cc @@ -21,19 +21,19 @@ limitations under the License. */ -#include "ts/ink_platform.h" -#include "ts/ink_string.h" -#include "ts/ink_memory.h" -#include "ts/ink_time.h" -#include "ts/ink_file.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_string.h" +#include "tscore/ink_memory.h" +#include "tscore/ink_time.h" +#include "tscore/ink_file.h" #include "LocalManager.h" #include "Rollback.h" #include "WebMgmtUtils.h" #include "MgmtUtils.h" #include "ExpandingArray.h" #include "MgmtSocket.h" -#include "ts/ink_cap.h" -#include "ts/I_Layout.h" +#include "tscore/ink_cap.h" +#include "tscore/I_Layout.h" #include "FileManager.h" #include "ProxyConfig.h" diff --git a/mgmt/Rollback.h b/mgmt/Rollback.h index 5586e3c66c7..5ad2a09bc59 100644 --- a/mgmt/Rollback.h +++ b/mgmt/Rollback.h @@ -31,11 +31,11 @@ * ****************************************************************************/ -#include "ts/ink_platform.h" -#include "ts/ink_mutex.h" -#include "ts/ink_assert.h" -#include "ts/TextBuffer.h" -#include "ts/List.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_mutex.h" +#include "tscore/ink_assert.h" +#include "tscore/TextBuffer.h" +#include "tscore/List.h" class FileManager; diff --git a/mgmt/WebMgmtUtils.cc b/mgmt/WebMgmtUtils.cc index 41bf759ea7d..9784eb59ad2 100644 --- a/mgmt/WebMgmtUtils.cc +++ b/mgmt/WebMgmtUtils.cc @@ -21,15 +21,15 @@ limitations under the License. */ -#include "ts/ink_platform.h" -#include "ts/ink_string.h" -#include "ts/Tokenizer.h" -#include "ts/ink_code.h" -#include "ts/ink_file.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_string.h" +#include "tscore/Tokenizer.h" +#include "tscore/ink_code.h" +#include "tscore/ink_file.h" #include "LocalManager.h" #include "MgmtUtils.h" #include "WebMgmtUtils.h" -#include "ts/Regex.h" +#include "tscore/Regex.h" /**************************************************************************** * diff --git a/mgmt/WebMgmtUtils.h b/mgmt/WebMgmtUtils.h index 4a01ab9eb2a..517c6aaeae6 100644 --- a/mgmt/WebMgmtUtils.h +++ b/mgmt/WebMgmtUtils.h @@ -34,16 +34,16 @@ * ****************************************************************************/ -#include "ts/ink_hash_table.h" -#include "ts/TextBuffer.h" +#include "tscore/ink_hash_table.h" +#include "tscore/TextBuffer.h" #include "ExpandingArray.h" -#include "P_RecCore.h" +#include "records/P_RecCore.h" // class MgmtData - stores information from local manager // variables in its native type // -#include "P_RecCore.h" +#include "records/P_RecCore.h" class MgmtData { public: diff --git a/mgmt/api/APITestCliRemote.cc b/mgmt/api/APITestCliRemote.cc index 201f85cb088..80f8cca14e9 100644 --- a/mgmt/api/APITestCliRemote.cc +++ b/mgmt/api/APITestCliRemote.cc @@ -75,14 +75,14 @@ * reset_stats - resets all statistics to default values */ -#include "ts/ink_config.h" -#include "ts/ink_defs.h" -#include "ts/ink_memory.h" +#include "tscore/ink_config.h" +#include "tscore/ink_defs.h" +#include "tscore/ink_memory.h" #include #include #include #include -#include "ts/ink_string.h" +#include "tscore/ink_string.h" #include "mgmtapi.h" diff --git a/mgmt/api/CoreAPI.cc b/mgmt/api/CoreAPI.cc index 69a42015361..5ebaf7f74f9 100644 --- a/mgmt/api/CoreAPI.cc +++ b/mgmt/api/CoreAPI.cc @@ -29,24 +29,24 @@ * ***************************************************************************/ -#include "ts/ink_platform.h" -#include "ts/ink_file.h" -#include "ts/ParseRules.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_file.h" +#include "tscore/ParseRules.h" #include "MgmtUtils.h" #include "LocalManager.h" #include "FileManager.h" #include "Rollback.h" #include "WebMgmtUtils.h" -#include "ts/Diags.h" -#include "ts/ink_hash_table.h" +#include "tscore/Diags.h" +#include "tscore/ink_hash_table.h" #include "ExpandingArray.h" //#include "I_AccCrypto.h" #include "CoreAPI.h" #include "CoreAPIShared.h" #include "EventCallback.h" -#include "ts/I_Layout.h" -#include "ts/ink_cap.h" +#include "tscore/I_Layout.h" +#include "tscore/ink_cap.h" #include diff --git a/mgmt/api/CoreAPI.h b/mgmt/api/CoreAPI.h index 621cfc114e2..c6e3b1c4ab1 100644 --- a/mgmt/api/CoreAPI.h +++ b/mgmt/api/CoreAPI.h @@ -25,11 +25,11 @@ #include // for va_list -#include "ts/ink_llqueue.h" +#include "tscore/ink_llqueue.h" #include "MgmtDefs.h" // MgmtInt, MgmtFloat, etc #include "mgmtapi.h" -#include "ts/Tokenizer.h" +#include "tscore/Tokenizer.h" // for buffer used temporarily to parse incoming commands. #ifndef MAX_BUF_SIZE diff --git a/mgmt/api/CoreAPIRemote.cc b/mgmt/api/CoreAPIRemote.cc index e3a87435300..67a66519583 100644 --- a/mgmt/api/CoreAPIRemote.cc +++ b/mgmt/api/CoreAPIRemote.cc @@ -36,13 +36,13 @@ * ***************************************************************************/ -#include "ts/ink_config.h" -#include "ts/ink_defs.h" +#include "tscore/ink_config.h" +#include "tscore/ink_defs.h" #include -#include "ts/ink_string.h" -#include "ts/I_Layout.h" -#include "ts/ParseRules.h" -#include "ts/ink_memory.h" +#include "tscore/ink_string.h" +#include "tscore/I_Layout.h" +#include "tscore/ParseRules.h" +#include "tscore/ink_memory.h" #include "CoreAPI.h" #include "CoreAPIShared.h" #include "NetworkUtilsRemote.h" diff --git a/mgmt/api/CoreAPIShared.cc b/mgmt/api/CoreAPIShared.cc index c05ef04a98b..84462583d92 100644 --- a/mgmt/api/CoreAPIShared.cc +++ b/mgmt/api/CoreAPIShared.cc @@ -21,10 +21,10 @@ See the License for the specific language governing permissions and limitations under the License. */ -#include "ts/ink_platform.h" -#include "ts/ink_sock.h" -#include "ts/ink_string.h" -#include "ts/ink_memory.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_sock.h" +#include "tscore/ink_string.h" +#include "tscore/ink_memory.h" #include "CoreAPIShared.h" #include "MgmtSocket.h" diff --git a/mgmt/api/EventCallback.cc b/mgmt/api/EventCallback.cc index cde092ea944..2fc463a4cfd 100644 --- a/mgmt/api/EventCallback.cc +++ b/mgmt/api/EventCallback.cc @@ -29,8 +29,8 @@ * ***************************************************************************/ -#include "ts/ink_config.h" -#include "ts/ink_memory.h" +#include "tscore/ink_config.h" +#include "tscore/ink_memory.h" #include "EventCallback.h" #include "CoreAPIShared.h" diff --git a/mgmt/api/EventCallback.h b/mgmt/api/EventCallback.h index ffef9c72afe..34743f0be11 100644 --- a/mgmt/api/EventCallback.h +++ b/mgmt/api/EventCallback.h @@ -37,7 +37,7 @@ #pragma once -#include "ts/ink_llqueue.h" +#include "tscore/ink_llqueue.h" #include "mgmtapi.h" #include "CoreAPIShared.h" diff --git a/mgmt/api/EventControlMain.cc b/mgmt/api/EventControlMain.cc index eaa5f99ac0a..59bbb1918e5 100644 --- a/mgmt/api/EventControlMain.cc +++ b/mgmt/api/EventControlMain.cc @@ -29,8 +29,8 @@ * ***************************************************************************/ -#include "ts/ink_platform.h" -#include "ts/ink_sock.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_sock.h" #include "LocalManager.h" #include "MgmtSocket.h" #include "MgmtMarshall.h" diff --git a/mgmt/api/INKMgmtAPI.cc b/mgmt/api/INKMgmtAPI.cc index 3dff0a0a210..9cb64adbb49 100644 --- a/mgmt/api/INKMgmtAPI.cc +++ b/mgmt/api/INKMgmtAPI.cc @@ -29,18 +29,18 @@ * * ***************************************************************************/ -#include "ts/ink_platform.h" -#include "ts/ink_code.h" -#include "ts/ink_memory.h" -#include "ts/ParseRules.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_code.h" +#include "tscore/ink_memory.h" +#include "tscore/ParseRules.h" #include -#include "ts/I_Layout.h" +#include "tscore/I_Layout.h" #include "mgmtapi.h" #include "CoreAPI.h" #include "CoreAPIShared.h" -#include "ts/TextBuffer.h" +#include "tscore/TextBuffer.h" /*************************************************************************** * API Memory Management diff --git a/mgmt/api/Makefile.am b/mgmt/api/Makefile.am index 29c01d9b8dd..8c9a6e394ec 100644 --- a/mgmt/api/Makefile.am +++ b/mgmt/api/Makefile.am @@ -23,11 +23,11 @@ SUBDIRS = include AM_CPPFLAGS += \ $(iocore_include_dirs) \ - -I$(abs_top_srcdir)/lib/records \ + -I$(abs_top_srcdir)/include/records \ -I$(abs_top_srcdir)/mgmt \ -I$(abs_top_srcdir)/mgmt/utils \ -I$(abs_top_srcdir)/mgmt/api/include \ - -I$(abs_top_srcdir)/lib \ + -I$(abs_top_srcdir)/include \ $(TS_INCLUDES) \ $(LIBUNWIND_CFLAGS) @@ -65,12 +65,12 @@ libtsmgmt_la_SOURCES = \ libmgmtapilocal_la_LIBADD = \ libmgmtapi.la \ - $(top_builddir)/lib/ts/libtsutil.la + $(top_builddir)/src/tscore/libtscore.la libtsmgmt_la_LDFLAGS = -no-undefined -version-info @TS_LIBTOOL_VERSION@ libtsmgmt_la_LIBADD = @LIBOBJS@ \ libmgmtapi.la \ - $(top_builddir)/lib/ts/libtsutil.la \ + $(top_builddir)/src/tscore/libtscore.la \ $(top_builddir)/mgmt/utils/libutils_p.la if BUILD_TESTS @@ -78,8 +78,11 @@ traffic_api_cli_remote_SOURCES = APITestCliRemote.cc endif traffic_api_cli_remote_LDADD = \ + $(top_builddir)/src/tscpp/util/libtscpputil.la \ libtsmgmt.la \ - $(top_builddir)/lib/ts/libtsutil.la \ + $(top_builddir)/src/tscpp/util/libtscpputil.la \ + $(top_builddir)/src/tscore/libtscore.la \ + $(top_builddir)/src/tscpp/util/libtscpputil.la \ @LIBTCL@ @OPENSSL_LIBS@ clang-tidy-local: $(DIST_SOURCES) diff --git a/mgmt/api/NetworkMessage.cc b/mgmt/api/NetworkMessage.cc index 44aa6eeaa58..9e5f35fd71e 100644 --- a/mgmt/api/NetworkMessage.cc +++ b/mgmt/api/NetworkMessage.cc @@ -21,11 +21,11 @@ limitations under the License. */ -#include "ts/ink_config.h" -#include "ts/ink_defs.h" -#include "ts/ink_error.h" -#include "ts/ink_assert.h" -#include "ts/ink_memory.h" +#include "tscore/ink_config.h" +#include "tscore/ink_defs.h" +#include "tscore/ink_error.h" +#include "tscore/ink_assert.h" +#include "tscore/ink_memory.h" #include "mgmtapi.h" #include "NetworkMessage.h" diff --git a/mgmt/api/NetworkUtilsLocal.cc b/mgmt/api/NetworkUtilsLocal.cc index 7e28dfdc9b5..50fb8028d14 100644 --- a/mgmt/api/NetworkUtilsLocal.cc +++ b/mgmt/api/NetworkUtilsLocal.cc @@ -30,9 +30,9 @@ * ***************************************************************************/ -#include "ts/ink_platform.h" -#include "ts/ink_sock.h" -#include "ts/Diags.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_sock.h" +#include "tscore/Diags.h" #include "MgmtUtils.h" #include "MgmtSocket.h" #include "MgmtMarshall.h" diff --git a/mgmt/api/NetworkUtilsLocal.h b/mgmt/api/NetworkUtilsLocal.h index cfa3281490c..d60006658c0 100644 --- a/mgmt/api/NetworkUtilsLocal.h +++ b/mgmt/api/NetworkUtilsLocal.h @@ -23,7 +23,7 @@ #pragma once -#include "ts/ink_defs.h" +#include "tscore/ink_defs.h" #include "mgmtapi.h" /***************************************************************************** diff --git a/mgmt/api/NetworkUtilsRemote.cc b/mgmt/api/NetworkUtilsRemote.cc index 4629ae1f5db..4c75f802b69 100644 --- a/mgmt/api/NetworkUtilsRemote.cc +++ b/mgmt/api/NetworkUtilsRemote.cc @@ -21,12 +21,12 @@ limitations under the License. */ -#include "ts/ink_config.h" -#include "ts/ink_defs.h" -#include "ts/ink_sock.h" -#include "ts/ink_string.h" -#include "ts/ink_memory.h" -#include "ts/I_Layout.h" +#include "tscore/ink_config.h" +#include "tscore/ink_defs.h" +#include "tscore/ink_sock.h" +#include "tscore/ink_string.h" +#include "tscore/ink_memory.h" +#include "tscore/I_Layout.h" #include "NetworkUtilsRemote.h" #include "CoreAPI.h" #include "CoreAPIShared.h" diff --git a/mgmt/api/TSControlMain.cc b/mgmt/api/TSControlMain.cc index deedc667a9f..e709415417e 100644 --- a/mgmt/api/TSControlMain.cc +++ b/mgmt/api/TSControlMain.cc @@ -31,8 +31,8 @@ ***************************************************************************/ #include "mgmtapi.h" -#include "ts/ink_platform.h" -#include "ts/ink_sock.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_sock.h" #include "LocalManager.h" #include "MgmtUtils.h" #include "MgmtSocket.h" diff --git a/mgmt/utils/ExpandingArray.cc b/mgmt/utils/ExpandingArray.cc index 952d553246a..651fd29868e 100644 --- a/mgmt/utils/ExpandingArray.cc +++ b/mgmt/utils/ExpandingArray.cc @@ -21,8 +21,8 @@ limitations under the License. */ -#include "ts/ink_platform.h" -#include "ts/ink_memory.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_memory.h" #include "ExpandingArray.h" ExpandingArray::ExpandingArray(int initialSize, bool freeContents) diff --git a/mgmt/utils/Makefile.am b/mgmt/utils/Makefile.am index b8ed71608ef..7941be7eb7d 100644 --- a/mgmt/utils/Makefile.am +++ b/mgmt/utils/Makefile.am @@ -22,10 +22,10 @@ AM_CPPFLAGS += \ -I$(abs_top_srcdir)/mgmt \ -I$(abs_top_srcdir)/mgmt/api \ -I$(abs_top_srcdir)/mgmt/api/include \ - -I$(abs_top_srcdir)/lib/tsconfig \ + -I$(abs_top_srcdir)/include/tsconfig \ -I$(abs_top_srcdir)/proxy \ - -I$(abs_top_srcdir)/lib/records \ - -I$(abs_top_srcdir)/lib \ + -I$(abs_top_srcdir)/include/records \ + -I$(abs_top_srcdir)/include \ $(TS_INCLUDES) \ @OPENSSL_INCLUDES@ @@ -62,7 +62,8 @@ test_marshall_LDFLAGS = \ test_marshall_SOURCES = test_marshall.cc test_marshall_LDADD = \ libutils_p.la \ - $(top_builddir)/lib/ts/libtsutil.la + $(top_builddir)/src/tscore/libtscore.la \ + $(top_builddir)/src/tscpp/util/libtscpputil.la include $(top_srcdir)/build/tidy.mk diff --git a/mgmt/utils/MgmtHashTable.h b/mgmt/utils/MgmtHashTable.h index ea50e0338aa..a21ec565407 100644 --- a/mgmt/utils/MgmtHashTable.h +++ b/mgmt/utils/MgmtHashTable.h @@ -32,9 +32,9 @@ #pragma once -#include "ts/ink_memory.h" -#include "ts/ink_hash_table.h" -#include "ts/ink_mutex.h" +#include "tscore/ink_memory.h" +#include "tscore/ink_hash_table.h" +#include "tscore/ink_mutex.h" class MgmtHashTable { diff --git a/mgmt/utils/MgmtMarshall.cc b/mgmt/utils/MgmtMarshall.cc index c7d8fd0c71c..eb2358600c3 100644 --- a/mgmt/utils/MgmtMarshall.cc +++ b/mgmt/utils/MgmtMarshall.cc @@ -21,9 +21,9 @@ limitations under the License. */ -#include "ts/ink_platform.h" -#include "ts/ink_memory.h" -#include "ts/ink_assert.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_memory.h" +#include "tscore/ink_assert.h" #include "MgmtMarshall.h" #include "MgmtSocket.h" diff --git a/mgmt/utils/MgmtSocket.cc b/mgmt/utils/MgmtSocket.cc index a6d9d8d30f0..5bd6bb014a1 100644 --- a/mgmt/utils/MgmtSocket.cc +++ b/mgmt/utils/MgmtSocket.cc @@ -21,9 +21,9 @@ limitations under the License. */ -#include "ts/ink_platform.h" -#include "ts/ink_assert.h" -#include "ts/ink_cap.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_assert.h" +#include "tscore/ink_cap.h" #include "MgmtSocket.h" #if HAVE_UCRED_H diff --git a/mgmt/utils/MgmtSocket.h b/mgmt/utils/MgmtSocket.h index 7ee8a8fe74f..99ecd88e952 100644 --- a/mgmt/utils/MgmtSocket.h +++ b/mgmt/utils/MgmtSocket.h @@ -23,7 +23,7 @@ #pragma once -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" //------------------------------------------------------------------------- // transient_error diff --git a/mgmt/utils/MgmtUtils.cc b/mgmt/utils/MgmtUtils.cc index 6e4b0fb8e23..57ad7ed737d 100644 --- a/mgmt/utils/MgmtUtils.cc +++ b/mgmt/utils/MgmtUtils.cc @@ -20,11 +20,11 @@ See the License for the specific language governing permissions and limitations under the License. */ -#include "ts/ink_platform.h" -#include "ts/ink_sock.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_sock.h" #include "MgmtUtils.h" #include "MgmtSocket.h" -#include "ts/Diags.h" +#include "tscore/Diags.h" #include "LocalManager.h" diff --git a/mgmt/utils/MgmtUtils.h b/mgmt/utils/MgmtUtils.h index 66a735442d6..16a3da83e5a 100644 --- a/mgmt/utils/MgmtUtils.h +++ b/mgmt/utils/MgmtUtils.h @@ -33,10 +33,10 @@ #pragma once -#include "ts/ink_platform.h" -#include "ts/Diags.h" +#include "tscore/ink_platform.h" +#include "tscore/Diags.h" -#include "P_RecCore.h" +#include "records/P_RecCore.h" constexpr const char SSL_SERVER_NAME_CONFIG[] = "ssl_server_name.yaml"; diff --git a/mgmt/utils/test_marshall.cc b/mgmt/utils/test_marshall.cc index 136f049cd1d..b83d3cd54a1 100644 --- a/mgmt/utils/test_marshall.cc +++ b/mgmt/utils/test_marshall.cc @@ -16,11 +16,11 @@ * limitations under the License. */ -#include "ts/ink_defs.h" -#include "ts/ink_thread.h" -#include "ts/ink_inet.h" +#include "tscore/ink_defs.h" +#include "tscore/ink_thread.h" +#include "tscore/ink_inet.h" -#include +#include "tscore/TestBox.h" #include #include diff --git a/plugins/authproxy/authproxy.cc b/plugins/authproxy/authproxy.cc index 1537398ab1d..dd1390c39f0 100644 --- a/plugins/authproxy/authproxy.cc +++ b/plugins/authproxy/authproxy.cc @@ -38,7 +38,7 @@ #include #include -#include "ts/ink_config.h" +#include "tscore/ink_config.h" using std::strlen; diff --git a/plugins/background_fetch/configs.h b/plugins/background_fetch/configs.h index 422111b71ff..0af048f8491 100644 --- a/plugins/background_fetch/configs.h +++ b/plugins/background_fetch/configs.h @@ -27,7 +27,7 @@ #include #include "rules.h" -#include "ts/ink_atomic.h" +#include "tscore/ink_atomic.h" // Constants const char PLUGIN_NAME[] = "background_fetch"; diff --git a/plugins/cache_promote/cache_promote.cc b/plugins/cache_promote/cache_promote.cc index 8205fe7c64d..d05127a548f 100644 --- a/plugins/cache_promote/cache_promote.cc +++ b/plugins/cache_promote/cache_promote.cc @@ -30,7 +30,7 @@ #include "ts/ts.h" #include "ts/remap.h" -#include "ts/ink_config.h" +#include "tscore/ink_config.h" #define MINIMUM_BUCKET_SIZE 10 diff --git a/plugins/cachekey/pattern.h b/plugins/cachekey/pattern.h index 3cb7d582b69..876edf0a3db 100644 --- a/plugins/cachekey/pattern.h +++ b/plugins/cachekey/pattern.h @@ -23,7 +23,7 @@ #pragma once -#include "ts/ink_defs.h" +#include "tscore/ink_defs.h" #ifdef HAVE_PCRE_PCRE_H #include diff --git a/plugins/compress/compress.cc b/plugins/compress/compress.cc index 612714e5e01..6eb9b72e784 100644 --- a/plugins/compress/compress.cc +++ b/plugins/compress/compress.cc @@ -29,7 +29,7 @@ #endif #include "ts/ts.h" -#include "ts/ink_defs.h" +#include "tscore/ink_defs.h" #include "debug_macros.h" #include "misc.h" diff --git a/plugins/compress/configuration.h b/plugins/compress/configuration.h index d20f754c168..df5f74de0ad 100644 --- a/plugins/compress/configuration.h +++ b/plugins/compress/configuration.h @@ -27,8 +27,8 @@ #include #include #include "debug_macros.h" -#include "ts/ink_atomic.h" -#include +#include "tscore/ink_atomic.h" +#include "tscpp/api/noncopyable.h" namespace Gzip { diff --git a/plugins/compress/misc.cc b/plugins/compress/misc.cc index 9f572d3bbe1..8c4b3bb500c 100644 --- a/plugins/compress/misc.cc +++ b/plugins/compress/misc.cc @@ -22,7 +22,7 @@ */ #include "ts/ts.h" -#include "ts/ink_defs.h" +#include "tscore/ink_defs.h" #include "misc.h" #include diff --git a/plugins/conf_remap/conf_remap.cc b/plugins/conf_remap/conf_remap.cc index 6a0177278e8..a821ba70dda 100644 --- a/plugins/conf_remap/conf_remap.cc +++ b/plugins/conf_remap/conf_remap.cc @@ -18,7 +18,7 @@ #include "ts/ts.h" #include "ts/remap.h" -#include "ts/ink_defs.h" +#include "tscore/ink_defs.h" #include #include diff --git a/plugins/esi/combo_handler.cc b/plugins/esi/combo_handler.cc index 9f1b0474ea9..4a5c336fb1d 100644 --- a/plugins/esi/combo_handler.cc +++ b/plugins/esi/combo_handler.cc @@ -35,7 +35,7 @@ #include "ts/ts.h" #include "ts/experimental.h" #include "ts/remap.h" -#include "ts/ink_defs.h" +#include "tscore/ink_defs.h" #include "HttpDataFetcherImpl.h" #include "gzip.h" diff --git a/plugins/esi/esi.cc b/plugins/esi/esi.cc index 0e3800ecf51..9aa8d61b561 100644 --- a/plugins/esi/esi.cc +++ b/plugins/esi/esi.cc @@ -21,7 +21,7 @@ limitations under the License. */ -#include "ts/ink_defs.h" +#include "tscore/ink_defs.h" #include #include diff --git a/plugins/esi/serverIntercept.cc b/plugins/esi/serverIntercept.cc index 00d5f3dd20d..a7c1c26c9de 100644 --- a/plugins/esi/serverIntercept.cc +++ b/plugins/esi/serverIntercept.cc @@ -21,7 +21,7 @@ limitations under the License. */ -#include "ts/ink_defs.h" +#include "tscore/ink_defs.h" #include "serverIntercept.h" #include diff --git a/plugins/experimental/access_control/Makefile.inc b/plugins/experimental/access_control/Makefile.inc index fc4c16b1eba..3fefd4f9cdc 100644 --- a/plugins/experimental/access_control/Makefile.inc +++ b/plugins/experimental/access_control/Makefile.inc @@ -30,8 +30,8 @@ check_PROGRAMS += experimental/access_control/test_access_control experimental_access_control_test_access_control_CPPFLAGS = $(AM_CPPFLAGS) -I$(abs_top_srcdir)/tests/include -DACCESS_CONTROL_UNIT_TEST experimental_access_control_test_access_control_LDADD = $(OPENSSL_LIBS) experimental_access_control_test_access_control_SOURCES = \ - experimental/access_control/unit-tests/test_access_control.cc \ - experimental/access_control/unit-tests/test_utils.cc \ + experimental/access_control/unit_tests/test_access_control.cc \ + experimental/access_control/unit_tests/test_utils.cc \ experimental/access_control/access_control.cc \ experimental/access_control/common.cc \ experimental/access_control/utils.cc diff --git a/plugins/experimental/access_control/unit-tests/test_access_control.cc b/plugins/experimental/access_control/unit_tests/test_access_control.cc similarity index 100% rename from plugins/experimental/access_control/unit-tests/test_access_control.cc rename to plugins/experimental/access_control/unit_tests/test_access_control.cc diff --git a/plugins/experimental/access_control/unit-tests/test_utils.cc b/plugins/experimental/access_control/unit_tests/test_utils.cc similarity index 100% rename from plugins/experimental/access_control/unit-tests/test_utils.cc rename to plugins/experimental/access_control/unit_tests/test_utils.cc diff --git a/plugins/experimental/acme/acme.c b/plugins/experimental/acme/acme.c index e7deee3499c..32c899d61a3 100644 --- a/plugins/experimental/acme/acme.c +++ b/plugins/experimental/acme/acme.c @@ -25,8 +25,8 @@ limitations under the License. #include #include "ts/ts.h" -#include "ts/ink_platform.h" -#include "ts/ink_defs.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_defs.h" static const char PLUGIN_NAME[] = "acme"; static const char ACME_WK_PATH[] = ".well-known/acme-challenge/"; diff --git a/plugins/experimental/balancer/balancer.cc b/plugins/experimental/balancer/balancer.cc index 1af60e06f37..4bce592a94e 100644 --- a/plugins/experimental/balancer/balancer.cc +++ b/plugins/experimental/balancer/balancer.cc @@ -30,7 +30,7 @@ #include // Using ink_inet API is cheating, but I was too lazy to write new IPv6 address parsing routines ;) -#include "ts/ink_inet.h" +#include "tscore/ink_inet.h" // The policy type is the first comma-separated token. static BalancerInstance * diff --git a/plugins/experimental/geoip_acl/acl.h b/plugins/experimental/geoip_acl/acl.h index 89125b76d0e..f66b9c240c6 100644 --- a/plugins/experimental/geoip_acl/acl.h +++ b/plugins/experimental/geoip_acl/acl.h @@ -22,7 +22,7 @@ #include #include -#include "ts/ink_defs.h" +#include "tscore/ink_defs.h" #ifdef HAVE_PCRE_PCRE_H #include diff --git a/plugins/experimental/geoip_acl/lulu.h b/plugins/experimental/geoip_acl/lulu.h index 77a786a2675..c4c9cd99b5e 100644 --- a/plugins/experimental/geoip_acl/lulu.h +++ b/plugins/experimental/geoip_acl/lulu.h @@ -24,8 +24,8 @@ #include -#include "ts/ink_defs.h" -#include "ts/ink_atomic.h" +#include "tscore/ink_defs.h" +#include "tscore/ink_atomic.h" // Used for Debug etc. static const char *PLUGIN_NAME = "geoip_acl"; diff --git a/plugins/experimental/memcache/Makefile.inc b/plugins/experimental/memcache/Makefile.inc index 496667453c0..42638db8274 100644 --- a/plugins/experimental/memcache/Makefile.inc +++ b/plugins/experimental/memcache/Makefile.inc @@ -22,9 +22,9 @@ experimental_memcache_tsmemcache_la_CPPFLAGS = \ -I$(abs_top_srcdir)/iocore/eventsystem \ -I$(abs_top_srcdir)/iocore/net \ -I$(abs_top_srcdir)/iocore/utils \ - -I$(abs_top_srcdir)/lib \ - -I$(abs_top_srcdir)/lib/records \ - -I$(abs_top_srcdir)/lib/ts + -I$(abs_top_srcdir)/include \ + -I$(abs_top_srcdir)/include/records \ + -I$(abs_top_srcdir)/include/ts pkglib_LTLIBRARIES += experimental/memcache/tsmemcache.la diff --git a/plugins/experimental/memcache/tsmemcache.h b/plugins/experimental/memcache/tsmemcache.h index 5630230dadc..c43fc1f032e 100644 --- a/plugins/experimental/memcache/tsmemcache.h +++ b/plugins/experimental/memcache/tsmemcache.h @@ -27,13 +27,13 @@ #include "I_EventSystem.h" #include "I_Net.h" #include "I_Cache.h" -#include "I_Version.h" +#include "tscore/I_Version.h" #include "ts/ts.h" // plugin header #include "protocol_binary.h" -#include "ink_memory.h" -#include "ink_hrtime.h" -#include "CryptoHash.h" +#include "tscore/ink_memory.h" +#include "tscore/ink_hrtime.h" +#include "tscore/CryptoHash.h" #define TSMEMCACHE_VERSION "1.0.0" #define TSMEMCACHE_MAX_CMD_SIZE (128 * 1024 * 1024) // silly large diff --git a/plugins/experimental/remap_purge/remap_purge.c b/plugins/experimental/remap_purge/remap_purge.c index 4a20b9046ac..a8ce00fb2ce 100644 --- a/plugins/experimental/remap_purge/remap_purge.c +++ b/plugins/experimental/remap_purge/remap_purge.c @@ -34,7 +34,7 @@ #include "ts/ts.h" #include "ts/remap.h" -#include "ts/ink_defs.h" +#include "tscore/ink_defs.h" static const char *PLUGIN_NAME = "remap_purge"; static const char *DEFAULT_DIR = "var/trafficserver"; /* Not perfect, but no better API) */ diff --git a/plugins/experimental/remap_stats/remap_stats.c b/plugins/experimental/remap_stats/remap_stats.c index 8bf0686845b..240b2cff4f3 100644 --- a/plugins/experimental/remap_stats/remap_stats.c +++ b/plugins/experimental/remap_stats/remap_stats.c @@ -19,8 +19,8 @@ limitations under the License. */ -#include "ts/ink_config.h" -#include "ts/ink_defs.h" +#include "tscore/ink_config.h" +#include "tscore/ink_defs.h" #include "ts/ts.h" #include diff --git a/plugins/experimental/server_push_preload/Makefile.inc b/plugins/experimental/server_push_preload/Makefile.inc index 0f91e6582f3..d1fe0887d9a 100644 --- a/plugins/experimental/server_push_preload/Makefile.inc +++ b/plugins/experimental/server_push_preload/Makefile.inc @@ -20,8 +20,8 @@ experimental_server_push_preload_server_push_preload_la_SOURCES = \ experimental/server_push_preload/server_push_preload.cc experimental_server_push_preload_server_push_preload_la_LDFLAGS = \ - $(AM_LDFLAGS) \ - -L$(top_builddir)/lib/cppapi + $(AM_LDFLAGS) experimental_server_push_preload_server_push_preload_la_LIBADD = \ - -latscppapi + $(top_builddir)/src/tscpp/api/libtscppapi.la + diff --git a/plugins/experimental/server_push_preload/server_push_preload.cc b/plugins/experimental/server_push_preload/server_push_preload.cc index 1147c9326c8..def21cca672 100644 --- a/plugins/experimental/server_push_preload/server_push_preload.cc +++ b/plugins/experimental/server_push_preload/server_push_preload.cc @@ -27,8 +27,8 @@ #include #include #include -#include -#include +#include "tscpp/api/GlobalPlugin.h" +#include "tscpp/api/utils.h" #define PLUGIN_NAME "server_push_preload" #define PRELOAD_PARAM "rel=preload" diff --git a/plugins/experimental/ssl_cert_loader/ssl-cert-loader.cc b/plugins/experimental/ssl_cert_loader/ssl-cert-loader.cc index ef89cfa75ae..75546faeeaa 100644 --- a/plugins/experimental/ssl_cert_loader/ssl-cert-loader.cc +++ b/plugins/experimental/ssl_cert_loader/ssl-cert-loader.cc @@ -33,9 +33,9 @@ #include #include "domain-tree.h" -#include "ts/ink_inet.h" -#include "ts/ink_config.h" -#include "ts/IpMap.h" +#include "tscore/ink_inet.h" +#include "tscore/ink_config.h" +#include "tscore/IpMap.h" using ts::config::Configuration; using ts::config::Value; diff --git a/plugins/experimental/sslheaders/Makefile.inc b/plugins/experimental/sslheaders/Makefile.inc index 50b507006d7..3e77d29c450 100644 --- a/plugins/experimental/sslheaders/Makefile.inc +++ b/plugins/experimental/sslheaders/Makefile.inc @@ -17,7 +17,7 @@ sslheaders_CPP_FLAGS = \ $(AM_CPPFLAGS) \ @OPENSSL_INCLUDES@ \ - -I$(abs_top_srcdir)/lib + -I$(abs_top_srcdir)/include noinst_LTLIBRARIES += experimental/sslheaders/libsslhdr.la pkglib_LTLIBRARIES += experimental/sslheaders/sslheaders.la @@ -46,12 +46,13 @@ experimental_sslheaders_test_sslheaders_SOURCES = \ experimental_sslheaders_test_sslheaders_CPPFLAGS = \ $(AM_CPPFLAGS) \ @OPENSSL_INCLUDES@ \ - -I$(abs_top_srcdir)/lib + -I$(abs_top_srcdir)/include experimental_sslheaders_test_sslheaders_LDFLAGS = @OPENSSL_LDFLAGS@ experimental_sslheaders_test_sslheaders_LDADD = \ @AM_LDFLAGS@ \ experimental/sslheaders/libsslhdr.la \ - $(abs_top_builddir)/lib/ts/libtsutil.la \ + $(abs_top_builddir)/src/tscore/libtscore.la \ + $(top_builddir)/src/tscpp/util/libtscpputil.la \ @OPENSSL_LIBS@ # vim: ft=make ts=8 sw=8 et: diff --git a/plugins/experimental/sslheaders/expand.cc b/plugins/experimental/sslheaders/expand.cc index 142a98e852e..15b20d6ae2e 100644 --- a/plugins/experimental/sslheaders/expand.cc +++ b/plugins/experimental/sslheaders/expand.cc @@ -17,7 +17,7 @@ */ #include "sslheaders.h" -#include "ts/ink_defs.h" +#include "tscore/ink_defs.h" #include #include diff --git a/plugins/experimental/sslheaders/sslheaders.cc b/plugins/experimental/sslheaders/sslheaders.cc index 909b6258ab4..085c7ac4b05 100644 --- a/plugins/experimental/sslheaders/sslheaders.cc +++ b/plugins/experimental/sslheaders/sslheaders.cc @@ -17,7 +17,7 @@ */ #include "sslheaders.h" -#include "ts/ink_memory.h" +#include "tscore/ink_memory.h" #include #include diff --git a/plugins/experimental/sslheaders/test_sslheaders.cc b/plugins/experimental/sslheaders/test_sslheaders.cc index fa925db1e2d..a3c68bb2a7c 100644 --- a/plugins/experimental/sslheaders/test_sslheaders.cc +++ b/plugins/experimental/sslheaders/test_sslheaders.cc @@ -17,7 +17,7 @@ */ #include "sslheaders.h" -#include +#include "tscore/TestBox.h" #include #include #include diff --git a/plugins/experimental/sslheaders/util.cc b/plugins/experimental/sslheaders/util.cc index 47bebb20b84..d0feeff78cd 100644 --- a/plugins/experimental/sslheaders/util.cc +++ b/plugins/experimental/sslheaders/util.cc @@ -18,7 +18,7 @@ #include "sslheaders.h" #include -#include "ts/ink_defs.h" +#include "tscore/ink_defs.h" // Count of fields (not including SSL_HEADERS_FIELD_NONE). #define NUMFIELDS (SSL_HEADERS_FIELD_MAX - 1) diff --git a/plugins/experimental/stale_while_revalidate/stale_while_revalidate.c b/plugins/experimental/stale_while_revalidate/stale_while_revalidate.c index be137bba3dd..c49eb4043d0 100644 --- a/plugins/experimental/stale_while_revalidate/stale_while_revalidate.c +++ b/plugins/experimental/stale_while_revalidate/stale_while_revalidate.c @@ -31,7 +31,7 @@ #include #include -#include "ts/ink_defs.h" +#include "tscore/ink_defs.h" #include "ts/ts.h" #include "ts/experimental.h" diff --git a/plugins/experimental/system_stats/system_stats.c b/plugins/experimental/system_stats/system_stats.c index abb3afbb3e2..d25dada7d6f 100644 --- a/plugins/experimental/system_stats/system_stats.c +++ b/plugins/experimental/system_stats/system_stats.c @@ -19,8 +19,8 @@ limitations under the License. */ -#include "ts/ink_config.h" -#include "ts/ink_defs.h" +#include "tscore/ink_config.h" +#include "tscore/ink_defs.h" #include "ts/ts.h" #include diff --git a/plugins/experimental/tls_bridge/tls_bridge.cc b/plugins/experimental/tls_bridge/tls_bridge.cc index 2c6d9965897..0a699265700 100644 --- a/plugins/experimental/tls_bridge/tls_bridge.cc +++ b/plugins/experimental/tls_bridge/tls_bridge.cc @@ -20,7 +20,7 @@ #include #include #include -#include "ts/TextView.h" +#include "tscpp/util/TextView.h" #include "regex.h" #define PLUGIN_NAME "TLS Bridge" diff --git a/plugins/experimental/url_sig/url_sig.c b/plugins/experimental/url_sig/url_sig.c index 58bbbcd0917..65c36aca09f 100644 --- a/plugins/experimental/url_sig/url_sig.c +++ b/plugins/experimental/url_sig/url_sig.c @@ -23,7 +23,7 @@ _a < _b ? _a : _b; \ }) -#include "ts/ink_defs.h" +#include "tscore/ink_defs.h" #include "url_sig.h" #include diff --git a/plugins/experimental/webp_transform/ImageTransform.cc b/plugins/experimental/webp_transform/ImageTransform.cc index fb64186c564..8c7a1b0baec 100644 --- a/plugins/experimental/webp_transform/ImageTransform.cc +++ b/plugins/experimental/webp_transform/ImageTransform.cc @@ -19,10 +19,10 @@ #include #include #include -#include -#include -#include -#include +#include "tscpp/api/PluginInit.h" +#include "tscpp/api/GlobalPlugin.h" +#include "tscpp/api/TransformationPlugin.h" +#include "tscpp/api/Logger.h" #include diff --git a/plugins/header_rewrite/conditions.h b/plugins/header_rewrite/conditions.h index 916085ef628..be04da18fe7 100644 --- a/plugins/header_rewrite/conditions.h +++ b/plugins/header_rewrite/conditions.h @@ -25,7 +25,7 @@ #include #include "ts/ts.h" -#include "ts/ink_string.h" +#include "tscore/ink_string.h" #include "condition.h" #include "matcher.h" diff --git a/plugins/header_rewrite/header_rewrite.cc b/plugins/header_rewrite/header_rewrite.cc index 1942c1b9a1b..fb25b411be3 100644 --- a/plugins/header_rewrite/header_rewrite.cc +++ b/plugins/header_rewrite/header_rewrite.cc @@ -21,7 +21,7 @@ #include "ts/ts.h" #include "ts/remap.h" -#include "ts/ink_atomic.h" +#include "tscore/ink_atomic.h" #include "parser.h" #include "ruleset.h" diff --git a/plugins/header_rewrite/lulu.h b/plugins/header_rewrite/lulu.h index e9e02525705..c0c20f06380 100644 --- a/plugins/header_rewrite/lulu.h +++ b/plugins/header_rewrite/lulu.h @@ -24,8 +24,8 @@ #include -#include "ts/ink_defs.h" -#include "ts/ink_platform.h" +#include "tscore/ink_defs.h" +#include "tscore/ink_platform.h" #define TS_REMAP_PSEUDO_HOOK TS_HTTP_LAST_HOOK // Ugly, but use the "last hook" for remap instances. diff --git a/plugins/header_rewrite/operators.cc b/plugins/header_rewrite/operators.cc index 1bfaa9f1e65..9c2e5c02e9d 100644 --- a/plugins/header_rewrite/operators.cc +++ b/plugins/header_rewrite/operators.cc @@ -26,7 +26,7 @@ #include "operators.h" #include "expander.h" -#include "../../lib/ts/apidefs.h" +#include "ts/apidefs.h" // OperatorConfig void diff --git a/plugins/header_rewrite/regex_helper.h b/plugins/header_rewrite/regex_helper.h index 74db207e4a9..0b88f11c5d5 100644 --- a/plugins/header_rewrite/regex_helper.h +++ b/plugins/header_rewrite/regex_helper.h @@ -17,7 +17,7 @@ */ #pragma once -#include "ts/ink_defs.h" +#include "tscore/ink_defs.h" #ifdef HAVE_PCRE_PCRE_H #include diff --git a/plugins/healthchecks/healthchecks.c b/plugins/healthchecks/healthchecks.c index 37864b83ecf..c2fe0955a5b 100644 --- a/plugins/healthchecks/healthchecks.c +++ b/plugins/healthchecks/healthchecks.c @@ -33,8 +33,8 @@ limitations under the License. #include #include "ts/ts.h" -#include "ts/ink_platform.h" -#include "ts/ink_defs.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_defs.h" static const char PLUGIN_NAME[] = "healthchecks"; static const char SEPARATORS[] = " \t\n"; diff --git a/plugins/lua/ts_lua_client_request.c b/plugins/lua/ts_lua_client_request.c index f1176912b67..aef49cac10e 100644 --- a/plugins/lua/ts_lua_client_request.c +++ b/plugins/lua/ts_lua_client_request.c @@ -16,7 +16,7 @@ limitations under the License. */ -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #include #include "ts_lua_util.h" diff --git a/plugins/lua/ts_lua_common.h b/plugins/lua/ts_lua_common.h index 0115f0ebf61..b98e42fc07a 100644 --- a/plugins/lua/ts_lua_common.h +++ b/plugins/lua/ts_lua_common.h @@ -29,7 +29,7 @@ #include #include #include -#include "ts/ink_defs.h" +#include "tscore/ink_defs.h" #include "ts_lua_coroutine.h" #define TS_LUA_FUNCTION_REMAP "do_remap" diff --git a/plugins/lua/ts_lua_misc.c b/plugins/lua/ts_lua_misc.c index 380ea92f085..8da3a160aa0 100644 --- a/plugins/lua/ts_lua_misc.c +++ b/plugins/lua/ts_lua_misc.c @@ -16,7 +16,7 @@ limitations under the License. */ -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #include #include "ts_lua_util.h" diff --git a/plugins/lua/ts_lua_server_request.c b/plugins/lua/ts_lua_server_request.c index 3c52cc6c223..d0b26e0800b 100644 --- a/plugins/lua/ts_lua_server_request.c +++ b/plugins/lua/ts_lua_server_request.c @@ -16,7 +16,7 @@ limitations under the License. */ -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #include #include "ts_lua_util.h" diff --git a/plugins/regex_remap/regex_remap.cc b/plugins/regex_remap/regex_remap.cc index 920680abf31..484a0d9ca68 100644 --- a/plugins/regex_remap/regex_remap.cc +++ b/plugins/regex_remap/regex_remap.cc @@ -39,10 +39,10 @@ #include // Get some specific stuff from libts, yes, we can do that now that we build inside the core. -#include "ts/ink_platform.h" -#include "ts/ink_atomic.h" -#include "ts/ink_time.h" -#include "ts/ink_inet.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_atomic.h" +#include "tscore/ink_time.h" +#include "tscore/ink_inet.h" #ifdef HAVE_PCRE_PCRE_H #include diff --git a/plugins/regex_revalidate/regex_revalidate.c b/plugins/regex_revalidate/regex_revalidate.c index 260878fcdbd..4b009df2b8b 100644 --- a/plugins/regex_revalidate/regex_revalidate.c +++ b/plugins/regex_revalidate/regex_revalidate.c @@ -19,8 +19,8 @@ limitations under the License. */ -#include "ts/ink_defs.h" -#include "ts/ink_platform.h" +#include "tscore/ink_defs.h" +#include "tscore/ink_platform.h" #include #include diff --git a/plugins/s3_auth/Makefile.inc b/plugins/s3_auth/Makefile.inc index 696aa5e6ae0..b17ab21d7a5 100644 --- a/plugins/s3_auth/Makefile.inc +++ b/plugins/s3_auth/Makefile.inc @@ -22,5 +22,5 @@ check_PROGRAMS += s3_auth/test_s3auth s3_auth_test_s3auth_CPPFLAGS = $(AM_CPPFLAGS) -I$(abs_top_srcdir)/tests/include -DAWS_AUTH_V4_UNIT_TEST s3_auth_test_s3auth_LDADD = $(OPENSSL_LIBS) s3_auth_test_s3auth_SOURCES = \ - s3_auth/unit-tests/test_aws_auth_v4.cc \ + s3_auth/unit_tests/test_aws_auth_v4.cc \ s3_auth/aws_auth_v4.cc diff --git a/plugins/s3_auth/aws_auth_v4.h b/plugins/s3_auth/aws_auth_v4.h index 6e0b94a786f..f1b65158e86 100644 --- a/plugins/s3_auth/aws_auth_v4.h +++ b/plugins/s3_auth/aws_auth_v4.h @@ -52,7 +52,7 @@ class TsInterface }; #ifdef AWS_AUTH_V4_UNIT_TEST -#include "unit-tests/test_aws_auth_v4.h" +#include "unit_tests/test_aws_auth_v4.h" #else #include "aws_auth_v4_wrap.h" #endif diff --git a/plugins/s3_auth/s3_auth.cc b/plugins/s3_auth/s3_auth.cc index 4d65e293fdb..1d954057834 100644 --- a/plugins/s3_auth/s3_auth.cc +++ b/plugins/s3_auth/s3_auth.cc @@ -39,10 +39,10 @@ #include #include -#include +#include "tscore/ink_config.h" // Special snowflake here, only availbale when building inside the ATS source tree. -#include "ts/ink_atomic.h" +#include "tscore/ink_atomic.h" #include "aws_auth_v4.h" /////////////////////////////////////////////////////////////////////////////// diff --git a/plugins/s3_auth/unit-tests/test_aws_auth_v4.cc b/plugins/s3_auth/unit_tests/test_aws_auth_v4.cc similarity index 100% rename from plugins/s3_auth/unit-tests/test_aws_auth_v4.cc rename to plugins/s3_auth/unit_tests/test_aws_auth_v4.cc diff --git a/plugins/s3_auth/unit-tests/test_aws_auth_v4.h b/plugins/s3_auth/unit_tests/test_aws_auth_v4.h similarity index 100% rename from plugins/s3_auth/unit-tests/test_aws_auth_v4.h rename to plugins/s3_auth/unit_tests/test_aws_auth_v4.h diff --git a/plugins/stats_over_http/stats_over_http.c b/plugins/stats_over_http/stats_over_http.c index 72d4675170f..fe51f1710d8 100644 --- a/plugins/stats_over_http/stats_over_http.c +++ b/plugins/stats_over_http/stats_over_http.c @@ -34,7 +34,7 @@ #include #include -#include "ts/ink_defs.h" +#include "tscore/ink_defs.h" #define PLUGIN_NAME "stats_over_http" diff --git a/plugins/tcpinfo/tcpinfo.cc b/plugins/tcpinfo/tcpinfo.cc index 580b98cb833..dccb4c22300 100644 --- a/plugins/tcpinfo/tcpinfo.cc +++ b/plugins/tcpinfo/tcpinfo.cc @@ -38,8 +38,8 @@ #include #include -#include "ts/ink_defs.h" -#include "ts/ParseRules.h" +#include "tscore/ink_defs.h" +#include "tscore/ParseRules.h" #if defined(TCP_INFO) && defined(HAVE_STRUCT_TCP_INFO) #define TCPI_PLUGIN_SUPPORTED 1 diff --git a/plugins/test_cppapi/Makefile.inc b/plugins/test_cppapi/Makefile.inc index 42a0e7aa98f..7afe5d885b5 100644 --- a/plugins/test_cppapi/Makefile.inc +++ b/plugins/test_cppapi/Makefile.inc @@ -15,5 +15,5 @@ # limitations under the License. pkglib_LTLIBRARIES += test_cppapi/test_cppapi.la -test_cppapi_test_cppapi_la_LIBADD = $(top_builddir)/lib/cppapi/libatscppapi.la +test_cppapi_test_cppapi_la_LIBADD = $(top_builddir)/src/tscpp/api/libtscppapi.la test_cppapi_test_cppapi_la_SOURCES = test_cppapi/test_cppapi.cc diff --git a/plugins/test_cppapi/test_cppapi.cc b/plugins/test_cppapi/test_cppapi.cc index 5a72ffe622f..7b93e0cd50a 100644 --- a/plugins/test_cppapi/test_cppapi.cc +++ b/plugins/test_cppapi/test_cppapi.cc @@ -22,9 +22,9 @@ #include -#include +#include "tscpp/util/TextView.h" -#include +#include "tscpp/api/Continuation.h" // TSReleaseAssert() doesn't seem to produce any logging output for a debug build, so do both kinds of assert. // diff --git a/plugins/xdebug/xdebug.cc b/plugins/xdebug/xdebug.cc index 785648d13a3..42e83d8def6 100644 --- a/plugins/xdebug/xdebug.cc +++ b/plugins/xdebug/xdebug.cc @@ -25,7 +25,7 @@ #include #include "ts/ts.h" -#include "ts/ink_defs.h" +#include "tscore/ink_defs.h" #define DEBUG_TAG_LOG_HEADERS "xdebug.headers" diff --git a/proxy/CacheControl.cc b/proxy/CacheControl.cc index 271c296cb20..5d5da5efde3 100644 --- a/proxy/CacheControl.cc +++ b/proxy/CacheControl.cc @@ -30,7 +30,7 @@ #include -#include "ts/ink_config.h" +#include "tscore/ink_config.h" #include "CacheControl.h" #include "ControlMatcher.h" #include "Main.h" @@ -39,7 +39,7 @@ #include "HTTP.h" #include "HttpConfig.h" #include "P_Cache.h" -#include "ts/Regex.h" +#include "tscore/Regex.h" static const char modulePrefix[] = "[CacheControl]"; diff --git a/proxy/CacheControl.h b/proxy/CacheControl.h index 8383179ead2..ab072783e27 100644 --- a/proxy/CacheControl.h +++ b/proxy/CacheControl.h @@ -33,7 +33,7 @@ #include "Main.h" #include "P_EventSystem.h" #include "ControlBase.h" -#include "ts/Result.h" +#include "tscore/Result.h" struct RequestData; diff --git a/proxy/ControlBase.cc b/proxy/ControlBase.cc index cfa08c89b95..68a546592da 100644 --- a/proxy/ControlBase.cc +++ b/proxy/ControlBase.cc @@ -28,20 +28,20 @@ * * ****************************************************************************/ -#include "ts/ink_platform.h" -#include "ts/ink_defs.h" -#include "ts/ink_time.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_defs.h" +#include "tscore/ink_time.h" #include "Main.h" #include "URL.h" -#include "ts/Tokenizer.h" +#include "tscore/Tokenizer.h" #include "ControlBase.h" -#include "ts/MatcherUtils.h" +#include "tscore/MatcherUtils.h" #include "HTTP.h" #include "ControlMatcher.h" #include "HdrUtils.h" -#include +#include "tscore/TsBuffer.h" #include diff --git a/proxy/ControlBase.h b/proxy/ControlBase.h index ceea278ab88..844276f8285 100644 --- a/proxy/ControlBase.h +++ b/proxy/ControlBase.h @@ -31,7 +31,7 @@ #pragma once -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #include "vector" class HttpRequestData; diff --git a/proxy/ControlMatcher.cc b/proxy/ControlMatcher.cc index d96f139a432..d883f961992 100644 --- a/proxy/ControlMatcher.cc +++ b/proxy/ControlMatcher.cc @@ -30,15 +30,15 @@ #include -#include "ts/ink_config.h" -#include "ts/MatcherUtils.h" -#include "ts/Tokenizer.h" +#include "tscore/ink_config.h" +#include "tscore/MatcherUtils.h" +#include "tscore/Tokenizer.h" #include "Main.h" #include "ProxyConfig.h" #include "ControlMatcher.h" #include "CacheControl.h" #include "ParentSelection.h" -#include "ts/HostLookup.h" +#include "tscore/HostLookup.h" #include "HTTP.h" #include "URL.h" #include "P_EventSystem.h" diff --git a/proxy/ControlMatcher.h b/proxy/ControlMatcher.h index 40d53dc7978..b47085e9982 100644 --- a/proxy/ControlMatcher.h +++ b/proxy/ControlMatcher.h @@ -86,16 +86,16 @@ #pragma once -#include "ts/DynArray.h" -#include "ts/ink_hash_table.h" -#include "ts/IpMap.h" -#include "ts/Result.h" -#include "ts/MatcherUtils.h" - -#include "ts/ink_apidefs.h" -#include "ts/ink_defs.h" +#include "tscore/DynArray.h" +#include "tscore/ink_hash_table.h" +#include "tscore/IpMap.h" +#include "tscore/Result.h" +#include "tscore/MatcherUtils.h" + +#include "tscore/ink_apidefs.h" +#include "tscore/ink_defs.h" #include "HTTP.h" -#include "ts/Regex.h" +#include "tscore/Regex.h" #include "URL.h" #ifdef HAVE_CTYPE_H diff --git a/proxy/HostStatus.h b/proxy/HostStatus.h index 6eddb219897..18f127e17ea 100644 --- a/proxy/HostStatus.h +++ b/proxy/HostStatus.h @@ -32,7 +32,7 @@ #include "ControlBase.h" #include "ControlMatcher.h" -#include "P_RecProcess.h" +#include "records/P_RecProcess.h" enum HostStatus_t { HOST_STATUS_INIT, diff --git a/proxy/IPAllow.cc b/proxy/IPAllow.cc index acb42816d0b..a8cfd0270ee 100644 --- a/proxy/IPAllow.cc +++ b/proxy/IPAllow.cc @@ -28,7 +28,7 @@ * ****************************************************************************/ -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #include "Main.h" #include "IPAllow.h" #include "ProxyConfig.h" diff --git a/proxy/IPAllow.h b/proxy/IPAllow.h index 70390951700..be2a880d51d 100644 --- a/proxy/IPAllow.h +++ b/proxy/IPAllow.h @@ -32,7 +32,7 @@ #include "Main.h" #include "hdrs/HTTP.h" -#include "ts/IpMap.h" +#include "tscore/IpMap.h" #include "ProxyConfig.h" #include diff --git a/proxy/InkAPIInternal.h b/proxy/InkAPIInternal.h index 05e579455ff..99aaec20add 100644 --- a/proxy/InkAPIInternal.h +++ b/proxy/InkAPIInternal.h @@ -27,13 +27,13 @@ #include "URL.h" #include "P_Net.h" #include "HTTP.h" -#include "ts/List.h" +#include "tscore/List.h" #include "ProxyConfig.h" #include "P_Cache.h" #include "I_Tasks.h" -#include "api/ts/InkAPIPrivateIOCore.h" -#include "api/ts/experimental.h" +#include "ts/InkAPIPrivateIOCore.h" +#include "ts/experimental.h" #include diff --git a/proxy/Main.h b/proxy/Main.h index 14e36e3bdb8..cdfc3e3efcd 100644 --- a/proxy/Main.h +++ b/proxy/Main.h @@ -22,11 +22,11 @@ */ #pragma once -#include "ts/ink_platform.h" -#include "ts/ink_apidefs.h" -#include -#include "ts/Regression.h" -#include "ts/I_Version.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_apidefs.h" +#include "tscore/ink_defs.h" +#include "tscore/Regression.h" +#include "tscore/I_Version.h" // // Constants diff --git a/proxy/Makefile.am b/proxy/Makefile.am index c996669382a..57c362dd317 100644 --- a/proxy/Makefile.am +++ b/proxy/Makefile.am @@ -24,8 +24,8 @@ noinst_LIBRARIES = libproxy.a AM_CPPFLAGS += \ $(iocore_include_dirs) \ - -I$(abs_top_srcdir)/lib \ - -I$(abs_top_srcdir)/lib/records \ + -I$(abs_top_srcdir)/include \ + -I$(abs_top_srcdir)/include/records \ -I$(abs_srcdir)/http \ -I$(abs_srcdir)/logging \ -I$(abs_srcdir)/http/remap \ diff --git a/proxy/Milestones.h b/proxy/Milestones.h index 52265cdeabc..d429e285b81 100644 --- a/proxy/Milestones.h +++ b/proxy/Milestones.h @@ -23,10 +23,10 @@ #pragma once -#include "ts/ink_platform.h" -#include "ts/ink_hrtime.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_hrtime.h" #include "ts/apidefs.h" -#include "../lib/ts/ink_hrtime.h" +#include "tscore/ink_hrtime.h" ///////////////////////////////////////////////////////////// // diff --git a/proxy/ParentConsistentHash.h b/proxy/ParentConsistentHash.h index 72fb676ead7..3a8ee582789 100644 --- a/proxy/ParentConsistentHash.h +++ b/proxy/ParentConsistentHash.h @@ -29,7 +29,7 @@ #pragma once -#include "ts/HashSip.h" +#include "tscore/HashSip.h" #include "ParentSelection.h" // diff --git a/proxy/ParentSelection.h b/proxy/ParentSelection.h index 54e5cc37bc1..ee3dcab24db 100644 --- a/proxy/ParentSelection.h +++ b/proxy/ParentSelection.h @@ -34,10 +34,10 @@ #include "ProxyConfig.h" #include "ControlBase.h" #include "ControlMatcher.h" -#include "P_RecProcess.h" -#include "ts/ConsistentHash.h" -#include "ts/Tokenizer.h" -#include "ts/ink_apidefs.h" +#include "records/P_RecProcess.h" +#include "tscore/ConsistentHash.h" +#include "tscore/Tokenizer.h" +#include "tscore/ink_apidefs.h" #include "HostStatus.h" #include diff --git a/proxy/Plugin.cc b/proxy/Plugin.cc index 587ec4dfc43..075d9596565 100644 --- a/proxy/Plugin.cc +++ b/proxy/Plugin.cc @@ -22,15 +22,15 @@ */ #include -#include "ts/ink_platform.h" -#include "ts/ink_file.h" -#include "ts/ParseRules.h" -#include "I_RecCore.h" -#include "ts/I_Layout.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_file.h" +#include "tscore/ParseRules.h" +#include "records/I_RecCore.h" +#include "tscore/I_Layout.h" #include "InkAPIInternal.h" #include "Main.h" #include "Plugin.h" -#include "ts/ink_cap.h" +#include "tscore/ink_cap.h" #define MAX_PLUGIN_ARGS 64 diff --git a/proxy/Plugin.h b/proxy/Plugin.h index 198cdfe2337..349a1482fa7 100644 --- a/proxy/Plugin.h +++ b/proxy/Plugin.h @@ -23,7 +23,7 @@ #pragma once -#include "ts/List.h" +#include "tscore/List.h" struct PluginRegInfo { PluginRegInfo(); diff --git a/proxy/PluginVC.cc b/proxy/PluginVC.cc index 7f5db486429..760a0f291fd 100644 --- a/proxy/PluginVC.cc +++ b/proxy/PluginVC.cc @@ -74,7 +74,7 @@ #include "PluginVC.h" #include "P_EventSystem.h" #include "P_Net.h" -#include "ts/Regression.h" +#include "tscore/Regression.h" #define PVC_LOCK_RETRY_TIME HRTIME_MSECONDS(10) #define PVC_DEFAULT_MAX_BYTES 32768 diff --git a/proxy/PluginVC.h b/proxy/PluginVC.h index c8519e24ce0..1e879efcced 100644 --- a/proxy/PluginVC.h +++ b/proxy/PluginVC.h @@ -37,7 +37,7 @@ #include "Plugin.h" #include "P_Net.h" -#include "ts/ink_atomic.h" +#include "tscore/ink_atomic.h" class PluginVCCore; diff --git a/proxy/ProxyClientSession.h b/proxy/ProxyClientSession.h index e08162c3aca..98e2e12205c 100644 --- a/proxy/ProxyClientSession.h +++ b/proxy/ProxyClientSession.h @@ -23,8 +23,8 @@ #pragma once -#include -#include +#include "tscore/ink_platform.h" +#include "tscore/ink_resolver.h" #include #include "P_Net.h" #include "InkAPIInternal.h" diff --git a/proxy/RegressionSM.h b/proxy/RegressionSM.h index 2031921112f..d643de37a8a 100644 --- a/proxy/RegressionSM.h +++ b/proxy/RegressionSM.h @@ -24,8 +24,8 @@ #pragma once #include "I_EventSystem.h" -#include "ts/Regression.h" -#include "ts/DynArray.h" +#include "tscore/Regression.h" +#include "tscore/DynArray.h" /* Regression Test Composition State Machine diff --git a/proxy/ReverseProxy.cc b/proxy/ReverseProxy.cc index 3d7e174ff22..f2eaf28539a 100644 --- a/proxy/ReverseProxy.cc +++ b/proxy/ReverseProxy.cc @@ -27,16 +27,16 @@ */ -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #include #include "Main.h" #include "P_EventSystem.h" #include "P_Cache.h" #include "ProxyConfig.h" #include "ReverseProxy.h" -#include "ts/MatcherUtils.h" -#include "ts/Tokenizer.h" -#include "api/ts/remap.h" +#include "tscore/MatcherUtils.h" +#include "tscore/Tokenizer.h" +#include "ts/remap.h" #include "RemapPluginInfo.h" #include "RemapProcessor.h" #include "UrlRewrite.h" diff --git a/proxy/ReverseProxy.h b/proxy/ReverseProxy.h index 4009b14b9dc..8839627de00 100644 --- a/proxy/ReverseProxy.h +++ b/proxy/ReverseProxy.h @@ -32,10 +32,10 @@ #pragma once -#include "P_RecProcess.h" +#include "records/P_RecProcess.h" -#include "ts/ink_hash_table.h" -#include "ts/ink_defs.h" +#include "tscore/ink_hash_table.h" +#include "tscore/ink_defs.h" #include "HttpTransact.h" #include "RemapPluginInfo.h" #include "UrlRewrite.h" diff --git a/proxy/StatPages.cc b/proxy/StatPages.cc index b98e9304821..16183c5e99f 100644 --- a/proxy/StatPages.cc +++ b/proxy/StatPages.cc @@ -28,11 +28,11 @@ ****************************************************************************/ -#include "ts/ink_config.h" +#include "tscore/ink_config.h" #include "ProxyConfig.h" #include "StatPages.h" #include "HdrUtils.h" -#include "ts/MatcherUtils.h" +#include "tscore/MatcherUtils.h" #define MAX_STAT_PAGES 32 diff --git a/proxy/hdrs/HTTP.cc b/proxy/hdrs/HTTP.cc index 907f6da7899..3858bd0cafa 100644 --- a/proxy/hdrs/HTTP.cc +++ b/proxy/hdrs/HTTP.cc @@ -21,15 +21,15 @@ limitations under the License. */ -#include "ts/ink_defs.h" -#include "ts/ink_platform.h" -#include "ts/ink_inet.h" +#include "tscore/ink_defs.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_inet.h" #include #include #include #include "HTTP.h" #include "HdrToken.h" -#include "ts/Diags.h" +#include "tscore/Diags.h" /*********************************************************************** * * diff --git a/proxy/hdrs/HTTP.h b/proxy/hdrs/HTTP.h index d229da4ff8f..682a65a3557 100644 --- a/proxy/hdrs/HTTP.h +++ b/proxy/hdrs/HTTP.h @@ -24,12 +24,12 @@ #pragma once #include -#include "ts/Arena.h" -#include "ts/CryptoHash.h" +#include "tscore/Arena.h" +#include "tscore/CryptoHash.h" #include "MIME.h" #include "URL.h" -#include "ts/ink_apidefs.h" +#include "tscore/ink_apidefs.h" #define HTTP_VERSION(a, b) ((((a)&0xFFFF) << 16) | ((b)&0xFFFF)) #define HTTP_MINOR(v) ((v)&0xFFFF) diff --git a/proxy/hdrs/HdrHeap.cc b/proxy/hdrs/HdrHeap.cc index 87490dd11c1..0de45b212c9 100644 --- a/proxy/hdrs/HdrHeap.cc +++ b/proxy/hdrs/HdrHeap.cc @@ -30,7 +30,7 @@ ****************************************************************************/ -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #include "HdrHeap.h" #include "URL.h" #include "MIME.h" @@ -1182,7 +1182,7 @@ struct StrTest { }; #if TS_HAS_TESTS -#include +#include "tscore/TestBox.h" REGRESSION_TEST(HdrHeap_Coalesce)(RegressionTest *t, int /* atype ATS_UNUSED */, int *pstatus) { *pstatus = REGRESSION_TEST_PASSED; diff --git a/proxy/hdrs/HdrHeap.h b/proxy/hdrs/HdrHeap.h index 9fb2e00c5e6..faa8c488910 100644 --- a/proxy/hdrs/HdrHeap.h +++ b/proxy/hdrs/HdrHeap.h @@ -32,10 +32,10 @@ #pragma once -#include "ts/Ptr.h" -#include "ts/ink_defs.h" -#include "ts/ink_assert.h" -#include "ts/Arena.h" +#include "tscore/Ptr.h" +#include "tscore/ink_defs.h" +#include "tscore/ink_assert.h" +#include "tscore/Arena.h" #include "HdrToken.h" // Objects in the heap must currently be aligned to 8 byte boundaries, diff --git a/proxy/hdrs/HdrTSOnly.cc b/proxy/hdrs/HdrTSOnly.cc index a9b9987378c..9f96b85ff25 100644 --- a/proxy/hdrs/HdrTSOnly.cc +++ b/proxy/hdrs/HdrTSOnly.cc @@ -37,7 +37,7 @@ ****************************************************************************/ -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #include "HTTP.h" #include "P_EventSystem.h" diff --git a/proxy/hdrs/HdrTest.cc b/proxy/hdrs/HdrTest.cc index 09bd49d7185..49107ca9623 100644 --- a/proxy/hdrs/HdrTest.cc +++ b/proxy/hdrs/HdrTest.cc @@ -32,14 +32,14 @@ ****************************************************************************/ -#include "ts/ink_platform.h" -#include "ts/ink_memory.h" -#include "ts/ink_time.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_memory.h" +#include "tscore/ink_time.h" -#include "ts/Arena.h" +#include "tscore/Arena.h" #include "HTTP.h" #include "MIME.h" -#include "ts/Regex.h" +#include "tscore/Regex.h" #include "URL.h" #include "HttpCompat.h" diff --git a/proxy/hdrs/HdrTest.h b/proxy/hdrs/HdrTest.h index 6c98f2600fb..9d5224d4912 100644 --- a/proxy/hdrs/HdrTest.h +++ b/proxy/hdrs/HdrTest.h @@ -34,7 +34,7 @@ #pragma once -#include "ts/Regression.h" +#include "tscore/Regression.h" class HdrTest { diff --git a/proxy/hdrs/HdrToken.cc b/proxy/hdrs/HdrToken.cc index 33e004f442c..55fe5200a6f 100644 --- a/proxy/hdrs/HdrToken.cc +++ b/proxy/hdrs/HdrToken.cc @@ -21,16 +21,16 @@ limitations under the License. */ -#include "ts/ink_platform.h" -#include "ts/HashFNV.h" -#include "ts/Diags.h" -#include "ts/ink_memory.h" +#include "tscore/ink_platform.h" +#include "tscore/HashFNV.h" +#include "tscore/Diags.h" +#include "tscore/ink_memory.h" #include -#include "ts/Allocator.h" +#include "tscore/Allocator.h" #include "HTTP.h" #include "HdrToken.h" #include "MIME.h" -#include "ts/Regex.h" +#include "tscore/Regex.h" #include "URL.h" /* diff --git a/proxy/hdrs/HdrToken.h b/proxy/hdrs/HdrToken.h index acaa1a09a83..ab5f4fb5beb 100644 --- a/proxy/hdrs/HdrToken.h +++ b/proxy/hdrs/HdrToken.h @@ -25,13 +25,13 @@ #include #include -#include "ts/ink_assert.h" -#include "ts/ink_atomic.h" -#include "ts/ink_defs.h" -#include "ts/ink_string.h" -#include "ts/Allocator.h" -#include "ts/Regex.h" -#include "ts/ink_apidefs.h" +#include "tscore/ink_assert.h" +#include "tscore/ink_atomic.h" +#include "tscore/ink_defs.h" +#include "tscore/ink_string.h" +#include "tscore/Allocator.h" +#include "tscore/Regex.h" +#include "tscore/ink_apidefs.h" //////////////////////////////////////////////////////////////////////////// // diff --git a/proxy/hdrs/HdrUtils.cc b/proxy/hdrs/HdrUtils.cc index 31aa4848875..37a00acda71 100644 --- a/proxy/hdrs/HdrUtils.cc +++ b/proxy/hdrs/HdrUtils.cc @@ -31,7 +31,7 @@ ****************************************************************************/ -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #include "HdrUtils.h" #define GETNEXT() \ diff --git a/proxy/hdrs/HdrUtils.h b/proxy/hdrs/HdrUtils.h index 7218fd6fdb3..df40737feb7 100644 --- a/proxy/hdrs/HdrUtils.h +++ b/proxy/hdrs/HdrUtils.h @@ -33,7 +33,7 @@ #pragma once -#include "ts/ParseRules.h" +#include "tscore/ParseRules.h" #include "MIME.h" // csv = comma separated value diff --git a/proxy/hdrs/HttpCompat.cc b/proxy/hdrs/HttpCompat.cc index 4ce1008e089..52f96836931 100644 --- a/proxy/hdrs/HttpCompat.cc +++ b/proxy/hdrs/HttpCompat.cc @@ -21,7 +21,7 @@ limitations under the License. */ -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #include "HttpCompat.h" #include "HdrUtils.h" /* MAGIC_EDITING_TAG */ diff --git a/proxy/hdrs/HttpCompat.h b/proxy/hdrs/HttpCompat.h index d534c1759b2..3b8a8554d4a 100644 --- a/proxy/hdrs/HttpCompat.h +++ b/proxy/hdrs/HttpCompat.h @@ -23,10 +23,10 @@ #pragma once -#include "ts/ink_string++.h" +#include "tscore/ink_string++.h" #include "MIME.h" -#include "ts/RawHashTable.h" -#include "ts/Diags.h" +#include "tscore/RawHashTable.h" +#include "tscore/Diags.h" struct HttpBodySetRawData { unsigned int magic; diff --git a/proxy/hdrs/MIME.cc b/proxy/hdrs/MIME.cc index ae0324e179a..c2a22c8c257 100644 --- a/proxy/hdrs/MIME.cc +++ b/proxy/hdrs/MIME.cc @@ -21,10 +21,10 @@ limitations under the License. */ -#include "ts/ink_defs.h" -#include "ts/ink_platform.h" -#include "ts/ink_memory.h" -#include "ts/TsBuffer.h" +#include "tscore/ink_defs.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_memory.h" +#include "tscore/TsBuffer.h" #include #include #include diff --git a/proxy/hdrs/MIME.h b/proxy/hdrs/MIME.h index fbdf4c83da4..d95f147d9f8 100644 --- a/proxy/hdrs/MIME.h +++ b/proxy/hdrs/MIME.h @@ -25,10 +25,10 @@ #include -#include "ts/ink_assert.h" -#include "ts/ink_apidefs.h" -#include "ts/ink_string++.h" -#include "ts/ParseRules.h" +#include "tscore/ink_assert.h" +#include "tscore/ink_apidefs.h" +#include "tscore/ink_string++.h" +#include "tscore/ParseRules.h" #include "HdrHeap.h" #include "HdrToken.h" diff --git a/proxy/hdrs/Makefile.am b/proxy/hdrs/Makefile.am index f2e5c27e77e..d1235539c2c 100644 --- a/proxy/hdrs/Makefile.am +++ b/proxy/hdrs/Makefile.am @@ -20,8 +20,8 @@ include $(top_srcdir)/build/tidy.mk AM_CPPFLAGS += \ $(iocore_include_dirs) \ - -I$(abs_top_srcdir)/lib \ - -I$(abs_top_srcdir)/lib/records \ + -I$(abs_top_srcdir)/include \ + -I$(abs_top_srcdir)/include/records \ $(TS_INCLUDES) noinst_LIBRARIES = libhdrs.a @@ -58,7 +58,8 @@ load_http_hdr_SOURCES = \ load_http_hdr.cc load_http_hdr_LDADD = -L. -lhdrs \ - $(top_builddir)/lib/ts/libtsutil.la \ + $(top_builddir)/src/tscore/libtscore.la \ + $(top_builddir)/src/tscpp/util/libtscpputil.la \ @LIBTCL@ check_PROGRAMS = test_mime @@ -66,7 +67,8 @@ check_PROGRAMS = test_mime TESTS = test_mime test_mime_LDADD = -L. -lhdrs \ - $(top_builddir)/lib/ts/libtsutil.la \ + $(top_builddir)/src/tscore/libtscore.la \ + $(top_builddir)/src/tscpp/util/libtscpputil.la \ $(top_builddir)/iocore/eventsystem/libinkevent.a \ $(top_builddir)/lib/records/librecords_p.a \ $(top_builddir)/mgmt/libmgmt_p.la \ diff --git a/proxy/hdrs/URL.cc b/proxy/hdrs/URL.cc index 3daea054a6c..8f94329796d 100644 --- a/proxy/hdrs/URL.cc +++ b/proxy/hdrs/URL.cc @@ -23,13 +23,13 @@ #include #include -#include "ts/ink_platform.h" -#include "ts/ink_memory.h" -#include "ts/TsBuffer.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_memory.h" +#include "tscore/TsBuffer.h" #include "URL.h" #include "MIME.h" #include "HTTP.h" -#include "ts/Diags.h" +#include "tscore/Diags.h" const char *URL_SCHEME_FILE; const char *URL_SCHEME_FTP; @@ -1805,7 +1805,7 @@ url_host_CryptoHash_get(URLImpl *url, CryptoHash *hash) * Regression tests -------------------------------------------------------------------------*/ #if TS_HAS_TESTS -#include "ts/TestBox.h" +#include "tscore/TestBox.h" const static struct { const char *const text; diff --git a/proxy/hdrs/URL.h b/proxy/hdrs/URL.h index 44b3929b2f8..d1fa5822d11 100644 --- a/proxy/hdrs/URL.h +++ b/proxy/hdrs/URL.h @@ -23,14 +23,14 @@ #pragma once -#include "ts/Arena.h" +#include "tscore/Arena.h" #include "HdrToken.h" #include "HdrHeap.h" -#include "ts/CryptoHash.h" +#include "tscore/CryptoHash.h" #include "MIME.h" #include -#include "ts/ink_apidefs.h" +#include "tscore/ink_apidefs.h" typedef int64_t cache_generation_t; diff --git a/proxy/hdrs/load_http_hdr.cc b/proxy/hdrs/load_http_hdr.cc index 66269bbbf59..95561e744d4 100644 --- a/proxy/hdrs/load_http_hdr.cc +++ b/proxy/hdrs/load_http_hdr.cc @@ -45,8 +45,8 @@ #include "HdrHeap.h" #include "MIME.h" #include "HTTP.h" -#include "ts/Tokenizer.h" -#include "ts/Diags.h" +#include "tscore/Tokenizer.h" +#include "tscore/Diags.h" #include #include #include diff --git a/proxy/hdrs/test_mime.cc b/proxy/hdrs/test_mime.cc index 634c31e4260..b5055f6bb27 100644 --- a/proxy/hdrs/test_mime.cc +++ b/proxy/hdrs/test_mime.cc @@ -21,7 +21,7 @@ limitations under the License. */ -#include +#include "tscore/TestBox.h" #include "I_EventSystem.h" #include "MIME.h" diff --git a/proxy/hdrs/test_urlhash.cc b/proxy/hdrs/test_urlhash.cc index 2a4124ba5d1..7eb1bf07de5 100644 --- a/proxy/hdrs/test_urlhash.cc +++ b/proxy/hdrs/test_urlhash.cc @@ -24,10 +24,10 @@ #include #include -#include "ts/Arena.h" +#include "tscore/Arena.h" #include "HTTP.h" #include "MIME.h" -#include "ts/Regex.h" +#include "tscore/Regex.h" #include "URL.h" #include "HttpCompat.h" diff --git a/proxy/http/ForwardedConfig.cc b/proxy/http/ForwardedConfig.cc index 1365dd86271..09caffc8320 100644 --- a/proxy/http/ForwardedConfig.cc +++ b/proxy/http/ForwardedConfig.cc @@ -26,7 +26,7 @@ #include #include -#include +#include "tscpp/util/TextView.h" #include diff --git a/proxy/http/Http1ClientSession.cc b/proxy/http/Http1ClientSession.cc index 4fae601b216..748e601f346 100644 --- a/proxy/http/Http1ClientSession.cc +++ b/proxy/http/Http1ClientSession.cc @@ -30,7 +30,7 @@ ****************************************************************************/ -#include +#include "tscore/ink_resolver.h" #include "Http1ClientSession.h" #include "Http1ClientTransaction.h" #include "HttpSM.h" diff --git a/proxy/http/HttpBodyFactory.cc b/proxy/http/HttpBodyFactory.cc index f5a61e544b7..162a515bf63 100644 --- a/proxy/http/HttpBodyFactory.cc +++ b/proxy/http/HttpBodyFactory.cc @@ -28,9 +28,9 @@ ****************************************************************************/ -#include "ts/ink_platform.h" -#include "ts/ink_sprintf.h" -#include "ts/ink_file.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_sprintf.h" +#include "tscore/ink_file.h" #include "HttpBodyFactory.h" #include #include @@ -40,7 +40,7 @@ #include "logging/Log.h" #include "logging/LogAccess.h" #include "HttpCompat.h" -#include "ts/I_Layout.h" +#include "tscore/I_Layout.h" ////////////////////////////////////////////////////////////////////// // The HttpBodyFactory creates HTTP response page bodies, supported // diff --git a/proxy/http/HttpBodyFactory.h b/proxy/http/HttpBodyFactory.h index 19145e99879..9fbaf1e4ada 100644 --- a/proxy/http/HttpBodyFactory.h +++ b/proxy/http/HttpBodyFactory.h @@ -56,14 +56,14 @@ #include #include -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #include "HTTP.h" #include "HttpConfig.h" #include "HttpCompat.h" #include "HttpTransact.h" #include "Main.h" -#include "ts/RawHashTable.h" -#include "ts/ink_sprintf.h" +#include "tscore/RawHashTable.h" +#include "tscore/ink_sprintf.h" #define HTTP_BODY_TEMPLATE_MAGIC 0xB0DFAC00 #define HTTP_BODY_SET_MAGIC 0xB0DFAC55 diff --git a/proxy/http/HttpConfig.cc b/proxy/http/HttpConfig.cc index 061802d9392..1afb230b6cf 100644 --- a/proxy/http/HttpConfig.cc +++ b/proxy/http/HttpConfig.cc @@ -21,7 +21,7 @@ limitations under the License. */ -#include "ts/ink_config.h" +#include "tscore/ink_config.h" #include #include #include "HttpConfig.h" @@ -29,7 +29,7 @@ #include "ProcessManager.h" #include "ProxyConfig.h" #include "P_Net.h" -#include "P_RecUtils.h" +#include "records/P_RecUtils.h" #include #define HttpEstablishStaticConfigStringAlloc(_ix, _n) \ diff --git a/proxy/http/HttpConfig.h b/proxy/http/HttpConfig.h index 644e586f026..ad070f73d02 100644 --- a/proxy/http/HttpConfig.h +++ b/proxy/http/HttpConfig.h @@ -41,15 +41,15 @@ #include #endif -#include "ts/ink_platform.h" -#include "ts/ink_inet.h" -#include "ts/IpMap.h" -#include "ts/Regex.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_inet.h" +#include "tscore/IpMap.h" +#include "tscore/Regex.h" #include "string_view" -#include "ts/BufferWriter.h" +#include "tscore/BufferWriter.h" #include "HttpProxyAPIEnums.h" #include "ProxyConfig.h" -#include "P_RecProcess.h" +#include "records/P_RecProcess.h" static const unsigned HTTP_STATUS_NUMBER = 600; using HttpStatusBitset = std::bitset; diff --git a/proxy/http/HttpConnectionCount.h b/proxy/http/HttpConnectionCount.h index 95677108a92..bb953150be7 100644 --- a/proxy/http/HttpConnectionCount.h +++ b/proxy/http/HttpConnectionCount.h @@ -22,13 +22,13 @@ */ // -#include "ts/ink_platform.h" -#include "ts/ink_inet.h" -#include "ts/ink_mutex.h" -#include "ts/Map.h" -#include "ts/Diags.h" -#include "ts/CryptoHash.h" -#include "ts/ink_config.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_inet.h" +#include "tscore/ink_mutex.h" +#include "tscore/Map.h" +#include "tscore/Diags.h" +#include "tscore/CryptoHash.h" +#include "tscore/ink_config.h" #include "HttpProxyAPIEnums.h" #include "Show.h" #include diff --git a/proxy/http/HttpDebugNames.h b/proxy/http/HttpDebugNames.h index ae76737e6b8..d94f1418e04 100644 --- a/proxy/http/HttpDebugNames.h +++ b/proxy/http/HttpDebugNames.h @@ -24,7 +24,7 @@ #pragma once #include "HttpTransact.h" -#include +#include "tscore/BufferWriter.h" class HttpDebugNames { diff --git a/proxy/http/HttpPages.h b/proxy/http/HttpPages.h index f5e1e885557..b51e45ed9d8 100644 --- a/proxy/http/HttpPages.h +++ b/proxy/http/HttpPages.h @@ -33,9 +33,9 @@ #pragma once -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #include "P_EventSystem.h" -#include "ts/DynArray.h" +#include "tscore/DynArray.h" #include "HTTP.h" #include "StatPages.h" #include "HttpSM.h" diff --git a/proxy/http/HttpProxyServerMain.cc b/proxy/http/HttpProxyServerMain.cc index 2362949c328..0a910ba0edb 100644 --- a/proxy/http/HttpProxyServerMain.cc +++ b/proxy/http/HttpProxyServerMain.cc @@ -21,7 +21,7 @@ limitations under the License. */ -#include "ts/ink_config.h" +#include "tscore/ink_config.h" #include "P_Net.h" #include "Main.h" #include "HttpConfig.h" @@ -34,7 +34,7 @@ #endif #include "HttpPages.h" #include "HttpTunnel.h" -#include "ts/Tokenizer.h" +#include "tscore/Tokenizer.h" #include "P_SSLNextProtocolAccept.h" #include "ProtocolProbeSessionAccept.h" #include "http2/Http2SessionAccept.h" diff --git a/proxy/http/HttpSM.cc b/proxy/http/HttpSM.cc index dbc41fe4324..36dcb9ca2b6 100644 --- a/proxy/http/HttpSM.cc +++ b/proxy/http/HttpSM.cc @@ -41,7 +41,7 @@ #include "P_SSLConfig.h" #include "HttpPages.h" #include "IPAllow.h" -#include "ts/I_Layout.h" +#include "tscore/I_Layout.h" #include #include diff --git a/proxy/http/HttpSM.h b/proxy/http/HttpSM.h index 6948d60ac2e..1f3ac23266d 100644 --- a/proxy/http/HttpSM.h +++ b/proxy/http/HttpSM.h @@ -32,7 +32,7 @@ #pragma once -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #include "P_EventSystem.h" #include "HttpCacheSM.h" #include "HttpTransact.h" @@ -42,7 +42,7 @@ #include "../ProxyClientTransaction.h" #include "HdrUtils.h" #include -#include +#include "tscore/History.h" //#include "AuthHttpAdapter.h" /* Enable LAZY_BUF_ALLOC to delay allocation of buffers until they diff --git a/proxy/http/HttpServerSession.cc b/proxy/http/HttpServerSession.cc index c70cf44bfd0..1260653bda4 100644 --- a/proxy/http/HttpServerSession.cc +++ b/proxy/http/HttpServerSession.cc @@ -28,8 +28,8 @@ Description: ****************************************************************************/ -#include "ts/ink_config.h" -#include "ts/Allocator.h" +#include "tscore/ink_config.h" +#include "tscore/Allocator.h" #include "HttpServerSession.h" #include "HttpSessionManager.h" #include "HttpSM.h" diff --git a/proxy/http/HttpSessionAccept.h b/proxy/http/HttpSessionAccept.h index 0a57eef1a8b..49d8350e849 100644 --- a/proxy/http/HttpSessionAccept.h +++ b/proxy/http/HttpSessionAccept.h @@ -23,7 +23,7 @@ #pragma once -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #include "records/I_RecHttp.h" #include "P_EventSystem.h" #include "HttpConfig.h" diff --git a/proxy/http/HttpSessionManager.h b/proxy/http/HttpSessionManager.h index 66998a720f9..54cf384a33e 100644 --- a/proxy/http/HttpSessionManager.h +++ b/proxy/http/HttpSessionManager.h @@ -34,7 +34,7 @@ #include "P_EventSystem.h" #include "HttpServerSession.h" -#include +#include "tscore/Map.h" class ProxyClientTransaction; class HttpSM; diff --git a/proxy/http/HttpTransact.cc b/proxy/http/HttpTransact.cc index 6dce383bd56..0d4b948dd81 100644 --- a/proxy/http/HttpTransact.cc +++ b/proxy/http/HttpTransact.cc @@ -21,7 +21,7 @@ limitations under the License. */ -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #include #include @@ -32,7 +32,7 @@ #include "HttpCacheSM.h" //Added to get the scope of HttpCacheSM object - YTS Team, yamsat #include "HttpDebugNames.h" #include -#include "ts/ParseRules.h" +#include "tscore/ParseRules.h" #include "HTTP.h" #include "HdrUtils.h" #include "logging/Log.h" diff --git a/proxy/http/HttpTransact.h b/proxy/http/HttpTransact.h index 9feebe569a0..e3ee61b28cb 100644 --- a/proxy/http/HttpTransact.h +++ b/proxy/http/HttpTransact.h @@ -23,7 +23,7 @@ #pragma once -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #include "P_HostDB.h" #include "P_Net.h" #include "HttpConfig.h" @@ -35,7 +35,7 @@ #include "ProxyConfig.h" #include "Transform.h" #include "Milestones.h" -#include "api/ts/remap.h" +#include "ts/remap.h" #include "RemapPluginInfo.h" #include "UrlMapping.h" #include "records/I_RecHttp.h" @@ -70,7 +70,7 @@ typedef time_t ink_time_t; struct HttpConfigParams; class HttpSM; -#include "ts/InkErrno.h" +#include "tscore/InkErrno.h" #define UNKNOWN_INTERNAL_ERROR (INK_START_ERRNO - 1) enum ViaStringIndex_t { diff --git a/proxy/http/HttpTransactCache.cc b/proxy/http/HttpTransactCache.cc index 5febd748e5b..0b5ecdf92f1 100644 --- a/proxy/http/HttpTransactCache.cc +++ b/proxy/http/HttpTransactCache.cc @@ -21,7 +21,7 @@ limitations under the License. */ -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #include "HttpTransact.h" #include "HttpTransactHeaders.h" @@ -29,7 +29,7 @@ #include #include "HTTP.h" #include "HttpCompat.h" -#include "ts/InkErrno.h" +#include "tscore/InkErrno.h" /** Find the pointer and length of an etag, after stripping off any leading diff --git a/proxy/http/HttpTransactCache.h b/proxy/http/HttpTransactCache.h index 1f3ec6af760..4f7e142b894 100644 --- a/proxy/http/HttpTransactCache.h +++ b/proxy/http/HttpTransactCache.h @@ -30,7 +30,7 @@ ****************************************************************************/ #pragma once -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #include "HttpConfig.h" // This is needed since txn_conf->cache_guaranteed_max_lifetime is currently not diff --git a/proxy/http/HttpTransactHeaders.cc b/proxy/http/HttpTransactHeaders.cc index 9168afa20bb..95f662626c7 100644 --- a/proxy/http/HttpTransactHeaders.cc +++ b/proxy/http/HttpTransactHeaders.cc @@ -26,8 +26,8 @@ #include #include -#include -#include +#include "tscore/ink_platform.h" +#include "tscore/BufferWriter.h" #include "HttpTransact.h" #include "HttpTransactHeaders.h" diff --git a/proxy/http/HttpTunnel.cc b/proxy/http/HttpTunnel.cc index 9bac98454e4..84634c37bb2 100644 --- a/proxy/http/HttpTunnel.cc +++ b/proxy/http/HttpTunnel.cc @@ -30,12 +30,12 @@ ****************************************************************************/ -#include "ts/ink_config.h" +#include "tscore/ink_config.h" #include "HttpConfig.h" #include "HttpTunnel.h" #include "HttpSM.h" #include "HttpDebugNames.h" -#include "ts/ParseRules.h" +#include "tscore/ParseRules.h" static const int min_block_transfer_bytes = 256; static const char *const CHUNK_HEADER_FMT = "%" PRIx64 "\r\n"; diff --git a/proxy/http/HttpTunnel.h b/proxy/http/HttpTunnel.h index 7e04c8dbdaa..e47160d9a0c 100644 --- a/proxy/http/HttpTunnel.h +++ b/proxy/http/HttpTunnel.h @@ -32,7 +32,7 @@ #pragma once -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #include "P_EventSystem.h" // Get rid of any previous definition first... /leif diff --git a/proxy/http/HttpUpdateTester.cc b/proxy/http/HttpUpdateTester.cc index d482c9f979c..581eafbe150 100644 --- a/proxy/http/HttpUpdateTester.cc +++ b/proxy/http/HttpUpdateTester.cc @@ -23,8 +23,8 @@ #include "HttpUpdateSM.h" #include "HttpDebugNames.h" -#include "ts/Diags.h" -#include "ts/ink_platform.h" +#include "tscore/Diags.h" +#include "tscore/ink_platform.h" #define MAX_ACTIVE_REQUESTS 5 #define MAX_TOTAL_REQUESTS 100 diff --git a/proxy/http/Makefile.am b/proxy/http/Makefile.am index c437e957550..193393278c0 100644 --- a/proxy/http/Makefile.am +++ b/proxy/http/Makefile.am @@ -23,8 +23,8 @@ SUBDIRS = remap AM_CPPFLAGS += \ $(iocore_include_dirs) \ -I$(abs_top_srcdir)/proxy \ - -I$(abs_top_srcdir)/lib \ - -I$(abs_top_srcdir)/lib/records \ + -I$(abs_top_srcdir)/include \ + -I$(abs_top_srcdir)/include/records \ -I$(abs_top_srcdir)/mgmt \ -I$(abs_top_srcdir)/mgmt/utils \ -I$(abs_top_srcdir)/proxy/hdrs \ @@ -90,12 +90,13 @@ test_ForwardedConfig_CPPFLAGS = $(AM_CPPFLAGS)\ -I$(abs_top_srcdir)/tests/include test_ForwardedConfig_SOURCES = \ - unit-tests/test_ForwardedConfig.cc \ + unit_tests/test_ForwardedConfig.cc \ ForwardedConfig.cc \ - unit-tests/test_ForwardedConfig_mocks.cc + unit_tests/test_ForwardedConfig_mocks.cc test_ForwardedConfig_LDADD = \ - $(top_builddir)/lib/ts/libtsutil.la + $(top_builddir)/src/tscore/libtscore.la \ + $(top_builddir)/src/tscpp/util/libtscpputil.la clang-tidy-local: $(libhttp_a_SOURCES) $(noinst_HEADERS) $(CXX_Clang_Tidy) diff --git a/proxy/http/RegressionHttpTransact.cc b/proxy/http/RegressionHttpTransact.cc index d77f685e118..501a01e590e 100644 --- a/proxy/http/RegressionHttpTransact.cc +++ b/proxy/http/RegressionHttpTransact.cc @@ -21,7 +21,7 @@ limitations under the License. */ -#include "ts/Regression.h" +#include "tscore/Regression.h" #include "HttpTransact.h" #include "HttpSM.h" diff --git a/proxy/http/remap/AclFiltering.h b/proxy/http/remap/AclFiltering.h index 053fe50d221..dfe42b41131 100644 --- a/proxy/http/remap/AclFiltering.h +++ b/proxy/http/remap/AclFiltering.h @@ -24,7 +24,7 @@ #pragma once #include "Main.h" -#include "ts/ink_inet.h" +#include "tscore/ink_inet.h" #include #include diff --git a/proxy/http/remap/Makefile.am b/proxy/http/remap/Makefile.am index b62d30bae5e..7d20677bbb6 100644 --- a/proxy/http/remap/Makefile.am +++ b/proxy/http/remap/Makefile.am @@ -20,8 +20,8 @@ include $(top_srcdir)/build/tidy.mk AM_CPPFLAGS += \ $(iocore_include_dirs) \ - -I$(abs_top_srcdir)/lib \ - -I$(abs_top_srcdir)/lib/records \ + -I$(abs_top_srcdir)/include \ + -I$(abs_top_srcdir)/include/records \ -I$(abs_top_srcdir)/proxy \ -I$(abs_top_srcdir)/mgmt \ -I$(abs_top_srcdir)/mgmt/utils \ diff --git a/proxy/http/remap/RemapConfig.cc b/proxy/http/remap/RemapConfig.cc index f082374555a..dcbc076874b 100644 --- a/proxy/http/remap/RemapConfig.cc +++ b/proxy/http/remap/RemapConfig.cc @@ -24,14 +24,14 @@ #include "RemapConfig.h" #include "UrlRewrite.h" #include "ReverseProxy.h" -#include "ts/I_Layout.h" +#include "tscore/I_Layout.h" #include "HTTP.h" -#include "ts/ink_platform.h" -#include "ts/List.h" -#include "ts/ink_cap.h" -#include "ts/ink_file.h" -#include "ts/Tokenizer.h" -#include "../../proxy/IPAllow.h" +#include "tscore/ink_platform.h" +#include "tscore/List.h" +#include "tscore/ink_cap.h" +#include "tscore/ink_file.h" +#include "tscore/Tokenizer.h" +#include "IPAllow.h" #define modulePrefix "[ReverseProxy]" diff --git a/proxy/http/remap/RemapPluginInfo.cc b/proxy/http/remap/RemapPluginInfo.cc index 8e36374eec4..ad0b06c9e96 100644 --- a/proxy/http/remap/RemapPluginInfo.cc +++ b/proxy/http/remap/RemapPluginInfo.cc @@ -22,8 +22,8 @@ */ #include "RemapPluginInfo.h" -#include "ts/ink_string.h" -#include "ts/ink_memory.h" +#include "tscore/ink_string.h" +#include "tscore/ink_memory.h" remap_plugin_info::remap_plugin_info(char *_path) : next(nullptr), diff --git a/proxy/http/remap/RemapPluginInfo.h b/proxy/http/remap/RemapPluginInfo.h index 92fdf9126bf..cf9e8c77f66 100644 --- a/proxy/http/remap/RemapPluginInfo.h +++ b/proxy/http/remap/RemapPluginInfo.h @@ -22,10 +22,10 @@ */ #pragma once -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #include "ts/apidefs.h" -#include "api/ts/remap.h" +#include "ts/remap.h" #define TSREMAP_FUNCNAME_INIT "TSRemapInit" #define TSREMAP_FUNCNAME_CONFIG_RELOAD "TSRemapConfigReload" diff --git a/proxy/http/remap/RemapPlugins.h b/proxy/http/remap/RemapPlugins.h index fd509748562..bd7647710c4 100644 --- a/proxy/http/remap/RemapPlugins.h +++ b/proxy/http/remap/RemapPlugins.h @@ -27,7 +27,7 @@ #pragma once -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #include "I_EventSystem.h" #include "RemapProcessor.h" #include "RemapPluginInfo.h" diff --git a/proxy/http/remap/UrlMapping.cc b/proxy/http/remap/UrlMapping.cc index e3181074b23..5ff1d541772 100644 --- a/proxy/http/remap/UrlMapping.cc +++ b/proxy/http/remap/UrlMapping.cc @@ -21,10 +21,10 @@ limitations under the License. */ -#include "ts/ink_defs.h" +#include "tscore/ink_defs.h" #include "UrlMapping.h" -#include "I_RecCore.h" -#include "ts/ink_cap.h" +#include "records/I_RecCore.h" +#include "tscore/ink_cap.h" /** * diff --git a/proxy/http/remap/UrlMapping.h b/proxy/http/remap/UrlMapping.h index feb0bce3ba4..6618731caac 100644 --- a/proxy/http/remap/UrlMapping.h +++ b/proxy/http/remap/UrlMapping.h @@ -25,13 +25,13 @@ #include -#include "ts/ink_config.h" +#include "tscore/ink_config.h" #include "AclFiltering.h" #include "Main.h" #include "URL.h" #include "RemapPluginInfo.h" -#include "ts/Regex.h" -#include "ts/List.h" +#include "tscore/Regex.h" +#include "tscore/List.h" /** * Used to store http referer strings (and/or regexp) diff --git a/proxy/http/remap/UrlMappingPathIndex.h b/proxy/http/remap/UrlMappingPathIndex.h index bede50dbec5..bfcba1fc25e 100644 --- a/proxy/http/remap/UrlMappingPathIndex.h +++ b/proxy/http/remap/UrlMappingPathIndex.h @@ -22,13 +22,13 @@ */ #pragma once -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #undef std // FIXME: remove dependancy on the STL #include #include "URL.h" #include "UrlMapping.h" -#include "ts/Trie.h" +#include "tscore/Trie.h" class UrlMappingPathIndex { diff --git a/proxy/http/remap/UrlRewrite.cc b/proxy/http/remap/UrlRewrite.cc index d95063ccd1d..8f2577b057e 100644 --- a/proxy/http/remap/UrlRewrite.cc +++ b/proxy/http/remap/UrlRewrite.cc @@ -26,7 +26,7 @@ #include "ReverseProxy.h" #include "UrlMappingPathIndex.h" #include "RemapConfig.h" -#include "ts/I_Layout.h" +#include "tscore/I_Layout.h" #include "HttpSM.h" #define modulePrefix "[ReverseProxy]" diff --git a/proxy/http/remap/UrlRewrite.h b/proxy/http/remap/UrlRewrite.h index 4355ee6fabc..08577f3cf92 100644 --- a/proxy/http/remap/UrlRewrite.h +++ b/proxy/http/remap/UrlRewrite.h @@ -23,10 +23,10 @@ #pragma once -#include "ts/ink_config.h" +#include "tscore/ink_config.h" #include "UrlMapping.h" #include "HttpTransact.h" -#include "ts/Regex.h" +#include "tscore/Regex.h" #define URL_REMAP_FILTER_NONE 0x00000000 #define URL_REMAP_FILTER_REFERER 0x00000001 /* enable "referer" header validation */ diff --git a/proxy/http/testheaders.cc b/proxy/http/testheaders.cc index 772f6024998..7f7e9f4fba5 100644 --- a/proxy/http/testheaders.cc +++ b/proxy/http/testheaders.cc @@ -21,7 +21,7 @@ limitations under the License. */ -#include "ts/ink_string.h" +#include "tscore/ink_string.h" #include "HttpTransact.h" #include "HttpTransactHeaders.h" diff --git a/proxy/http/unit-tests/test_ForwardedConfig.cc b/proxy/http/unit_tests/test_ForwardedConfig.cc similarity index 100% rename from proxy/http/unit-tests/test_ForwardedConfig.cc rename to proxy/http/unit_tests/test_ForwardedConfig.cc diff --git a/proxy/http/unit-tests/test_ForwardedConfig_mocks.cc b/proxy/http/unit_tests/test_ForwardedConfig_mocks.cc similarity index 100% rename from proxy/http/unit-tests/test_ForwardedConfig_mocks.cc rename to proxy/http/unit_tests/test_ForwardedConfig_mocks.cc diff --git a/proxy/http2/HPACK.h b/proxy/http2/HPACK.h index c20f40f6d47..9d0f9f56295 100644 --- a/proxy/http2/HPACK.h +++ b/proxy/http2/HPACK.h @@ -23,8 +23,8 @@ #pragma once -#include "ts/ink_platform.h" -#include "ts/Diags.h" +#include "tscore/ink_platform.h" +#include "tscore/Diags.h" #include "HTTP.h" #include diff --git a/proxy/http2/HTTP2.cc b/proxy/http2/HTTP2.cc index 4327e71fb95..9a94b048ec1 100644 --- a/proxy/http2/HTTP2.cc +++ b/proxy/http2/HTTP2.cc @@ -24,9 +24,9 @@ #include "HTTP2.h" #include "HPACK.h" #include "HuffmanCodec.h" -#include "ts/ink_assert.h" -#include "P_RecCore.h" -#include "P_RecProcess.h" +#include "tscore/ink_assert.h" +#include "records/P_RecCore.h" +#include "records/P_RecProcess.h" const char *const HTTP2_CONNECTION_PREFACE = "PRI * HTTP/2.0\r\n\r\nSM\r\n\r\n"; @@ -805,7 +805,7 @@ forceLinkRegressionHPACKCaller() forceLinkRegressionHPACK(); } -#include "ts/TestBox.h" +#include "tscore/TestBox.h" /*********************************************************************************** * * diff --git a/proxy/http2/HTTP2.h b/proxy/http2/HTTP2.h index 471b5452a39..7b26d148799 100644 --- a/proxy/http2/HTTP2.h +++ b/proxy/http2/HTTP2.h @@ -23,11 +23,11 @@ #pragma once -#include "ts/ink_defs.h" -#include "ts/ink_memory.h" +#include "tscore/ink_defs.h" +#include "tscore/ink_memory.h" #include "HPACK.h" #include "MIME.h" -#include "P_RecDefs.h" +#include "records/P_RecDefs.h" class HTTPHdr; diff --git a/proxy/http2/Http2ClientSession.cc b/proxy/http2/Http2ClientSession.cc index 0bdccaae288..18b671e25fc 100644 --- a/proxy/http2/Http2ClientSession.cc +++ b/proxy/http2/Http2ClientSession.cc @@ -23,7 +23,7 @@ #include "Http2ClientSession.h" #include "HttpDebugNames.h" -#include "ts/ink_base64.h" +#include "tscore/ink_base64.h" #define STATE_ENTER(state_name, event) \ do { \ diff --git a/proxy/http2/Http2ClientSession.h b/proxy/http2/Http2ClientSession.h index 4f69dc93f68..998fccbd747 100644 --- a/proxy/http2/Http2ClientSession.h +++ b/proxy/http2/Http2ClientSession.h @@ -28,7 +28,7 @@ #include "ProxyClientSession.h" #include "Http2ConnectionState.h" #include -#include +#include "tscore/ink_inet.h" // Name Edata Description // HTTP2_SESSION_EVENT_INIT Http2ClientSession * HTTP/2 session is born diff --git a/proxy/http2/Http2DebugNames.h b/proxy/http2/Http2DebugNames.h index 790587d7c25..5aaf41f5157 100644 --- a/proxy/http2/Http2DebugNames.h +++ b/proxy/http2/Http2DebugNames.h @@ -23,7 +23,7 @@ #pragma once -#include "ts/ink_defs.h" +#include "tscore/ink_defs.h" enum class Http2StreamState; diff --git a/proxy/http2/Http2DependencyTree.h b/proxy/http2/Http2DependencyTree.h index d02e6ad20f4..936f5d50570 100644 --- a/proxy/http2/Http2DependencyTree.h +++ b/proxy/http2/Http2DependencyTree.h @@ -26,9 +26,9 @@ #pragma once -#include "ts/List.h" -#include "ts/Diags.h" -#include "ts/PriorityQueue.h" +#include "tscore/List.h" +#include "tscore/Diags.h" +#include "tscore/PriorityQueue.h" #include "HTTP2.h" diff --git a/proxy/http2/Http2SessionAccept.h b/proxy/http2/Http2SessionAccept.h index 56841f9abfc..e01cd2333f6 100644 --- a/proxy/http2/Http2SessionAccept.h +++ b/proxy/http2/Http2SessionAccept.h @@ -23,7 +23,7 @@ #pragma once -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #include "I_Net.h" // XXX HttpSessionAccept::Options needs to be refactored and separated from HttpSessionAccept so that diff --git a/proxy/http2/HuffmanCodec.cc b/proxy/http2/HuffmanCodec.cc index 34ec166a7d8..0c103731c14 100644 --- a/proxy/http2/HuffmanCodec.cc +++ b/proxy/http2/HuffmanCodec.cc @@ -22,9 +22,9 @@ */ #include "HuffmanCodec.h" -#include "ts/ink_platform.h" -#include "ts/ink_memory.h" -#include "ts/ink_defs.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_memory.h" +#include "tscore/ink_defs.h" struct huffman_entry { uint32_t code_as_hex; diff --git a/proxy/http2/Makefile.am b/proxy/http2/Makefile.am index 67e2f5b6bb1..fe86f782721 100644 --- a/proxy/http2/Makefile.am +++ b/proxy/http2/Makefile.am @@ -20,8 +20,8 @@ include $(top_srcdir)/build/tidy.mk AM_CPPFLAGS += \ $(iocore_include_dirs) \ - -I$(abs_top_srcdir)/lib \ - -I$(abs_top_srcdir)/lib/records \ + -I$(abs_top_srcdir)/include \ + -I$(abs_top_srcdir)/include/records \ -I$(abs_top_srcdir)/mgmt \ -I$(abs_top_srcdir)/mgmt/utils \ -I$(abs_top_srcdir)/proxy \ @@ -68,7 +68,8 @@ TESTS = \ test_HPACK test_Huffmancode_LDADD = \ - $(top_builddir)/lib/ts/libtsutil.la + $(top_builddir)/src/tscore/libtscore.la \ + $(top_builddir)/src/tscpp/util/libtscpputil.la test_Huffmancode_SOURCES = \ test_Huffmancode.cc \ @@ -76,7 +77,8 @@ test_Huffmancode_SOURCES = \ HuffmanCodec.h test_Http2DependencyTree_LDADD = \ - $(top_builddir)/lib/ts/libtsutil.la + $(top_builddir)/src/tscore/libtscore.la \ + $(top_builddir)/src/tscpp/util/libtscpputil.la test_Http2DependencyTree_SOURCES = \ test_Http2DependencyTree.cc \ @@ -84,7 +86,8 @@ test_Http2DependencyTree_SOURCES = \ test_HPACK_LDADD = \ $(top_builddir)/proxy/hdrs/libhdrs.a \ - $(top_builddir)/lib/ts/libtsutil.la \ + $(top_builddir)/src/tscore/libtscore.la \ + $(top_builddir)/src/tscpp/util/libtscpputil.la \ $(top_builddir)/iocore/eventsystem/libinkevent.a \ $(top_builddir)/lib/records/librecords_p.a \ $(top_builddir)/mgmt/libmgmt_p.la \ diff --git a/proxy/http2/RegressionHPACK.cc b/proxy/http2/RegressionHPACK.cc index 399df34e03d..7b2de58141a 100644 --- a/proxy/http2/RegressionHPACK.cc +++ b/proxy/http2/RegressionHPACK.cc @@ -23,7 +23,7 @@ #include "HPACK.h" #include "HuffmanCodec.h" -#include "ts/TestBox.h" +#include "tscore/TestBox.h" // Constants for regression test const static int DYNAMIC_TABLE_SIZE_FOR_REGRESSION_TEST = 256; diff --git a/proxy/http2/test_HPACK.cc b/proxy/http2/test_HPACK.cc index 04b72610872..b1d4ed459d1 100644 --- a/proxy/http2/test_HPACK.cc +++ b/proxy/http2/test_HPACK.cc @@ -29,8 +29,8 @@ #include #include #include -#include "ts/ink_args.h" -#include "ts/TestBox.h" +#include "tscore/ink_args.h" +#include "tscore/TestBox.h" const static int MAX_REQUEST_HEADER_SIZE = 131072; const static int MAX_TABLE_SIZE = 4096; diff --git a/proxy/http2/test_Http2DependencyTree.cc b/proxy/http2/test_Http2DependencyTree.cc index 2cccd696f87..3595a842d9c 100644 --- a/proxy/http2/test_Http2DependencyTree.cc +++ b/proxy/http2/test_Http2DependencyTree.cc @@ -25,7 +25,7 @@ #include #include -#include "ts/TestBox.h" +#include "tscore/TestBox.h" #include "Http2DependencyTree.h" diff --git a/proxy/logging/Log.cc b/proxy/logging/Log.cc index 930dcf2e159..6549ea9f0a2 100644 --- a/proxy/logging/Log.cc +++ b/proxy/logging/Log.cc @@ -32,7 +32,7 @@ class. ***************************************************************************/ -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #include "Main.h" #include "P_EventSystem.h" #include "P_Net.h" @@ -51,9 +51,9 @@ #include "LogUtils.h" #include "Log.h" #include "LogSock.h" -#include "ts/SimpleTokenizer.h" +#include "tscore/SimpleTokenizer.h" -#include "ts/ink_apidefs.h" +#include "tscore/ink_apidefs.h" #define PERIODIC_TASKS_INTERVAL_FALLBACK 5 diff --git a/proxy/logging/Log.h b/proxy/logging/Log.h index 5906d92920a..94a3a8f134c 100644 --- a/proxy/logging/Log.h +++ b/proxy/logging/Log.h @@ -52,11 +52,11 @@ #pragma once #include -#include "ts/ink_platform.h" -#include "ts/EventNotify.h" -#include "ts/ink_hash_table.h" -#include "ts/Regression.h" -#include "P_RecProcess.h" +#include "tscore/ink_platform.h" +#include "tscore/EventNotify.h" +#include "tscore/ink_hash_table.h" +#include "tscore/Regression.h" +#include "records/P_RecProcess.h" #include "LogFile.h" #include "LogBuffer.h" diff --git a/proxy/logging/LogAccess.h b/proxy/logging/LogAccess.h index 20e4b9ea77c..f402ad97186 100644 --- a/proxy/logging/LogAccess.h +++ b/proxy/logging/LogAccess.h @@ -24,7 +24,7 @@ #pragma once -#include "ts/ink_align.h" +#include "tscore/ink_align.h" #include "LogField.h" class HTTPHdr; diff --git a/proxy/logging/LogBuffer.cc b/proxy/logging/LogBuffer.cc index 86b1344c5f9..2b2d1b192b6 100644 --- a/proxy/logging/LogBuffer.cc +++ b/proxy/logging/LogBuffer.cc @@ -25,7 +25,7 @@ recording log entries. See the header file LogBuffer.h for more information on the structure of a LogBuffer. */ -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #include #include diff --git a/proxy/logging/LogBuffer.h b/proxy/logging/LogBuffer.h index 1a7138e46c8..c96606ee7b9 100644 --- a/proxy/logging/LogBuffer.h +++ b/proxy/logging/LogBuffer.h @@ -23,8 +23,8 @@ #pragma once -#include "ts/ink_platform.h" -#include "ts/Diags.h" +#include "tscore/ink_platform.h" +#include "tscore/Diags.h" #include "LogFormat.h" #include "LogLimits.h" #include "LogAccess.h" diff --git a/proxy/logging/LogCollationAccept.cc b/proxy/logging/LogCollationAccept.cc index b0ac5e06926..3e9414396ad 100644 --- a/proxy/logging/LogCollationAccept.cc +++ b/proxy/logging/LogCollationAccept.cc @@ -25,7 +25,7 @@ // include files //------------------------------------------------------------------------- -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #include "P_EventSystem.h" #include "Log.h" diff --git a/proxy/logging/LogCollationClientSM.cc b/proxy/logging/LogCollationClientSM.cc index d978a09d6f2..73051ccec94 100644 --- a/proxy/logging/LogCollationClientSM.cc +++ b/proxy/logging/LogCollationClientSM.cc @@ -25,7 +25,7 @@ // include files //------------------------------------------------------------------------- -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #include #include diff --git a/proxy/logging/LogCollationHostSM.cc b/proxy/logging/LogCollationHostSM.cc index 4a96d071c27..2962271a93d 100644 --- a/proxy/logging/LogCollationHostSM.cc +++ b/proxy/logging/LogCollationHostSM.cc @@ -25,7 +25,7 @@ // include files //------------------------------------------------------------------------- -#include "ts/ink_config.h" +#include "tscore/ink_config.h" #include #include diff --git a/proxy/logging/LogConfig.cc b/proxy/logging/LogConfig.cc index 8c3dec62408..a72f4f9c5ca 100644 --- a/proxy/logging/LogConfig.cc +++ b/proxy/logging/LogConfig.cc @@ -21,8 +21,8 @@ limitations under the License. */ -#include "ts/ink_platform.h" -#include "ts/I_Layout.h" +#include "tscore/ink_platform.h" +#include "tscore/I_Layout.h" #ifdef HAVE_SYS_PARAM_H #include @@ -30,11 +30,11 @@ #include -#include "ts/ink_platform.h" -#include "ts/ink_file.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_file.h" #include "Main.h" -#include "ts/List.h" +#include "tscore/List.h" #include "Log.h" #include "LogField.h" @@ -46,7 +46,7 @@ #include "LogObject.h" #include "LogConfig.h" #include "LogUtils.h" -#include "ts/SimpleTokenizer.h" +#include "tscore/SimpleTokenizer.h" #include "LogCollationAccept.h" diff --git a/proxy/logging/LogConfig.h b/proxy/logging/LogConfig.h index 816e22b59cc..1920aa49f2f 100644 --- a/proxy/logging/LogConfig.h +++ b/proxy/logging/LogConfig.h @@ -23,8 +23,8 @@ #pragma once -#include "ts/ink_platform.h" -#include "P_RecProcess.h" +#include "tscore/ink_platform.h" +#include "records/P_RecProcess.h" #include "ProxyConfig.h" #include "LogObject.h" diff --git a/proxy/logging/LogField.cc b/proxy/logging/LogField.cc index 049f2b349f9..8e63f815a32 100644 --- a/proxy/logging/LogField.cc +++ b/proxy/logging/LogField.cc @@ -27,7 +27,7 @@ This file implements the LogField object, which is the central representation of a logging field. ***************************************************************************/ -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #include "LogUtils.h" #include "LogField.h" diff --git a/proxy/logging/LogField.h b/proxy/logging/LogField.h index c8920915f6d..0bda8c6dabc 100644 --- a/proxy/logging/LogField.h +++ b/proxy/logging/LogField.h @@ -23,9 +23,9 @@ #pragma once -#include "ts/ink_platform.h" -#include "ts/List.h" -#include +#include "tscore/ink_platform.h" +#include "tscore/List.h" +#include "tscore/TsBuffer.h" #include "LogFieldAliasMap.h" #include "Milestones.h" diff --git a/proxy/logging/LogFieldAliasMap.cc b/proxy/logging/LogFieldAliasMap.cc index 564c363cfc7..4e186d061b7 100644 --- a/proxy/logging/LogFieldAliasMap.cc +++ b/proxy/logging/LogFieldAliasMap.cc @@ -27,10 +27,10 @@ ***************************************************************************/ -#include "ts/ink_config.h" +#include "tscore/ink_config.h" #include "LogFieldAliasMap.h" -#include "ts/ink_assert.h" -#include "ts/ink_memory.h" +#include "tscore/ink_assert.h" +#include "tscore/ink_memory.h" void LogFieldAliasTable::init(size_t numPairs, ...) diff --git a/proxy/logging/LogFieldAliasMap.h b/proxy/logging/LogFieldAliasMap.h index 45a464bf47e..1d605770253 100644 --- a/proxy/logging/LogFieldAliasMap.h +++ b/proxy/logging/LogFieldAliasMap.h @@ -31,10 +31,10 @@ #include #include -#include "ts/ink_platform.h" -#include "ts/Ptr.h" +#include "tscore/ink_platform.h" +#include "tscore/Ptr.h" #include "LogUtils.h" -#include "ts/ink_string.h" +#include "tscore/ink_string.h" /***************************************************************************** diff --git a/proxy/logging/LogFile.cc b/proxy/logging/LogFile.cc index 87898f49a10..a7064627802 100644 --- a/proxy/logging/LogFile.cc +++ b/proxy/logging/LogFile.cc @@ -27,9 +27,9 @@ ***************************************************************************/ -#include "ts/ink_platform.h" -#include "ts/SimpleTokenizer.h" -#include "ts/ink_file.h" +#include "tscore/ink_platform.h" +#include "tscore/SimpleTokenizer.h" +#include "tscore/ink_file.h" #include #include @@ -40,7 +40,7 @@ #include "I_Machine.h" #include "LogSock.h" -#include "ts/BaseLogFile.h" +#include "tscore/BaseLogFile.h" #include "LogField.h" #include "LogFilter.h" #include "LogFormat.h" diff --git a/proxy/logging/LogFile.h b/proxy/logging/LogFile.h index 1b72d6a22b8..98db0706691 100644 --- a/proxy/logging/LogFile.h +++ b/proxy/logging/LogFile.h @@ -26,7 +26,7 @@ #include #include -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #include "LogBufferSink.h" class LogSock; diff --git a/proxy/logging/LogFilter.cc b/proxy/logging/LogFilter.cc index 8c60d82b10d..cfed08981d5 100644 --- a/proxy/logging/LogFilter.cc +++ b/proxy/logging/LogFilter.cc @@ -26,7 +26,7 @@ ***************************************************************************/ -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #include "LogUtils.h" #include "LogFilter.h" @@ -38,7 +38,7 @@ #include "LogObject.h" #include "LogConfig.h" #include "Log.h" -#include "ts/SimpleTokenizer.h" +#include "tscore/SimpleTokenizer.h" const char *LogFilter::OPERATOR_NAME[] = {"MATCH", "CASE_INSENSITIVE_MATCH", "CONTAIN", "CASE_INSENSITIVE_CONTAIN"}; const char *LogFilter::ACTION_NAME[] = {"REJECT", "ACCEPT", "WIPE_FIELD_VALUE"}; @@ -1078,7 +1078,7 @@ LogFilterList::display(FILE *fd) } #if TS_HAS_TESTS -#include "ts/TestBox.h" +#include "tscore/TestBox.h" REGRESSION_TEST(Log_FilterParse)(RegressionTest *t, int /* atype */, int *pstatus) { diff --git a/proxy/logging/LogFilter.h b/proxy/logging/LogFilter.h index 259f9dddb13..7d9d6a115e5 100644 --- a/proxy/logging/LogFilter.h +++ b/proxy/logging/LogFilter.h @@ -23,9 +23,9 @@ #pragma once -#include "ts/ink_platform.h" -#include "ts/IpMap.h" -#include "ts/Ptr.h" +#include "tscore/ink_platform.h" +#include "tscore/IpMap.h" +#include "tscore/Ptr.h" #include "LogAccess.h" #include "LogField.h" #include "LogFormat.h" diff --git a/proxy/logging/LogFormat.cc b/proxy/logging/LogFormat.cc index 0b6897e6588..6e6c978e3aa 100644 --- a/proxy/logging/LogFormat.cc +++ b/proxy/logging/LogFormat.cc @@ -26,14 +26,14 @@ ***************************************************************************/ -#include "ts/ink_config.h" +#include "tscore/ink_config.h" #include #include #include -#include "ts/SimpleTokenizer.h" -#include "ts/CryptoHash.h" +#include "tscore/SimpleTokenizer.h" +#include "tscore/CryptoHash.h" #include "LogUtils.h" #include "LogFile.h" diff --git a/proxy/logging/LogFormat.h b/proxy/logging/LogFormat.h index 77792dc6b37..60c3a42356f 100644 --- a/proxy/logging/LogFormat.h +++ b/proxy/logging/LogFormat.h @@ -25,7 +25,7 @@ #define LOG_FIELD_MARKER '\377' -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #include "LogField.h" enum LogFormatType { diff --git a/proxy/logging/LogHost.cc b/proxy/logging/LogHost.cc index a55c52a3e16..649682b1cbb 100644 --- a/proxy/logging/LogHost.cc +++ b/proxy/logging/LogHost.cc @@ -26,7 +26,7 @@ ***************************************************************************/ -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #include "LogUtils.h" #include "LogSock.h" diff --git a/proxy/logging/LogObject.cc b/proxy/logging/LogObject.cc index 50385e52009..c745bddb277 100644 --- a/proxy/logging/LogObject.cc +++ b/proxy/logging/LogObject.cc @@ -26,8 +26,8 @@ ***************************************************************************/ -#include "ts/ink_platform.h" -#include "ts/CryptoHash.h" +#include "tscore/ink_platform.h" +#include "tscore/CryptoHash.h" #include "P_EventSystem.h" #include "LogUtils.h" #include "LogField.h" @@ -35,7 +35,7 @@ #include "LogConfig.h" #include "LogAccess.h" #include "Log.h" -#include "ts/TestBox.h" +#include "tscore/TestBox.h" #include #include diff --git a/proxy/logging/LogObject.h b/proxy/logging/LogObject.h index a1ba77f27d8..3dc50e278d0 100644 --- a/proxy/logging/LogObject.h +++ b/proxy/logging/LogObject.h @@ -23,7 +23,7 @@ #pragma once -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #include "Log.h" #include "LogFile.h" #include "LogFormat.h" diff --git a/proxy/logging/LogSock.cc b/proxy/logging/LogSock.cc index b84874092b4..4a37d0c8c6f 100644 --- a/proxy/logging/LogSock.cc +++ b/proxy/logging/LogSock.cc @@ -21,8 +21,8 @@ limitations under the License. */ -#include "ts/ink_inet.h" -#include "ts/ink_string.h" +#include "tscore/ink_inet.h" +#include "tscore/ink_string.h" #include "P_EventSystem.h" #include "LogSock.h" diff --git a/proxy/logging/LogSock.h b/proxy/logging/LogSock.h index 1394c0a8ff1..eda5d1a126e 100644 --- a/proxy/logging/LogSock.h +++ b/proxy/logging/LogSock.h @@ -23,7 +23,7 @@ #pragma once -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" /*------------------------------------------------------------------------- LogSock diff --git a/proxy/logging/LogStandalone.cc b/proxy/logging/LogStandalone.cc index 07e8c2e09e8..9034140c150 100644 --- a/proxy/logging/LogStandalone.cc +++ b/proxy/logging/LogStandalone.cc @@ -27,15 +27,15 @@ ***************************************************************************/ -#include "ts/ink_platform.h" -#include "ts/ink_lockfile.h" -#include "ts/ink_sys_control.h" -#include "ts/signals.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_lockfile.h" +#include "tscore/ink_sys_control.h" +#include "tscore/signals.h" #include "DiagsConfig.h" #include "Main.h" #include "P_EventSystem.h" -#include "P_RecProcess.h" +#include "records/P_RecProcess.h" #include "ProcessManager.h" #include "MgmtUtils.h" diff --git a/proxy/logging/LogUtils.cc b/proxy/logging/LogUtils.cc index 71077bfb6aa..94becf250ac 100644 --- a/proxy/logging/LogUtils.cc +++ b/proxy/logging/LogUtils.cc @@ -21,8 +21,8 @@ See the License for the specific language governing permissions and limitations under the License. */ -#include "ts/ink_config.h" -#include "ts/ink_string.h" +#include "tscore/ink_config.h" +#include "tscore/ink_string.h" #include #include @@ -40,7 +40,7 @@ #include #include -#include "P_RecProcess.h" +#include "records/P_RecProcess.h" // REC_SIGNAL_LOGGING_ERROR is defined in I_RecSignals.h // REC_SIGNAL_LOGGING_WARNING is defined in I_RecSignals.h diff --git a/proxy/logging/LogUtils.h b/proxy/logging/LogUtils.h index 7d7be5ffa47..96cd05148b0 100644 --- a/proxy/logging/LogUtils.h +++ b/proxy/logging/LogUtils.h @@ -24,8 +24,8 @@ #include -#include "ts/ink_platform.h" -#include "ts/Arena.h" +#include "tscore/ink_platform.h" +#include "tscore/Arena.h" namespace LogUtils { diff --git a/proxy/logging/Makefile.am b/proxy/logging/Makefile.am index 98383947319..4c341e0234f 100644 --- a/proxy/logging/Makefile.am +++ b/proxy/logging/Makefile.am @@ -20,8 +20,8 @@ include $(top_srcdir)/build/tidy.mk AM_CPPFLAGS += \ $(iocore_include_dirs) \ - -I$(abs_top_srcdir)/lib \ - -I$(abs_top_srcdir)/lib/records \ + -I$(abs_top_srcdir)/include \ + -I$(abs_top_srcdir)/include/records \ -I$(abs_top_srcdir)/proxy \ -I$(abs_top_srcdir)/proxy/http \ -I$(abs_top_srcdir)/proxy/http/remap \ @@ -85,7 +85,8 @@ TESTS = \ test_LogUtils test_LogUtils_LDADD = \ - $(top_builddir)/lib/ts/libtsutil.la \ + $(top_builddir)/src/tscore/libtscore.la \ + $(top_builddir)/src/tscpp/util/libtscpputil.la \ $(top_builddir)/iocore/eventsystem/libinkevent.a test_LogUtils_SOURCES = \ diff --git a/proxy/logging/YamlLogConfig.cc b/proxy/logging/YamlLogConfig.cc index dc93f1c142f..999496252fb 100644 --- a/proxy/logging/YamlLogConfig.cc +++ b/proxy/logging/YamlLogConfig.cc @@ -25,7 +25,7 @@ #include "LogConfig.h" #include "LogObject.h" -#include "ts/EnumDescriptor.h" +#include "tscore/EnumDescriptor.h" #include #include diff --git a/proxy/logging/test_LogUtils.cc b/proxy/logging/test_LogUtils.cc index 10ce96d2fe7..0f39524ceaa 100644 --- a/proxy/logging/test_LogUtils.cc +++ b/proxy/logging/test_LogUtils.cc @@ -21,7 +21,7 @@ limitations under the License. */ -#include +#include "tscore/TestBox.h" #include "LogUtils.cc" #include diff --git a/proxy/shared/DiagsConfig.cc b/proxy/shared/DiagsConfig.cc index 0d4d38e37b5..ebdedeb70f6 100644 --- a/proxy/shared/DiagsConfig.cc +++ b/proxy/shared/DiagsConfig.cc @@ -21,12 +21,12 @@ limitations under the License. */ -#include "ts/ink_platform.h" -#include "ts/ink_memory.h" -#include "ts/ink_file.h" -#include "ts/I_Layout.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_memory.h" +#include "tscore/ink_file.h" +#include "tscore/I_Layout.h" #include "DiagsConfig.h" -#include "P_RecCore.h" +#include "records/P_RecCore.h" ////////////////////////////////////////////////////////////////////////////// // diff --git a/proxy/shared/DiagsConfig.h b/proxy/shared/DiagsConfig.h index 5aa57892bea..e76f2dff3bd 100644 --- a/proxy/shared/DiagsConfig.h +++ b/proxy/shared/DiagsConfig.h @@ -23,8 +23,8 @@ #pragma once -#include "ts/Diags.h" -#include "ts/BaseLogFile.h" +#include "tscore/Diags.h" +#include "tscore/BaseLogFile.h" struct DiagsConfig { void reconfigure_diags(); diff --git a/proxy/shared/Makefile.am b/proxy/shared/Makefile.am index f20979f612c..1880725076a 100644 --- a/proxy/shared/Makefile.am +++ b/proxy/shared/Makefile.am @@ -25,7 +25,7 @@ noinst_LIBRARIES = \ AM_CPPFLAGS += \ $(iocore_include_dirs) \ - -I$(abs_top_srcdir)/lib/records \ + -I$(abs_top_srcdir)/include/records \ -I$(abs_top_srcdir)/mgmt \ -I$(abs_top_srcdir)/mgmt/api \ -I$(abs_top_srcdir)/mgmt/api/include \ @@ -35,7 +35,7 @@ AM_CPPFLAGS += \ -I$(abs_top_srcdir)/proxy/http \ -I$(abs_top_srcdir)/proxy/hdrs \ -I$(abs_top_srcdir)/proxy/logging \ - -I$(abs_top_srcdir)/lib \ + -I$(abs_top_srcdir)/include \ $(TS_INCLUDES) libdiagsconfig_a_SOURCES = \ diff --git a/proxy/shared/UglyLogStubs.cc b/proxy/shared/UglyLogStubs.cc index 05ada09f64d..ce4d97be2b4 100644 --- a/proxy/shared/UglyLogStubs.cc +++ b/proxy/shared/UglyLogStubs.cc @@ -24,7 +24,7 @@ // This is total BS, because our libraries are riddled with cross dependencies. // TODO: Clean up the dependency mess, and get rid of this. -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #include "LogObject.h" #if defined(solaris) diff --git a/src/Makefile.am b/src/Makefile.am index 5fc1b2e3c5c..fa3e9cea696 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -20,6 +20,15 @@ include $(top_srcdir)/build/tidy.mk bin_PROGRAMS = check_PROGRAMS = TESTS = +lib_LTLIBRARIES = +noinst_PROGRAMS = + +SUBDIRS = tscpp/api + +if BUILD_WCCP +SUBDIRS += wccp +include traffic_wccp/Makefile.inc +endif include traffic_cache_tool/Makefile.inc include traffic_via/Makefile.inc @@ -32,11 +41,6 @@ include traffic_ctl/Makefile.inc include traffic_layout/Makefile.inc include traffic_logcat/Makefile.inc -if BUILD_WCCP -include traffic_wccp/Makefile.inc -endif - -TESTS += \ $(check_PROGRAMS) clang-tidy-local: $(DIST_SOURCES) diff --git a/src/traffic_cache_tool/CacheDefs.h b/src/traffic_cache_tool/CacheDefs.h index 2ec599cb03a..08a73e4d8b3 100644 --- a/src/traffic_cache_tool/CacheDefs.h +++ b/src/traffic_cache_tool/CacheDefs.h @@ -24,14 +24,14 @@ #pragma once #include #include -#include -#include -#include +#include "tscore/I_Version.h" +#include "tscore/Scalar.h" +#include "tscore/Regex.h" #include -#include -#include +#include "tscpp/util/TextView.h" +#include "tscore/ink_file.h" #include -#include +#include "tscore/CryptoHash.h" #include "Command.h" #include "File.h" diff --git a/src/traffic_cache_tool/CacheTool.cc b/src/traffic_cache_tool/CacheTool.cc index c59f355cb75..d6218ed3241 100644 --- a/src/traffic_cache_tool/CacheTool.cc +++ b/src/traffic_cache_tool/CacheTool.cc @@ -38,10 +38,10 @@ #include #include -#include -#include -#include -#include +#include "tscore/ink_memory.h" +#include "tscore/ink_file.h" +#include "tscore/BufferWriter.h" +#include "tscore/CryptoHash.h" #include #include "File.h" diff --git a/src/traffic_cache_tool/File.h b/src/traffic_cache_tool/File.h index 4d3e7173cd4..4991d37f21b 100644 --- a/src/traffic_cache_tool/File.h +++ b/src/traffic_cache_tool/File.h @@ -26,8 +26,8 @@ #include #include #include -#include "ts/ink_memory.h" -#include "ts/TextView.h" +#include "tscore/ink_memory.h" +#include "tscpp/util/TextView.h" namespace ts { diff --git a/src/traffic_cache_tool/Makefile.inc b/src/traffic_cache_tool/Makefile.inc index 71c5d1fb4bc..9082cf8d149 100644 --- a/src/traffic_cache_tool/Makefile.inc +++ b/src/traffic_cache_tool/Makefile.inc @@ -21,7 +21,7 @@ bin_PROGRAMS += traffic_cache_tool/traffic_cache_tool traffic_cache_tool_traffic_cache_tool_CPPFLAGS = \ $(AM_CPPFLAGS) \ - -I $(top_srcdir)/lib \ + -I $(abs_top_srcdir)/include \ -D__STDC_FORMAT_MACROS traffic_cache_tool_traffic_cache_tool_SOURCES = \ @@ -36,16 +36,16 @@ traffic_cache_tool_traffic_cache_tool_SOURCES = \ traffic_cache_tool/CacheScan.cc traffic_cache_tool_traffic_cache_tool_LDADD = \ - $(top_builddir)/lib/ts/.libs/ink_assert.o \ - $(top_builddir)/lib/ts/.libs/ink_code.o \ - $(top_builddir)/lib/ts/.libs/ink_error.o \ - $(top_builddir)/lib/ts/.libs/ink_file.o \ - $(top_builddir)/lib/ts/.libs/ink_memory.o \ - $(top_builddir)/lib/ts/.libs/ink_string.o \ - $(top_builddir)/lib/ts/.libs/BufferWriterFormat.o \ - $(top_builddir)/lib/ts/.libs/TextView.o \ + $(top_builddir)/src/tscore/.libs/ink_assert.o \ + $(top_builddir)/src/tscore/.libs/ink_code.o \ + $(top_builddir)/src/tscore/.libs/ink_error.o \ + $(top_builddir)/src/tscore/.libs/ink_file.o \ + $(top_builddir)/src/tscore/.libs/ink_memory.o \ + $(top_builddir)/src/tscore/.libs/ink_string.o \ + $(top_builddir)/src/tscore/.libs/BufferWriterFormat.o \ + $(top_builddir)/src/tscpp/util/.libs/TextView.o \ $(top_builddir)/lib/tsconfig/.libs/Errata.o \ - $(top_builddir)/lib/ts/.libs/Regex.o \ - $(top_builddir)/lib/ts/.libs/CryptoHash.o \ - $(top_builddir)/lib/ts/.libs/MMH.o \ + $(top_builddir)/src/tscore/.libs/Regex.o \ + $(top_builddir)/src/tscore/.libs/CryptoHash.o \ + $(top_builddir)/src/tscore/.libs/MMH.o \ @OPENSSL_LIBS@ @LIBPCRE@ @LIBTCL@ diff --git a/src/traffic_crashlog/Makefile.inc b/src/traffic_crashlog/Makefile.inc index 90f8add1039..7880a2ba41f 100644 --- a/src/traffic_crashlog/Makefile.inc +++ b/src/traffic_crashlog/Makefile.inc @@ -20,8 +20,8 @@ bin_PROGRAMS += traffic_crashlog/traffic_crashlog traffic_crashlog_traffic_crashlog_CPPFLAGS = \ $(AM_CPPFLAGS) \ $(iocore_include_dirs) \ - -I$(abs_top_srcdir)/lib \ - -I$(abs_top_srcdir)/lib/records \ + -I$(abs_top_srcdir)/include \ + -I$(abs_top_srcdir)/include/records \ -I$(abs_top_srcdir)/mgmt \ -I$(abs_top_srcdir)/mgmt/utils \ -I$(abs_top_srcdir)/mgmt/api/include \ @@ -42,5 +42,6 @@ traffic_crashlog_traffic_crashlog_LDADD = \ $(top_builddir)/proxy/shared/libUglyLogStubs.a \ $(top_builddir)/iocore/eventsystem/libinkevent.a \ $(top_builddir)/mgmt/api/libtsmgmt.la \ - $(top_builddir)/lib/ts/libtsutil.la \ + $(top_builddir)/src/tscore/libtscore.la \ + $(top_builddir)/src/tscpp/util/libtscpputil.la \ @LIBTCL@ @HWLOC_LIBS@ diff --git a/src/traffic_crashlog/traffic_crashlog.cc b/src/traffic_crashlog/traffic_crashlog.cc index 3f04d17db16..c2848f9491e 100644 --- a/src/traffic_crashlog/traffic_crashlog.cc +++ b/src/traffic_crashlog/traffic_crashlog.cc @@ -22,15 +22,15 @@ */ #include "traffic_crashlog.h" -#include "ts/ink_args.h" -#include "ts/ink_cap.h" -#include "ts/I_Version.h" -#include "ts/I_Layout.h" -#include "ts/ink_syslog.h" -#include "I_RecProcess.h" +#include "tscore/ink_args.h" +#include "tscore/ink_cap.h" +#include "tscore/I_Version.h" +#include "tscore/I_Layout.h" +#include "tscore/ink_syslog.h" +#include "records/I_RecProcess.h" #include "RecordsConfig.h" -#include "ts/BaseLogFile.h" -#include "ts/runroot.h" +#include "tscore/BaseLogFile.h" +#include "tscore/runroot.h" static int syslog_mode = false; static int debug_mode = false; diff --git a/src/traffic_crashlog/traffic_crashlog.h b/src/traffic_crashlog/traffic_crashlog.h index 0d1551eb922..ba17f5a7611 100644 --- a/src/traffic_crashlog/traffic_crashlog.h +++ b/src/traffic_crashlog/traffic_crashlog.h @@ -23,10 +23,10 @@ #pragma once -#include "ts/ink_platform.h" -#include "ts/ink_memory.h" -#include "ts/Diags.h" -#include "ts/TextBuffer.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_memory.h" +#include "tscore/Diags.h" +#include "tscore/TextBuffer.h" #include "mgmtapi.h" // ucontext.h is deprecated on Darwin, and we really only need it on Linux, so only diff --git a/src/traffic_ctl/Makefile.inc b/src/traffic_ctl/Makefile.inc index 23dca972f35..94ab54dc7f9 100644 --- a/src/traffic_ctl/Makefile.inc +++ b/src/traffic_ctl/Makefile.inc @@ -22,8 +22,8 @@ bin_PROGRAMS += traffic_ctl/traffic_ctl traffic_ctl_traffic_ctl_CPPFLAGS = \ $(AM_CPPFLAGS) \ $(iocore_include_dirs) \ - -I$(abs_top_srcdir)/lib \ - -I$(abs_top_srcdir)/lib/records \ + -I$(abs_top_srcdir)/include \ + -I$(abs_top_srcdir)/include/records \ -I$(abs_top_srcdir)/mgmt \ -I$(abs_top_srcdir)/mgmt/api/include \ $(TS_INCLUDES) @@ -44,5 +44,6 @@ traffic_ctl_traffic_ctl_LDADD = \ $(top_builddir)/iocore/eventsystem/libinkevent.a \ $(top_builddir)/proxy/shared/libUglyLogStubs.a \ $(top_builddir)/mgmt/api/libtsmgmt.la \ - $(top_builddir)/lib/ts/libtsutil.la \ + $(top_builddir)/src/tscore/libtscore.la \ + $(top_builddir)/src/tscpp/util/libtscpputil.la \ @LIBTCL@ @HWLOC_LIBS@ diff --git a/src/traffic_ctl/config.cc b/src/traffic_ctl/config.cc index 14a7554ad0d..35c73035f6d 100644 --- a/src/traffic_ctl/config.cc +++ b/src/traffic_ctl/config.cc @@ -23,8 +23,8 @@ #include "traffic_ctl.h" #include -#include -#include +#include "records/I_RecDefs.h" +#include "records/P_RecUtils.h" struct RecordDescriptionPolicy { using entry_type = TSConfigRecordDescription *; diff --git a/src/traffic_ctl/host.cc b/src/traffic_ctl/host.cc index 0041044301a..2607804a6d8 100644 --- a/src/traffic_ctl/host.cc +++ b/src/traffic_ctl/host.cc @@ -21,7 +21,7 @@ limitations under the License. */ #include "traffic_ctl.h" -#include +#include "records/P_RecUtils.h" const std::string stat_prefix = "host_status."; static int status_get(unsigned argc, const char **argv) diff --git a/src/traffic_ctl/metric.cc b/src/traffic_ctl/metric.cc index d207c3fc051..68796b5e62d 100644 --- a/src/traffic_ctl/metric.cc +++ b/src/traffic_ctl/metric.cc @@ -22,7 +22,7 @@ */ #include "traffic_ctl.h" -#include +#include "records/P_RecUtils.h" static int metric_get(unsigned argc, const char **argv) diff --git a/src/traffic_ctl/traffic_ctl.cc b/src/traffic_ctl/traffic_ctl.cc index af75351b932..c510c422cda 100644 --- a/src/traffic_ctl/traffic_ctl.cc +++ b/src/traffic_ctl/traffic_ctl.cc @@ -23,10 +23,10 @@ #include "traffic_ctl.h" -#include "I_RecProcess.h" +#include "records/I_RecProcess.h" #include "RecordsConfig.h" -#include "ts/I_Layout.h" -#include "ts/runroot.h" +#include "tscore/I_Layout.h" +#include "tscore/runroot.h" AppVersionInfo CtrlVersionInfo; diff --git a/src/traffic_ctl/traffic_ctl.h b/src/traffic_ctl/traffic_ctl.h index b5a5a1de982..991c790bfa8 100644 --- a/src/traffic_ctl/traffic_ctl.h +++ b/src/traffic_ctl/traffic_ctl.h @@ -23,13 +23,13 @@ #pragma once -#include "ts/ink_platform.h" -#include "ts/Diags.h" -#include "ts/ink_memory.h" +#include "tscore/ink_platform.h" +#include "tscore/Diags.h" +#include "tscore/ink_memory.h" #include "mgmtapi.h" -#include "ts/ink_args.h" -#include "ts/I_Version.h" -#include "ts/BaseLogFile.h" +#include "tscore/ink_args.h" +#include "tscore/I_Version.h" +#include "tscore/BaseLogFile.h" #include #include diff --git a/src/traffic_layout/Makefile.inc b/src/traffic_layout/Makefile.inc index c48b62d5cc1..71e47fa1bb9 100644 --- a/src/traffic_layout/Makefile.inc +++ b/src/traffic_layout/Makefile.inc @@ -20,8 +20,8 @@ bin_PROGRAMS += traffic_layout/traffic_layout traffic_layout_traffic_layout_CPPFLAGS = \ $(AM_CPPFLAGS) \ $(iocore_include_dirs) \ - -I$(abs_top_srcdir)/lib \ - -I$(abs_top_srcdir)/lib/records \ + -I$(abs_top_srcdir)/include \ + -I$(abs_top_srcdir)/include/records \ -I$(abs_top_srcdir)/mgmt \ -I$(abs_top_srcdir)/mgmt/utils \ @YAMLCPP_INCLUDES@ \ @@ -46,5 +46,6 @@ traffic_layout_traffic_layout_LDADD = \ $(top_builddir)/mgmt/libmgmt_p.la \ $(top_builddir)/proxy/shared/libUglyLogStubs.a \ $(top_builddir)/iocore/eventsystem/libinkevent.a \ - $(top_builddir)/lib/ts/libtsutil.la \ + $(top_builddir)/src/tscore/libtscore.la \ + $(top_builddir)/src/tscpp/util/libtscpputil.la \ @LIBTCL@ @HWLOC_LIBS@ @YAMLCPP_LIBS@ diff --git a/src/traffic_layout/engine.cc b/src/traffic_layout/engine.cc index 086ce9e5bf2..c7e21ca560f 100644 --- a/src/traffic_layout/engine.cc +++ b/src/traffic_layout/engine.cc @@ -24,17 +24,17 @@ // for engine of traffic runroot // function introduction in engine.h -#include "ts/runroot.h" -#include "ts/I_Layout.h" -#include "ts/ink_error.h" -#include "ts/ink_args.h" -#include "ts/I_Version.h" +#include "tscore/runroot.h" +#include "tscore/I_Layout.h" +#include "tscore/ink_error.h" +#include "tscore/ink_args.h" +#include "tscore/I_Version.h" #include "records/I_RecCore.h" -#include "ts/ink_config.h" +#include "tscore/ink_config.h" #include "engine.h" #include "file_system.h" -#include "ts/runroot.h" +#include "tscore/runroot.h" #include #include diff --git a/src/traffic_layout/file_system.cc b/src/traffic_layout/file_system.cc index 02c6c5dced0..a1f054022b5 100644 --- a/src/traffic_layout/file_system.cc +++ b/src/traffic_layout/file_system.cc @@ -25,9 +25,9 @@ // including: make directory (with parents), copy directory (recursively), remove directory (recursively), remove all directories // inside -#include "ts/ink_error.h" -#include "ts/I_Layout.h" -#include "ts/runroot.h" +#include "tscore/ink_error.h" +#include "tscore/I_Layout.h" +#include "tscore/runroot.h" #include "file_system.h" #include diff --git a/src/traffic_layout/info.cc b/src/traffic_layout/info.cc index 5304706e5f2..1be0d3779e3 100644 --- a/src/traffic_layout/info.cc +++ b/src/traffic_layout/info.cc @@ -21,8 +21,8 @@ limitations under the License. */ -#include "ts/I_Layout.h" -#include "I_RecProcess.h" +#include "tscore/I_Layout.h" +#include "records/I_RecProcess.h" #include "RecordsConfig.h" #include "info.h" diff --git a/src/traffic_layout/traffic_layout.cc b/src/traffic_layout/traffic_layout.cc index 51b0762bb52..f3cd448442d 100644 --- a/src/traffic_layout/traffic_layout.cc +++ b/src/traffic_layout/traffic_layout.cc @@ -21,13 +21,13 @@ limitations under the License. */ -#include "ts/ink_platform.h" -#include "ts/ink_args.h" -#include "ts/I_Version.h" -#include "ts/I_Layout.h" -#include "I_RecProcess.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_args.h" +#include "tscore/I_Version.h" +#include "tscore/I_Layout.h" +#include "records/I_RecProcess.h" #include "RecordsConfig.h" -#include "ts/runroot.h" +#include "tscore/runroot.h" #include "engine.h" #include "file_system.h" #include "info.h" diff --git a/src/traffic_logcat/Makefile.inc b/src/traffic_logcat/Makefile.inc index ec65d415257..c58a047d3d6 100644 --- a/src/traffic_logcat/Makefile.inc +++ b/src/traffic_logcat/Makefile.inc @@ -22,8 +22,8 @@ bin_PROGRAMS += traffic_logcat/traffic_logcat traffic_logcat_traffic_logcat_CPPFLAGS = \ $(AM_CPPFLAGS) \ $(iocore_include_dirs) \ - -I$(abs_top_srcdir)/lib \ - -I$(abs_top_srcdir)/lib/records \ + -I$(abs_top_srcdir)/include \ + -I$(abs_top_srcdir)/include/records \ -I$(abs_top_srcdir)/proxy \ -I$(abs_top_srcdir)/proxy/logging \ -I$(abs_top_srcdir)/proxy/shared \ @@ -46,7 +46,8 @@ traffic_logcat_traffic_logcat_LDADD = \ $(top_builddir)/mgmt/libmgmt_p.la \ $(top_builddir)/lib/records/librecords_p.a \ $(top_builddir)/iocore/eventsystem/libinkevent.a \ - $(top_builddir)/lib/ts/libtsutil.la + $(top_builddir)/src/tscore/libtscore.la \ + $(top_builddir)/src/tscpp/util/libtscpputil.la traffic_logcat_traffic_logcat_LDADD += \ @LIBTCL@ @HWLOC_LIBS@ \ diff --git a/src/traffic_logcat/logcat.cc b/src/traffic_logcat/logcat.cc index 45cf30a0c69..879938c47c0 100644 --- a/src/traffic_logcat/logcat.cc +++ b/src/traffic_logcat/logcat.cc @@ -21,10 +21,10 @@ limitations under the License. */ -#include "ts/ink_platform.h" -#include "ts/ink_args.h" -#include "ts/I_Layout.h" -#include "ts/runroot.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_args.h" +#include "tscore/I_Layout.h" +#include "tscore/runroot.h" #define PROGRAM_NAME "traffic_logcat" #define MAX_LOGBUFFER_SIZE 65536 diff --git a/src/traffic_logstats/Makefile.inc b/src/traffic_logstats/Makefile.inc index 3d2b72ef17d..d41219eaa76 100644 --- a/src/traffic_logstats/Makefile.inc +++ b/src/traffic_logstats/Makefile.inc @@ -22,8 +22,8 @@ bin_PROGRAMS += traffic_logstats/traffic_logstats traffic_logstats_traffic_logstats_CPPFLAGS = \ $(AM_CPPFLAGS) \ $(iocore_include_dirs) \ - -I$(abs_top_srcdir)/lib \ - -I$(abs_top_srcdir)/lib/records \ + -I$(abs_top_srcdir)/include \ + -I$(abs_top_srcdir)/include/records \ -I$(abs_top_srcdir)/proxy \ -I$(abs_top_srcdir)/proxy/logging \ -I$(abs_top_srcdir)/proxy/shared \ @@ -50,7 +50,8 @@ traffic_logstats_traffic_logstats_LDADD = \ $(top_builddir)/mgmt/libmgmt_p.la \ $(top_builddir)/lib/records/librecords_p.a \ $(top_builddir)/iocore/eventsystem/libinkevent.a \ - $(top_builddir)/lib/ts/libtsutil.la + $(top_builddir)/src/tscore/libtscore.la \ + $(top_builddir)/src/tscpp/util/libtscpputil.la traffic_logstats_traffic_logstats_LDADD += \ @LIBTCL@ @HWLOC_LIBS@ \ diff --git a/src/traffic_logstats/logstats.cc b/src/traffic_logstats/logstats.cc index 44cbb1e931a..72885e1bc65 100644 --- a/src/traffic_logstats/logstats.cc +++ b/src/traffic_logstats/logstats.cc @@ -22,14 +22,14 @@ limitations under the License. */ -#include "ts/ink_platform.h" -#include "ts/ink_file.h" -#include "ts/I_Layout.h" -#include "ts/I_Version.h" -#include "ts/HashFNV.h" -#include "ts/ink_args.h" -#include "ts/MatcherUtils.h" -#include "ts/runroot.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_file.h" +#include "tscore/I_Layout.h" +#include "tscore/I_Version.h" +#include "tscore/HashFNV.h" +#include "tscore/ink_args.h" +#include "tscore/MatcherUtils.h" +#include "tscore/runroot.h" // Includes and namespaces etc. #include "LogStandalone.cc" diff --git a/src/traffic_manager/AddConfigFilesHere.cc b/src/traffic_manager/AddConfigFilesHere.cc index f1126375355..fd3b961abe6 100644 --- a/src/traffic_manager/AddConfigFilesHere.cc +++ b/src/traffic_manager/AddConfigFilesHere.cc @@ -21,9 +21,9 @@ limitations under the License. */ -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #include "MgmtUtils.h" -#include "ts/Diags.h" +#include "tscore/Diags.h" #include "FileManager.h" extern FileManager *configFiles; diff --git a/src/traffic_manager/Makefile.inc b/src/traffic_manager/Makefile.inc index 94c6438f812..c99bec367d4 100644 --- a/src/traffic_manager/Makefile.inc +++ b/src/traffic_manager/Makefile.inc @@ -20,14 +20,14 @@ bin_PROGRAMS += traffic_manager/traffic_manager traffic_manager_traffic_manager_CPPFLAGS = \ $(AM_CPPFLAGS) \ $(iocore_include_dirs) \ - -I$(abs_top_srcdir)/lib/records \ + -I$(abs_top_srcdir)/include/records \ -I$(abs_top_srcdir)/proxy/hdrs \ -I$(abs_top_srcdir)/proxy/shared \ -I$(abs_top_srcdir)/mgmt \ -I$(abs_top_srcdir)/mgmt/api \ -I$(abs_top_srcdir)/mgmt/api/include \ -I$(abs_top_srcdir)/mgmt/utils \ - -I$(abs_top_srcdir)/lib \ + -I$(abs_top_srcdir)/include \ $(TS_INCLUDES) traffic_manager_traffic_manager_LDFLAGS = \ @@ -43,7 +43,8 @@ traffic_manager_traffic_manager_LDADD = \ $(top_builddir)/mgmt/api/libmgmtapilocal.la \ $(top_builddir)/mgmt/libmgmt_lm.la \ $(top_builddir)/proxy/hdrs/libhdrs.a \ - $(top_builddir)/lib/ts/libtsutil.la \ + $(top_builddir)/src/tscore/libtscore.la \ + $(top_builddir)/src/tscpp/util/libtscpputil.la \ $(top_builddir)/iocore/eventsystem/libinkevent.a \ $(top_builddir)/lib/records/librecords_lm.a \ $(top_builddir)/proxy/shared/libdiagsconfig.a \ @@ -55,7 +56,7 @@ traffic_manager_traffic_manager_LDADD = \ # Must do it this way or the dependencies aren't detected. if BUILD_WCCP traffic_manager_traffic_manager_LDADD += \ - $(top_builddir)/lib/wccp/libwccp.a \ + wccp/libwccp.a \ $(top_builddir)/lib/tsconfig/libtsconfig.la \ @OPENSSL_LIBS@ endif diff --git a/src/traffic_manager/traffic_manager.cc b/src/traffic_manager/traffic_manager.cc index 86fe2482f68..f1d47f0e072 100644 --- a/src/traffic_manager/traffic_manager.cc +++ b/src/traffic_manager/traffic_manager.cc @@ -21,22 +21,22 @@ limitations under the License. */ -#include "ts/ink_sys_control.h" -#include "ts/ink_cap.h" -#include "ts/ink_lockfile.h" -#include "ts/ink_sock.h" -#include "ts/ink_args.h" -#include "ts/ink_syslog.h" -#include "ts/runroot.h" +#include "tscore/ink_sys_control.h" +#include "tscore/ink_cap.h" +#include "tscore/ink_lockfile.h" +#include "tscore/ink_sock.h" +#include "tscore/ink_args.h" +#include "tscore/ink_syslog.h" +#include "tscore/runroot.h" #include "WebMgmtUtils.h" #include "MgmtUtils.h" #include "MgmtSocket.h" #include "NetworkUtilsRemote.h" #include "FileManager.h" -#include "ts/I_Layout.h" -#include "ts/I_Version.h" -#include "ts/TextBuffer.h" +#include "tscore/I_Layout.h" +#include "tscore/I_Version.h" +#include "tscore/TextBuffer.h" #include "DiagsConfig.h" #include "HTTP.h" #include "CoreAPI.h" @@ -48,7 +48,7 @@ // Needs LibRecordsConfigInit() #include "RecordsConfig.h" -#include "P_RecLocal.h" +#include "records/P_RecLocal.h" #include "DerivativeMetrics.h" #if TS_USE_POSIX_CAP @@ -56,7 +56,7 @@ #endif #include #include -#include +#include "tscore/bwf_std_format.h" #define FD_THROTTLE_HEADROOM (128 + 64) // TODO: consolidate with THROTTLE_FD_HEADROOM #define DIAGS_LOG_FILENAME "manager.log" diff --git a/src/traffic_server/CoreUtils.cc b/src/traffic_server/CoreUtils.cc index bdcb8530e02..ac628b5e68d 100644 --- a/src/traffic_server/CoreUtils.cc +++ b/src/traffic_server/CoreUtils.cc @@ -86,7 +86,7 @@ /* modify the "note" in process_core */ /* Document properly */ -#include "ts/ink_config.h" +#include "tscore/ink_config.h" #if defined(linux) #include "CoreUtils.h" @@ -103,7 +103,7 @@ int program_counter = 0; #include #include #include -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #include "CoreUtils.h" #endif /* darwin || freebsd || solaris */ diff --git a/src/traffic_server/CoreUtils.h b/src/traffic_server/CoreUtils.h index 120aa75494f..f4817290523 100644 --- a/src/traffic_server/CoreUtils.h +++ b/src/traffic_server/CoreUtils.h @@ -38,7 +38,7 @@ #include #include #include -#include "ts/DynArray.h" +#include "tscore/DynArray.h" #define SP_REGNUM 15 /* Contains address of top of stack USP */ #define PC_REGNUM 12 /* Contains program counter EIP */ diff --git a/src/traffic_server/Crash.cc b/src/traffic_server/Crash.cc index 7f153951872..9a8dffaf164 100644 --- a/src/traffic_server/Crash.cc +++ b/src/traffic_server/Crash.cc @@ -22,10 +22,10 @@ */ #include "Main.h" -#include "ts/I_Layout.h" +#include "tscore/I_Layout.h" #include "I_Net.h" -#include "ts/signals.h" -#include "ts/ink_cap.h" +#include "tscore/signals.h" +#include "tscore/ink_cap.h" // ucontext.h is deprecated on Darwin, and we really only need it on Linux, so only // include it if we are planning to use it. diff --git a/src/traffic_server/EventName.cc b/src/traffic_server/EventName.cc index cac03e93704..e45be296351 100644 --- a/src/traffic_server/EventName.cc +++ b/src/traffic_server/EventName.cc @@ -21,7 +21,7 @@ limitations under the License. */ -#include "ts/ink_config.h" +#include "tscore/ink_config.h" #include #include diff --git a/src/traffic_server/FetchSM.cc b/src/traffic_server/FetchSM.cc index df6d720937e..436405fa34e 100644 --- a/src/traffic_server/FetchSM.cc +++ b/src/traffic_server/FetchSM.cc @@ -21,12 +21,12 @@ limitations under the License. */ -#include "ts/ink_config.h" +#include "tscore/ink_config.h" #include "FetchSM.h" #include #include "HTTP.h" #include "PluginVC.h" -#include "api/ts/ts.h" // Ugly, but we need a bunch of the public APIs here ... :-/ +#include "ts/ts.h" // Ugly, but we need a bunch of the public APIs here ... :-/ #define DEBUG_TAG "FetchSM" #define FETCH_LOCK_RETRY_TIME HRTIME_MSECONDS(10) diff --git a/src/traffic_server/InkAPI.cc b/src/traffic_server/InkAPI.cc index 67ec1a4c9a7..5413fa1efd8 100644 --- a/src/traffic_server/InkAPI.cc +++ b/src/traffic_server/InkAPI.cc @@ -24,9 +24,9 @@ #include #include -#include "ts/ink_platform.h" -#include "ts/ink_base64.h" -#include "ts/I_Layout.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_base64.h" +#include "tscore/I_Layout.h" #include "InkAPIInternal.h" #include "Log.h" @@ -43,14 +43,14 @@ #include "P_UDPNet.h" #include "P_HostDB.h" #include "P_Cache.h" -#include "I_RecCore.h" +#include "records/I_RecCore.h" #include "P_SSLConfig.h" #include "ProxyConfig.h" #include "Plugin.h" #include "LogObject.h" #include "LogConfig.h" #include "PluginVC.h" -#include "api/ts/experimental.h" +#include "ts/experimental.h" #include "HttpSessionAccept.h" #include "PluginVC.h" #include "FetchSM.h" @@ -59,13 +59,13 @@ #include "I_Tasks.h" #include "P_OCSPStapling.h" -#include "I_RecDefs.h" -#include "I_RecCore.h" +#include "records/I_RecDefs.h" +#include "records/I_RecCore.h" #include "I_Machine.h" #include "HttpProxyServerMain.h" #include -#include "api/ts/ts.h" +#include "ts/ts.h" /**************************************************************** * IMPORTANT - READ ME @@ -6718,7 +6718,7 @@ TSHttpTxnIntercept(TSCont contp, TSHttpTxn txnp) // The API below require timer values as TSHRTime parameters // which are in nanoseconds. Use the TS_HRTIME macros defined -// in api/ts/experimental.h until they are promoted to stable +// in ts/experimental.h until they are promoted to stable // api. /* Net VConnections */ void diff --git a/src/traffic_server/InkAPITest.cc b/src/traffic_server/InkAPITest.cc index 688cbe38294..6193a0bc394 100644 --- a/src/traffic_server/InkAPITest.cc +++ b/src/traffic_server/InkAPITest.cc @@ -36,19 +36,19 @@ #include #include -#include "ts/ink_config.h" -#include "ts/ink_sprintf.h" -#include "ts/ink_file.h" -#include "ts/Regression.h" -#include "api/ts/ts.h" -#include "api/ts/experimental.h" -#include "I_RecCore.h" +#include "tscore/ink_config.h" +#include "tscore/ink_sprintf.h" +#include "tscore/ink_file.h" +#include "tscore/Regression.h" +#include "ts/ts.h" +#include "ts/experimental.h" +#include "records/I_RecCore.h" #include "P_Net.h" #include "records/I_RecHttp.h" #include "http/HttpSM.h" -#include "ts/TestBox.h" +#include "tscore/TestBox.h" // This used to be in InkAPITestTool.cc, which we'd just #include here... But that seemed silly. #define SDBG_TAG "SockServer" @@ -9011,7 +9011,7 @@ REGRESSION_TEST(SDK_API_DEBUG_NAME_LOOKUPS)(RegressionTest *test, int /* atype A // TSUuidVersionGet // TSUuidStringParse //////////////////////////////////////////////// -#include "ts/ink_uuid.h" +#include "tscore/ink_uuid.h" REGRESSION_TEST(SDK_API_UUID)(RegressionTest *test, int /* atype ATS_UNUSED */, int *pstatus) { diff --git a/src/traffic_server/InkIOCoreAPI.cc b/src/traffic_server/InkIOCoreAPI.cc index cd6c65d26cf..d3dc3bf35b9 100644 --- a/src/traffic_server/InkIOCoreAPI.cc +++ b/src/traffic_server/InkIOCoreAPI.cc @@ -27,9 +27,9 @@ * file to ensure that it gets exported as a global symbol in TS */ -#include "ts/ink_platform.h" -#include "api/ts/ts.h" -#include "api/ts/InkAPIPrivateIOCore.h" +#include "tscore/ink_platform.h" +#include "ts/ts.h" +#include "ts/InkAPIPrivateIOCore.h" #if defined(solaris) && !defined(__GNUC__) #include "P_EventSystem.h" // I_EventSystem.h #include "P_Net.h" // I_Net.h diff --git a/src/traffic_server/Makefile.inc b/src/traffic_server/Makefile.inc index 8175f78f5ab..eae9362696b 100644 --- a/src/traffic_server/Makefile.inc +++ b/src/traffic_server/Makefile.inc @@ -22,8 +22,8 @@ bin_PROGRAMS += traffic_server/traffic_server traffic_server_traffic_server_CPPFLAGS = \ $(AM_CPPFLAGS) \ $(iocore_include_dirs) \ - -I$(abs_top_srcdir)/lib \ - -I$(abs_top_srcdir)/lib/records \ + -I$(abs_top_srcdir)/include \ + -I$(abs_top_srcdir)/include/records \ -I$(abs_top_srcdir)/proxy \ -I$(abs_top_srcdir)/proxy/http \ -I$(abs_top_srcdir)/proxy/http2 \ @@ -74,7 +74,8 @@ traffic_server_traffic_server_LDADD = \ $(top_builddir)/iocore/dns/libinkdns.a \ $(top_builddir)/iocore/cache/libinkcache.a \ $(top_builddir)/iocore/aio/libinkaio.a \ - $(top_builddir)/lib/ts/libtsutil.la \ + $(top_builddir)/src/tscore/libtscore.la \ + $(top_builddir)/src/tscpp/util/libtscpputil.la \ $(top_builddir)/proxy/libproxy.a \ $(top_builddir)/iocore/net/libinknet.a \ $(top_builddir)/lib/records/librecords_p.a \ diff --git a/src/traffic_server/SocksProxy.cc b/src/traffic_server/SocksProxy.cc index 1db846b60dd..77208ee4669 100644 --- a/src/traffic_server/SocksProxy.cc +++ b/src/traffic_server/SocksProxy.cc @@ -27,7 +27,7 @@ */ -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #include "P_Net.h" #include "I_OneWayTunnel.h" #include "HttpSessionAccept.h" diff --git a/src/traffic_server/traffic_server.cc b/src/traffic_server/traffic_server.cc index 0e786685c08..5ab48bc093b 100644 --- a/src/traffic_server/traffic_server.cc +++ b/src/traffic_server/traffic_server.cc @@ -30,16 +30,16 @@ ****************************************************************************/ -#include "ts/ink_platform.h" -#include "ts/ink_sys_control.h" -#include "ts/ink_args.h" -#include "ts/ink_lockfile.h" -#include "ts/ink_stack_trace.h" -#include "ts/ink_syslog.h" -#include "ts/hugepages.h" -#include "ts/runroot.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_sys_control.h" +#include "tscore/ink_args.h" +#include "tscore/ink_lockfile.h" +#include "tscore/ink_stack_trace.h" +#include "tscore/ink_syslog.h" +#include "tscore/hugepages.h" +#include "tscore/runroot.h" -#include "api/ts/ts.h" // This is sadly needed because of us using TSThreadInit() for some reason. +#include "ts/ts.h" // This is sadly needed because of us using TSThreadInit() for some reason. #include #include @@ -59,7 +59,7 @@ extern "C" int plock(int); #endif #include "Main.h" -#include "ts/signals.h" +#include "tscore/signals.h" #include "P_EventSystem.h" #include "P_Net.h" #include "P_UDPNet.h" @@ -67,10 +67,10 @@ extern "C" int plock(int); #include "P_SplitDNS.h" #include "P_HostDB.h" #include "P_Cache.h" -#include "ts/I_Layout.h" +#include "tscore/I_Layout.h" #include "I_Machine.h" #include "RecordsConfig.h" -#include "I_RecProcess.h" +#include "records/I_RecProcess.h" #include "Transform.h" #include "ProcessManager.h" #include "ProxyConfig.h" @@ -93,10 +93,10 @@ extern "C" int plock(int); #include "I_Tasks.h" #include "InkAPIInternal.h" #include "HTTP2.h" -#include "ts/ink_config.h" +#include "tscore/ink_config.h" #include "P_SSLSNI.h" -#include +#include "tscore/ink_cap.h" #if TS_HAS_PROFILER #include diff --git a/src/traffic_top/Makefile.inc b/src/traffic_top/Makefile.inc index 2a969c116d8..67636be6fcc 100644 --- a/src/traffic_top/Makefile.inc +++ b/src/traffic_top/Makefile.inc @@ -23,8 +23,8 @@ bin_PROGRAMS += traffic_top/traffic_top traffic_top_traffic_top_CPPFLAGS = \ $(AM_CPPFLAGS) \ $(iocore_include_dirs) \ - -I$(abs_top_srcdir)/lib \ - -I$(abs_top_srcdir)/lib/records \ + -I$(abs_top_srcdir)/include \ + -I$(abs_top_srcdir)/include/records \ -I$(abs_top_srcdir)/mgmt \ -I$(abs_top_srcdir)/mgmt/api/include \ $(TS_INCLUDES) \ @@ -45,7 +45,8 @@ traffic_top_traffic_top_LDADD = \ $(top_builddir)/iocore/eventsystem/libinkevent.a \ $(top_builddir)/proxy/shared/libUglyLogStubs.a \ $(top_builddir)/mgmt/api/libtsmgmt.la \ - $(top_builddir)/lib/ts/libtsutil.la \ + $(top_builddir)/src/tscore/libtscore.la \ + $(top_builddir)/src/tscpp/util/libtscpputil.la \ @CURL_LIBS@ \ @CURSES_LIBS@ \ @LIBTCL@ @HWLOC_LIBS@ diff --git a/src/traffic_top/traffic_top.cc b/src/traffic_top/traffic_top.cc index da44ae8279b..4021cc77d91 100644 --- a/src/traffic_top/traffic_top.cc +++ b/src/traffic_top/traffic_top.cc @@ -21,7 +21,7 @@ limitations under the License. */ -#include "ts/ink_config.h" +#include "tscore/ink_config.h" #include #include #include @@ -53,9 +53,9 @@ #include "stats.h" -#include "ts/I_Layout.h" -#include "ts/ink_args.h" -#include "I_RecProcess.h" +#include "tscore/I_Layout.h" +#include "tscore/ink_args.h" +#include "records/I_RecProcess.h" #include "RecordsConfig.h" using namespace std; diff --git a/src/traffic_via/Makefile.inc b/src/traffic_via/Makefile.inc index 1ce8c710f0d..fa75a84212b 100644 --- a/src/traffic_via/Makefile.inc +++ b/src/traffic_via/Makefile.inc @@ -22,7 +22,7 @@ bin_PROGRAMS += traffic_via/traffic_via traffic_via_traffic_via_CPPFLAGS = \ $(AM_CPPFLAGS) \ $(iocore_include_dirs) \ - -I$(abs_top_srcdir)/lib \ + -I$(abs_top_srcdir)/include \ -I$(abs_top_srcdir)/mgmt/api/include \ $(TS_INCLUDES) @@ -34,7 +34,8 @@ traffic_via_traffic_via_SOURCES = \ traffic_via/traffic_via.cc traffic_via_traffic_via_LDADD = \ - $(top_builddir)/lib/ts/libtsutil.la \ + $(top_builddir)/src/tscore/libtscore.la \ + $(top_builddir)/src/tscpp/util/libtscpputil.la \ @LIBPCRE@ TESTS += \ diff --git a/src/traffic_via/traffic_via.cc b/src/traffic_via/traffic_via.cc index 632e524d6d4..db55da36284 100644 --- a/src/traffic_via/traffic_via.cc +++ b/src/traffic_via/traffic_via.cc @@ -21,15 +21,15 @@ limitations under the License. */ -#include "ts/ink_platform.h" -#include "ts/ink_args.h" -#include "ts/I_Version.h" -#include "ts/Tokenizer.h" -#include "ts/TextBuffer.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_args.h" +#include "tscore/I_Version.h" +#include "tscore/Tokenizer.h" +#include "tscore/TextBuffer.h" #include "mgmtapi.h" #include #include -#include "ts/Regex.h" +#include "tscore/Regex.h" /// XXX Use DFA or Regex wrappers? #ifdef HAVE_PCRE_PCRE_H diff --git a/src/traffic_wccp/Makefile.inc b/src/traffic_wccp/Makefile.inc index 01f01d9565b..5446e2475b7 100644 --- a/src/traffic_wccp/Makefile.inc +++ b/src/traffic_wccp/Makefile.inc @@ -22,9 +22,9 @@ bin_PROGRAMS += traffic_wccp/traffic_wccp traffic_wccp_traffic_wccp_CPPFLAGS = \ $(AM_CPPFLAGS) \ $(iocore_include_dirs) \ - -I$(abs_top_srcdir)/lib \ - -I$(abs_top_srcdir)/lib/records \ - -I$(abs_top_srcdir)/lib/wccp \ + -I$(abs_top_srcdir)/include \ + -I$(abs_top_srcdir)/include/records \ + -I$(abs_top_srcdir)/include/wccp \ $(TS_INCLUDES) \ @OPENSSL_INCLUDES@ @@ -37,6 +37,7 @@ traffic_wccp_traffic_wccp_SOURCES = \ traffic_wccp_traffic_wccp_LDADD = \ $(top_builddir)/lib/tsconfig/libtsconfig.la \ - $(top_builddir)/lib/wccp/libwccp.a \ - $(top_builddir)/lib/ts/libtsutil.la \ + $(top_builddir)/src/wccp/libwccp.a \ + $(top_builddir)/src/tscore/libtscore.la \ + $(top_builddir)/src/tscpp/util/libtscpputil.la \ @OPENSSL_LIBS@ diff --git a/src/traffic_wccp/wccp_client.cc b/src/traffic_wccp/wccp_client.cc index 92921df8551..03a9d56a280 100644 --- a/src/traffic_wccp/wccp_client.cc +++ b/src/traffic_wccp/wccp_client.cc @@ -36,11 +36,11 @@ #include -#include "ts/ink_memory.h" +#include "tscore/ink_memory.h" #include "Wccp.h" -#include "WccpUtil.h" +#include "wccp/WccpUtil.h" #include "tsconfig/TsValue.h" -#include "ts/ink_lockfile.h" +#include "tscore/ink_lockfile.h" #define WCCP_LOCK "wccp.pid" diff --git a/lib/ts/Arena.cc b/src/tscore/Arena.cc similarity index 96% rename from lib/ts/Arena.cc rename to src/tscore/Arena.cc index daa52b4f61f..23469e08b4f 100644 --- a/lib/ts/Arena.cc +++ b/src/tscore/Arena.cc @@ -21,10 +21,10 @@ limitations under the License. */ -#include "ts/ink_platform.h" -#include "ts/ink_memory.h" -#include "ts/Allocator.h" -#include "ts/Arena.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_memory.h" +#include "tscore/Allocator.h" +#include "tscore/Arena.h" #include #include diff --git a/lib/ts/BaseLogFile.cc b/src/tscore/BaseLogFile.cc similarity index 99% rename from lib/ts/BaseLogFile.cc rename to src/tscore/BaseLogFile.cc index 2d130bf64be..64968153605 100644 --- a/lib/ts/BaseLogFile.cc +++ b/src/tscore/BaseLogFile.cc @@ -21,7 +21,7 @@ limitations under the License. */ -#include "BaseLogFile.h" +#include "tscore/BaseLogFile.h" /* * This consturctor creates a BaseLogFile based on a given name. diff --git a/lib/ts/Bitops.cc b/src/tscore/Bitops.cc similarity index 98% rename from lib/ts/Bitops.cc rename to src/tscore/Bitops.cc index 3d223bb0815..d73467713ff 100644 --- a/lib/ts/Bitops.cc +++ b/src/tscore/Bitops.cc @@ -21,7 +21,7 @@ limitations under the License. */ -#include "ts/Bitops.h" +#include "tscore/Bitops.h" unsigned char bit_table[256] = { 0, 1, 2, 1, 3, 1, 2, 1, 4, 1, 2, 1, 3, 1, 2, 1, 5, 1, 2, 1, 3, 1, 2, 1, 4, 1, 2, 1, 3, 1, 2, 1, 6, 1, 2, 1, 3, 1, 2, 1, 4, 1, 2, diff --git a/lib/ts/BufferWriterFormat.cc b/src/tscore/BufferWriterFormat.cc similarity index 99% rename from lib/ts/BufferWriterFormat.cc rename to src/tscore/BufferWriterFormat.cc index 836c97295aa..d5152e6f24c 100644 --- a/lib/ts/BufferWriterFormat.cc +++ b/src/tscore/BufferWriterFormat.cc @@ -21,8 +21,8 @@ limitations under the License. */ -#include -#include +#include "tscore/BufferWriter.h" +#include "tscore/bwf_std_format.h" #include #include #include diff --git a/lib/ts/CompileParseRules.cc b/src/tscore/CompileParseRules.cc similarity index 98% rename from lib/ts/CompileParseRules.cc rename to src/tscore/CompileParseRules.cc index 6c66a2182d0..2ccda9416d9 100644 --- a/lib/ts/CompileParseRules.cc +++ b/src/tscore/CompileParseRules.cc @@ -23,7 +23,7 @@ #define COMPILE_PARSE_RULES -#include "ts/ParseRules.h" +#include "tscore/ParseRules.h" const unsigned int parseRulesCType[256] = {0}; const char parseRulesCTypeToUpper[256] = {0}; @@ -35,7 +35,7 @@ char tparseRulesCTypeToLower[256]; #include #include -#include "ts/ink_string.h" +#include "tscore/ink_string.h" static char * uint_to_binary(unsigned int u) diff --git a/lib/ts/ConsistentHash.cc b/src/tscore/ConsistentHash.cc similarity index 99% rename from lib/ts/ConsistentHash.cc rename to src/tscore/ConsistentHash.cc index a13e528f6b6..3d060d8cbd1 100644 --- a/lib/ts/ConsistentHash.cc +++ b/src/tscore/ConsistentHash.cc @@ -19,7 +19,7 @@ limitations under the License. */ -#include "ConsistentHash.h" +#include "tscore/ConsistentHash.h" #include #include #include diff --git a/lib/ts/ContFlags.cc b/src/tscore/ContFlags.cc similarity index 97% rename from lib/ts/ContFlags.cc rename to src/tscore/ContFlags.cc index ba5e0bf08af..9d5c3be6ed9 100644 --- a/lib/ts/ContFlags.cc +++ b/src/tscore/ContFlags.cc @@ -21,7 +21,7 @@ limitations under the License. */ -#include "ContFlags.h" +#include "tscore/ContFlags.h" thread_local ContFlags local_flags; diff --git a/lib/ts/CryptoHash.cc b/src/tscore/CryptoHash.cc similarity index 93% rename from lib/ts/CryptoHash.cc rename to src/tscore/CryptoHash.cc index 5c315f0ca89..f10eca0d2e1 100644 --- a/lib/ts/CryptoHash.cc +++ b/src/tscore/CryptoHash.cc @@ -24,17 +24,17 @@ #include #include #include -#include "ts/ink_assert.h" -#include "ts/ink_platform.h" -#include "ts/ink_code.h" -#include "ts/CryptoHash.h" -#include "ts/SHA256.h" +#include "tscore/ink_assert.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_code.h" +#include "tscore/CryptoHash.h" +#include "tscore/SHA256.h" #if TS_ENABLE_FIPS == 1 CryptoContext::HashType CryptoContext::Setting = CryptoContext::SHA256; #else -#include "ts/INK_MD5.h" -#include "ts/MMH.h" +#include "tscore/INK_MD5.h" +#include "tscore/MMH.h" CryptoContext::HashType CryptoContext::Setting = CryptoContext::MD5; #endif diff --git a/lib/ts/Diags.cc b/src/tscore/Diags.cc similarity index 98% rename from lib/ts/Diags.cc rename to src/tscore/Diags.cc index 4c191647db2..8d2cd02a185 100644 --- a/lib/ts/Diags.cc +++ b/src/tscore/Diags.cc @@ -34,16 +34,16 @@ ****************************************************************************/ -#include "ts/ink_platform.h" -#include "ts/ink_memory.h" -#include "ts/ink_defs.h" -#include "ts/ink_error.h" -#include "ts/ink_assert.h" -#include "ts/ink_time.h" -#include "ts/ink_hrtime.h" -#include "ts/ink_thread.h" -#include "ts/BufferWriter.h" -#include "ts/Diags.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_memory.h" +#include "tscore/ink_defs.h" +#include "tscore/ink_error.h" +#include "tscore/ink_assert.h" +#include "tscore/ink_time.h" +#include "tscore/ink_hrtime.h" +#include "tscore/ink_thread.h" +#include "tscore/BufferWriter.h" +#include "tscore/Diags.h" int diags_on_for_plugins = 0; int DiagsConfigState::enabled[2] = {0, 0}; diff --git a/lib/ts/EventNotify.cc b/src/tscore/EventNotify.cc similarity index 97% rename from lib/ts/EventNotify.cc rename to src/tscore/EventNotify.cc index 96ab365f1d9..dc1e1521573 100644 --- a/lib/ts/EventNotify.cc +++ b/src/tscore/EventNotify.cc @@ -27,9 +27,9 @@ Generic event notify mechanism among threads. **************************************************************************/ -#include "ts/EventNotify.h" -#include "ts/ink_hrtime.h" -#include "ts/ink_defs.h" +#include "tscore/EventNotify.h" +#include "tscore/ink_hrtime.h" +#include "tscore/ink_defs.h" #ifdef HAVE_EVENTFD #include diff --git a/lib/ts/Hash.cc b/src/tscore/Hash.cc similarity index 98% rename from lib/ts/Hash.cc rename to src/tscore/Hash.cc index ce57bfe2b16..5a34377b133 100644 --- a/lib/ts/Hash.cc +++ b/src/tscore/Hash.cc @@ -19,7 +19,7 @@ limitations under the License. */ -#include "ts/Hash.h" +#include "tscore/Hash.h" #include ATSHashBase::~ATSHashBase() {} diff --git a/lib/ts/HashFNV.cc b/src/tscore/HashFNV.cc similarity index 96% rename from lib/ts/HashFNV.cc rename to src/tscore/HashFNV.cc index 4ddd346b634..b060ab4205a 100644 --- a/lib/ts/HashFNV.cc +++ b/src/tscore/HashFNV.cc @@ -7,7 +7,7 @@ Currently implemented FNV-1a 32bit and FNV-1a 64bit */ -#include "ts/HashFNV.h" +#include "tscore/HashFNV.h" static const uint32_t FNV_INIT_32 = 0x811c9dc5u; static const uint64_t FNV_INIT_64 = 0xcbf29ce484222325ull; diff --git a/lib/ts/HashMD5.cc b/src/tscore/HashMD5.cc similarity index 95% rename from lib/ts/HashMD5.cc rename to src/tscore/HashMD5.cc index e1fd6ecdd58..7f1dedc1b80 100644 --- a/lib/ts/HashMD5.cc +++ b/src/tscore/HashMD5.cc @@ -19,9 +19,9 @@ limitations under the License. */ -#include "ts/ink_assert.h" -#include "ts/ink_config.h" -#include "ts/HashMD5.h" +#include "tscore/ink_assert.h" +#include "tscore/ink_config.h" +#include "tscore/HashMD5.h" ATSHashMD5::ATSHashMD5() : md_len(0), finalized(false) { diff --git a/lib/ts/HashSip.cc b/src/tscore/HashSip.cc similarity index 99% rename from lib/ts/HashSip.cc rename to src/tscore/HashSip.cc index 6e64298af7b..bc0db100556 100644 --- a/lib/ts/HashSip.cc +++ b/src/tscore/HashSip.cc @@ -8,7 +8,7 @@ Based off of implementation: */ -#include "ts/HashSip.h" +#include "tscore/HashSip.h" #include using namespace std; diff --git a/lib/ts/HostLookup.cc b/src/tscore/HostLookup.cc similarity index 99% rename from lib/ts/HostLookup.cc rename to src/tscore/HostLookup.cc index 4be5c499ddc..8d9abcc2b1e 100644 --- a/lib/ts/HostLookup.cc +++ b/src/tscore/HostLookup.cc @@ -27,15 +27,15 @@ * * ****************************************************************************/ -#include "ts/ink_platform.h" -#include "ts/ink_memory.h" -#include "ts/DynArray.h" -#include "ts/ink_inet.h" -#include "ts/ink_assert.h" -#include "ts/ink_hash_table.h" -#include "ts/Tokenizer.h" -#include "ts/HostLookup.h" -#include "ts/MatcherUtils.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_memory.h" +#include "tscore/DynArray.h" +#include "tscore/ink_inet.h" +#include "tscore/ink_assert.h" +#include "tscore/ink_hash_table.h" +#include "tscore/Tokenizer.h" +#include "tscore/HostLookup.h" +#include "tscore/MatcherUtils.h" // bool domaincmp(const char* hostname, const char* domain) // diff --git a/lib/ts/InkErrno.cc b/src/tscore/InkErrno.cc similarity index 97% rename from lib/ts/InkErrno.cc rename to src/tscore/InkErrno.cc index 9e637d41a73..3126bfd40db 100644 --- a/lib/ts/InkErrno.cc +++ b/src/tscore/InkErrno.cc @@ -21,8 +21,8 @@ limitations under the License. */ -#include "InkErrno.h" -#include "ink_assert.h" +#include "tscore/InkErrno.h" +#include "tscore/ink_assert.h" #include const char * diff --git a/lib/ts/IntrusivePtrTest.cc b/src/tscore/IntrusivePtrTest.cc similarity index 95% rename from lib/ts/IntrusivePtrTest.cc rename to src/tscore/IntrusivePtrTest.cc index 0b698cbddca..7edd6acbcb1 100644 --- a/lib/ts/IntrusivePtrTest.cc +++ b/src/tscore/IntrusivePtrTest.cc @@ -21,9 +21,9 @@ limitations under the License. */ -#include -#include -#include +#include "tscore/IntrusivePtr.h" +#include "tscore/IntrusiveDList.h" +#include "tscore/TestBox.h" namespace { // Hide our local defintions diff --git a/lib/ts/IpMap.cc b/src/tscore/IpMap.cc similarity index 99% rename from lib/ts/IpMap.cc rename to src/tscore/IpMap.cc index b61c98cb5f4..44b047db256 100644 --- a/lib/ts/IpMap.cc +++ b/src/tscore/IpMap.cc @@ -1,5 +1,5 @@ -#include "ts/IpMap.h" -#include "ink_inet.h" +#include "tscore/IpMap.h" +#include "tscore/ink_inet.h" /** @file IP address map support. diff --git a/lib/ts/IpMapConf.cc b/src/tscore/IpMapConf.cc similarity index 98% rename from lib/ts/IpMapConf.cc rename to src/tscore/IpMapConf.cc index dc5e83799eb..51859d175ea 100644 --- a/lib/ts/IpMapConf.cc +++ b/src/tscore/IpMapConf.cc @@ -23,9 +23,9 @@ // Copied from IPRange.cc for backwards compatibility. -#include -#include -#include +#include "tscore/IpMap.h" +#include "tscore/IpMapConf.h" +#include "tscore/ink_memory.h" static size_t const ERR_STRING_LEN = 256; static size_t const MAX_LINE_SIZE = 2048; diff --git a/lib/ts/JeAllocator.cc b/src/tscore/JeAllocator.cc similarity index 96% rename from lib/ts/JeAllocator.cc rename to src/tscore/JeAllocator.cc index 75d9d106a0f..214ffc0223e 100644 --- a/lib/ts/JeAllocator.cc +++ b/src/tscore/JeAllocator.cc @@ -19,11 +19,11 @@ #include #include #include -#include "ts/ink_memory.h" -#include "ts/ink_error.h" -#include "ts/ink_assert.h" -#include "ts/ink_align.h" -#include "ts/JeAllocator.h" +#include "tscore/ink_memory.h" +#include "tscore/ink_error.h" +#include "tscore/ink_assert.h" +#include "tscore/ink_align.h" +#include "tscore/JeAllocator.h" namespace jearena { diff --git a/lib/ts/Layout.cc b/src/tscore/Layout.cc similarity index 96% rename from lib/ts/Layout.cc rename to src/tscore/Layout.cc index 08fba29cd5f..af650db5fb1 100644 --- a/lib/ts/Layout.cc +++ b/src/tscore/Layout.cc @@ -21,13 +21,13 @@ limitations under the License. */ -#include "ts/ink_platform.h" -#include "ts/ink_assert.h" -#include "ts/ink_file.h" -#include "ts/ink_memory.h" -#include "ts/ink_string.h" -#include "ts/I_Layout.h" -#include "ts/runroot.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_assert.h" +#include "tscore/ink_file.h" +#include "tscore/ink_memory.h" +#include "tscore/ink_string.h" +#include "tscore/I_Layout.h" +#include "tscore/runroot.h" #include diff --git a/lib/ts/MMH.cc b/src/tscore/MMH.cc similarity index 99% rename from lib/ts/MMH.cc rename to src/tscore/MMH.cc index 199b0f74322..bb442e971e7 100644 --- a/lib/ts/MMH.cc +++ b/src/tscore/MMH.cc @@ -23,9 +23,9 @@ #include #include -#include "ts/ink_assert.h" -#include "ts/ink_platform.h" -#include "ts/MMH.h" +#include "tscore/ink_assert.h" +#include "tscore/ink_platform.h" +#include "tscore/MMH.h" #define MMH_X_SIZE 512 diff --git a/lib/ts/Makefile.am b/src/tscore/Makefile.am similarity index 72% rename from lib/ts/Makefile.am rename to src/tscore/Makefile.am index 797c4e3326c..65d6dbec5c9 100644 --- a/lib/ts/Makefile.am +++ b/src/tscore/Makefile.am @@ -20,26 +20,24 @@ include $(top_srcdir)/build/tidy.mk library_includedir=$(includedir)/ts -library_include_HEADERS = apidefs.h TextView.h - noinst_PROGRAMS = mkdfa CompileParseRules -check_PROGRAMS = test_tsutil test_arena test_atomic test_freelist test_geometry test_List test_Map test_Vec test_X509HostnameValidator test_tslib +check_PROGRAMS = test_libtscore test_arena test_atomic test_freelist test_geometry test_List test_Map test_Vec test_X509HostnameValidator test_tscore TESTS_ENVIRONMENT = LSAN_OPTIONS=suppressions=suppression.txt TESTS = $(check_PROGRAMS) -lib_LTLIBRARIES = libtsutil.la +lib_LTLIBRARIES = libtscore.la AM_CPPFLAGS += \ $(iocore_include_dirs) \ - -I$(abs_top_srcdir)/lib \ - -I$(abs_top_srcdir)/lib/records \ + -I$(abs_top_srcdir)/include \ + -I$(abs_top_srcdir)/include/records \ $(TS_INCLUDES) \ @YAMLCPP_INCLUDES@ -libtsutil_la_LDFLAGS = -no-undefined -version-info @TS_LIBTOOL_VERSION@ @YAMLCPP_LDFLAGS@ -libtsutil_la_LIBADD = \ +libtscore_la_LDFLAGS = -no-undefined -version-info @TS_LIBTOOL_VERSION@ @YAMLCPP_LDFLAGS@ +libtscore_la_LIBADD = \ @HWLOC_LIBS@ \ @LIBOBJS@ \ @LIBPCRE@ \ @@ -50,7 +48,7 @@ libtsutil_la_LIBADD = \ @YAMLCPP_LIBS@ \ -lc -libtsutil_la_SOURCES = \ +libtscore_la_SOURCES = \ Allocator.h \ Arena.cc \ Arena.h \ @@ -203,7 +201,6 @@ libtsutil_la_SOURCES = \ TestBox.h \ TextBuffer.cc \ TextBuffer.h \ - TextView.h TextView.cc \ Tokenizer.cc \ Tokenizer.h \ Trie.h \ @@ -229,55 +226,54 @@ ParseRulesCType: CompileParseRules mkdfa_SOURCES = mkdfa.c test_atomic_SOURCES = test_atomic.cc -test_atomic_LDADD = libtsutil.la @LIBTCL@ @LIBPCRE@ +test_atomic_LDADD = libtscore.la $(top_builddir)/src/tscpp/util/libtscpputil.la @LIBTCL@ @LIBPCRE@ test_freelist_SOURCES = test_freelist.cc -test_freelist_LDADD = libtsutil.la @LIBTCL@ @LIBPCRE@ +test_freelist_LDADD = libtscore.la $(top_builddir)/src/tscpp/util/libtscpputil.la @LIBTCL@ @LIBPCRE@ test_arena_SOURCES = test_arena.cc -test_arena_LDADD = libtsutil.la @LIBTCL@ @LIBPCRE@ +test_arena_LDADD = libtscore.la $(top_builddir)/src/tscpp/util/libtscpputil.la @LIBTCL@ @LIBPCRE@ test_List_SOURCES = test_List.cc test_Map_SOURCES = test_Map.cc -test_Map_LDADD = libtsutil.la @LIBTCL@ @LIBPCRE@ +test_Map_LDADD = libtscore.la $(top_builddir)/src/tscpp/util/libtscpputil.la @LIBTCL@ @LIBPCRE@ test_Vec_SOURCES = test_Vec.cc -test_Vec_LDADD = libtsutil.la @LIBTCL@ @LIBPCRE@ +test_Vec_LDADD = libtscore.la $(top_builddir)/src/tscpp/util/libtscpputil.la @LIBTCL@ @LIBPCRE@ test_geometry_SOURCES = test_geometry.cc -test_geometry_LDADD = libtsutil.la @LIBTCL@ @LIBPCRE@ +test_geometry_LDADD = libtscore.la $(top_builddir)/src/tscpp/util/libtscpputil.la @LIBTCL@ @LIBPCRE@ test_X509HostnameValidator_SOURCES = test_X509HostnameValidator.cc -test_X509HostnameValidator_LDADD = libtsutil.la @LIBTCL@ @LIBPCRE@ @OPENSSL_LIBS@ +test_X509HostnameValidator_LDADD = libtscore.la $(top_builddir)/src/tscpp/util/libtscpputil.la @LIBTCL@ @LIBPCRE@ @OPENSSL_LIBS@ -test_tsutil_LDADD = libtsutil.la @LIBTCL@ @LIBPCRE@ -test_tsutil_SOURCES = \ +test_libtscore_LDADD = libtscore.la $(top_builddir)/src/tscpp/util/libtscpputil.la @LIBTCL@ @LIBPCRE@ +test_libtscore_SOURCES = \ test_History.cc \ test_PriorityQueue.cc \ test_Ptr.cc \ test_Regex.cc \ tests.cc -test_tslib_CPPFLAGS = $(AM_CPPFLAGS)\ +test_tscore_CPPFLAGS = $(AM_CPPFLAGS)\ -I$(abs_top_srcdir)/tests/include # add you catch based test file here for tslib -test_tslib_CXXFLAGS = -Wno-array-bounds $(AM_CXXFLAGS) -test_tslib_LDADD = libtsutil.la $(top_builddir)/iocore/eventsystem/libinkevent.a -test_tslib_SOURCES = \ - unit-tests/unit_test_main.cc \ - unit-tests/test_BufferWriter.cc \ - unit-tests/test_BufferWriterFormat.cc \ - unit-tests/test_ink_inet.cc \ - unit-tests/test_IntrusivePtr.cc \ - unit-tests/test_IpMap.cc \ - unit-tests/test_layout.cc \ - unit-tests/test_MemSpan.cc \ - unit-tests/test_MemArena.cc \ - unit-tests/test_MT_hashtable.cc \ - unit-tests/test_Scalar.cc \ - unit-tests/test_scoped_resource.cc \ - unit-tests/test_TextView.cc +test_tscore_CXXFLAGS = -Wno-array-bounds $(AM_CXXFLAGS) +test_tscore_LDADD = libtscore.la $(top_builddir)/src/tscpp/util/libtscpputil.la $(top_builddir)/iocore/eventsystem/libinkevent.a +test_tscore_SOURCES = \ + unit_tests/unit_test_main.cc \ + unit_tests/test_BufferWriter.cc \ + unit_tests/test_BufferWriterFormat.cc \ + unit_tests/test_ink_inet.cc \ + unit_tests/test_IntrusivePtr.cc \ + unit_tests/test_IpMap.cc \ + unit_tests/test_layout.cc \ + unit_tests/test_MemSpan.cc \ + unit_tests/test_MemArena.cc \ + unit_tests/test_MT_hashtable.cc \ + unit_tests/test_Scalar.cc \ + unit_tests/test_scoped_resource.cc CompileParseRules_SOURCES = CompileParseRules.cc diff --git a/lib/ts/MatcherUtils.cc b/src/tscore/MatcherUtils.cc similarity index 98% rename from lib/ts/MatcherUtils.cc rename to src/tscore/MatcherUtils.cc index d4c5fa76699..7e7648c0275 100644 --- a/lib/ts/MatcherUtils.cc +++ b/src/tscore/MatcherUtils.cc @@ -29,13 +29,13 @@ * ****************************************************************************/ -#include "ts/ink_platform.h" -#include "ts/Diags.h" -#include "ts/ink_memory.h" -#include "ts/ink_inet.h" -#include "ts/ink_assert.h" -#include "ts/MatcherUtils.h" -#include "ts/Tokenizer.h" +#include "tscore/ink_platform.h" +#include "tscore/Diags.h" +#include "tscore/ink_memory.h" +#include "tscore/ink_inet.h" +#include "tscore/ink_assert.h" +#include "tscore/MatcherUtils.h" +#include "tscore/Tokenizer.h" // char* readIntoBuffer(const char* file_path, const char* module_name, // int* read_size_ptr) diff --git a/lib/ts/MemArena.cc b/src/tscore/MemArena.cc similarity index 97% rename from lib/ts/MemArena.cc rename to src/tscore/MemArena.cc index 9b3db244679..4ffe4efb19f 100644 --- a/lib/ts/MemArena.cc +++ b/src/tscore/MemArena.cc @@ -24,9 +24,9 @@ #include -#include -#include -#include +#include "tscore/MemArena.h" +#include "tscore/ink_memory.h" +#include "tscore/ink_assert.h" using namespace ts; diff --git a/lib/ts/ParseRules.cc b/src/tscore/ParseRules.cc similarity index 98% rename from lib/ts/ParseRules.cc rename to src/tscore/ParseRules.cc index e87f8df9f2c..a3b0f78a568 100644 --- a/lib/ts/ParseRules.cc +++ b/src/tscore/ParseRules.cc @@ -28,8 +28,8 @@ ****************************************************************************/ -#include "ts/ink_platform.h" -#include "ts/ParseRules.h" +#include "tscore/ink_platform.h" +#include "tscore/ParseRules.h" const unsigned int parseRulesCType[256] = { #include "ParseRulesCType" diff --git a/lib/ts/RawHashTable.cc b/src/tscore/RawHashTable.cc similarity index 97% rename from lib/ts/RawHashTable.cc rename to src/tscore/RawHashTable.cc index c4ea99ec24d..7bfdaa146cf 100644 --- a/lib/ts/RawHashTable.cc +++ b/src/tscore/RawHashTable.cc @@ -28,4 +28,4 @@ */ -#include "ts/RawHashTable.h" +#include "tscore/RawHashTable.h" diff --git a/lib/ts/RbTree.cc b/src/tscore/RbTree.cc similarity index 99% rename from lib/ts/RbTree.cc rename to src/tscore/RbTree.cc index dcb3acab173..156899725a4 100644 --- a/lib/ts/RbTree.cc +++ b/src/tscore/RbTree.cc @@ -19,7 +19,7 @@ limitations under the License. */ -#include "ts/RbTree.h" +#include "tscore/RbTree.h" namespace ts { diff --git a/lib/ts/Regex.cc b/src/tscore/Regex.cc similarity index 97% rename from lib/ts/Regex.cc rename to src/tscore/Regex.cc index 402aed219de..1a6cbedff00 100644 --- a/lib/ts/Regex.cc +++ b/src/tscore/Regex.cc @@ -21,10 +21,10 @@ limitations under the License. */ -#include "ts/ink_platform.h" -#include "ts/ink_thread.h" -#include "ts/ink_memory.h" -#include "ts/Regex.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_thread.h" +#include "tscore/ink_memory.h" +#include "tscore/Regex.h" #ifdef PCRE_CONFIG_JIT struct RegexThreadKey { diff --git a/lib/ts/Regression.cc b/src/tscore/Regression.cc similarity index 98% rename from lib/ts/Regression.cc rename to src/tscore/Regression.cc index 34ba7bf5277..a167c6b910d 100644 --- a/lib/ts/Regression.cc +++ b/src/tscore/Regression.cc @@ -28,11 +28,11 @@ ****************************************************************************/ -#include "ts/Regression.h" -#include "ts/I_Version.h" -#include "ts/ink_platform.h" -#include "ts/ink_assert.h" -#include "ts/ink_args.h" +#include "tscore/Regression.h" +#include "tscore/I_Version.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_assert.h" +#include "tscore/ink_args.h" static RegressionTest *test = nullptr; static RegressionTest *exclusive_test = nullptr; diff --git a/lib/ts/SourceLocation.cc b/src/tscore/SourceLocation.cc similarity index 96% rename from lib/ts/SourceLocation.cc rename to src/tscore/SourceLocation.cc index b2ac79db7f6..4429f21f439 100644 --- a/lib/ts/SourceLocation.cc +++ b/src/tscore/SourceLocation.cc @@ -21,8 +21,8 @@ * limitations under the License. */ -#include "SourceLocation.h" -#include "ink_defs.h" +#include "tscore/SourceLocation.h" +#include "tscore/ink_defs.h" #include #include diff --git a/lib/ts/TestHttpHeader.cc b/src/tscore/TestHttpHeader.cc similarity index 99% rename from lib/ts/TestHttpHeader.cc rename to src/tscore/TestHttpHeader.cc index 37d5b4ec3c6..6e63be41faa 100644 --- a/lib/ts/TestHttpHeader.cc +++ b/src/tscore/TestHttpHeader.cc @@ -29,7 +29,7 @@ ****************************************************************************/ #include "HttpHeaderTokenizer.h" -#include "ts/ink_assert.h" +#include "tscore/ink_assert.h" #include #include #include diff --git a/lib/ts/TextBuffer.cc b/src/tscore/TextBuffer.cc similarity index 98% rename from lib/ts/TextBuffer.cc rename to src/tscore/TextBuffer.cc index c24a86b2c65..ec62ca40c46 100644 --- a/lib/ts/TextBuffer.cc +++ b/src/tscore/TextBuffer.cc @@ -22,9 +22,9 @@ */ #include -#include "ts/ink_platform.h" -#include "ts/ink_memory.h" -#include "ts/TextBuffer.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_memory.h" +#include "tscore/TextBuffer.h" /**************************************************************************** * diff --git a/lib/ts/Tokenizer.cc b/src/tscore/Tokenizer.cc similarity index 98% rename from lib/ts/Tokenizer.cc rename to src/tscore/Tokenizer.cc index 13a3330e1cf..70fdd960719 100644 --- a/lib/ts/Tokenizer.cc +++ b/src/tscore/Tokenizer.cc @@ -22,10 +22,10 @@ */ /***************************************/ -#include "ts/ink_platform.h" -#include "ts/Tokenizer.h" -#include "ts/ink_assert.h" -#include "ts/ink_memory.h" +#include "tscore/ink_platform.h" +#include "tscore/Tokenizer.h" +#include "tscore/ink_assert.h" +#include "tscore/ink_memory.h" /**************************************************************************** * @@ -376,7 +376,7 @@ Tokenizer::ReUse() } #if TS_HAS_TESTS -#include "ts/TestBox.h" +#include "tscore/TestBox.h" REGRESSION_TEST(libts_Tokenizer)(RegressionTest *test, int /* atype ATS_UNUSED */, int *pstatus) { diff --git a/lib/ts/Version.cc b/src/tscore/Version.cc similarity index 98% rename from lib/ts/Version.cc rename to src/tscore/Version.cc index 7af00bbd72e..07c72feeea2 100644 --- a/lib/ts/Version.cc +++ b/src/tscore/Version.cc @@ -21,9 +21,9 @@ limitations under the License. */ -#include "ts/ink_platform.h" -#include "ts/I_Version.h" -#include "ts/ink_string.h" +#include "tscore/ink_platform.h" +#include "tscore/I_Version.h" +#include "tscore/ink_string.h" AppVersionInfo::AppVersionInfo() { @@ -126,7 +126,7 @@ AppVersionInfo::setup(const char *pkg_name, const char *app_name, const char *ap } #if TS_HAS_TESTS -#include +#include "tscore/TestBox.h" /** * AppVersionInfo class test. diff --git a/lib/ts/X509HostnameValidator.cc b/src/tscore/X509HostnameValidator.cc similarity index 99% rename from lib/ts/X509HostnameValidator.cc rename to src/tscore/X509HostnameValidator.cc index 3e36795a424..ab3a7800f5e 100644 --- a/lib/ts/X509HostnameValidator.cc +++ b/src/tscore/X509HostnameValidator.cc @@ -27,7 +27,7 @@ #include #include -#include "ts/ink_memory.h" +#include "tscore/ink_memory.h" using equal_fn = bool (*)(const unsigned char *, size_t, const unsigned char *, size_t); diff --git a/lib/ts/fastlz.c b/src/tscore/fastlz.c similarity index 100% rename from lib/ts/fastlz.c rename to src/tscore/fastlz.c diff --git a/lib/ts/hugepages.cc b/src/tscore/hugepages.cc similarity index 98% rename from lib/ts/hugepages.cc rename to src/tscore/hugepages.cc index 8c746ae959e..3b7067a2772 100644 --- a/lib/ts/hugepages.cc +++ b/src/tscore/hugepages.cc @@ -21,8 +21,8 @@ #include #include -#include "ts/Diags.h" -#include "ts/ink_align.h" +#include "tscore/Diags.h" +#include "tscore/ink_align.h" #define DEBUG_TAG "hugepages" diff --git a/lib/ts/ink_args.cc b/src/tscore/ink_args.cc similarity index 97% rename from lib/ts/ink_args.cc rename to src/tscore/ink_args.cc index 30b7680c5cc..c4cb2d234ac 100644 --- a/lib/ts/ink_args.cc +++ b/src/tscore/ink_args.cc @@ -26,13 +26,13 @@ Process arguments ****************************************************************************/ -#include "ts/ink_platform.h" -#include "ts/ink_args.h" -#include "ts/Diags.h" -#include "ts/I_Version.h" -#include "ts/ink_file.h" -#include "ts/ink_memory.h" -#include "ts/ink_string.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_args.h" +#include "tscore/Diags.h" +#include "tscore/I_Version.h" +#include "tscore/ink_file.h" +#include "tscore/ink_memory.h" +#include "tscore/ink_string.h" // // Global variables diff --git a/lib/ts/ink_assert.cc b/src/tscore/ink_assert.cc similarity index 90% rename from lib/ts/ink_assert.cc rename to src/tscore/ink_assert.cc index 3ae290dec15..ef1a9e0b070 100644 --- a/lib/ts/ink_assert.cc +++ b/src/tscore/ink_assert.cc @@ -26,10 +26,10 @@ Assertions ***************************************************************************/ -#include "ts/ink_platform.h" -#include "ts/ink_assert.h" -#include "ts/ink_error.h" -#include "ts/ink_string.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_assert.h" +#include "tscore/ink_error.h" +#include "tscore/ink_string.h" void _ink_assert(const char *expression, const char *file, int line) diff --git a/lib/ts/ink_base64.cc b/src/tscore/ink_base64.cc similarity index 98% rename from lib/ts/ink_base64.cc rename to src/tscore/ink_base64.cc index 2aee51687d5..47f2e6a8745 100644 --- a/lib/ts/ink_base64.cc +++ b/src/tscore/ink_base64.cc @@ -31,9 +31,9 @@ * These routines return char*'s to malloc-ed strings. The caller is * responsible for freeing the strings. */ -#include "ts/ink_platform.h" -#include "ts/ink_base64.h" -#include "ts/ink_assert.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_base64.h" +#include "tscore/ink_assert.h" // TODO: The code here seems a bit klunky, and could probably be improved a bit. diff --git a/lib/ts/ink_cap.cc b/src/tscore/ink_cap.cc similarity index 99% rename from lib/ts/ink_cap.cc rename to src/tscore/ink_cap.cc index 5e713f0288e..7c53050cf1c 100644 --- a/lib/ts/ink_cap.cc +++ b/src/tscore/ink_cap.cc @@ -21,10 +21,10 @@ limitations under the License. */ -#include "ts/ink_config.h" -#include "ts/Diags.h" -#include "ts/ink_cap.h" -#include "ts/ink_thread.h" +#include "tscore/ink_config.h" +#include "tscore/Diags.h" +#include "tscore/ink_cap.h" +#include "tscore/ink_thread.h" #include diff --git a/lib/ts/ink_code.cc b/src/tscore/ink_code.cc similarity index 94% rename from lib/ts/ink_code.cc rename to src/tscore/ink_code.cc index 82ae10bec45..8dbfba9f54c 100644 --- a/lib/ts/ink_code.cc +++ b/src/tscore/ink_code.cc @@ -23,13 +23,13 @@ #include #include -#include "ts/ink_code.h" -#include "ts/ink_assert.h" -#include "ts/CryptoHash.h" +#include "tscore/ink_code.h" +#include "tscore/ink_assert.h" +#include "tscore/CryptoHash.h" ats::CryptoHash const ats::CRYPTO_HASH_ZERO; // default constructed is correct. #if TS_ENABLE_FIPS == 0 -#include "ts/INK_MD5.h" +#include "tscore/INK_MD5.h" MD5Context::MD5Context() { diff --git a/lib/ts/ink_defs.cc b/src/tscore/ink_defs.cc similarity index 98% rename from lib/ts/ink_defs.cc rename to src/tscore/ink_defs.cc index 65b02f50355..68654efd96d 100644 --- a/lib/ts/ink_defs.cc +++ b/src/tscore/ink_defs.cc @@ -28,7 +28,7 @@ ****************************************************************************/ -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #if defined(linux) || defined(freebsd) || defined(darwin) #include diff --git a/lib/ts/ink_error.cc b/src/tscore/ink_error.cc similarity index 98% rename from lib/ts/ink_error.cc rename to src/tscore/ink_error.cc index cfa18683c76..142e930a845 100644 --- a/lib/ts/ink_error.cc +++ b/src/tscore/ink_error.cc @@ -22,9 +22,9 @@ */ -#include "ts/ink_platform.h" -#include "ts/ink_error.h" -#include "ts/ink_stack_trace.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_error.h" +#include "tscore/ink_stack_trace.h" #include #include /* MAGIC_EDITING_TAG */ diff --git a/lib/ts/ink_file.cc b/src/tscore/ink_file.cc similarity index 99% rename from lib/ts/ink_file.cc rename to src/tscore/ink_file.cc index 890a167cf24..d737ad8b2d1 100644 --- a/lib/ts/ink_file.cc +++ b/src/tscore/ink_file.cc @@ -23,10 +23,10 @@ #include #include -#include "ts/ink_platform.h" -#include "ts/ink_file.h" -#include "ts/ink_string.h" -#include "ts/ink_memory.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_file.h" +#include "tscore/ink_string.h" +#include "tscore/ink_memory.h" #if HAVE_SYS_STAT_H #include diff --git a/lib/ts/ink_hash_table.cc b/src/tscore/ink_hash_table.cc similarity index 99% rename from lib/ts/ink_hash_table.cc rename to src/tscore/ink_hash_table.cc index 808c367487f..d4cf6e7eab1 100644 --- a/lib/ts/ink_hash_table.cc +++ b/src/tscore/ink_hash_table.cc @@ -30,9 +30,9 @@ ****************************************************************************/ -#include "ts/ink_error.h" -#include "ts/ink_hash_table.h" -#include "ts/ink_memory.h" +#include "tscore/ink_error.h" +#include "tscore/ink_hash_table.h" +#include "tscore/ink_memory.h" /*===========================================================================* diff --git a/lib/ts/ink_hrtime.cc b/src/tscore/ink_hrtime.cc similarity index 98% rename from lib/ts/ink_hrtime.cc rename to src/tscore/ink_hrtime.cc index 9d89b082db0..3a328c21441 100644 --- a/lib/ts/ink_hrtime.cc +++ b/src/tscore/ink_hrtime.cc @@ -28,9 +28,9 @@ This file contains code supporting the Inktomi high-resolution timer. **************************************************************************/ -#include "ts/ink_hrtime.h" -#include "ts/ink_assert.h" -#include "ts/ink_defs.h" +#include "tscore/ink_hrtime.h" +#include "tscore/ink_assert.h" +#include "tscore/ink_defs.h" #if defined(freebsd) #include diff --git a/lib/ts/ink_inet.cc b/src/tscore/ink_inet.cc similarity index 99% rename from lib/ts/ink_inet.cc rename to src/tscore/ink_inet.cc index ec4d7dc8f89..12524878b77 100644 --- a/lib/ts/ink_inet.cc +++ b/src/tscore/ink_inet.cc @@ -23,16 +23,15 @@ #include -#include "ts/ink_platform.h" -#include "ts/ink_defs.h" -#include "ts/ink_inet.h" -#include "ts/ParseRules.h" -#include "ts/CryptoHash.h" -#include "ts/ink_assert.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_defs.h" +#include "tscore/ink_inet.h" +#include "tscore/ParseRules.h" +#include "tscore/CryptoHash.h" +#include "tscore/ink_assert.h" #include "ts/apidefs.h" -#include "ts/TextView.h" -#include "ts/ink_inet.h" -#include "ink_inet.h" +#include "tscpp/util/TextView.h" +#include "tscore/ink_inet.h" IpAddr const IpAddr::INVALID; diff --git a/lib/ts/ink_memory.cc b/src/tscore/ink_memory.cc similarity index 97% rename from lib/ts/ink_memory.cc rename to src/tscore/ink_memory.cc index a45f147e6ff..5419d627828 100644 --- a/lib/ts/ink_memory.cc +++ b/src/tscore/ink_memory.cc @@ -20,12 +20,12 @@ See the License for the specific language governing permissions and limitations under the License. */ -#include "ts/ink_platform.h" -#include "ts/ink_memory.h" -#include "ts/ink_defs.h" -#include "ts/ink_stack_trace.h" -#include "ts/Diags.h" -#include "ts/ink_atomic.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_memory.h" +#include "tscore/ink_defs.h" +#include "tscore/ink_stack_trace.h" +#include "tscore/Diags.h" +#include "tscore/ink_atomic.h" #if defined(freebsd) #include // for malloc_usable_size diff --git a/lib/ts/ink_mutex.cc b/src/tscore/ink_mutex.cc similarity index 95% rename from lib/ts/ink_mutex.cc rename to src/tscore/ink_mutex.cc index f18559472c3..606359b3b9d 100644 --- a/lib/ts/ink_mutex.cc +++ b/src/tscore/ink_mutex.cc @@ -21,11 +21,11 @@ limitations under the License. */ -#include "ts/ink_error.h" -#include "ts/ink_defs.h" +#include "tscore/ink_error.h" +#include "tscore/ink_defs.h" #include #include -#include "ts/ink_mutex.h" +#include "tscore/ink_mutex.h" ink_mutex __global_death = PTHREAD_MUTEX_INITIALIZER; diff --git a/lib/ts/ink_queue.cc b/src/tscore/ink_queue.cc similarity index 98% rename from lib/ts/ink_queue.cc rename to src/tscore/ink_queue.cc index b05f75f9163..f6e8787f177 100644 --- a/lib/ts/ink_queue.cc +++ b/src/tscore/ink_queue.cc @@ -36,22 +36,22 @@ ****************************************************************************/ -#include "ts/ink_config.h" +#include "tscore/ink_config.h" #include #include #include #include #include #include -#include "ts/ink_atomic.h" -#include "ts/ink_queue.h" -#include "ts/ink_memory.h" -#include "ts/ink_error.h" -#include "ts/ink_assert.h" -#include "ts/ink_align.h" -#include "ts/hugepages.h" -#include "ts/Diags.h" -#include "ts/JeAllocator.h" +#include "tscore/ink_atomic.h" +#include "tscore/ink_queue.h" +#include "tscore/ink_memory.h" +#include "tscore/ink_error.h" +#include "tscore/ink_assert.h" +#include "tscore/ink_align.h" +#include "tscore/hugepages.h" +#include "tscore/Diags.h" +#include "tscore/JeAllocator.h" #define DEBUG_TAG "freelist" diff --git a/lib/ts/ink_queue_utils.cc b/src/tscore/ink_queue_utils.cc similarity index 97% rename from lib/ts/ink_queue_utils.cc rename to src/tscore/ink_queue_utils.cc index 2afda49dc49..4246a3b58df 100644 --- a/lib/ts/ink_queue_utils.cc +++ b/src/tscore/ink_queue_utils.cc @@ -21,11 +21,11 @@ limitations under the License. */ -#include "ts/ink_config.h" +#include "tscore/ink_config.h" #include -#include "ts/ink_atomic.h" -#include "ts/ink_queue.h" +#include "tscore/ink_atomic.h" +#include "tscore/ink_queue.h" /* * This file was added during the debugging of Bug 50475. diff --git a/lib/ts/ink_rand.cc b/src/tscore/ink_rand.cc similarity index 98% rename from lib/ts/ink_rand.cc rename to src/tscore/ink_rand.cc index 379b0b4f78f..6a23af3b1f1 100644 --- a/lib/ts/ink_rand.cc +++ b/src/tscore/ink_rand.cc @@ -54,8 +54,8 @@ email: m-mat @ math.sci.hiroshima-u.ac.jp (remove spaces) */ -#include "ts/ink_platform.h" -#include "ts/ink_rand.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_rand.h" #define NN 312 #define MM 156 diff --git a/lib/ts/ink_res_init.cc b/src/tscore/ink_res_init.cc similarity index 99% rename from lib/ts/ink_res_init.cc rename to src/tscore/ink_res_init.cc index 39a24cd1599..962fc6b6070 100644 --- a/lib/ts/ink_res_init.cc +++ b/src/tscore/ink_res_init.cc @@ -64,8 +64,8 @@ * OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. */ -#include "ts/ink_platform.h" -#include "ts/ink_defs.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_defs.h" #include #include @@ -84,10 +84,10 @@ #include #include -#include "ts/ink_string.h" -#include "ts/ink_resolver.h" -#include "ts/ink_inet.h" -#include "ts/Tokenizer.h" +#include "tscore/ink_string.h" +#include "tscore/ink_resolver.h" +#include "tscore/ink_inet.h" +#include "tscore/Tokenizer.h" #if !defined(isascii) /* XXX - could be a function */ #define isascii(c) (!(c & 0200)) diff --git a/lib/ts/ink_res_mkquery.cc b/src/tscore/ink_res_mkquery.cc similarity index 99% rename from lib/ts/ink_res_mkquery.cc rename to src/tscore/ink_res_mkquery.cc index 2741991341c..4ae16427763 100644 --- a/lib/ts/ink_res_mkquery.cc +++ b/src/tscore/ink_res_mkquery.cc @@ -64,8 +64,8 @@ * OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. */ -#include "ts/ink_config.h" -#include "ts/ink_defs.h" +#include "tscore/ink_config.h" +#include "tscore/ink_defs.h" #include #include @@ -79,8 +79,8 @@ #include #include -#include "ts/ink_error.h" -#include "ts/ink_resolver.h" +#include "tscore/ink_error.h" +#include "tscore/ink_resolver.h" #define SPRINTF(x) (sprintf x) diff --git a/lib/ts/ink_resource.cc b/src/tscore/ink_resource.cc similarity index 98% rename from lib/ts/ink_resource.cc rename to src/tscore/ink_resource.cc index d6f6cfba62a..08ba118983b 100644 --- a/lib/ts/ink_resource.cc +++ b/src/tscore/ink_resource.cc @@ -21,9 +21,9 @@ limitations under the License. */ -#include "ts/ink_assert.h" -#include "ts/ink_atomic.h" -#include "ts/ink_resource.h" +#include "tscore/ink_assert.h" +#include "tscore/ink_atomic.h" +#include "tscore/ink_resource.h" #include int res_track_memory = 0; // Disabled by default diff --git a/lib/ts/ink_rwlock.cc b/src/tscore/ink_rwlock.cc similarity index 98% rename from lib/ts/ink_rwlock.cc rename to src/tscore/ink_rwlock.cc index 1bef9595abe..1d44876f12b 100644 --- a/lib/ts/ink_rwlock.cc +++ b/src/tscore/ink_rwlock.cc @@ -21,8 +21,8 @@ limitations under the License. */ -#include "ts/ink_config.h" -#include "ts/ink_rwlock.h" +#include "tscore/ink_config.h" +#include "tscore/ink_rwlock.h" //------------------------------------------------------------------------- // ink_rwlock_init diff --git a/lib/ts/ink_sock.cc b/src/tscore/ink_sock.cc similarity index 98% rename from lib/ts/ink_sock.cc rename to src/tscore/ink_sock.cc index e3848e093a1..c9406205f9f 100644 --- a/lib/ts/ink_sock.cc +++ b/src/tscore/ink_sock.cc @@ -27,10 +27,10 @@ ***************************************************************************/ -#include "ts/ink_platform.h" -#include "ts/ink_assert.h" -#include "ts/ink_string.h" -#include "ts/ink_inet.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_assert.h" +#include "tscore/ink_string.h" +#include "tscore/ink_inet.h" // // Compilation options diff --git a/lib/ts/ink_sprintf.cc b/src/tscore/ink_sprintf.cc similarity index 99% rename from lib/ts/ink_sprintf.cc rename to src/tscore/ink_sprintf.cc index 46db8c3df2f..c468a5e3295 100644 --- a/lib/ts/ink_sprintf.cc +++ b/src/tscore/ink_sprintf.cc @@ -31,7 +31,7 @@ ****************************************************************************/ -#include "ts/ink_sprintf.h" +#include "tscore/ink_sprintf.h" #define NUL '\0' diff --git a/lib/ts/ink_stack_trace.cc b/src/tscore/ink_stack_trace.cc similarity index 95% rename from lib/ts/ink_stack_trace.cc rename to src/tscore/ink_stack_trace.cc index 7df57fc27a9..568cc0dab7b 100644 --- a/lib/ts/ink_stack_trace.cc +++ b/src/tscore/ink_stack_trace.cc @@ -21,9 +21,9 @@ limitations under the License. */ -#include "ts/ink_platform.h" -#include "ts/ink_stack_trace.h" -#include "ts/ink_args.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_stack_trace.h" +#include "tscore/ink_args.h" #include #include diff --git a/lib/ts/ink_string++.cc b/src/tscore/ink_string++.cc similarity index 97% rename from lib/ts/ink_string++.cc rename to src/tscore/ink_string++.cc index 9fba742743d..bc8db8ac0d9 100644 --- a/lib/ts/ink_string++.cc +++ b/src/tscore/ink_string++.cc @@ -30,11 +30,11 @@ ****************************************************************************/ -#include "ts/ink_platform.h" -#include "ts/ink_string++.h" -#include "ts/ink_assert.h" -#include "ts/ink_memory.h" -#include "ts/ink_align.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_string++.h" +#include "tscore/ink_assert.h" +#include "tscore/ink_memory.h" +#include "tscore/ink_align.h" /*********************************************************************** * * diff --git a/lib/ts/ink_string.cc b/src/tscore/ink_string.cc similarity index 98% rename from lib/ts/ink_string.cc rename to src/tscore/ink_string.cc index c36dda07e1a..ba3f825fdb1 100644 --- a/lib/ts/ink_string.cc +++ b/src/tscore/ink_string.cc @@ -21,8 +21,8 @@ limitations under the License. */ -#include "ts/ink_platform.h" -#include "ts/ink_assert.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_assert.h" #include #include diff --git a/lib/ts/ink_sys_control.cc b/src/tscore/ink_sys_control.cc similarity index 94% rename from lib/ts/ink_sys_control.cc rename to src/tscore/ink_sys_control.cc index b7f192c5f27..2601d6d4f09 100644 --- a/lib/ts/ink_sys_control.cc +++ b/src/tscore/ink_sys_control.cc @@ -23,10 +23,10 @@ #include -#include "ts/ink_defs.h" -#include "ts/ink_assert.h" -#include "ts/ink_sys_control.h" -#include "ts/Diags.h" +#include "tscore/ink_defs.h" +#include "tscore/ink_assert.h" +#include "tscore/ink_sys_control.h" +#include "tscore/Diags.h" rlim_t ink_max_out_rlimit(int which) diff --git a/lib/ts/ink_syslog.cc b/src/tscore/ink_syslog.cc similarity index 98% rename from lib/ts/ink_syslog.cc rename to src/tscore/ink_syslog.cc index ce6891a4705..48d56d22d3a 100644 --- a/lib/ts/ink_syslog.cc +++ b/src/tscore/ink_syslog.cc @@ -28,7 +28,7 @@ * * ****************************************************************************/ -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" struct syslog_fac { char *long_str; diff --git a/lib/ts/ink_thread.cc b/src/tscore/ink_thread.cc similarity index 96% rename from lib/ts/ink_thread.cc rename to src/tscore/ink_thread.cc index 3ed086ef1ea..32c5c51cbc4 100644 --- a/lib/ts/ink_thread.cc +++ b/src/tscore/ink_thread.cc @@ -28,9 +28,9 @@ Generic threads interface. **************************************************************************/ -#include "ts/ink_platform.h" -#include "ts/ink_thread.h" -#include "ts/ink_atomic.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_thread.h" +#include "tscore/ink_atomic.h" // // ignore the compiler warning... so that this can be used // // in the face of changes to the Solaris header files (see "man thread") diff --git a/lib/ts/ink_time.cc b/src/tscore/ink_time.cc similarity index 96% rename from lib/ts/ink_time.cc rename to src/tscore/ink_time.cc index 7507dc32cf9..c8145cd01e8 100644 --- a/lib/ts/ink_time.cc +++ b/src/tscore/ink_time.cc @@ -28,11 +28,11 @@ ****************************************************************************/ -#include "ts/ink_platform.h" -#include "ts/ink_defs.h" -#include "ts/ink_time.h" -#include "ts/ink_assert.h" -#include "ts/ink_string.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_defs.h" +#include "tscore/ink_time.h" +#include "tscore/ink_assert.h" +#include "tscore/ink_string.h" #include #include diff --git a/lib/ts/ink_uuid.cc b/src/tscore/ink_uuid.cc similarity index 97% rename from lib/ts/ink_uuid.cc rename to src/tscore/ink_uuid.cc index 88bc75c57b1..92266cdf23c 100644 --- a/lib/ts/ink_uuid.cc +++ b/src/tscore/ink_uuid.cc @@ -23,8 +23,8 @@ */ #include -#include "ts/ink_error.h" -#include "ts/ink_uuid.h" +#include "tscore/ink_error.h" +#include "tscore/ink_uuid.h" void ATSUuid::initialize(TSUuidVersion v) diff --git a/lib/ts/llqueue.cc b/src/tscore/llqueue.cc similarity index 98% rename from lib/ts/llqueue.cc rename to src/tscore/llqueue.cc index 67634555626..597366a4317 100644 --- a/lib/ts/llqueue.cc +++ b/src/tscore/llqueue.cc @@ -21,15 +21,15 @@ limitations under the License. */ -#include "ts/ink_config.h" -#include "ts/ink_memory.h" +#include "tscore/ink_config.h" +#include "tscore/ink_memory.h" #include #include #include #include -#include "ts/ink_llqueue.h" +#include "tscore/ink_llqueue.h" #include #define RECORD_CHUNK 1024 diff --git a/lib/ts/load_http_hdr.cc b/src/tscore/load_http_hdr.cc similarity index 99% rename from lib/ts/load_http_hdr.cc rename to src/tscore/load_http_hdr.cc index 780f6e46a01..b565438acf8 100644 --- a/lib/ts/load_http_hdr.cc +++ b/src/tscore/load_http_hdr.cc @@ -35,7 +35,7 @@ #include "Marshal.h" #include "MIME.h" #include "HTTP.h" -#include "ts/Tokenizer.h" +#include "tscore/Tokenizer.h" #include #include #include diff --git a/lib/ts/lockfile.cc b/src/tscore/lockfile.cc similarity index 99% rename from lib/ts/lockfile.cc rename to src/tscore/lockfile.cc index d8947be3e45..b3782682af8 100644 --- a/lib/ts/lockfile.cc +++ b/src/tscore/lockfile.cc @@ -21,8 +21,8 @@ limitations under the License. */ -#include "ts/ink_platform.h" -#include "ts/ink_lockfile.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_lockfile.h" #define LOCKFILE_BUF_LEN 16 // 16 bytes should be enought for a pid diff --git a/lib/ts/mkdfa.c b/src/tscore/mkdfa.c similarity index 100% rename from lib/ts/mkdfa.c rename to src/tscore/mkdfa.c diff --git a/lib/ts/runroot.cc b/src/tscore/runroot.cc similarity index 98% rename from lib/ts/runroot.cc rename to src/tscore/runroot.cc index bde86028a76..eb22ed65744 100644 --- a/lib/ts/runroot.cc +++ b/src/tscore/runroot.cc @@ -37,10 +37,10 @@ prefix, exec_prefix, includedir, localstatedir, bindir, logdir, sbindir, sysconf datadir, libexecdir, libdir, runtimedir, cachedir. */ -#include "ts/ink_error.h" -#include "ts/ink_file.h" -#include "ts/I_Layout.h" -#include "runroot.h" +#include "tscore/ink_error.h" +#include "tscore/ink_file.h" +#include "tscore/I_Layout.h" +#include "tscore/runroot.h" #include #include diff --git a/lib/ts/signals.cc b/src/tscore/signals.cc similarity index 96% rename from lib/ts/signals.cc rename to src/tscore/signals.cc index 3ccb11d3738..f3151724e4a 100644 --- a/lib/ts/signals.cc +++ b/src/tscore/signals.cc @@ -26,12 +26,12 @@ **************************************************************************/ -#include "ts/ink_platform.h" -#include "ts/signals.h" -#include "ts/ink_stack_trace.h" -#include "ts/ink_assert.h" -#include "ts/ink_thread.h" -#include "ts/Diags.h" +#include "tscore/ink_platform.h" +#include "tscore/signals.h" +#include "tscore/ink_stack_trace.h" +#include "tscore/ink_assert.h" +#include "tscore/ink_thread.h" +#include "tscore/Diags.h" bool signal_check_handler(int signal, signal_handler_t handler) diff --git a/lib/ts/suppression.txt b/src/tscore/suppression.txt similarity index 100% rename from lib/ts/suppression.txt rename to src/tscore/suppression.txt diff --git a/lib/ts/test_History.cc b/src/tscore/test_History.cc similarity index 98% rename from lib/ts/test_History.cc rename to src/tscore/test_History.cc index 9585680180d..d4dfd0da478 100644 --- a/lib/ts/test_History.cc +++ b/src/tscore/test_History.cc @@ -21,8 +21,8 @@ * limitations under the License. */ -#include "ts/History.h" -#include "ts/TestBox.h" +#include "tscore/History.h" +#include "tscore/TestBox.h" #define REMEMBER(e, r) \ { \ diff --git a/lib/ts/test_List.cc b/src/tscore/test_List.cc similarity index 98% rename from lib/ts/test_List.cc rename to src/tscore/test_List.cc index 80b88f7abc3..0407ed7f94d 100644 --- a/lib/ts/test_List.cc +++ b/src/tscore/test_List.cc @@ -21,7 +21,7 @@ limitations under the License. */ -#include "ts/List.h" +#include "tscore/List.h" class Foo { diff --git a/lib/ts/test_Map.cc b/src/tscore/test_Map.cc similarity index 99% rename from lib/ts/test_Map.cc rename to src/tscore/test_Map.cc index 4a03511dc7a..bc2b4ffc33d 100644 --- a/lib/ts/test_Map.cc +++ b/src/tscore/test_Map.cc @@ -21,7 +21,7 @@ limitations under the License. */ #include -#include "ts/Map.h" +#include "tscore/Map.h" #include using cchar = const char; diff --git a/lib/ts/test_PriorityQueue.cc b/src/tscore/test_PriorityQueue.cc similarity index 99% rename from lib/ts/test_PriorityQueue.cc rename to src/tscore/test_PriorityQueue.cc index bb5b51cbb01..d9e6bb0186d 100644 --- a/lib/ts/test_PriorityQueue.cc +++ b/src/tscore/test_PriorityQueue.cc @@ -25,9 +25,9 @@ #include #include -#include +#include "tscore/TestBox.h" -#include "PriorityQueue.h" +#include "tscore/PriorityQueue.h" using namespace std; diff --git a/lib/ts/test_Ptr.cc b/src/tscore/test_Ptr.cc similarity index 98% rename from lib/ts/test_Ptr.cc rename to src/tscore/test_Ptr.cc index 9acd4c8d6c8..dd6a002fdce 100644 --- a/lib/ts/test_Ptr.cc +++ b/src/tscore/test_Ptr.cc @@ -19,8 +19,8 @@ limitations under the License. */ -#include "ts/Ptr.h" -#include "ts/TestBox.h" +#include "tscore/Ptr.h" +#include "tscore/TestBox.h" struct PtrObject : RefCountObj { PtrObject(unsigned *_c) : count(_c) { ++(*count); } diff --git a/lib/ts/test_Regex.cc b/src/tscore/test_Regex.cc similarity index 93% rename from lib/ts/test_Regex.cc rename to src/tscore/test_Regex.cc index c5b279beaea..7d7b8b65f94 100644 --- a/lib/ts/test_Regex.cc +++ b/src/tscore/test_Regex.cc @@ -19,10 +19,10 @@ limitations under the License. */ -#include "ts/ink_assert.h" -#include "ts/ink_defs.h" -#include "ts/Regex.h" -#include "ts/TestBox.h" +#include "tscore/ink_assert.h" +#include "tscore/ink_defs.h" +#include "tscore/Regex.h" +#include "tscore/TestBox.h" typedef struct { char subject[100]; diff --git a/lib/ts/test_Vec.cc b/src/tscore/test_Vec.cc similarity index 99% rename from lib/ts/test_Vec.cc rename to src/tscore/test_Vec.cc index 6eab32f2f8d..53a6fa86ef0 100644 --- a/lib/ts/test_Vec.cc +++ b/src/tscore/test_Vec.cc @@ -24,8 +24,8 @@ #include #include -#include "ts/ink_assert.h" -#include "ts/Map.h" +#include "tscore/ink_assert.h" +#include "tscore/Map.h" // Intervals store sets in interval format (e.g. [1..10][12..12]). // Inclusion test is by binary search on intervals. diff --git a/lib/ts/test_X509HostnameValidator.cc b/src/tscore/test_X509HostnameValidator.cc similarity index 97% rename from lib/ts/test_X509HostnameValidator.cc rename to src/tscore/test_X509HostnameValidator.cc index 674b30e359a..1ced1b8d449 100644 --- a/lib/ts/test_X509HostnameValidator.cc +++ b/src/tscore/test_X509HostnameValidator.cc @@ -26,12 +26,12 @@ #include #include -#include "ts/ink_apidefs.h" -#include "ts/Diags.h" -#include "ts/ink_resource.h" -#include "ts/ink_queue.h" -#include "ts/X509HostnameValidator.h" -#include "ts/TestBox.h" +#include "tscore/ink_apidefs.h" +#include "tscore/Diags.h" +#include "tscore/ink_resource.h" +#include "tscore/ink_queue.h" +#include "tscore/X509HostnameValidator.h" +#include "tscore/TestBox.h" // clang-format off diff --git a/lib/ts/test_arena.cc b/src/tscore/test_arena.cc similarity index 99% rename from lib/ts/test_arena.cc rename to src/tscore/test_arena.cc index dbc0fadbbf8..17e7c6dfbbc 100644 --- a/lib/ts/test_arena.cc +++ b/src/tscore/test_arena.cc @@ -33,7 +33,7 @@ ****************************************************************************/ -#include "ts/Arena.h" +#include "tscore/Arena.h" #include void diff --git a/lib/ts/test_atomic.cc b/src/tscore/test_atomic.cc similarity index 98% rename from lib/ts/test_atomic.cc rename to src/tscore/test_atomic.cc index 8d37ace0abe..41107d5c626 100644 --- a/lib/ts/test_atomic.cc +++ b/src/tscore/test_atomic.cc @@ -27,9 +27,9 @@ #include #include -#include "ts/ink_atomic.h" -#include "ts/ink_queue.h" -#include "ts/ink_thread.h" +#include "tscore/ink_atomic.h" +#include "tscore/ink_queue.h" +#include "tscore/ink_thread.h" #ifndef LONG_ATOMICLIST_TEST diff --git a/lib/ts/test_freelist.cc b/src/tscore/test_freelist.cc similarity index 97% rename from lib/ts/test_freelist.cc rename to src/tscore/test_freelist.cc index 48d1c27bc99..159951017ea 100644 --- a/lib/ts/test_freelist.cc +++ b/src/tscore/test_freelist.cc @@ -23,8 +23,8 @@ #include #include -#include "ts/ink_thread.h" -#include "ts/ink_queue.h" +#include "tscore/ink_thread.h" +#include "tscore/ink_queue.h" #define NTHREADS 64 InkFreeList *flist = nullptr; diff --git a/lib/ts/test_geometry.cc b/src/tscore/test_geometry.cc similarity index 94% rename from lib/ts/test_geometry.cc rename to src/tscore/test_geometry.cc index 0ebf84222f4..2197ae5caa6 100644 --- a/lib/ts/test_geometry.cc +++ b/src/tscore/test_geometry.cc @@ -21,9 +21,9 @@ limitations under the License. */ -#include "ts/ink_platform.h" -#include "ts/ink_defs.h" -#include "ts/ink_file.h" +#include "tscore/ink_platform.h" +#include "tscore/ink_defs.h" +#include "tscore/ink_file.h" // This isn't really a unit test. It's just a dumb little program to probe the disk // geometry of an arbitrary device file. That's useful when figuring out how ATS will diff --git a/lib/ts/tests.cc b/src/tscore/tests.cc similarity index 96% rename from lib/ts/tests.cc rename to src/tscore/tests.cc index 095e9319430..df939e991e6 100644 --- a/lib/ts/tests.cc +++ b/src/tscore/tests.cc @@ -19,7 +19,7 @@ limitations under the License. */ -#include "ts/Regression.h" +#include "tscore/Regression.h" int main(int argc, const char **argv) diff --git a/lib/ts/unit-tests/test_BufferWriter.cc b/src/tscore/unit_tests/test_BufferWriter.cc similarity index 99% rename from lib/ts/unit-tests/test_BufferWriter.cc rename to src/tscore/unit_tests/test_BufferWriter.cc index d4139e28774..52678b9aad6 100644 --- a/lib/ts/unit-tests/test_BufferWriter.cc +++ b/src/tscore/unit_tests/test_BufferWriter.cc @@ -22,7 +22,7 @@ */ #include "catch.hpp" -#include +#include "tscore/BufferWriter.h" #include namespace diff --git a/lib/ts/unit-tests/test_BufferWriterFormat.cc b/src/tscore/unit_tests/test_BufferWriterFormat.cc similarity index 99% rename from lib/ts/unit-tests/test_BufferWriterFormat.cc rename to src/tscore/unit_tests/test_BufferWriterFormat.cc index 0f229dc4864..99a0ee334ac 100644 --- a/lib/ts/unit-tests/test_BufferWriterFormat.cc +++ b/src/tscore/unit_tests/test_BufferWriterFormat.cc @@ -24,11 +24,11 @@ #include "catch.hpp" #include #include -#include -#include -#include -#include -#include +#include "tscore/BufferWriter.h" +#include "tscore/bwf_std_format.h" +#include "tscore/MemSpan.h" +#include "tscore/INK_MD5.h" +#include "tscore/CryptoHash.h" using namespace std::literals; diff --git a/lib/ts/unit-tests/test_IntrusivePtr.cc b/src/tscore/unit_tests/test_IntrusivePtr.cc similarity index 100% rename from lib/ts/unit-tests/test_IntrusivePtr.cc rename to src/tscore/unit_tests/test_IntrusivePtr.cc diff --git a/lib/ts/unit-tests/test_IpMap.cc b/src/tscore/unit_tests/test_IpMap.cc similarity index 99% rename from lib/ts/unit-tests/test_IpMap.cc rename to src/tscore/unit_tests/test_IpMap.cc index 28fa5c0edd8..d4b153b88b4 100644 --- a/lib/ts/unit-tests/test_IpMap.cc +++ b/src/tscore/unit_tests/test_IpMap.cc @@ -21,7 +21,7 @@ limitations under the License. */ -#include +#include "tscore/IpMap.h" #include #include diff --git a/lib/ts/unit-tests/test_MT_hashtable.cc b/src/tscore/unit_tests/test_MT_hashtable.cc similarity index 98% rename from lib/ts/unit-tests/test_MT_hashtable.cc rename to src/tscore/unit_tests/test_MT_hashtable.cc index a0527aa8fd5..deb153309da 100644 --- a/lib/ts/unit-tests/test_MT_hashtable.cc +++ b/src/tscore/unit_tests/test_MT_hashtable.cc @@ -21,9 +21,9 @@ limitations under the License. */ #include -#include "ts/ink_platform.h" +#include "tscore/ink_platform.h" #include "P_EventSystem.h" -#include +#include "tscore/MT_hashtable.h" #include "I_Lock.h" #include diff --git a/lib/ts/unit-tests/test_MemArena.cc b/src/tscore/unit_tests/test_MemArena.cc similarity index 99% rename from lib/ts/unit-tests/test_MemArena.cc rename to src/tscore/unit_tests/test_MemArena.cc index 6e358b49446..0908939dbb4 100644 --- a/lib/ts/unit-tests/test_MemArena.cc +++ b/src/tscore/unit_tests/test_MemArena.cc @@ -23,7 +23,7 @@ #include -#include +#include "tscore/MemArena.h" using ts::MemSpan; using ts::MemArena; diff --git a/lib/ts/unit-tests/test_MemSpan.cc b/src/tscore/unit_tests/test_MemSpan.cc similarity index 98% rename from lib/ts/unit-tests/test_MemSpan.cc rename to src/tscore/unit_tests/test_MemSpan.cc index d5949c1be05..b7d68fe49ff 100644 --- a/lib/ts/unit-tests/test_MemSpan.cc +++ b/src/tscore/unit_tests/test_MemSpan.cc @@ -22,7 +22,7 @@ */ #include -#include +#include "tscore/MemSpan.h" #include using ts::MemSpan; diff --git a/lib/ts/unit-tests/test_Scalar.cc b/src/tscore/unit_tests/test_Scalar.cc similarity index 99% rename from lib/ts/unit-tests/test_Scalar.cc rename to src/tscore/unit_tests/test_Scalar.cc index d0629f6041e..3f8ac69ba9b 100644 --- a/lib/ts/unit-tests/test_Scalar.cc +++ b/src/tscore/unit_tests/test_Scalar.cc @@ -22,7 +22,7 @@ */ #include -#include +#include "tscore/Scalar.h" //#include //#include //#include diff --git a/lib/ts/unit-tests/test_ink_inet.cc b/src/tscore/unit_tests/test_ink_inet.cc similarity index 98% rename from lib/ts/unit-tests/test_ink_inet.cc rename to src/tscore/unit_tests/test_ink_inet.cc index b00ff7e78b2..bd5749818b8 100644 --- a/lib/ts/unit-tests/test_ink_inet.cc +++ b/src/tscore/unit_tests/test_ink_inet.cc @@ -21,14 +21,14 @@ limitations under the License. */ -#include -#include -#include +#include "tscpp/util/TextView.h" +#include "tscore/BufferWriter.h" +#include "tscore/ink_inet.h" #include #include -#include -#include -#include +#include "ts/apidefs.h" +#include "tscore/ink_inet.h" +#include "tscore/BufferWriter.h" using namespace std::literals; diff --git a/lib/ts/unit-tests/test_layout.cc b/src/tscore/unit_tests/test_layout.cc similarity index 97% rename from lib/ts/unit-tests/test_layout.cc rename to src/tscore/unit_tests/test_layout.cc index ee1d11e71d3..e478f137c3d 100644 --- a/lib/ts/unit-tests/test_layout.cc +++ b/src/tscore/unit_tests/test_layout.cc @@ -21,8 +21,8 @@ #include "catch.hpp" -#include "ts/I_Layout.h" -#include "ts/ink_platform.h" +#include "tscore/I_Layout.h" +#include "tscore/ink_platform.h" std::string append_slash(const char *path) diff --git a/lib/ts/unit-tests/test_scoped_resource.cc b/src/tscore/unit_tests/test_scoped_resource.cc similarity index 97% rename from lib/ts/unit-tests/test_scoped_resource.cc rename to src/tscore/unit_tests/test_scoped_resource.cc index 41082367114..6a3caa3c843 100644 --- a/lib/ts/unit-tests/test_scoped_resource.cc +++ b/src/tscore/unit_tests/test_scoped_resource.cc @@ -21,7 +21,7 @@ limitations under the License. */ -#include +#include "tscore/ink_memory.h" #include ats_scoped_fd diff --git a/lib/ts/unit-tests/unit_test_main.cc b/src/tscore/unit_tests/unit_test_main.cc similarity index 100% rename from lib/ts/unit-tests/unit_test_main.cc rename to src/tscore/unit_tests/unit_test_main.cc diff --git a/lib/cppapi/AsyncHttpFetch.cc b/src/tscpp/api/AsyncHttpFetch.cc similarity index 99% rename from lib/cppapi/AsyncHttpFetch.cc rename to src/tscpp/api/AsyncHttpFetch.cc index 720d0c84293..64239946912 100644 --- a/lib/cppapi/AsyncHttpFetch.cc +++ b/src/tscpp/api/AsyncHttpFetch.cc @@ -22,9 +22,9 @@ #include #include -#include "atscppapi/AsyncHttpFetch.h" -#include -#include +#include "tscpp/api/AsyncHttpFetch.h" +#include "ts/ts.h" +#include "ts/experimental.h" #include "logging_internal.h" #include "utils_internal.h" diff --git a/lib/cppapi/AsyncTimer.cc b/src/tscpp/api/AsyncTimer.cc similarity index 98% rename from lib/cppapi/AsyncTimer.cc rename to src/tscpp/api/AsyncTimer.cc index cc446991647..3450cbb6d83 100644 --- a/lib/cppapi/AsyncTimer.cc +++ b/src/tscpp/api/AsyncTimer.cc @@ -19,8 +19,8 @@ /** * @file AsyncTimer.cc */ -#include "atscppapi/AsyncTimer.h" -#include +#include "tscpp/api/AsyncTimer.h" +#include "ts/ts.h" #include "logging_internal.h" using namespace atscppapi; diff --git a/lib/cppapi/CaseInsensitiveStringComparator.cc b/src/tscpp/api/CaseInsensitiveStringComparator.cc similarity index 96% rename from lib/cppapi/CaseInsensitiveStringComparator.cc rename to src/tscpp/api/CaseInsensitiveStringComparator.cc index 3c8b804ca47..9da9d089653 100644 --- a/lib/cppapi/CaseInsensitiveStringComparator.cc +++ b/src/tscpp/api/CaseInsensitiveStringComparator.cc @@ -21,7 +21,7 @@ */ #include -#include "atscppapi/CaseInsensitiveStringComparator.h" +#include "tscpp/api/CaseInsensitiveStringComparator.h" using atscppapi::CaseInsensitiveStringComparator; using std::string; diff --git a/lib/cppapi/ClientRequest.cc b/src/tscpp/api/ClientRequest.cc similarity index 96% rename from lib/cppapi/ClientRequest.cc rename to src/tscpp/api/ClientRequest.cc index ebbe65188f0..b184fef936e 100644 --- a/lib/cppapi/ClientRequest.cc +++ b/src/tscpp/api/ClientRequest.cc @@ -20,10 +20,10 @@ * @file ClientRequest.cc */ -#include "atscppapi/ClientRequest.h" +#include "tscpp/api/ClientRequest.h" #include -#include -#include "atscppapi/noncopyable.h" +#include "ts/ts.h" +#include "tscpp/api/noncopyable.h" #include "logging_internal.h" using namespace atscppapi; diff --git a/lib/cppapi/Continuation.cc b/src/tscpp/api/Continuation.cc similarity index 96% rename from lib/cppapi/Continuation.cc rename to src/tscpp/api/Continuation.cc index 9c3fc8c4418..01c608e2107 100644 --- a/lib/cppapi/Continuation.cc +++ b/src/tscpp/api/Continuation.cc @@ -20,7 +20,7 @@ * @file Continuation.cc */ -#include +#include "tscpp/api/Continuation.h" namespace atscppapi { diff --git a/lib/cppapi/GlobalPlugin.cc b/src/tscpp/api/GlobalPlugin.cc similarity index 97% rename from lib/cppapi/GlobalPlugin.cc rename to src/tscpp/api/GlobalPlugin.cc index 151dbf11afa..b1be2302a1f 100644 --- a/lib/cppapi/GlobalPlugin.cc +++ b/src/tscpp/api/GlobalPlugin.cc @@ -19,11 +19,11 @@ /** * @file GlobalPlugin.cc */ -#include "atscppapi/GlobalPlugin.h" -#include +#include "tscpp/api/GlobalPlugin.h" +#include "ts/ts.h" #include #include -#include "atscppapi/noncopyable.h" +#include "tscpp/api/noncopyable.h" #include "utils_internal.h" #include "logging_internal.h" diff --git a/lib/cppapi/GzipDeflateTransformation.cc b/src/tscpp/api/GzipDeflateTransformation.cc similarity index 98% rename from lib/cppapi/GzipDeflateTransformation.cc rename to src/tscpp/api/GzipDeflateTransformation.cc index ee856490b8a..9832ec1f8ca 100644 --- a/lib/cppapi/GzipDeflateTransformation.cc +++ b/src/tscpp/api/GzipDeflateTransformation.cc @@ -24,8 +24,8 @@ #include #include #include -#include "atscppapi/TransformationPlugin.h" -#include "atscppapi/GzipDeflateTransformation.h" +#include "tscpp/api/TransformationPlugin.h" +#include "tscpp/api/GzipDeflateTransformation.h" #include "logging_internal.h" using namespace atscppapi::transformations; diff --git a/lib/cppapi/GzipInflateTransformation.cc b/src/tscpp/api/GzipInflateTransformation.cc similarity index 97% rename from lib/cppapi/GzipInflateTransformation.cc rename to src/tscpp/api/GzipInflateTransformation.cc index 49674f68409..04c389205e9 100644 --- a/lib/cppapi/GzipInflateTransformation.cc +++ b/src/tscpp/api/GzipInflateTransformation.cc @@ -25,8 +25,8 @@ #include #include #include -#include "atscppapi/TransformationPlugin.h" -#include "atscppapi/GzipInflateTransformation.h" +#include "tscpp/api/TransformationPlugin.h" +#include "tscpp/api/GzipInflateTransformation.h" #include "logging_internal.h" using namespace atscppapi::transformations; diff --git a/lib/cppapi/Headers.cc b/src/tscpp/api/Headers.cc similarity index 99% rename from lib/cppapi/Headers.cc rename to src/tscpp/api/Headers.cc index 94208997e01..174588391ae 100644 --- a/lib/cppapi/Headers.cc +++ b/src/tscpp/api/Headers.cc @@ -25,10 +25,10 @@ #include #include -#include -#include "atscppapi/Headers.h" +#include "ts/ts.h" +#include "tscpp/api/Headers.h" #include "logging_internal.h" -#include "atscppapi/noncopyable.h" +#include "tscpp/api/noncopyable.h" using atscppapi::Headers; using atscppapi::HeaderField; diff --git a/lib/cppapi/HttpMethod.cc b/src/tscpp/api/HttpMethod.cc similarity index 97% rename from lib/cppapi/HttpMethod.cc rename to src/tscpp/api/HttpMethod.cc index 16a13c22d5d..a1f68016463 100644 --- a/lib/cppapi/HttpMethod.cc +++ b/src/tscpp/api/HttpMethod.cc @@ -20,7 +20,7 @@ * @file HttpMethod.cc */ -#include "atscppapi/HttpMethod.h" +#include "tscpp/api/HttpMethod.h" const std::string atscppapi::HTTP_METHOD_STRINGS[] = {std::string("UNKNOWN"), std::string("GET"), std::string("POST"), std::string("HEAD"), std::string("CONNECT"), std::string("DELETE"), diff --git a/lib/cppapi/HttpVersion.cc b/src/tscpp/api/HttpVersion.cc similarity index 96% rename from lib/cppapi/HttpVersion.cc rename to src/tscpp/api/HttpVersion.cc index 583469357e0..1d652b9f642 100644 --- a/lib/cppapi/HttpVersion.cc +++ b/src/tscpp/api/HttpVersion.cc @@ -20,7 +20,7 @@ * @file HttpVersion.cc */ -#include "atscppapi/HttpVersion.h" +#include "tscpp/api/HttpVersion.h" const std::string atscppapi::HTTP_VERSION_STRINGS[] = {std::string("UNKNOWN"), std::string("HTTP/0.9"), std::string("HTTP/1.0"), std::string("HTTP/1.1")}; diff --git a/lib/cppapi/InterceptPlugin.cc b/src/tscpp/api/InterceptPlugin.cc similarity index 99% rename from lib/cppapi/InterceptPlugin.cc rename to src/tscpp/api/InterceptPlugin.cc index 71c1da80172..db72a59363d 100644 --- a/lib/cppapi/InterceptPlugin.cc +++ b/src/tscpp/api/InterceptPlugin.cc @@ -20,11 +20,11 @@ * @file InterceptPlugin.cc */ -#include "atscppapi/InterceptPlugin.h" +#include "tscpp/api/InterceptPlugin.h" -#include +#include "ts/ts.h" #include "logging_internal.h" -#include "atscppapi/noncopyable.h" +#include "tscpp/api/noncopyable.h" #include "utils_internal.h" #include diff --git a/lib/cppapi/Logger.cc b/src/tscpp/api/Logger.cc similarity index 98% rename from lib/cppapi/Logger.cc rename to src/tscpp/api/Logger.cc index 0c85eb11375..da94f313baa 100644 --- a/lib/cppapi/Logger.cc +++ b/src/tscpp/api/Logger.cc @@ -22,14 +22,14 @@ * Apply the patch in TS-1813 to correct log rolling in 3.2.x */ -#include "atscppapi/Logger.h" +#include "tscpp/api/Logger.h" #include #include #include #include #include -#include -#include "atscppapi/noncopyable.h" +#include "ts/ts.h" +#include "tscpp/api/noncopyable.h" #include "logging_internal.h" using std::vector; diff --git a/src/tscpp/api/Makefile.am b/src/tscpp/api/Makefile.am new file mode 100644 index 00000000000..67446dfcd23 --- /dev/null +++ b/src/tscpp/api/Makefile.am @@ -0,0 +1,49 @@ +# +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# 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. + +lib_LTLIBRARIES = libtscppapi.la + +libtscppapi_la_CPPFLAGS = $(AM_CPPFLAGS) -I $(abs_top_srcdir)/include + +libtscppapi_la_LDFLAGS=-lz -lpthread -version-info @TS_LIBTOOL_VERSION@ + +libtscppapi_la_SOURCES = \ + AsyncHttpFetch.cc \ + AsyncTimer.cc \ + CaseInsensitiveStringComparator.cc \ + ClientRequest.cc \ + Continuation.cc \ + GlobalPlugin.cc \ + GzipDeflateTransformation.cc \ + GzipInflateTransformation.cc \ + Headers.cc \ + HttpMethod.cc \ + HttpVersion.cc \ + InterceptPlugin.cc \ + Logger.cc \ + Plugin.cc \ + RemapPlugin.cc \ + Request.cc \ + Response.cc \ + Stat.cc \ + Transaction.cc \ + TransactionPlugin.cc \ + TransformationPlugin.cc \ + Url.cc \ + utils.cc \ + utils_internal.cc + diff --git a/lib/cppapi/Plugin.cc b/src/tscpp/api/Plugin.cc similarity index 97% rename from lib/cppapi/Plugin.cc rename to src/tscpp/api/Plugin.cc index ee4dd2006f3..d8964baa910 100644 --- a/lib/cppapi/Plugin.cc +++ b/src/tscpp/api/Plugin.cc @@ -19,8 +19,8 @@ /** * @file Plugin.cc */ -#include "atscppapi/Plugin.h" -#include +#include "tscpp/api/Plugin.h" +#include "ts/ts.h" const std::string atscppapi::HOOK_TYPE_STRINGS[] = { std::string("HOOK_READ_REQUEST_HEADERS_PRE_REMAP"), std::string("HOOK_READ_REQUEST_HEADERS_POST_REMAP"), std::string("HOOK_SEND_REQUEST_HEADERS"), std::string("HOOK_READ_RESPONSE_HEADERS"), diff --git a/lib/cppapi/RemapPlugin.cc b/src/tscpp/api/RemapPlugin.cc similarity index 97% rename from lib/cppapi/RemapPlugin.cc rename to src/tscpp/api/RemapPlugin.cc index 4c1e1f12511..7be742ca01e 100644 --- a/lib/cppapi/RemapPlugin.cc +++ b/src/tscpp/api/RemapPlugin.cc @@ -19,11 +19,11 @@ * @file RemapPlugin.cc */ -#include "atscppapi/RemapPlugin.h" +#include "tscpp/api/RemapPlugin.h" #include "logging_internal.h" #include "utils_internal.h" #include -#include +#include "ts/remap.h" using namespace atscppapi; diff --git a/lib/cppapi/Request.cc b/src/tscpp/api/Request.cc similarity index 98% rename from lib/cppapi/Request.cc rename to src/tscpp/api/Request.cc index 8131e1eb205..83bd1901d93 100644 --- a/lib/cppapi/Request.cc +++ b/src/tscpp/api/Request.cc @@ -19,9 +19,9 @@ * @file Request.cc */ -#include "atscppapi/Request.h" -#include -#include "atscppapi/noncopyable.h" +#include "tscpp/api/Request.h" +#include "ts/ts.h" +#include "tscpp/api/noncopyable.h" #include "utils_internal.h" #include "logging_internal.h" diff --git a/lib/cppapi/Response.cc b/src/tscpp/api/Response.cc similarity index 98% rename from lib/cppapi/Response.cc rename to src/tscpp/api/Response.cc index b0609c47979..bc2f0017059 100644 --- a/lib/cppapi/Response.cc +++ b/src/tscpp/api/Response.cc @@ -18,8 +18,8 @@ /** * @file Response.cc */ -#include "atscppapi/Response.h" -#include "atscppapi/noncopyable.h" +#include "tscpp/api/Response.h" +#include "tscpp/api/noncopyable.h" #include "utils_internal.h" #include "logging_internal.h" diff --git a/lib/cppapi/Stat.cc b/src/tscpp/api/Stat.cc similarity index 98% rename from lib/cppapi/Stat.cc rename to src/tscpp/api/Stat.cc index e3980306ceb..b1422fa796d 100644 --- a/lib/cppapi/Stat.cc +++ b/src/tscpp/api/Stat.cc @@ -19,10 +19,10 @@ * @file Stat.cc */ -#include "atscppapi/Stat.h" +#include "tscpp/api/Stat.h" #include #include -#include +#include "ts/ts.h" #include "logging_internal.h" using namespace atscppapi; diff --git a/lib/cppapi/Transaction.cc b/src/tscpp/api/Transaction.cc similarity index 99% rename from lib/cppapi/Transaction.cc rename to src/tscpp/api/Transaction.cc index 21573461c0b..97e00dd6878 100644 --- a/lib/cppapi/Transaction.cc +++ b/src/tscpp/api/Transaction.cc @@ -27,11 +27,11 @@ #include #include -#include "atscppapi/Transaction.h" -#include "ts/ink_memory.h" +#include "tscpp/api/Transaction.h" +#include "tscore/ink_memory.h" #include "logging_internal.h" #include "utils_internal.h" -#include "atscppapi/noncopyable.h" +#include "tscpp/api/noncopyable.h" using std::map; using std::string; diff --git a/lib/cppapi/TransactionPlugin.cc b/src/tscpp/api/TransactionPlugin.cc similarity index 96% rename from lib/cppapi/TransactionPlugin.cc rename to src/tscpp/api/TransactionPlugin.cc index 7f6f651c64a..5aba50b1fc7 100644 --- a/lib/cppapi/TransactionPlugin.cc +++ b/src/tscpp/api/TransactionPlugin.cc @@ -23,10 +23,10 @@ #include #include #include -#include -#include "atscppapi/TransactionPlugin.h" +#include "ts/ts.h" +#include "tscpp/api/TransactionPlugin.h" #include "utils_internal.h" -#include "atscppapi/noncopyable.h" +#include "tscpp/api/noncopyable.h" #include "logging_internal.h" using namespace atscppapi; diff --git a/lib/cppapi/TransformationPlugin.cc b/src/tscpp/api/TransformationPlugin.cc similarity index 99% rename from lib/cppapi/TransformationPlugin.cc rename to src/tscpp/api/TransformationPlugin.cc index 33e73db923c..5eb5aafee0c 100644 --- a/lib/cppapi/TransformationPlugin.cc +++ b/src/tscpp/api/TransformationPlugin.cc @@ -20,14 +20,14 @@ * @file TransformationPlugin.cc */ -#include "atscppapi/TransformationPlugin.h" +#include "tscpp/api/TransformationPlugin.h" -#include +#include "ts/ts.h" #include #include #include "utils_internal.h" #include "logging_internal.h" -#include "atscppapi/noncopyable.h" +#include "tscpp/api/noncopyable.h" #ifndef INT64_MAX #define INT64_MAX (9223372036854775807LL) diff --git a/lib/cppapi/Url.cc b/src/tscpp/api/Url.cc similarity index 98% rename from lib/cppapi/Url.cc rename to src/tscpp/api/Url.cc index 24a3f5c474c..a8f7144176e 100644 --- a/lib/cppapi/Url.cc +++ b/src/tscpp/api/Url.cc @@ -19,9 +19,9 @@ /** * @file Url.cc */ -#include "atscppapi/Url.h" -#include -#include "atscppapi/noncopyable.h" +#include "tscpp/api/Url.h" +#include "ts/ts.h" +#include "tscpp/api/noncopyable.h" #include "logging_internal.h" using namespace atscppapi; diff --git a/lib/cppapi/include/logging_internal.h b/src/tscpp/api/logging_internal.h similarity index 97% rename from lib/cppapi/include/logging_internal.h rename to src/tscpp/api/logging_internal.h index 021c5072b58..9c0e32e3c26 100644 --- a/lib/cppapi/include/logging_internal.h +++ b/src/tscpp/api/logging_internal.h @@ -25,7 +25,7 @@ #pragma once -#include "atscppapi/Logger.h" +#include "tscpp/api/Logger.h" // Because we have the helper in Logger.h with the same name. #ifdef LOG_DEBUG diff --git a/lib/cppapi/utils.cc b/src/tscpp/api/utils.cc similarity index 98% rename from lib/cppapi/utils.cc rename to src/tscpp/api/utils.cc index 22945968b23..7af0682b457 100644 --- a/lib/cppapi/utils.cc +++ b/src/tscpp/api/utils.cc @@ -20,10 +20,10 @@ * @file utils.cc */ -#include "atscppapi/utils.h" +#include "tscpp/api/utils.h" #include #include -#include +#include "ts/ts.h" #include "logging_internal.h" std::string diff --git a/lib/cppapi/utils_internal.cc b/src/tscpp/api/utils_internal.cc similarity index 97% rename from lib/cppapi/utils_internal.cc rename to src/tscpp/api/utils_internal.cc index aaae1e359bc..f70f2c9855a 100644 --- a/lib/cppapi/utils_internal.cc +++ b/src/tscpp/api/utils_internal.cc @@ -21,18 +21,18 @@ */ #include "utils_internal.h" #include -#include +#include "ts/ts.h" #include #include #include #include #include -#include "atscppapi/Plugin.h" -#include "atscppapi/GlobalPlugin.h" -#include "atscppapi/Transaction.h" -#include "atscppapi/TransactionPlugin.h" -#include "atscppapi/TransformationPlugin.h" -#include "atscppapi/utils.h" +#include "tscpp/api/Plugin.h" +#include "tscpp/api/GlobalPlugin.h" +#include "tscpp/api/Transaction.h" +#include "tscpp/api/TransactionPlugin.h" +#include "tscpp/api/TransformationPlugin.h" +#include "tscpp/api/utils.h" #include "logging_internal.h" using namespace atscppapi; diff --git a/lib/cppapi/include/utils_internal.h b/src/tscpp/api/utils_internal.h similarity index 88% rename from lib/cppapi/include/utils_internal.h rename to src/tscpp/api/utils_internal.h index fe22304dbfe..eacd1e4e9ed 100644 --- a/lib/cppapi/include/utils_internal.h +++ b/src/tscpp/api/utils_internal.h @@ -25,17 +25,17 @@ #pragma once -#include +#include "ts/ts.h" #include -#include "atscppapi/GlobalPlugin.h" -#include "atscppapi/TransactionPlugin.h" -#include "atscppapi/TransformationPlugin.h" -#include "atscppapi/Plugin.h" -#include "atscppapi/HttpVersion.h" -#include "atscppapi/utils.h" -#include "atscppapi/AsyncHttpFetch.h" -#include "atscppapi/Transaction.h" -#include "atscppapi/InterceptPlugin.h" +#include "tscpp/api/GlobalPlugin.h" +#include "tscpp/api/TransactionPlugin.h" +#include "tscpp/api/TransformationPlugin.h" +#include "tscpp/api/Plugin.h" +#include "tscpp/api/HttpVersion.h" +#include "tscpp/api/utils.h" +#include "tscpp/api/AsyncHttpFetch.h" +#include "tscpp/api/Transaction.h" +#include "tscpp/api/InterceptPlugin.h" namespace atscppapi { diff --git a/src/tscpp/util/Makefile.am b/src/tscpp/util/Makefile.am new file mode 100644 index 00000000000..78d7ef5821d --- /dev/null +++ b/src/tscpp/util/Makefile.am @@ -0,0 +1,46 @@ +# tscpp/util Makefile.am +# +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# 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. + +check_PROGRAMS = test_tscpputil + +TESTS = $(check_PROGRAMS) + +lib_LTLIBRARIES = libtscpputil.la + +AM_CPPFLAGS += -I$(abs_top_srcdir)/include + +libtscpputil_la_LDFLAGS = -no-undefined -version-info @TS_LIBTOOL_VERSION@ + +libtscpputil_la_SOURCES = \ + TextView.h TextView.cc + +test_tscpputil_CPPFLAGS = $(AM_CPPFLAGS)\ + -I$(abs_top_srcdir)/tests/include + +test_tscpputil_CXXFLAGS = -Wno-array-bounds $(AM_CXXFLAGS) +test_tscpputil_LDADD = libtscpputil.la +test_tscpputil_SOURCES = \ + unit_tests/unit_test_main.cc \ + unit_tests/test_TextView.cc + +clean-local: + rm -f ParseRulesCType ParseRulesCTypeToLower ParseRulesCTypeToUpper + +clang-tidy-local: $(DIST_SOURCES) + $(CXX_Clang_Tidy) + diff --git a/lib/ts/TextView.cc b/src/tscpp/util/TextView.cc similarity index 99% rename from lib/ts/TextView.cc rename to src/tscpp/util/TextView.cc index 99b1459a35b..76f41635d8b 100644 --- a/lib/ts/TextView.cc +++ b/src/tscpp/util/TextView.cc @@ -23,7 +23,7 @@ See the License for the specific language governing permissions and limitations under the License. */ -#include +#include "tscpp/util/TextView.h" #include #include diff --git a/lib/ts/unit-tests/test_TextView.cc b/src/tscpp/util/unit_tests/test_TextView.cc similarity index 99% rename from lib/ts/unit-tests/test_TextView.cc rename to src/tscpp/util/unit_tests/test_TextView.cc index 0be0c7378b0..3580b726071 100644 --- a/lib/ts/unit-tests/test_TextView.cc +++ b/src/tscpp/util/unit_tests/test_TextView.cc @@ -21,7 +21,7 @@ limitations under the License. */ -#include +#include "tscpp/util/TextView.h" #include #include #include diff --git a/src/tscpp/util/unit_tests/unit_test_main.cc b/src/tscpp/util/unit_tests/unit_test_main.cc new file mode 100644 index 00000000000..6aed3a63097 --- /dev/null +++ b/src/tscpp/util/unit_tests/unit_test_main.cc @@ -0,0 +1,25 @@ +/** @file + + This file used for catch based tests. It is the main() stub. + + @section license License + + Licensed to the Apache Software Foundation (ASF) under one + or more contributor license agreements. See the NOTICE file + distributed with this work for additional information + regarding copyright ownership. The ASF licenses this file + to you under the Apache License, Version 2.0 (the + "License"); you may not use this file except in compliance + with the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + 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. + */ + +#define CATCH_CONFIG_MAIN +#include "catch.hpp" diff --git a/lib/wccp/Makefile.am b/src/wccp/Makefile.am similarity index 81% rename from lib/wccp/Makefile.am rename to src/wccp/Makefile.am index 6aff885cb65..a0b719f9855 100644 --- a/lib/wccp/Makefile.am +++ b/src/wccp/Makefile.am @@ -20,7 +20,7 @@ include $(top_srcdir)/build/tidy.mk AM_CPPFLAGS += \ - -I$(abs_top_srcdir)/lib \ + -I$(abs_top_srcdir)/include \ -I$(abs_top_srcdir)/proxy \ $(TS_INCLUDES) @@ -40,10 +40,3 @@ libwccp_a_SOURCES = \ WccpStatic.cc \ WccpUtil.h -# test_cache_SOURCES = \ -# wccp-test-cache.cc - -# test_cache_LDADD = $(LDADD) -L$(top_builddir)/lib/tsconfig -ltsconfig -L$(top_builddir)/lib/wccp -lwccp -L$(top_builddir)/lib/ts -ltsutil - -clang-tidy-local: $(DIST_SOURCES) - $(CXX_Clang_Tidy) diff --git a/lib/wccp/WccpConfig.cc b/src/wccp/WccpConfig.cc similarity index 100% rename from lib/wccp/WccpConfig.cc rename to src/wccp/WccpConfig.cc diff --git a/lib/wccp/WccpEndPoint.cc b/src/wccp/WccpEndPoint.cc similarity index 99% rename from lib/wccp/WccpEndPoint.cc rename to src/wccp/WccpEndPoint.cc index b69c5bc975e..bbd45f36295 100644 --- a/lib/wccp/WccpEndPoint.cc +++ b/src/wccp/WccpEndPoint.cc @@ -23,8 +23,8 @@ #include "WccpUtil.h" #include "WccpMeta.h" #include -#include "ts/ink_string.h" -#include "ts/ink_defs.h" +#include "tscore/ink_string.h" +#include "tscore/ink_defs.h" // ------------------------------------------------------ namespace wccp { diff --git a/lib/wccp/WccpLocal.h b/src/wccp/WccpLocal.h similarity index 99% rename from lib/wccp/WccpLocal.h rename to src/wccp/WccpLocal.h index d4114c2c76e..89dab2ebf2d 100644 --- a/lib/wccp/WccpLocal.h +++ b/src/wccp/WccpLocal.h @@ -22,9 +22,9 @@ #pragma once -#include "Wccp.h" +#include "wccp/Wccp.h" #include "WccpUtil.h" -#include +#include "tscore/TsBuffer.h" // Needed for template use of byte ordering functions. #include #include diff --git a/lib/wccp/WccpMeta.h b/src/wccp/WccpMeta.h similarity index 100% rename from lib/wccp/WccpMeta.h rename to src/wccp/WccpMeta.h diff --git a/lib/wccp/WccpMsg.cc b/src/wccp/WccpMsg.cc similarity index 99% rename from lib/wccp/WccpMsg.cc rename to src/wccp/WccpMsg.cc index ee833abfcf7..0b64990481c 100644 --- a/lib/wccp/WccpMsg.cc +++ b/src/wccp/WccpMsg.cc @@ -23,9 +23,9 @@ #include "WccpLocal.h" #include #include -#include "api/ts/TsException.h" -#include "ts/ink_memory.h" -#include "ts/ink_string.h" +#include "ts/TsException.h" +#include "tscore/ink_memory.h" +#include "tscore/ink_string.h" namespace wccp { diff --git a/lib/wccp/WccpStatic.cc b/src/wccp/WccpStatic.cc similarity index 98% rename from lib/wccp/WccpStatic.cc rename to src/wccp/WccpStatic.cc index d689b794d23..88e3370b779 100644 --- a/lib/wccp/WccpStatic.cc +++ b/src/wccp/WccpStatic.cc @@ -22,8 +22,8 @@ #include "WccpLocal.h" #include "WccpMeta.h" -#include "ts/ink_error.h" -#include "ts/ink_defs.h" +#include "tscore/ink_error.h" +#include "tscore/ink_defs.h" /* Solaris considers SIOCGIFCONF obsolete and only defines it if * BSD compatibility activated. */ diff --git a/lib/wccp/WccpUtil.h b/src/wccp/WccpUtil.h similarity index 100% rename from lib/wccp/WccpUtil.h rename to src/wccp/WccpUtil.h diff --git a/lib/wccp/wccp-test-router.cc b/src/wccp/wccp-test-router.cc similarity index 100% rename from lib/wccp/wccp-test-router.cc rename to src/wccp/wccp-test-router.cc diff --git a/tools/Makefile.am b/tools/Makefile.am index cad68464fa7..c806d5ba793 100644 --- a/tools/Makefile.am +++ b/tools/Makefile.am @@ -24,8 +24,8 @@ pkgconfig_DATA = trafficserver.pc AM_CPPFLAGS += \ $(iocore_include_dirs) \ - -I$(abs_top_srcdir)/lib \ - -I$(abs_top_srcdir)/lib/wccp \ + -I$(abs_top_srcdir)/include \ + -I$(abs_top_srcdir)/include/wccp \ $(TS_INCLUDES) if BUILD_TEST_TOOLS @@ -35,7 +35,7 @@ noinst_PROGRAMS = jtest/jtest endif jtest_jtest_SOURCES = jtest/jtest.cc -jtest_jtest_LDADD = $(top_builddir)/lib/ts/libtsutil.la -lssl -lcrypto +jtest_jtest_LDADD = $(top_builddir)/src/tscore/libtscore.la $(top_builddir)/src/tscpp/util/libtscpputil.la -lssl -lcrypto if BUILD_HTTP_LOAD diff --git a/tools/http_load/http_load.c b/tools/http_load/http_load.c index d865a58ff1a..9268f7432c6 100644 --- a/tools/http_load/http_load.c +++ b/tools/http_load/http_load.c @@ -25,7 +25,7 @@ ** SUCH DAMAGE. */ -#include "ts/ink_config.h" +#include "tscore/ink_config.h" #include #include diff --git a/tools/jtest/jtest.cc b/tools/jtest/jtest.cc index 7e8e1dca97c..6f612aa1ff0 100644 --- a/tools/jtest/jtest.cc +++ b/tools/jtest/jtest.cc @@ -52,15 +52,16 @@ #include #include -#include "ts/ink_defs.h" -#include "ts/ink_error.h" -#include "ts/ink_memory.h" -#include "ts/ink_assert.h" -#include "ts/INK_MD5.h" -#include "ts/ParseRules.h" -#include "ts/ink_time.h" -#include "ts/ink_args.h" -#include "ts/I_Version.h" +#include "tscore/ink_defs.h" +#include "tscore/ink_error.h" +#include "tscore/ink_memory.h" +#include "tscore/ink_assert.h" +#include "tscore/INK_MD5.h" +#include "tscore/ParseRules.h" +#include "tscore/ink_time.h" +#include "tscore/ink_args.h" +#include "tscore/I_Version.h" +#include "tscpp/util/TextView.h" /* FTP - Traffic Server Template @@ -3521,7 +3522,7 @@ make_url_client(const char *url, const char *base_url, bool seen, bool unthrottl ip = proxy_addr; } else { if (xport) { - iport = atoi(port); + iport = ts::svtoi(port); } if (!xhost) { if (verbose) {