From 0e921dacc9815f477e340d22642a004c993ce770 Mon Sep 17 00:00:00 2001 From: Brendan Cully Date: Mon, 1 Aug 2005 17:06:48 +0000 Subject: [PATCH] Insert compile-time paths to system resources into mutt.man. (closes #854) --- doc/Makefile.in | 19 +++++++++++-------- doc/mutt.man | 12 ++++++------ 2 files changed, 17 insertions(+), 14 deletions(-) diff --git a/doc/Makefile.in b/doc/Makefile.in index c01fa3d9..bcc89adc 100644 --- a/doc/Makefile.in +++ b/doc/Makefile.in @@ -7,6 +7,7 @@ VERSION = @VERSION@ prefix = @prefix@ exec_prefix = @exec_prefix@ +sysconfdir = @sysconfdir@ bindir = @bindir@ libdir = @libdir@ mandir = @mandir@ @@ -59,12 +60,11 @@ DISTFILES = Makefile.in dotlock.man \ srcdir_DOCFILES = PGP-Notes.txt applying-patches.txt \ devel-notes.txt patch-notes.txt smime-notes.txt - topsrcdir_DOCFILES = COPYRIGHT GPL INSTALL ChangeLog \ ChangeLog.old \ README NEWS TODO README.SECURITY README.SSL -all: muttrc.man try-html try-txt +all: mutt.1 muttrc.man try-html try-txt try-html: ../makedoc$(EXEEXT) test -f manual.html || $(MAKE) manual.html || cp $(srcdir)/manual*.html ./ @@ -75,7 +75,7 @@ try-txt: ../makedoc$(EXEEXT) install: all instdoc $(top_srcdir)/mkinstalldirs $(DESTDIR)$(mandir)/man1 $(top_srcdir)/mkinstalldirs $(DESTDIR)$(mandir)/man5 - ./instdoc $(srcdir)/mutt.man $(DESTDIR)$(mandir)/man1/mutt.1 + ./instdoc mutt.1 $(DESTDIR)$(mandir)/man1/mutt.1 ./instdoc $(srcdir)/muttbug.man $(DESTDIR)$(mandir)/man1/flea.1 ./instdoc $(srcdir)/muttbug.man $(DESTDIR)$(mandir)/man1/muttbug.1 ./instdoc $(srcdir)/dotlock.man \ @@ -153,11 +153,15 @@ dist distdir: Makefile $(DISTFILES) ../makedoc$(EXEEXT): $(top_srcdir)/makedoc.c (cd .. && $(MAKE) makedoc$(EXEEXT)) -# hack around autoconf mixing up patterns. -at = @ - update-doc: ../makedoc$(EXEEXT) stamp-doc-sgml stamp-doc-man manual.txt manual.html +EDIT = sed -e 's,@sysconfdir\@,$(sysconfdir),g' \ + -e 's,@bindir\@,$(bindir),g' \ + -e 's,@docdir\@,$(docdir),g' + +mutt.1: $(srcdir)/mutt.man + $(EDIT) $< > $@ + muttrc.man stamp-doc-man: ../makedoc$(EXEEXT) $(top_srcdir)/init.h muttrc.man.head muttrc.man.tail $(MAKEDOC_CPP) $(top_srcdir)/init.h | ../makedoc -m | \ cat $(srcdir)/muttrc.man.head - $(srcdir)/muttrc.man.tail\ @@ -165,8 +169,7 @@ muttrc.man stamp-doc-man: ../makedoc$(EXEEXT) $(top_srcdir)/init.h muttrc.man.he touch stamp-doc-man manual.sgml stamp-doc-sgml: ../makedoc$(EXEEXT) $(top_srcdir)/init.h manual.sgml.head manual.sgml.tail $(top_srcdir)/VERSION - ( sed -e "s/$(at)VERSION$(at)/`cat $(top_srcdir)/VERSION`/" $(srcdir)/manual.sgml.head ;\ + ( sed -e "s/@VERSION\@/`cat $(top_srcdir)/VERSION`/" $(srcdir)/manual.sgml.head ;\ $(MAKEDOC_CPP) $(top_srcdir)/init.h | ../makedoc -s ) | \ cat - $(srcdir)/manual.sgml.tail > manual.sgml touch stamp-doc-sgml - diff --git a/doc/mutt.man b/doc/mutt.man index 8d312ac3..109afa26 100644 --- a/doc/mutt.man +++ b/doc/mutt.man @@ -1,7 +1,7 @@ .\" -*-nroff-*- .\" .\" -.\" Copyright (C) 1996-2000 Michael R. Elkins +.\" Copyright (C) 1996-2004 Michael R. Elkins .\" .\" This program is free software; you can redistribute it and/or modify .\" it under the terms of the GNU General Public License as published by @@ -135,21 +135,21 @@ Specifies the editor to use when composing messages. .PP .IP "~/.muttrc or ~/.mutt/muttrc" User configuration file. -.IP "/etc/Muttrc" +.IP "@sysconfdir@/Muttrc" System-wide configuration file. .IP "/tmp/muttXXXXXX" Temporary files created by Mutt. .IP "~/.mailcap" User definition for handling non-text MIME types. -.IP "/etc/mailcap" +.IP "@sysconfdir@/mailcap" System definition for handling non-text MIME types. .IP "~/.mime.types" User's personal mapping between MIME types and file extensions. -.IP "/etc/mime.types" +.IP "@sysconfdir@/mime.types" System mapping between MIME types and file extensions. -.IP "/usr/local/bin/mutt_dotlock" +.IP "@bindir@/mutt_dotlock" The privileged dotlocking program. -.IP "/usr/local/doc/mutt/manual.txt" +.IP "@docdir@/manual.txt" The Mutt manual. .SH BUGS .PP -- 2.40.0