FreeBSD: Don't set MANPATH, use OS configuration
- make installer to set up man(1) paths using /usr/local/etc/man.d/* - don't override empty/unset MANPATH with compiled in default
This commit is contained in:
committed by
Jon Trulson
parent
f0a60e47b1
commit
c3cb5b8aa6
@@ -27,6 +27,7 @@ XCOMM ####################################################################
|
||||
|
||||
#define HASH #
|
||||
|
||||
#if !defined(__FreeBSD__)
|
||||
HASH
|
||||
HASH Source TIMEZONE
|
||||
HASH
|
||||
@@ -55,6 +56,7 @@ if [ -f $MANPATH_FILE -a -r $MANPATH_FILE ]; then
|
||||
export MANPATH="$MANPATH:`cat $MANPATH_FILE`"
|
||||
fi
|
||||
unset MANPATH_FILE
|
||||
#endif
|
||||
|
||||
XCOMM ######################### eof #####################
|
||||
|
||||
|
||||
@@ -42,6 +42,12 @@ ManSearchPath::ManSearchPath
|
||||
const char * sep
|
||||
) : SearchPath(user, envvar, sep)
|
||||
{
|
||||
#if defined(__FreeBSD__)
|
||||
/* Installer on FreeBSD sets up man configuration so that
|
||||
* setting MANPATH is not necessary
|
||||
*/
|
||||
if (!user->OS()->MANPATH().isNull()) {
|
||||
#endif
|
||||
if (user->DTMANPATH())
|
||||
search_path = user->FactoryManPath() + "," + *user->DTMANPATH();
|
||||
else
|
||||
@@ -55,6 +61,9 @@ ManSearchPath::ManSearchPath
|
||||
|
||||
NormalizePath();
|
||||
TraversePath();
|
||||
#if defined(__FreeBSD__)
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -83,7 +83,7 @@ UnixEnvironment::UnixEnvironment()
|
||||
#elif defined(__OpenBSD__)
|
||||
manpath = "/usr/share/man:/usr/X11R6/man:/usr/local/man:/usr/ports/infrastructure/man";
|
||||
#elif defined(__FreeBSD__)
|
||||
manpath = "/usr/share/man:/usr/local/man";
|
||||
manpath = temp;
|
||||
#endif
|
||||
else
|
||||
manpath = temp;
|
||||
|
||||
Reference in New Issue
Block a user