aboutsummaryrefslogtreecommitdiff
path: root/sysutils
diff options
context:
space:
mode:
authorDries Michiels <driesm@FreeBSD.org>2023-01-09 22:03:28 +0000
committerDries Michiels <driesm@FreeBSD.org>2023-01-10 19:18:13 +0000
commite7682c8251ec3098e6562374c4a43d748e03e8d6 (patch)
tree8e0421331633f1cfa03c19b9f259f90c904f1209 /sysutils
parenta566d9504025661733ded43942f0455adacd4ed3 (diff)
downloadports-e7682c8251ec3098e6562374c4a43d748e03e8d6.tar.gz
ports-e7682c8251ec3098e6562374c4a43d748e03e8d6.zip
sysutils/zrepl: various improvements
* Drop unneeded FreeBSD check, this was tracked down to a version check not being fully removed. Only the version check was removed but the FreeBSD check remained unnecessarily. * Limit the syslog sample to zrepl log messages, other daemons use local0 as facility too. * Switch to uses:ncurses
Diffstat (limited to 'sysutils')
-rw-r--r--sysutils/zrepl/Makefile18
-rw-r--r--sysutils/zrepl/files/syslog.conf1
-rw-r--r--sysutils/zrepl/files/zrepl.in3
3 files changed, 5 insertions, 17 deletions
diff --git a/sysutils/zrepl/Makefile b/sysutils/zrepl/Makefile
index 340a6ac098d0..ed56db478494 100644
--- a/sysutils/zrepl/Makefile
+++ b/sysutils/zrepl/Makefile
@@ -1,6 +1,7 @@
PORTNAME= zrepl
DISTVERSIONPREFIX= v
DISTVERSION= 0.6.0
+PORTREVISION= 1
CATEGORIES= sysutils
MAINTAINER= driesm@FreeBSD.org
@@ -10,7 +11,7 @@ WWW= https://zrepl.github.io/
LICENSE= MIT
LICENSE_FILE= ${WRKSRC}/LICENSE
-USES= go:modules
+USES= go:modules ncurses
USE_RC_SUBR= zrepl
GO_MODULE= github.com/${PORTNAME}/${PORTNAME}
@@ -27,21 +28,6 @@ MANPAGES_BUILD_DEPENDS= ${PYTHON_PKGNAMEPREFIX}sphinx>=1.8.5,1:textproc/py-sphin
MANPAGES_USES= gmake python:build,3.6+
MANPAGES_PLIST_FILES= man/man1/zrepl.1.gz
-.include <bsd.port.options.mk>
-
-.if ${OPSYS} == "FreeBSD" && ${OSVERSION} >= 1300079
-USES+= ncurses
-.else
-USES+= ncurses:port
-CFLAGS+= -I${LOCALBASE}/include/ncurses
-.endif
-
-.if ${OPSYS} == "FreeBSD"
-SUB_LIST+= DAEMON_LOGGING="-S -l \$${zrepl_facility} -s \$${zrepl_priority} -T \$${name}"
-.else
-SUB_LIST+= DAEMON_LOGGING=""
-.endif
-
post-build-MANPAGES-on:
@${MAKE_CMD} -C ${WRKSRC}/docs SPHINXBUILD=sphinx-build-${PYTHON_VER} man
diff --git a/sysutils/zrepl/files/syslog.conf b/sysutils/zrepl/files/syslog.conf
index 1cf0a16406e0..c825c409d5a6 100644
--- a/sysutils/zrepl/files/syslog.conf
+++ b/sysutils/zrepl/files/syslog.conf
@@ -3,4 +3,5 @@
#
# SELECTOR ACTION
# FACILITY.[!<=>]LEVEL
+!zrepl
local0.info /var/log/zrepl.log
diff --git a/sysutils/zrepl/files/zrepl.in b/sysutils/zrepl/files/zrepl.in
index 095a43f0d610..6a2510f80572 100644
--- a/sysutils/zrepl/files/zrepl.in
+++ b/sysutils/zrepl/files/zrepl.in
@@ -43,7 +43,8 @@ load_rc_config $name
pidfile="/var/run/zrepl.pid"
command="/usr/sbin/daemon"
procname="%%PREFIX%%/bin/zrepl"
-command_args="-p ${pidfile} %%DAEMON_LOGGING%% ${procname} ${zrepl_options} daemon"
+command_args="-p ${pidfile} -S -l ${zrepl_facility} -s ${zrepl_priority} -T ${name} \
+ ${procname} ${zrepl_options} daemon"
start_precmd="zrepl_precmd"
stop_postcmd="zrepl_postcmd"