diff options
Diffstat (limited to 'sysutils/munin-node')
| -rw-r--r-- | sysutils/munin-node/Makefile | 10 | ||||
| -rw-r--r-- | sysutils/munin-node/files/patch-node__sbin__munin-node | 12 | ||||
| -rw-r--r-- | sysutils/munin-node/files/patch-node__sbin__munin-node-configure | 13 | ||||
| -rw-r--r-- | sysutils/munin-node/files/patch-node__sbin__munin-run | 12 |
4 files changed, 46 insertions, 1 deletions
diff --git a/sysutils/munin-node/Makefile b/sysutils/munin-node/Makefile index a5dab22b9e4a..c9f1a04313ff 100644 --- a/sysutils/munin-node/Makefile +++ b/sysutils/munin-node/Makefile @@ -7,7 +7,7 @@ PORTNAME= munin PORTVERSION= 1.4.5 -PORTREVISION= 5 +PORTREVISION= 6 CATEGORIES= sysutils perl5 MASTER_SITES= SF/${PORTNAME}/${PORTNAME}%20stable/${PORTVERSION} PKGNAMESUFFIX= -node @@ -31,6 +31,7 @@ RUN_DEPENDS= ${SITE_PERL}/Cache/Cache.pm:${PORTSDIR}/devel/p5-Cache-Cache \ USE_PERL5= yes USE_GMAKE= yes PKGMESSAGE= ${WRKDIR}/pkg-message +REINPLACE_ARGS= -i "" .include "${.CURDIR}/../munin-common/munin.mk" @@ -64,6 +65,13 @@ MAN8= munin.8 SUB_FILES= pkg-message munin-node-revive.sh USE_RC_SUBR= munin-node +post-patch: + @${REINPLACE_CMD} -e 's|%%PREFIX%%|${PREFIX}|g' \ + ${WRKSRC}/node/sbin/munin-node \ + ${WRKSRC}/node/sbin/munin-node-configure \ + ${WRKSRC}/node/sbin/munin-run + @${FIND} ${WRKSRC}/node/sbin -type f -name "*.orig" -delete + pre-su-install: @${SETENV} ${SCRIPTS_ENV} PKG_PREFIX=${PREFIX} \ ${SH} ${PKGINSTALL} ${PKGNAME} PRE-INSTALL diff --git a/sysutils/munin-node/files/patch-node__sbin__munin-node b/sysutils/munin-node/files/patch-node__sbin__munin-node new file mode 100644 index 000000000000..75a1cb707116 --- /dev/null +++ b/sysutils/munin-node/files/patch-node__sbin__munin-node @@ -0,0 +1,12 @@ +--- node/sbin/munin-node.orig Wed Oct 20 14:51:29 2010 ++++ node/sbin/munin-node Wed Oct 20 14:52:34 2010 +@@ -56,6 +56,9 @@ sub main { + $ENV{$key} =~ /^(.*)$/; + $ENV{$key} = $1; + } ++ # plugins run in taint mode because the uid is changed, so the path ++ # must not contain writable directories. ++ $ENV{PATH}='/bin:/sbin:/usr/bin:/usr/sbin:%%PREFIX%%/bin:%%PREFIX%%/sbin'; + + $0 =~ /^(.*)$/; + $0 = $1; diff --git a/sysutils/munin-node/files/patch-node__sbin__munin-node-configure b/sysutils/munin-node/files/patch-node__sbin__munin-node-configure new file mode 100644 index 000000000000..8838c2432e8c --- /dev/null +++ b/sysutils/munin-node/files/patch-node__sbin__munin-node-configure @@ -0,0 +1,13 @@ +--- node/sbin/munin-node-configure.orig Tue Oct 5 22:36:04 2010 ++++ node/sbin/munin-node-configure Tue Oct 5 22:37:57 2010 +@@ -28,6 +28,10 @@ use POSIX (); + use Data::Dumper; + use Carp; + ++# plugins run in taint mode because the uid is changed, so the path ++# must not contain writable directories. ++$ENV{PATH}='/bin:/sbin:/usr/bin:/usr/sbin:%%PREFIX%%/bin:%%PREFIX%%/sbin'; ++ + use Munin::Common::Defaults; + use Munin::Node::Configure::PluginList; + use Munin::Node::Configure::Debug; diff --git a/sysutils/munin-node/files/patch-node__sbin__munin-run b/sysutils/munin-node/files/patch-node__sbin__munin-run new file mode 100644 index 000000000000..3730ea03ffea --- /dev/null +++ b/sysutils/munin-node/files/patch-node__sbin__munin-run @@ -0,0 +1,12 @@ +--- node/sbin/munin-run.orig Wed Oct 20 14:50:43 2010 ++++ node/sbin/munin-run Wed Oct 20 14:52:51 2010 +@@ -53,6 +53,9 @@ sub main + $ENV{$key} =~ /^(.*)$/; + $ENV{$key} = $1; + } ++ # plugins run in taint mode because the uid is changed, so the path ++ # must not contain writable directories. ++ $ENV{PATH}='/bin:/sbin:/usr/bin:/usr/sbin:%%PREFIX%%/bin:%%PREFIX%%/sbin'; + + $0 =~ /^(.*)$/; + $0 = $1; |
