diff options
author | Jérémie Courrèges-Anglas <jca@wxcvbn.org> | 2014-02-20 01:20:05 +0100 |
---|---|---|
committer | Jérémie Courrèges-Anglas <jca@wxcvbn.org> | 2014-02-20 01:50:31 +0100 |
commit | 571fedb62290ec6fc059830efc6ffaaff337e3d2 (patch) | |
tree | 08113a980ec5f09b2db3875bc65f8ba70697ea9e /doc/Makefile.am | |
parent | 9a65f65f5ed3be2eb1deefa97e797ee64137ba50 (diff) | |
download | ratpoison-571fedb62290ec6fc059830efc6ffaaff337e3d2.zip |
Replace man(7) manpage with a mdoc(7)-formatted one.
* The former manpage needed Groff to be properly formatted, this is a
dependancy I want to remove. Support for systems where neither groff
nor mandoc are available is achieved by generating a man(7) manpage,
which will be shipped in the tarballs.
* The mdoc(7) language provides semantic annotations for better
documentation of Unix utilities, contrary to man(7) which provides
mere presentation markup.
* The build system now encodes paths in the manpage according to the
settings passed to ./configure.
Note that some markup used may not be perfectly appropriate. Comments
about this matter, and questions from distro maintainers using manpage
patches are welcome.
Selected reading:
- http://mdocml.bsd.lv general information about mdoc(7)
- http://mdocml.bsd.lv/mdoc.7.html mdoc(7) macros reference
- http://manpages.bsd.lv/ mdoc(7) tutorial
Diffstat (limited to 'doc/Makefile.am')
-rw-r--r-- | doc/Makefile.am | 19 |
1 files changed, 17 insertions, 2 deletions
diff --git a/doc/Makefile.am b/doc/Makefile.am index e653893..1b8da1c 100644 --- a/doc/Makefile.am +++ b/doc/Makefile.am @@ -19,5 +19,20 @@ info_TEXINFOS = ratpoison.texi man_MANS = ratpoison.1 -EXTRA_DIST = $(man_MANS) sample.ratpoisonrc ipaq.ratpoisonrc fdl.texi -MAINTAINERCLEANFILES = Makefile.in texinfo.tex +CLEANFILES = ratpoison.1 +EXTRA_DIST = $(srcdir)/ratpoison.mdoc.1 $(srcdir)/ratpoison.man.1 sample.ratpoisonrc ipaq.ratpoisonrc fdl.texi +MAINTAINERCLEANFILES = $(srcdir)/ratpoison.man.1 Makefile.in texinfo.tex + +ratpoison.1: $(srcdir)/ratpoison.$(manpage_format).1 Makefile + tmp=`mktemp` && \ + sed -e 's|%%sysconfdir%%|$(sysconfdir)|g' \ + -e 's|%%docdir%%|$(docdir)|g' \ + < $(srcdir)/ratpoison.$(manpage_format).1 > "$$tmp" && \ + chmod 0644 "$$tmp" && \ + mv "$$tmp" ratpoison.1 + +$(srcdir)/ratpoison.man.1: $(srcdir)/ratpoison.mdoc.1 + tmp=`mktemp` && \ + $(MANDOC) -Tman < $(srcdir)/ratpoison.mdoc.1 > "$$tmp" && \ + chmod 0644 "$$tmp" && \ + mv "$$tmp" $(srcdir)/ratpoison.man.1 |