From b3f07ce236a83eae6796133ad63b34896be2ee61 Mon Sep 17 00:00:00 2001 From: ceriel Date: Mon, 4 Nov 1991 16:51:48 +0000 Subject: [PATCH] Added mk_manpage --- bin/.distr | 2 +- bin/mk_manpage | 18 ++++++++++++++++++ 2 files changed, 19 insertions(+), 1 deletion(-) create mode 100755 bin/mk_manpage diff --git a/bin/.distr b/bin/.distr index 5ce2f213c..e43bf8242 100644 --- a/bin/.distr +++ b/bin/.distr @@ -3,6 +3,6 @@ cc-and-mkdep.all cc-and-mkdep.sun do_deps do_resolve -em.pascal lint-lib.ack lint-lib.unix +mk_manpage diff --git a/bin/mk_manpage b/bin/mk_manpage new file mode 100755 index 000000000..28b382a0e --- /dev/null +++ b/bin/mk_manpage @@ -0,0 +1,18 @@ +num=`expr $1 : '.*\.\([1-8]\)'` + +if [ -d $2/man ] ; then : ; else mkdir $2/man ; fi +if [ -f $2/man/head ] ; then : ; else cat > $2/man/head <<'EOF' +.rn TH yy +.de TH +.di zz +.yy "\\$1" "\\$2" "\\$3" "\\$4" +.ds ]W 5th ACK distribution +.ds ]D Amsterdam Compiler Kit +.ds ]L "\\$3 +.di +.rm zz +.. +EOF +fi +if [ -d $2/man/man$num ] ; then : ; else mkdir $2/man/man$num ; fi +cat $2/man/head $1 > $2/man/man$num/`expr //$1 : '.*/\([^/]*\)'`