aboutsummaryrefslogtreecommitdiffstats
path: root/src/crctab.c (follow)
AgeCommit message (Collapse)AuthorFilesLines
2025-05-18build: generate src/crctab.c when building from gitCollin Funk1-437/+0
* src/crctab.c: Remove file. * src/cksum.c [!CRCTAB]: Include config.h. * src/local.mk: Generate src/crctab.c in a temporary directory. (EXTRA_DIST): Add src/crctab.c. * .gitignore (/src/crctab.c): Add entry.
2025-02-18cksum: minor crctab generation cleanupsPaul Eggert1-2/+0
* src/cksum.c [CRCTAB]: Include only config.h and stdio.h, to simplify the crctab-generating code. [!CRCTAB]: Do not include stdint.h or stdio.h, as cksum.h does it now. (BIT, r, crc_remainder, main) [CRCTAB]: Use unsigned int, not uint_fast32_t or uint32_t, as this is good enough for GNU where unsigned int is guaranteed to be at least 32 bits, and this way we needn’t worry about mismatches between %08x formats and uint_fast32_t. (main) [CRCTAB]: Prefer more-local decls. Do not output unnecessary directives to include stdint.h or stdio.h. No need for ‘return EXIT_SUCCESS;’ nowadays. * src/crctab.c: Regenerate.
2024-05-16cksum: improve API consistency checkingPaul Eggert1-1/+2
* src/cksum.c (main) [CRCTAB]: Generate updated crctab.c (see below). * src/crctab.c: Include cksum.h, to check consistency between decl and defn. Include stdio.h since cksum.h needs it.
2024-05-01maint: pacify GCC 14 -Wmissing-variable-declarationsCollin Funk1-0/+1
* src/local.mk: Include extern decl for 'Version'. * src/crctab.c (crctab): Add an extern decl. * src/cksum.c: Generate an extern decl.
2023-04-10build: fix _Noreturn compilation failurePádraig Brady1-0/+1
Fix a build failure seen on gcc 3.4 on Solaris 10 at least. * src/crctab.c: Ensure we include config.h for all compilation units. This is now required for new _Noreturn usage in gnulib for stdint.h. * src/cksum.c: Update generation code to ensure config.h included. * cfg.mk: Remove crctab.c exclusion from the config.h check.
2021-09-15digest: refactor cksum(1) into digest.cPádraig Brady1-0/+436
* cfg.mk: Adjust cksum.c to not require config.h and support a main (for crctab) without calling bindtextdomain(). * po/POTFILES.in: Remove cksum_pclmul.c since it no longer concerns itself with diagnostics. * src/cksum.c: Refactor to just providing stream digest, and digest printing functionality. * src/cksum.h: Adjust to the new interface. * src/cksum_pclmul.c: Remove diagnostics, and determine errors internally. * src/crctab.c: Separate from cksum.h since that's now included multiple times. * src/digest.c: Provide cksum(1) functionality if -DHASH_ALGO_CKSUM * src/local.mk: Adjust to new crctab.c and HASH_ALGO_CKSUM define.