diff --git a/sys/unix/Makefile.doc b/sys/unix/Makefile.doc index 5ea70b434..d43acfcdf 100644 --- a/sys/unix/Makefile.doc +++ b/sys/unix/Makefile.doc @@ -115,8 +115,11 @@ Guidebook.dat : Gbk-1pg-pfx.mn Gbk-1pg-sfx.mn $(GUIDEBOOK_MN) tmac.n tmac.nh \ $(ONEPAGECMD) > $@ # plain text output -#MAN2TXT = $(NHGREP) | nroff -man $(MORE_MAN2TXT_FLAGS) - | $(COLCMD) -MAN2TXT = $(NHGREP) | nroff -man $(MORE_MAN2TXT_FLAGS) - +# MORE_MAN2TXT_FLAGS is included so that a hints file can alter the options +MAN2TXT = $(NHGREP) | nroff -man $(MORE_MAN2TXT_FLAGS) +# If you aren't using a hints file, you can uncomment the following +# line if you have groff 1.23 or greater. +#MAN2TXT = $(NHGREP) | nroff -man -Tascii -P -cbou nethack.txt : nethack.6 cat nethack.6 | $(MAN2TXT) > nethack.txt recover.txt : recover.6 diff --git a/sys/unix/hints/include/misc.370 b/sys/unix/hints/include/misc.370 index eea26d2ba..973473444 100644 --- a/sys/unix/hints/include/misc.370 +++ b/sys/unix/hints/include/misc.370 @@ -69,20 +69,21 @@ endif NROFFISGROFF := $(shell echo `nroff --version | grep "GNU groff version"`) #$(info NROFFISGROFF=$(NROFFISGROFF)) ifneq "$(NROFFISGROFF)" "" -# --- version check is not currently needed --- -# get the version of groff -#GROFFGE123 := $(shell expr `echo $(NROFFISGROFF) | cut -f2 -d.` \>= 23) -#$(info GROFFGE123=$(GROFFGE123)) -#ifeq "$(GROFFGE123)" "1" -#NROFF_FLAGS = -W font -#endif -# --- +# get the version of groff and flag if it is gt or eq to 1.23 +GROFFGE123 := $(shell expr `echo $(NROFFISGROFF) | cut -f2 -d.` \>= 23) endif # NROFFISGROFF ifneq "$(NROFFISGROFF)" "" # It's groff -# add the groff-specific plain text flags -MORE_MAN2TXT_FLAGS += -Tascii -P -cbou +# add the -Tascii flag used by groff +MORE_MAN2TXT_FLAGS += -Tascii +ifneq "$(GROFFGE123)" "" # It's groff 1.23 or greater +#$(info GROFFGE123=$(GROFFGE123)) +# add the groff 1.23 specific plain text flag -P +MORE_MAN2TXT_FLAGS += -P endif +# add more plain text flags used by groff +MORE_MAN2TXT_FLAGS += -cbou +endif # end groff-specific #end of hints/include/misc.370 #------------------------------------------------------------------------------