mirror of
https://git.FreeBSD.org/ports.git
synced 2024-11-19 00:13:33 +00:00
news/nzbget: update to 21.1
ChangeLog: https://github.com/nzbget/nzbget/releases/tag/v21.1 * Remove unused options * Replace PYTHON option with USES flag * Enable setting an unprivileged user in rc.conf * Start daemon with "su -l" (allows "~" in config, fixes bug #243060) * Fix pkg-message PR: 256733 Reported by: thomas@beingboiled.info
This commit is contained in:
parent
2668279136
commit
059791e8b1
@ -1,9 +1,8 @@
|
||||
# Created by: Lewis Thompson <purple@lewiz.net>
|
||||
|
||||
PORTNAME= nzbget
|
||||
PORTVERSION= 21.0
|
||||
PORTVERSION= 21.1
|
||||
DISTVERSIONPREFIX= v
|
||||
PORTREVISION= 2
|
||||
CATEGORIES= news
|
||||
|
||||
MAINTAINER= ports@FreeBSD.org
|
||||
@ -13,9 +12,13 @@ LICENSE= GPLv2
|
||||
|
||||
LIB_DEPENDS= libxml2.so:textproc/libxml2
|
||||
|
||||
USES= autoreconf compiler:c++14-lang gmake localbase ncurses pkgconfig shebangfix ssl
|
||||
USES= autoreconf compiler:c++14-lang gmake localbase ncurses \
|
||||
pkgconfig python:build shebangfix ssl
|
||||
USE_GITHUB= yes
|
||||
USE_RC_SUBR= nzbget
|
||||
|
||||
SHEBANG_FILES= scripts/*.py
|
||||
|
||||
GNU_CONFIGURE= yes
|
||||
CONFIGURE_ARGS= --with-libcurses-includes=${NCURSESINC} \
|
||||
--with-libcurses-libraries=${NCURSESLIB} \
|
||||
@ -25,26 +28,12 @@ CONFIGURE_ARGS= --with-libcurses-includes=${NCURSESINC} \
|
||||
|
||||
BINMODE= 0755
|
||||
|
||||
SHEBANG_FILES= scripts/*.py
|
||||
SUB_FILES= pkg-message
|
||||
|
||||
USE_GITHUB= yes
|
||||
|
||||
OPTIONS_DEFINE= 7Z DOCS OPTIMIZED_FLAGS PYTHON RAR
|
||||
OPTIONS_DEFAULT= PAR PYTHON RAR 7Z
|
||||
7Z_DESC= Support extraction of 7z archives
|
||||
OPTIONS_DEFINE= DOCS OPTIMIZED_FLAGS
|
||||
OPTIMIZED_FLAGS_DESC= Enable optimized CPU instructions (SSE2/SSE3/NEON/etc)
|
||||
PYTHON_DESC= Support for python post-processing scripts
|
||||
RAR_DESC= Support extraction of rar archives
|
||||
|
||||
7Z_RUN_DEPENDS= 7z:archivers/p7zip
|
||||
|
||||
OPTIMIZED_FLAGS_EXTRA_PATCHES_OFF= ${FILESDIR}/extra-disable-optimized-flags.patch
|
||||
|
||||
PYTHON_USES= python:run
|
||||
|
||||
RAR_RUN_DEPENDS= unrar:archivers/unrar
|
||||
|
||||
.include <bsd.port.options.mk>
|
||||
|
||||
.if (${ARCH} == "i386")
|
||||
|
@ -1,3 +1,3 @@
|
||||
TIMESTAMP = 1559757041
|
||||
SHA256 (nzbget-nzbget-v21.0_GH0.tar.gz) = c7d3ece53f9bf958011b05404bf4063d74bd73fc8140a63c334e9e767eff6d50
|
||||
SIZE (nzbget-nzbget-v21.0_GH0.tar.gz) = 2011852
|
||||
TIMESTAMP = 1623584109
|
||||
SHA256 (nzbget-nzbget-v21.1_GH0.tar.gz) = 79695ea503447f13911a9fe58d0ef3e860b2ff5d6fdfd351186ee5fda1ae8bdb
|
||||
SIZE (nzbget-nzbget-v21.1_GH0.tar.gz) = 2011505
|
||||
|
@ -4,22 +4,34 @@
|
||||
# REQUIRE: LOGIN
|
||||
# KEYWORD: shutdown
|
||||
#
|
||||
# Add the following lines to /etc/rc.conf.local or /etc/rc.conf
|
||||
# to enable this service:
|
||||
# Add the following lines to /etc/rc.conf to enable the nzbget daemon:
|
||||
#
|
||||
# nzbget_enable (bool): Set to NO by default.
|
||||
# Set it to YES to enable it.
|
||||
# nzbget_enable="YES"
|
||||
#
|
||||
# Following additional settings are available:
|
||||
#
|
||||
# nzbget_user: user to run nzbget as (recommended)
|
||||
# nzbget_conf: path to config if in a non-standard location (optional)
|
||||
|
||||
command=%%PREFIX%%/bin/nzbget
|
||||
|
||||
. /etc/rc.subr
|
||||
|
||||
load_rc_config nzbget
|
||||
|
||||
nzbget_enable=${nzbget_enable:-NO}
|
||||
nzbget_user=${nzbget_user:-root}
|
||||
nzbget_conf=${nzbget_conf:+"-c $nzbget_conf"}
|
||||
|
||||
name=nzbget
|
||||
rcvar=nzbget_enable
|
||||
|
||||
load_rc_config ${name}
|
||||
start_cmd="nzbget_cmd -D"
|
||||
stop_cmd="nzbget_cmd -Q"
|
||||
reload_cmd="nzbget_cmd -O"
|
||||
|
||||
: ${nzbget_enable:=NO}
|
||||
|
||||
command=%%PREFIX%%/bin/nzbget
|
||||
command_args="-D"
|
||||
nzbget_cmd() {
|
||||
/usr/bin/su -l $nzbget_user -c "exec $command $nzbget_conf $1"
|
||||
}
|
||||
|
||||
run_rc_command "$1"
|
||||
|
@ -1,8 +1,8 @@
|
||||
[
|
||||
{ type: install
|
||||
message: <<EOM
|
||||
To run nzbget as an unprivileged user you can set the Daemonuser
|
||||
variable in %%LOCALBASE%%/etc/nzbget.conf
|
||||
Set "nzbget_user" in rc.conf or "DaemonUsername" in your nzbget config
|
||||
to run the nzbget daemon as an unprivileged user.
|
||||
EOM
|
||||
}
|
||||
]
|
||||
|
Loading…
Reference in New Issue
Block a user