From: Nathan Moinvaziri Date: Mon, 24 Aug 2020 00:20:20 +0000 (-0700) Subject: Rename table headers with tbl suffix. X-Git-Tag: 1.9.9-b1~68 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=4490d52d0a4153a904676a2cae0c105d81c389cd;p=thirdparty%2Fzlib-ng.git Rename table headers with tbl suffix. --- diff --git a/CMakeLists.txt b/CMakeLists.txt index 95edfb17..dd2bccb6 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -822,20 +822,20 @@ set(ZLIB_PUBLIC_HDRS set(ZLIB_PRIVATE_HDRS adler32_p.h chunkset_tpl.h - crc32.h crc32_p.h + crc32_tbl.h deflate.h deflate_p.h functable.h gzguts.h inffast.h - inffixed.h + inffixed_tbl.h inflate.h inflate_p.h inftrees.h insert_string_tpl.h match_tpl.h - trees.h + trees_tbl.h trees_emit.h trees_p.h zbuild.h @@ -1173,24 +1173,24 @@ if(ZLIB_ENABLE_TESTS) add_test(NAME makefixed COMMAND ${CMAKE_COMMAND} "-DCOMMAND=${MAKEFIXED_COMMAND}" - -DOUTPUT=${CMAKE_CURRENT_SOURCE_DIR}/inffixed._h - -DCOMPARE=${CMAKE_CURRENT_SOURCE_DIR}/inffixed.h + -DOUTPUT=${CMAKE_CURRENT_SOURCE_DIR}/inffixed_tbl._h + -DCOMPARE=${CMAKE_CURRENT_SOURCE_DIR}/inffixed_tbl.h -P ${CMAKE_CURRENT_SOURCE_DIR}/cmake/run-and-compare.cmake) set(MAKETREES_COMMAND ${CMAKE_CROSSCOMPILING_EMULATOR} $) add_test(NAME maketrees COMMAND ${CMAKE_COMMAND} "-DCOMMAND=${MAKETREES_COMMAND}" - -DOUTPUT=${CMAKE_CURRENT_SOURCE_DIR}/trees._h - -DCOMPARE=${CMAKE_CURRENT_SOURCE_DIR}/trees.h + -DOUTPUT=${CMAKE_CURRENT_SOURCE_DIR}/trees_tbl._h + -DCOMPARE=${CMAKE_CURRENT_SOURCE_DIR}/trees_tbl.h -P ${CMAKE_CURRENT_SOURCE_DIR}/cmake/run-and-compare.cmake) set(MAKECRCT_COMMAND ${CMAKE_CROSSCOMPILING_EMULATOR} $) add_test(NAME makecrct COMMAND ${CMAKE_COMMAND} "-DCOMMAND=${MAKECRCT_COMMAND}" - -DOUTPUT=${CMAKE_CURRENT_SOURCE_DIR}/crc32._h - -DCOMPARE=${CMAKE_CURRENT_SOURCE_DIR}/crc32.h + -DOUTPUT=${CMAKE_CURRENT_SOURCE_DIR}/crc32_tbl._h + -DCOMPARE=${CMAKE_CURRENT_SOURCE_DIR}/crc32_tbl.h -P ${CMAKE_CURRENT_SOURCE_DIR}/cmake/run-and-compare.cmake) set(INFCOVER_COMMAND ${CMAKE_CROSSCOMPILING_EMULATOR} $) diff --git a/INDEX.md b/INDEX.md index e5dc0eb1..10f74db9 100644 --- a/INDEX.md +++ b/INDEX.md @@ -27,7 +27,7 @@ Contents | infback.* | Inflate using a callback interface | | inflate.* | Decompress data | | inffast.* | Decompress data with speed optimizations | -| inffixed.h | Table for decoding fixed codes | +| inffixed_tbl.h | Table for decoding fixed codes | | inftrees.h | Generate Huffman trees for efficient decoding | | trees.* | Output deflated data using Huffman coding | | uncompr.c | Decompress a memory buffer | diff --git a/crc32.c b/crc32.c index ebc2be19..d4682730 100644 --- a/crc32.c +++ b/crc32.c @@ -15,7 +15,7 @@ #include "deflate.h" #include "functable.h" #include "crc32_p.h" -#include "crc32.h" +#include "crc32_tbl.h" /* Local functions for crc concatenation */ diff --git a/crc32.h b/crc32_tbl.h similarity index 99% rename from crc32.h rename to crc32_tbl.h index 6bb2e51c..592f539a 100644 --- a/crc32.h +++ b/crc32_tbl.h @@ -1,7 +1,7 @@ -#ifndef CRC32_H_ -#define CRC32_H_ +#ifndef CRC32_TBL_H_ +#define CRC32_TBL_H_ -/* crc32.h -- tables for rapid CRC calculation +/* crc32_tbl.h -- tables for rapid CRC calculation * Generated automatically by makecrct.c */ @@ -732,4 +732,4 @@ static const uint32_t crc_comb[32][32] = 0x04000000, 0x08000000 } }; -#endif /* CRC32_H_ */ +#endif /* CRC32_TBL_H_ */ diff --git a/inffixed.h b/inffixed_tbl.h similarity index 99% rename from inffixed.h rename to inffixed_tbl.h index d6283277..e71b2cf6 100644 --- a/inffixed.h +++ b/inffixed_tbl.h @@ -1,4 +1,4 @@ - /* inffixed.h -- table for decoding fixed codes + /* inffixed_tbl.h -- table for decoding fixed codes * Generated automatically by makefixed(). */ diff --git a/inflate.c b/inflate.c index 4f99c0e2..7211bf8d 100644 --- a/inflate.c +++ b/inflate.c @@ -9,7 +9,7 @@ #include "inflate.h" #include "inffast.h" #include "inflate_p.h" -#include "inffixed.h" +#include "inffixed_tbl.h" #include "functable.h" /* Architecture-specific hooks. */ @@ -190,7 +190,7 @@ int32_t ZEXPORT PREFIX(inflatePrime)(PREFIX3(stream) *strm, int32_t bits, int32_ /* Return state with length and distance decoding tables and index sizes set to - fixed code decoding. This returns fixed tables from inffixed.h. + fixed code decoding. This returns fixed tables from inffixed_tbl.h. */ void ZLIB_INTERNAL fixedtables(struct inflate_state *state) { diff --git a/tools/makecrct.c b/tools/makecrct.c index 62a5a31f..77116f78 100644 --- a/tools/makecrct.c +++ b/tools/makecrct.c @@ -112,9 +112,9 @@ static void make_crc_table() { static void print_crc32_tables() { int k; - printf("#ifndef CRC32_H_\n"); - printf("#define CRC32_H_\n\n"); - printf("/* crc32.h -- tables for rapid CRC calculation\n"); + printf("#ifndef CRC32_TBL_H_\n"); + printf("#define CRC32_TBL_H_\n\n"); + printf("/* crc32_tbl.h -- tables for rapid CRC calculation\n"); printf(" * Generated automatically by makecrct.c\n */\n\n"); /* print CRC table */ @@ -136,7 +136,7 @@ static void print_crc32_tables() { write_table(crc_comb[k], GF2_DIM); } printf(" }\n};\n"); - printf("#endif /* CRC32_H_ */\n"); + printf("#endif /* CRC32_TBL_H_ */\n"); } static void write_table(const uint32_t *table, int k) { diff --git a/tools/makefixed.c b/tools/makefixed.c index 66f4355d..4cc89a45 100644 --- a/tools/makefixed.c +++ b/tools/makefixed.c @@ -38,15 +38,15 @@ void ZLIB_INTERNAL buildfixedtables(struct inflate_state *state) { } -// Create fixed tables on the fly and write out a inffixed.h file that is #include'd above. -// makefixed() writes those tables to stdout, which would be piped to inffixed.h. +// Create fixed tables on the fly and write out a inffixed_tbl.h file that is #include'd above. +// makefixed() writes those tables to stdout, which would be piped to inffixed_tbl.h. void makefixed(void) { unsigned low, size; struct inflate_state state; memset(&state, 0, sizeof(state)); buildfixedtables(&state); - puts(" /* inffixed.h -- table for decoding fixed codes"); + puts(" /* inffixed_tbl.h -- table for decoding fixed codes"); puts(" * Generated automatically by makefixed()."); puts(" */"); puts(""); @@ -82,9 +82,8 @@ void makefixed(void) { puts("\n };"); } -// The output of this application can be piped out to recreate inffixed.h +// The output of this application can be piped out to recreate inffixed_tbl.h int main(void) { makefixed(); return 0; } - diff --git a/tools/maketrees.c b/tools/maketrees.c index 150e0266..c60cc130 100644 --- a/tools/maketrees.c +++ b/tools/maketrees.c @@ -101,8 +101,8 @@ static void tr_static_init(void) { static void gen_trees_header() { int i; - printf("#ifndef TREES_H_\n"); - printf("#define TREES_H_\n\n"); + printf("#ifndef TREES_TBL_H_\n"); + printf("#define TREES_TBL_H_\n\n"); printf("/* header created automatically with maketrees.c */\n\n"); @@ -136,7 +136,7 @@ static void gen_trees_header() { printf("%5d%s", base_dist[i], SEPARATOR(i, D_CODES-1, 10)); } - printf("#endif /* TREES_H_ */\n"); + printf("#endif /* TREES_TBL_H_ */\n"); } // The output of this application can be piped out to recreate trees.h diff --git a/trees.c b/trees.c index cdf853ea..f02853a0 100644 --- a/trees.c +++ b/trees.c @@ -34,7 +34,7 @@ #include "deflate.h" #include "trees_p.h" #include "trees_emit.h" -#include "trees.h" +#include "trees_tbl.h" /* The lengths of the bit length codes are sent in order of decreasing * probability, to avoid transmitting the lengths for unused bit length codes. diff --git a/trees.h b/trees_tbl.h similarity index 99% rename from trees.h rename to trees_tbl.h index 9704c9b0..7c968361 100644 --- a/trees.h +++ b/trees_tbl.h @@ -1,5 +1,5 @@ -#ifndef TREES_H_ -#define TREES_H_ +#ifndef TREES_TBL_H_ +#define TREES_TBL_H_ /* header created automatically with maketrees.c */ @@ -129,4 +129,4 @@ ZLIB_INTERNAL const int base_dist[D_CODES] = { 1024, 1536, 2048, 3072, 4096, 6144, 8192, 12288, 16384, 24576 }; -#endif /* TREES_H_ */ +#endif /* TREES_TBL_H_ */ diff --git a/win32/Makefile.a64 b/win32/Makefile.a64 index 11f0dd9f..fd34b409 100644 --- a/win32/Makefile.a64 +++ b/win32/Makefile.a64 @@ -157,7 +157,7 @@ gzread.obj: $(SRCDIR)/gzread.c $(SRCDIR)/zbuild.h $(SRCDIR)/gzguts.h gzwrite.obj: $(SRCDIR)/gzwrite.c $(SRCDIR)/zbuild.h $(SRCDIR)/gzguts.h compress.obj: $(SRCDIR)/compress.c $(SRCDIR)/zbuild.h $(SRCDIR)/zlib$(SUFFIX).h uncompr.obj: $(SRCDIR)/uncompr.c $(SRCDIR)/zbuild.h $(SRCDIR)/zlib$(SUFFIX).h -crc32.obj: $(SRCDIR)/crc32.c $(SRCDIR)/zbuild.h $(SRCDIR)/zendian.h $(SRCDIR)/deflate.h $(SRCDIR)/functable.h $(SRCDIR)/crc32.h +crc32.obj: $(SRCDIR)/crc32.c $(SRCDIR)/zbuild.h $(SRCDIR)/zendian.h $(SRCDIR)/deflate.h $(SRCDIR)/functable.h $(SRCDIR)/crc32_tbl.h deflate.obj: $(SRCDIR)/deflate.c $(SRCDIR)/zbuild.h $(SRCDIR)/deflate.h $(SRCDIR)/deflate_p.h $(SRCDIR)/functable.h deflate_quick.obj: $(SRCDIR)/deflate_quick.c $(SRCDIR)/zbuild.h $(SRCDIR)/deflate.h $(SRCDIR)/deflate_p.h $(SRCDIR)/functable.h $(SRCDIR)/trees_emit.h deflate_fast.obj: $(SRCDIR)/deflate_fast.c $(SRCDIR)/zbuild.h $(SRCDIR)/deflate.h $(SRCDIR)/deflate_p.h $(SRCDIR)/functable.h @@ -167,7 +167,7 @@ infback.obj: $(SRCDIR)/infback.c $(SRCDIR)/zbuild.h $(SRCDIR)/zutil.h $(SRCDIR)/ inffast.obj: $(SRCDIR)/inffast.c $(SRCDIR)/zbuild.h $(SRCDIR)/zutil.h $(SRCDIR)/inftrees.h $(SRCDIR)/inflate.h $(SRCDIR)/inffast.h $(SRCDIR)/functable.h inflate.obj: $(SRCDIR)/inflate.c $(SRCDIR)/zbuild.h $(SRCDIR)/zutil.h $(SRCDIR)/inftrees.h $(SRCDIR)/inflate.h $(SRCDIR)/inffast.h $(SRCDIR)/functable.h $(SRCDIR)/functable.h inftrees.obj: $(SRCDIR)/inftrees.c $(SRCDIR)/zbuild.h $(SRCDIR)/zutil.h $(SRCDIR)/inftrees.h -trees.obj: $(SRCDIR)/zbuild.h $(SRCDIR)/deflate.h $(SRCDIR)/trees.h +trees.obj: $(SRCDIR)/zbuild.h $(SRCDIR)/deflate.h $(SRCDIR)/trees_tbl.h zutil.obj: $(SRCDIR)/zbuild.h $(SRCDIR)/zutil.h $(SRCDIR)/gzguts.h example.obj: $(TOP)/test/example.c $(TOP)/zbuild.h $(TOP)/zlib$(SUFFIX).h diff --git a/win32/Makefile.arm b/win32/Makefile.arm index aa00330a..910fdcde 100644 --- a/win32/Makefile.arm +++ b/win32/Makefile.arm @@ -169,7 +169,7 @@ gzwrite.obj: $(SRCDIR)/gzwrite.c $(SRCDIR)/zbuild.h $(SRCDIR)/gzguts.h compress.obj: $(SRCDIR)/compress.c $(SRCDIR)/zbuild.h $(SRCDIR)/zlib$(SUFFIX).h uncompr.obj: $(SRCDIR)/uncompr.c $(SRCDIR)/zbuild.h $(SRCDIR)/zlib$(SUFFIX).h chunkset.obj: $(SRCDIR)/zbuild.h $(SRCDIR)/zutil.h -crc32.obj: $(SRCDIR)/crc32.c $(SRCDIR)/zbuild.h $(SRCDIR)/zendian.h $(SRCDIR)/deflate.h $(SRCDIR)/functable.h $(SRCDIR)/crc32.h +crc32.obj: $(SRCDIR)/crc32.c $(SRCDIR)/zbuild.h $(SRCDIR)/zendian.h $(SRCDIR)/deflate.h $(SRCDIR)/functable.h $(SRCDIR)/crc32_tbl.h deflate.obj: $(SRCDIR)/deflate.c $(SRCDIR)/zbuild.h $(SRCDIR)/deflate.h $(SRCDIR)/deflate_p.h $(SRCDIR)/functable.h deflate_fast.obj: $(SRCDIR)/deflate_fast.c $(SRCDIR)/zbuild.h $(SRCDIR)/deflate.h $(SRCDIR)/deflate_p.h $(SRCDIR)/functable.h deflate_medium.obj: $(SRCDIR)/deflate_medium.c $(SRCDIR)/zbuild.h $(SRCDIR)/deflate.h $(SRCDIR)/deflate_p.h $(SRCDIR)/functable.h @@ -179,7 +179,7 @@ infback.obj: $(SRCDIR)/infback.c $(SRCDIR)/zbuild.h $(SRCDIR)/zutil.h $(SRCDIR)/ inffast.obj: $(SRCDIR)/inffast.c $(SRCDIR)/zbuild.h $(SRCDIR)/zutil.h $(SRCDIR)/inftrees.h $(SRCDIR)/inflate.h $(SRCDIR)/inffast.h $(SRCDIR)/functable.h inflate.obj: $(SRCDIR)/inflate.c $(SRCDIR)/zbuild.h $(SRCDIR)/zutil.h $(SRCDIR)/inftrees.h $(SRCDIR)/inflate.h $(SRCDIR)/inffast.h $(SRCDIR)/functable.h $(SRCDIR)/functable.h inftrees.obj: $(SRCDIR)/inftrees.c $(SRCDIR)/zbuild.h $(SRCDIR)/zutil.h $(SRCDIR)/inftrees.h -trees.obj: $(SRCDIR)/zbuild.h $(SRCDIR)/deflate.h $(SRCDIR)/trees.h +trees.obj: $(SRCDIR)/zbuild.h $(SRCDIR)/deflate.h $(SRCDIR)/trees_tbl.h zutil.obj: $(SRCDIR)/zbuild.h $(SRCDIR)/zutil.h $(SRCDIR)/gzguts.h example.obj: $(TOP)/test/example.c $(TOP)/zbuild.h $(TOP)/zlib$(SUFFIX).h diff --git a/win32/Makefile.msc b/win32/Makefile.msc index b3670885..9bde1aa6 100644 --- a/win32/Makefile.msc +++ b/win32/Makefile.msc @@ -167,7 +167,7 @@ compress.obj: $(SRCDIR)/compress.c $(SRCDIR)/zbuild.h $(SRCDIR)/zlib$(SUFFIX).h uncompr.obj: $(SRCDIR)/uncompr.c $(SRCDIR)/zbuild.h $(SRCDIR)/zlib$(SUFFIX).h chunkset.obj: $(SRCDIR)/zbuild.h $(SRCDIR)/zutil.h chunkset_sse.obj: $(SRCDIR)/arch/x86/chunkset_sse.c $(SRCDIR)/zbuild.h $(SRCDIR)/zutil.h -crc32.obj: $(SRCDIR)/crc32.c $(SRCDIR)/zbuild.h $(SRCDIR)/zendian.h $(SRCDIR)/deflate.h $(SRCDIR)/functable.h $(SRCDIR)/crc32.h +crc32.obj: $(SRCDIR)/crc32.c $(SRCDIR)/zbuild.h $(SRCDIR)/zendian.h $(SRCDIR)/deflate.h $(SRCDIR)/functable.h $(SRCDIR)/crc32_tbl.h deflate.obj: $(SRCDIR)/deflate.c $(SRCDIR)/zbuild.h $(SRCDIR)/deflate.h $(SRCDIR)/deflate_p.h $(SRCDIR)/functable.h deflate_fast.obj: $(SRCDIR)/deflate_fast.c $(SRCDIR)/zbuild.h $(SRCDIR)/deflate.h $(SRCDIR)/deflate_p.h $(SRCDIR)/functable.h deflate_medium.obj: $(SRCDIR)/deflate_medium.c $(SRCDIR)/zbuild.h $(SRCDIR)/deflate.h $(SRCDIR)/deflate_p.h $(SRCDIR)/functable.h @@ -178,7 +178,7 @@ inffast.obj: $(SRCDIR)/inffast.c $(SRCDIR)/zbuild.h $(SRCDIR)/zutil.h $(SRCDIR)/ inflate.obj: $(SRCDIR)/inflate.c $(SRCDIR)/zbuild.h $(SRCDIR)/zutil.h $(SRCDIR)/inftrees.h $(SRCDIR)/inflate.h $(SRCDIR)/inffast.h $(SRCDIR)/functable.h $(SRCDIR)/functable.h inftrees.obj: $(SRCDIR)/inftrees.c $(SRCDIR)/zbuild.h $(SRCDIR)/zutil.h $(SRCDIR)/inftrees.h slide_sse.obj: $(SRCDIR)/arch/x86/slide_sse.c $(SRCDIR)/deflate.h -trees.obj: $(SRCDIR)/zbuild.h $(SRCDIR)/deflate.h $(SRCDIR)/trees.h +trees.obj: $(SRCDIR)/zbuild.h $(SRCDIR)/deflate.h $(SRCDIR)/trees_tbl.h zutil.obj: $(SRCDIR)/zbuild.h $(SRCDIR)/zutil.h $(SRCDIR)/gzguts.h example.obj: $(TOP)/test/example.c $(TOP)/zbuild.h $(TOP)/zlib$(SUFFIX).h