From: Amos Jeffries Date: Tue, 25 Aug 2015 14:10:22 +0000 (-0700) Subject: Maintenance: remove unused mk-string-arrays.pl script X-Git-Tag: SQUID_4_0_1~102 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=20b70b51876a0e364bdc2672f6ccd4f2b4f47324;p=thirdparty%2Fsquid.git Maintenance: remove unused mk-string-arrays.pl script --- diff --git a/CREDITS b/CREDITS index 02d7149cf9..aa6c1818f4 100644 --- a/CREDITS +++ b/CREDITS @@ -1829,12 +1829,6 @@ src/external_acl.c: ============================================================================== -src/mk-string-arrays.pl: - -# Author: Max Okumoto - -============================================================================== - src/repl/heap/store_heap_replacement.cc: * AUTHOR: John Dilley diff --git a/src/Makefile.am b/src/Makefile.am index 97b26321a1..8e124e6de8 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -521,7 +521,6 @@ EXTRA_squid_SOURCES = \ noinst_HEADERS = \ client_side_request.cci \ MemBuf.h \ - StoreEntryStream.h \ String.cci \ SquidString.h \ SquidTime.h @@ -735,7 +734,6 @@ EXTRA_DIST = \ cf.data.depend \ mk-globals-c.pl \ mk-globals-c.awk \ - mk-string-arrays.pl \ mk-string-arrays.awk \ repl_modules.sh \ $(STUB_SOURCE) \ @@ -2871,10 +2869,10 @@ tests_testStore_SOURCES= \ Transients.cc \ tests/stub_tools.cc \ tests/stub_UdsOp.cc \ + tests/testPackableStream.cc \ + tests/testPackableStream.h \ tests/testStore.cc \ tests/testStore.h \ - tests/testStoreEntryStream.cc \ - tests/testStoreEntryStream.h \ tests/testStoreController.cc \ tests/testStoreController.h \ tests/testStoreHashIndex.cc \ diff --git a/src/mk-string-arrays.awk b/src/mk-string-arrays.awk index 197eb9bb3f..a1f331ae0c 100644 --- a/src/mk-string-arrays.awk +++ b/src/mk-string-arrays.awk @@ -6,10 +6,8 @@ ## # tested with gawk, mawk, and nawk. -# drop-in replacement for mk-string-arrays.pl. # creates "enum.c" (on stdout) from "enum.h". -# invoke similarly: perl -f mk-string-arrays.pl enum.h -# --> awk -f mk-string-arrays.awk enum.h +# when invoked: awk -f mk-string-arrays.awk enum.h # # 2006 by Christopher Kerr. # diff --git a/src/mk-string-arrays.pl b/src/mk-string-arrays.pl deleted file mode 100755 index f7cd68eabb..0000000000 --- a/src/mk-string-arrays.pl +++ /dev/null @@ -1,62 +0,0 @@ -# -## Copyright (C) 1996-2015 The Squid Software Foundation and contributors -## -## Squid software is distributed under GPLv2+ license and includes -## contributions from numerous individuals and organizations. -## Please see the COPYING and CONTRIBUTORS files for details. -## - -#****************************************************************************** -# File: mk-strs.pl -# -# Author: Max Okumoto -# -# Abstract: This perl script parses enums and builds an array of -# printable strings. -# -# Warning: The parser is very simplistic, and will prob not work for -# things other than squid. -#****************************************************************************** - -$pat{'err_type'} = "err_type_str"; -$pat{'icp_opcode'} = "icp_opcode_str"; -$pat{'swap_log_op'} = "swap_log_op_str"; -$pat{'lookup_t'} = "lookup_t_str"; - -$state = 0; # start state -while (<>) { - if ($state == 0) { - # Looking for start of typedef - if (/^typedef enum /) { - $count = 0; # enum index - $state = 1; - } - next; - - } elsif ($state == 1) { - # Looking for end of typedef - if (/^} /) { - ($b, $t) = split(/[ \t;]/, $_); - if (defined($pat{$t})) { - print "const char *$pat{$t}\[\] = \n"; - print "{\n"; - for ($i = 0; $i < $count; $i++) { - printf "\t\"%s\"%s\n", - $ea[$i], - $i == $count - 1 ? '' : ','; - } - print "};\n"; - print "\n"; - } - $state = 0; - } else { - ($e) = split(' ', $_); - $e =~ s/,//; - $ea[$count] = $e; - $count++; - } - next; - } -} - -exit 0;