From 2e87aaf19e4f348097c91da9612e7b46d1d7a572 Mon Sep 17 00:00:00 2001 From: Colin Watson Date: Sun, 1 Sep 2019 00:18:16 +0100 Subject: Remove ability to undefine COMP_SRC This was a minor optimisation that wasn't worth the extra code complexity. * configure.ac (COMP_SRC): Remove. * include/comp_src.h.in: Remove COMP_SRC conditional. comp_list will simply contain only the terminal entry if no compressors are configured. * include/manconfig.h.in: Remove COMP_SRC conditional and comment. * manual/comp.me (Compressed manual pages): Remove documentation of COMP_SRC; explain that support depends on the decompressors available at configure time. * src/compression.c: Remove COMP_SRC conditional. (comp_info): Only do the HP-UX check if gunzip is available. * src/filenames.c (make_filename): Remove parenthetical comment about COMP_SRC. (filename_info): Remove COMP_SRC conditionals. * src/man.c (convert_name): Likewise. * src/straycats.c (check_for_stray): Likewise. * src/ult_src.c (ult_src): Likewise. * NEWS: Document this. --- include/comp_src.h.in | 4 ---- include/manconfig.h.in | 18 ++++++------------ 2 files changed, 6 insertions(+), 16 deletions(-) (limited to 'include') diff --git a/include/comp_src.h.in b/include/comp_src.h.in index 4d6b0e75..d3ef8901 100644 --- a/include/comp_src.h.in +++ b/include/comp_src.h.in @@ -42,8 +42,6 @@ #ifndef MAN_COMP_SRC_H #define MAN_COMP_SRC_H -#ifdef COMP_SRC - struct compression comp_list[] = { /* If we have gzip, incorporate the following */ @@ -93,6 +91,4 @@ struct compression comp_list[] = { {NULL, NULL, NULL} }; -#endif /* COMP_SRC */ - #endif /* MAN_COMP_SRC_H */ diff --git a/include/manconfig.h.in b/include/manconfig.h.in index 6166d9cb..859970f3 100644 --- a/include/manconfig.h.in +++ b/include/manconfig.h.in @@ -215,18 +215,16 @@ # define COMPRESS_EXT "@compress_ext@" #endif /* COMP_CAT */ -#ifdef COMP_SRC /* These are the currently supported decompressors. They are used for decompressing cat pages and source nroff. To add further decompressors, you will need to edit comp_src.h[.in] . Help is provided in the file */ -# define GUNZIP "@gunzip@" -# define UNCOMPRESS "@uncompress@" -# define BUNZIP2 "@bunzip2@" -# define UNLZMA "@unlzma@" -# define UNXZ "@unxz@" -# define UNLZIP "@unlzip@" -#endif /* COMP_SRC */ +#define GUNZIP "@gunzip@" +#define UNCOMPRESS "@uncompress@" +#define BUNZIP2 "@bunzip2@" +#define UNLZMA "@unlzma@" +#define UNXZ "@unxz@" +#define UNLZIP "@unlzip@" /*-----------------------------------------------------------------------*/ /* The things below here shouldn't really be changed unless you really */ @@ -287,10 +285,6 @@ extern int _nl_msg_cat_cntr; # define locale_changed() #endif /* ENABLE_NLS */ -/* This structure definition is only really needed if COMP_SRC==1, but it is - used in external declarations quite freely, so it's included - unconditionally */ - struct compression { /* The following are const because they should be pointers to parts * of strings allocated elsewhere and should not be written through -- cgit v1.2.3