- Adjust man pages for mountd/statd to match configuration options.
Subsystems (2)
PATCH 1/1 - Adjust man pages for mountd/statd to match configuration options.
Someone mentioned to me that if you configure nfs-utils without TCP_WRAPPERS, the man pages still say it is available. This sort of thing has bothered me on and off before so I thought I would do something about it. i.e. modify the man pages based on the config.
The following git-patch does this, but I would welcome review as I'm not a very experiences automake hacker.
Running "autogen.sh" reports:
utils/mountd/Makefile.am:29: %'-style pattern rules are a GNU make extension utils/statd/Makefile.am:66: %'-style pattern rules are a GNU make extension
Should we care? Is there a better way?
NeilBrown
(patch can be cherry-picked from git://neil.brown.name/nfs-utils/)
Quoted 1 line
From
be806a06d414603e0930c61d1576d47f46ff064cMon Sep 17 00:00:00 2001
From: Neil Brown <[email protected]>
Date: Tue, 30 Oct 2007 12:18:34 +1100
Subject: [PATCH] Make man pages configurable and exclude TCP_WRAPPERS notes where appropriate.
This patch makes mountd.man and statd.man able to be modified based on configuration, and removes the TCP_WRAPPERS section when that feature is not configured in.
---
aclocal/tcp-wrappers.m4 | 1 +
utils/mountd/Makefile.am | 10 ++++++++++
utils/mountd/{mountd.man => mountd.man.in} | 2 ++
utils/statd/Makefile.am | 10 ++++++++++
utils/statd/{statd.man => statd.man.in} | 2 ++
5 files changed, 25 insertions(+), 0 deletions(-)
rename utils/mountd/{mountd.man => mountd.man.in} (99%)
rename utils/statd/{statd.man => statd.man.in} (99%)aclocal/tcp-wrappers.m4 +1 -0
@@ -51,4 +51,5 @@ AC_DEFUN([AC_TCP_WRAPPERS],[ AC_SUBST(LIBWRAP) AC_SUBST(HAVE_LIBWRAP) AC_SUBST(HAVE_TCP_WRAPPER) + AM_CONDITIONAL(USE_TCP_WRAPPERS, [test $HAVE_TCP_WRAPPER = 1]) ])
utils/mountd/Makefile.am +10 -0
@@ -19,6 +19,16 @@ mountd_CPPFLAGS = $(AM_CPPFLAGS) $(CPPFLAGS) \ MAINTAINERCLEANFILES = Makefile.in +MAN_SED = +if USE_TCP_WRAPPERS +MAN_SED += -e 's/USE_TCP_WRAP/yes/' +else +MAN_SED += -e 's/USE_TCP_WRAP/no/' +endif + +%.man : %.man.in + sed $(MAN_SED) < $< > $@ + ####################################################################### # The following allows the current practice of having # daemons renamed during the install to include RPCPREFIX
utils/mountd/mountd.man.in renamed from utils/mountd/mountd.man +2 -0
@@ -166,6 +166,7 @@ the server. Note that the 'primary' group id is not affected so a command on the client will still be effective. This function requires a Linux Kernel with version at least 2.6.21. +.if 'USE_TCP_WRAP'no' .ig .SH TCP_WRAPPERS SUPPORT This .B rpc.mountd
@@ -187,6 +188,7 @@ For further information please have a look at the and .BR hosts_access (5) manual pages. +.. .SH SEE ALSO .BR rpc.nfsd (8),
utils/statd/Makefile.am +10 -0
@@ -56,6 +56,16 @@ MAINTAINERCLEANFILES = Makefile.in CLEANFILES = $(GENFILES) +MAN_SED = +if USE_TCP_WRAPPERS +MAN_SED += -e 's/USE_TCP_WRAP/yes/' +else +MAN_SED += -e 's/USE_TCP_WRAP/no/' +endif + +%.man : %.man.in + sed $(MAN_SED) < $< > $@ + ####################################################################### # The following allows the current practice of having # daemons renamed during the install to include RPCPREFIX
utils/statd/statd.man.in renamed from utils/statd/statd.man +2 -0
@@ -144,6 +144,7 @@ to print out version information and exit. +.if 'USE_TCP_WRAP'no' .ig .SH TCP_WRAPPERS SUPPORT This .B rpc.statd
@@ -165,6 +166,7 @@ For further information please have a look at the and .BR hosts_access (5) manual pages. +.. .SH SIGNALS .BR SIGUSR1
Signature · 11 lines
1.5.3.4 ------------------------------------------------------------------------- This SF.net email is sponsored by: Splunk Inc. Still grepping through log files to find problems? Stop. Now Search log events and configuration files using AJAX and a browser. Download your FREE copy of Splunk now >> http://get.splunk.com/ _______________________________________________ NFS maillist - [email protected] https://lists.sourceforge.net/lists/listinfo/nfs
Quoted 6 lines · Neil Brown
Someone mentioned to me that if you configure nfs-utils without
TCP_WRAPPERS, the man pages still say it is available. This sort of thing has bothered me on and off before so I thought I would do something about it. i.e. modify the man pages based on the config.
I think it would be better to add some words to the effect that the TCP_WRAPPERS support may not be available on all installs. People do "man foo" on all kinds of systems (including googling), not just the one that they're actually running "foo" on. So making it conditional will serve more to confuse than clarify.
Besides, the text just says to add the relevant hosts to /etc/hosts.allow. This is harmless, and might even be a good idea. Just change the verbs from "is" to "may be" and "have" to "may have".
So I say don't drop the text.
Tom.
Quoted 132 lines
The following git-patch does this, but I would welcome review as I'm not a very experiences automake hacker.
Running "
autogen.sh" reports:utils/mountd/Makefile.am:29:
%'-style pattern rules are a GNU make extension utils/statd/Makefile.am:66:%'-style pattern rules are a GNU make extensionShould we care? Is there a better way?
NeilBrown
(patch can be cherry-picked from
git://neil.brown.name/nfs-utils/)Quoted 1 line
From
be806a06d414603e0930c61d1576d47f46ff064cMon Sep 17 00:00:00 2001From: Neil Brown <[email protected]>
Date: Tue, 30 Oct 2007 12:18:34 +1100
Subject: [PATCH] Make man pages configurable and excludeTCP_WRAPPERSnotes where appropriate.This patch makes mountd.man and statd.man able to be modified based on configuration, and removes the
TCP_WRAPPERSsection when that feature is not configured in.
---aclocal/tcp-wrappers.m4 | 1 + utils/mountd/Makefile.am | 10 ++++++++++ utils/mountd/{mountd.man => mountd.man.in} | 2 ++ utils/statd/Makefile.am | 10 ++++++++++ utils/statd/{statd.man => statd.man.in} | 2 ++ 5 files changed, 25 insertions(+), 0 deletions(-)rename utils/mountd/{mountd.man => mountd.man.in} (99%) rename utils/statd/{statd.man => statd.man.in} (99%)
aclocal/tcp-wrappers.m4 +1
-0@@ -51,4 +51,5 @@ AC_DEFUN([AC_TCP_WRAPPERS],[ AC_SUBST(LIBWRAP) AC_SUBST(HAVE_LIBWRAP) AC_SUBST(HAVE_TCP_WRAPPER) + AM_CONDITIONAL(USE_TCP_WRAPPERS, [test $HAVE_TCP_WRAPPER = 1]) ])utils/mountd/Makefile.am +0
-0@@ -19,6 +19,16 @@ mountd_CPPFLAGS = $(AM_CPPFLAGS) $(CPPFLAGS) \MAINTAINERCLEANFILES = Makefile.in
utils/mountd/Makefile.am +10
-0+MAN_SED = +if USE_TCP_WRAPPERS +MAN_SED += -e 's/USE_TCP_WRAP/yes/' +else +MAN_SED += -e 's/USE_TCP_WRAP/no/' +endif + +%.man : %.man.in + sed $(MAN_SED) < $< > $@ +#######################################################################
# The following allows the current practice of having# daemons renamed during the install to include RPCPREFIXutils/mountd/mountd.man.in renamed from utils/mountd/mountd.man +0
-0@@ -166,6 +166,7 @@ the server. Note that the 'primary' group id isnot affected so a
command on the client will still be effective. This function requires a Linux Kernel with version at least 2.6.21.+.if 'USE_TCP_WRAP'no' .ig
.SHTCP_WRAPPERSSUPPORT
This
.B rpc.mountdutils/mountd/mountd.man.in renamed from utils/mountd/mountd.man +0
-0@@ -187,6 +188,7 @@ For further information please have a look at theand
.BRhosts_access(5)
manual pages.
+...SH SEE ALSO
.BR rpc.nfsd (8),utils/statd/Makefile.am +10
-0@@ -56,6 +56,16 @@ MAINTAINERCLEANFILES = Makefile.in CLEANFILES = $(GENFILES) +MAN_SED = +if USE_TCP_WRAPPERS +MAN_SED += -e 's/USE_TCP_WRAP/yes/' +else +MAN_SED += -e 's/USE_TCP_WRAP/no/' +endif + +%.man : %.man.in + sed $(MAN_SED) < $< > $@ + ####################################################################### # The following allows the current practice of having # daemons renamed during the install to include RPCPREFIXutils/statd/statd.man.in renamed from utils/statd/statd.man +1
-0@@ -144,6 +144,7 @@ to print out version information and exit. +.if 'USE_TCP_WRAP'no' .ig.SH
TCP_WRAPPERSSUPPORT
This
.B rpc.statdutils/statd/statd.man.in renamed from utils/statd/statd.man +0
-0@@ -165,6 +166,7 @@ For further information please have a look at theand
.BRhosts_access(5)
manual pages.
+..
Quoted 14 lines
.SH SIGNALS
.BR SIGUSR1Signature · 11 lines
1.5.3.4 ------------------------------------------------------------------------- This SF.net email is sponsored by: Splunk Inc. Still grepping through log files to find problems? Stop. Now Search log events and configuration files using AJAX and a browser. Download your FREE copy of Splunk now >> http://get.splunk.com/ _______________________________________________ NFS maillist - [email protected] https://lists.sourceforge.net/lists/listinfo/nfs
-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems? Stop. Now Search log events and configuration files using AJAX and a browser. Download your FREE copy of Splunk now >> http://get.splunk.com/
_______________________________________________
NFS maillist - [email protected]
https://lists.sourceforge.net/lists/listinfo/nfs