aboutsummaryrefslogtreecommitdiffstats
path: root/sysutils
diff options
context:
space:
mode:
authorcrees <crees@FreeBSD.org>2011-08-01 01:29:02 +0800
committercrees <crees@FreeBSD.org>2011-08-01 01:29:02 +0800
commita1956e3d1d72cf9e5578d757af9beac8673cc4b1 (patch)
tree24f8b8844fa9aaf870b892facc6657b2afb8f126 /sysutils
parent5f1b7cbdb9fee000d083d1d4ccc5c7be3bf46e0e (diff)
downloadfreebsd-ports-gnome-a1956e3d1d72cf9e5578d757af9beac8673cc4b1.tar.gz
freebsd-ports-gnome-a1956e3d1d72cf9e5578d757af9beac8673cc4b1.tar.zst
freebsd-ports-gnome-a1956e3d1d72cf9e5578d757af9beac8673cc4b1.zip
- Update to 2.2.0
- Program now lives in PREFIX/bin - Install manpage and extra docs - Reports don't need extra dependency, OPTION removed - Perl dependencies are now by package
Diffstat (limited to 'sysutils')
-rw-r--r--sysutils/monitorix/Makefile51
-rw-r--r--sysutils/monitorix/distinfo4
-rw-r--r--sysutils/monitorix/files/monitorix.in4
-rw-r--r--sysutils/monitorix/files/patch-monitorix9
-rw-r--r--sysutils/monitorix/pkg-plist14
5 files changed, 33 insertions, 49 deletions
diff --git a/sysutils/monitorix/Makefile b/sysutils/monitorix/Makefile
index f808d4d17950..0562cb487a7d 100644
--- a/sysutils/monitorix/Makefile
+++ b/sysutils/monitorix/Makefile
@@ -6,7 +6,7 @@
#
PORTNAME= monitorix
-PORTVERSION= 2.1.2
+PORTVERSION= 2.2.0
PORTREVISION?= 0
CATEGORIES= sysutils
MASTER_SITES= http://www.monitorix.org/ \
@@ -17,19 +17,16 @@ MAINTAINER= crees@FreeBSD.org
COMMENT= A web based monitoring system
LIB_DEPENDS= rrd:${PORTSDIR}/databases/rrdtool
-RUN_DEPENDS= ${SITE_PERL}/LWP/Parallel.pm:${PORTSDIR}/www/p5-ParallelUA \
- ${SITE_PERL}/CGI.pm:${PORTSDIR}/www/p5-CGI.pm \
- ${SITE_PERL}/LWP.pm:${PORTSDIR}/www/p5-libwww \
- ${SITE_PERL}/MIME/Lite.pm:${PORTSDIR}/mail/p5-MIME-Lite
+RUN_DEPENDS= p5-ParallelUA>=0:${PORTSDIR}/www/p5-ParallelUA \
+ p5-CGI.pm>=0:${PORTSDIR}/www/p5-CGI.pm \
+ p5-libwww>=0:${PORTSDIR}/www/p5-libwww \
+ p5-MIME-Lite>=0:${PORTSDIR}/mail/p5-MIME-Lite
LICENSE= GPLv2
-OPTIONS= REPORTS "Mail HTML reports to a given address" off
-
-.include <bsd.port.options.mk>
-
USE_PERL= 5.8+
MAN5= monitorix.conf.5
+MAN8= monitorix.8
MANCOMPRESSED= no
NO_BUILD= yes
USE_RC_SUBR= ${PORTNAME}
@@ -56,16 +53,11 @@ PORTDOCS= COPYING \
Changes \
README \
README.FreeBSD \
+ README.OpenBSD \
+ README.nginx \
monitorix-alert.sh \
monitorix-apache.conf
-.if defined(WITH_REPORTS)
-RUN_DEPENDS+= metamail>=2.7:${PORTSDIR}/mail/metamail
-PLIST_SUB+= REPORTS=""
-.else
-PLIST_SUB+= REPORTS="@comment "
-.endif
-
pre-everything::
@${ECHO_MSG} ""
@${ECHO_MSG} "You may set following options:"
@@ -77,11 +69,8 @@ pre-everything::
@${ECHO_MSG} ""
post-patch:
-# Set FreeBSD path for perl in shebang and absolute sysctl so as not to break
-# in cgi-bin
.for f in monitorix.cgi monitorix.conf monitorix reports/send_reports
@${REINPLACE_CMD} -e "1s|^\(#!\).*|\1${PERL}|" \
- -e 's|"\([^/]sysctl\)|"/sbin/\1|' \
${WRKSRC}/${f}
.endfor
# eth0 doesn't exist in FreeBSD! Also let's set our own paths.
@@ -97,33 +86,35 @@ post-patch:
${WRKSRC}/monitorix.conf
do-install:
- @${INSTALL_SCRIPT} ${WRKSRC}/monitorix ${PREFIX}/sbin/
+ @${INSTALL_SCRIPT} ${WRKSRC}/monitorix ${PREFIX}/bin/
@${MKDIR} ${WWWDIR}/imgs
@${CHOWN} ${WWW_OWNER}:${WWW_GROUP} ${WWWDIR}/imgs
- @for f in ${WWW_FILES}; do \
- ${INSTALL_DATA} ${WRKSRC}/$${f} ${WWWDIR}/; \
- done
+.for f in ${WWW_FILES}
+ @${INSTALL_DATA} ${WRKSRC}/${f} ${WWWDIR}/
+.endfor
@${MKDIR} ${PREFIX}/${CGIDIR}
@${INSTALL_SCRIPT} ${WRKSRC}/monitorix.cgi ${PREFIX}/${CGIDIR}/
.for m in ${MAN5}
@${INSTALL_MAN} ${WRKSRC}/man/man5/$m ${MAN5PREFIX}/man/man5/
.endfor
-.if defined(WITH_REPORTS)
+.for m in ${MAN8}
+ @${INSTALL_MAN} ${WRKSRC}/man/man8/$m ${MAN8PREFIX}/man/man8/
+.endfor
@${MKDIR} ${WWWDIR}/reports
-. for l in ${REPORT_LANG}
+.for l in ${REPORT_LANG}
@${INSTALL_DATA} ${WRKSRC}/reports/${l}.html \
${WWWDIR}/reports/
-. endfor
-.endif
+.endfor
.if !defined(NOPORTDOCS)
@${MKDIR} ${DOCSDIR}
- @for doc in ${PORTDOCS}; do \
- ${INSTALL_DATA} ${WRKSRC}/$${doc} ${DOCSDIR}; \
- done
+. for doc in ${PORTDOCS}
+ @${INSTALL_DATA} ${WRKSRC}/${doc} ${DOCSDIR}
+. endfor
.endif
post-install:
@${MKDIR} ${DATADIR}
+ @${MKDIR} ${WWWDIR}/usage
@${INSTALL_DATA} ${WRKSRC}/monitorix.conf ${PREFIX}/etc/monitorix.conf.sample
@if [ ! -f ${PREFIX}/etc/monitorix.conf ]; then \
${CP} -p ${PREFIX}/etc/monitorix.conf.sample \
diff --git a/sysutils/monitorix/distinfo b/sysutils/monitorix/distinfo
index 61e5a2e5b1c9..2ed0787eb078 100644
--- a/sysutils/monitorix/distinfo
+++ b/sysutils/monitorix/distinfo
@@ -1,2 +1,2 @@
-SHA256 (monitorix-2.1.2.tar.gz) = 7148c01426b0994332d1c4b2f31949ef7845736528aa79f16e4ee2c70e24ac03
-SIZE (monitorix-2.1.2.tar.gz) = 88540
+SHA256 (monitorix-2.2.0.tar.gz) = cf452dde8d3ff7d7afbc2a332741a4b34ec5de0d0d7cf32a0a62e937a9afd6f0
+SIZE (monitorix-2.2.0.tar.gz) = 98067
diff --git a/sysutils/monitorix/files/monitorix.in b/sysutils/monitorix/files/monitorix.in
index 2af18bf32028..7db63f440be0 100644
--- a/sysutils/monitorix/files/monitorix.in
+++ b/sysutils/monitorix/files/monitorix.in
@@ -20,7 +20,7 @@ start_cmd="${name}_start"
pidfile="/var/run/${name}.pid"
command_interpreter="."
-procname="%%PREFIX%%/sbin/${name}"
+procname="%%PREFIX%%/bin/${name}"
monitorix_start()
{
@@ -30,7 +30,7 @@ monitorix_start()
fi
echo "Starting ${name}."
rc_flags="-c %%PREFIX%%/etc/${name}.conf -p ${pidfile} ${rc_flags}"
- %%PERL%% %%PREFIX%%/sbin/${name} ${rc_flags} ${command_args}
+ %%PERL%% %%PREFIX%%/bin/${name} ${rc_flags} ${command_args}
}
run_rc_command "$1"
diff --git a/sysutils/monitorix/files/patch-monitorix b/sysutils/monitorix/files/patch-monitorix
index cd2739bf9ae7..e8362975a48b 100644
--- a/sysutils/monitorix/files/patch-monitorix
+++ b/sysutils/monitorix/files/patch-monitorix
@@ -25,12 +25,3 @@
}
# do exists in /proc/diskstats?
-@@ -3766,7 +3763,7 @@
- }
-
- # check configuration file syntax
--if(system("perl -wc $opt_c >/dev/null 2>&1")) {
-+if(!system("perl -wc $opt_c >/dev/null 2>&1")) {
- print("FATAL: configuration file '$opt_c' had compilation errors.\n");
- exit(1);
- }
diff --git a/sysutils/monitorix/pkg-plist b/sysutils/monitorix/pkg-plist
index 976217466798..0aa0c1c9826f 100644
--- a/sysutils/monitorix/pkg-plist
+++ b/sysutils/monitorix/pkg-plist
@@ -4,16 +4,18 @@
@unexec if cmp -s %D/etc/monitorix.conf %D/etc/monitorix.conf.sample; then rm -f %D/etc/monitorix.conf; fi
etc/monitorix.conf.sample
@exec if [ ! -f %D/etc/monitorix.conf ]; then cp %B/%f %D/etc/monitorix.conf; fi
-sbin/monitorix
+bin/monitorix
@exec mkdir -p %D/%%DATADIR%%
@dirrmtry %%DATADIR%%
+@exec mkdir -p %D/%%WWWDIR%%/usage
+@dirrmtry %%WWWDIR%%/usage
%%CGIDIR%%/monitorix.cgi
@dirrmtry %%CGIDIR%%
-%%REPORTS%%%%WWWDIR%%/reports/ca.html
-%%REPORTS%%%%WWWDIR%%/reports/de.html
-%%REPORTS%%%%WWWDIR%%/reports/en.html
-%%REPORTS%%%%WWWDIR%%/reports/it.html
-%%REPORTS%%@dirrm %%WWWDIR%%/reports
+%%WWWDIR%%/reports/ca.html
+%%WWWDIR%%/reports/de.html
+%%WWWDIR%%/reports/en.html
+%%WWWDIR%%/reports/it.html
+@dirrm %%WWWDIR%%/reports
%%WWWDIR%%/logo_bot.png
%%WWWDIR%%/logo_top.png
%%WWWDIR%%/monitorixico.png