diff options
author | Nick Clifton <nickc@redhat.com> | 2001-03-25 20:32:31 +0000 |
---|---|---|
committer | Nick Clifton <nickc@redhat.com> | 2001-03-25 20:32:31 +0000 |
commit | 0285c67df190b85c05973783e204cd1869644c76 (patch) | |
tree | 04a6234405c7c5aa6dd70c4361e65875ede971ce /ld/Makefile.am | |
parent | 551c1ca1767053de70c75514eee92b55ac8a821a (diff) | |
download | gdb-0285c67df190b85c05973783e204cd1869644c76.zip gdb-0285c67df190b85c05973783e204cd1869644c76.tar.gz gdb-0285c67df190b85c05973783e204cd1869644c76.tar.bz2 |
Automate generate on man pages
Diffstat (limited to 'ld/Makefile.am')
-rw-r--r-- | ld/Makefile.am | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/ld/Makefile.am b/ld/Makefile.am index 3d5931d..2cdbf78 100644 --- a/ld/Makefile.am +++ b/ld/Makefile.am @@ -41,6 +41,13 @@ MKDEP = gcc -MM # What version of the manual to build DOCVER = gen +# Options to extract the man page from ld.texinfo +MANCONF = -Dman + +TEXI2POD = perl $(BASEDIR)/etc/texi2pod.pl + +POD2MAN = pod2man --center="GNU" --release="binutils-$(VERSION)" --section=1 + #stuff for self hosting (can be overridden in config file). HOSTING_CRT0 = @HOSTING_CRT0@ HOSTING_LIBS = @HOSTING_LIBS@ @@ -900,6 +907,17 @@ ld.dvi: $(srcdir)/ld.texinfo configdoc.texi ldver.texi TEXINPUTS=$(top_srcdir)/../texinfo:$$TEXINPUTS \ MAKEINFO="$(MAKEINFO) -I $(srcdir) -I $(BFDDIR)/doc" $(TEXI2DVI) $(srcdir)/ld.texinfo +# Build the man page from the texinfo file +# The sed command removes the no-adjust Nroff command so that +# the man output looks standard. +$(srcdir)/ld.1: $(srcdir)/ld.texinfo + touch $(srcdir)/ld.1 + -$(TEXI2POD) $(MANCONF) < $(srcdir)/ld.texinfo > ld.pod + -($(POD2MAN) ld.pod | \ + sed -e '/^.if n .na/d' > $(srcdir)/ld.1.T$$$$ && \ + mv -f $(srcdir)/ld.1.T$$$$ $(srcdir)/ld.1) || \ + (rm -f $(srcdir)/ld.1.T$$$$ && exit 1) + MAINTAINERCLEANFILES = ldver.texi # We want to reconfigure if configure.host or configure.tgt changes. |