summaryrefslogtreecommitdiff
path: root/lang/perl5.12/files/use.perl
diff options
context:
space:
mode:
authorGordon Tetlow <gordon@FreeBSD.org>2010-11-05 05:41:37 +0000
committerGordon Tetlow <gordon@FreeBSD.org>2010-11-05 05:41:37 +0000
commitaad4dc8ca8295bbbbd7cccec4e1afecc93e5a2f8 (patch)
tree6f5f2e38840a389446d83fb5e6adb181ad2b7395 /lang/perl5.12/files/use.perl
parentAdd patch to install a configuration file for the new man utility (diff)
Add patch to install a configuration file for the new man utility
instead of manipulating /etc/manpath.config. Approved by: maintainer (timeout), wes@ (mentor, implicit)
Notes
Notes: svn path=/head/; revision=264121
Diffstat (limited to 'lang/perl5.12/files/use.perl')
-rw-r--r--lang/perl5.12/files/use.perl16
1 files changed, 9 insertions, 7 deletions
diff --git a/lang/perl5.12/files/use.perl b/lang/perl5.12/files/use.perl
index 3603d6ea50ae..890d8f4f31d0 100644
--- a/lang/perl5.12/files/use.perl
+++ b/lang/perl5.12/files/use.perl
@@ -110,8 +110,8 @@ do_cleanup_make_conf()
do_cleanup_manpath()
{
- echo -n "Cleaning up /etc/manpath.config..."
if [ -f /etc/manpath.config ] ; then
+ echo -n "Cleaning up /etc/manpath.config..."
/bin/cp -p /etc/manpath.config /etc/manpath.config.new
/usr/bin/awk 's=0;
/^#.*use.perl/ { s=1; mode=1 }
@@ -121,8 +121,8 @@ do_cleanup_manpath()
{ if (s != 1) { mode = 0 } if (mode == 0) print }' /etc/manpath.config >/etc/manpath.config.new
/bin/mv /etc/manpath.config /etc/manpath.config.bak
/bin/mv /etc/manpath.config.new /etc/manpath.config
+ echo " Done."
fi
- echo " Done."
}
do_spam_make_conf()
@@ -135,11 +135,13 @@ do_spam_make_conf()
do_spam_manpath()
{
- echo -n "Spamming /etc/manpath.config..."
- echo "$banner" >>/etc/manpath.config
- echo "OPTIONAL_MANPATH ${PKG_PREFIX}/lib/perl5/%%PERL_VERSION%%/man" >>/etc/manpath.config
- echo "OPTIONAL_MANPATH ${PKG_PREFIX}/lib/perl5/%%PERL_VERSION%%/perl/man" >>/etc/manpath.config
- echo " Done."
+ if [ -f /etc/manpath.config ] ; then
+ echo -n "Spamming /etc/manpath.config..."
+ echo "$banner" >>/etc/manpath.config
+ echo "OPTIONAL_MANPATH ${PKG_PREFIX}/lib/perl5/%%PERL_VERSION%%/man" >>/etc/manpath.config
+ echo "OPTIONAL_MANPATH ${PKG_PREFIX}/lib/perl5/%%PERL_VERSION%%/perl/man" >>/etc/manpath.config
+ echo " Done."
+ fi
}
[ "$need_remove_links" = "yes" ] && do_remove_links