aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMark Felder <feld@FreeBSD.org>2019-09-18 22:50:09 +0000
committerMark Felder <feld@FreeBSD.org>2019-09-18 22:50:09 +0000
commit0ea660908047d2e1516be0f7b8266a231668bed0 (patch)
tree1309393582964c3018a90cdcfce7549d583ff150
parent0d79c54a74bfaec38677384069d8226f246e176a (diff)
downloadports-0ea660908047d2e1516be0f7b8266a231668bed0.tar.gz
ports-0ea660908047d2e1516be0f7b8266a231668bed0.zip
Notes
-rw-r--r--net-p2p/Makefile1
-rw-r--r--net-p2p/sonarr-devel/Makefile47
-rw-r--r--net-p2p/sonarr-devel/distinfo3
-rw-r--r--net-p2p/sonarr-devel/files/sonarr.in45
-rw-r--r--net-p2p/sonarr-devel/pkg-descr3
5 files changed, 99 insertions, 0 deletions
diff --git a/net-p2p/Makefile b/net-p2p/Makefile
index 1359aa64ea8d..167863ed715d 100644
--- a/net-p2p/Makefile
+++ b/net-p2p/Makefile
@@ -78,6 +78,7 @@
SUBDIR += rtorrent
SUBDIR += shx
SUBDIR += sonarr
+ SUBDIR += sonarr-devel
SUBDIR += squall
SUBDIR += torrent-file-editor
SUBDIR += torrentcheck
diff --git a/net-p2p/sonarr-devel/Makefile b/net-p2p/sonarr-devel/Makefile
new file mode 100644
index 000000000000..63c78c581143
--- /dev/null
+++ b/net-p2p/sonarr-devel/Makefile
@@ -0,0 +1,47 @@
+# $FreeBSD$
+
+PORTNAME= sonarr
+PORTVERSION= 3.0.3.644
+PORTREVISION= 0
+CATEGORIES= net-p2p
+MASTER_SITES= http://download.sonarr.tv/v3/phantom-develop/${PORTVERSION}/
+PKGNAMESUFFIX= -devel
+DISTNAME= Sonarr.phantom-develop.${PORTVERSION}.linux
+
+MAINTAINER= feld@FreeBSD.org
+COMMENT= PVR for Usenet and BitTorrent users
+
+LICENSE= GPLv3
+
+RUN_DEPENDS= mono>4.6.1:lang/mono \
+ mediainfo>0:multimedia/mediainfo \
+ sqlite3>0:databases/sqlite3
+LIB_DEPENDS= libcurl.so:ftp/curl
+
+USE_RC_SUBR= sonarr
+
+NO_ARCH= YES
+NO_BUILD= YES
+WRKSRC= ${WRKDIR}/Sonarr
+
+USERS= sonarr
+GROUPS= sonarr
+
+OPTIONS_DEFINE= X11
+
+# Permits image resizing
+X11_LIB_DEPENDS+=libgdiplus.so:x11-toolkits/libgdiplus
+
+CONFLICTS= sonarr-2*
+
+.include <bsd.port.options.mk>
+
+do-install:
+ ${INSTALL} -d -m 755 ${STAGEDIR}/${DATADIR}
+ cd ${WRKSRC} && ${COPYTREE_SHARE} \* ${STAGEDIR}/${DATADIR}
+
+post-install:
+ @${FIND} -s ${STAGEDIR}${DATADIR} -not -type d | ${SORT} | \
+ ${SED} -e 's#^${STAGEDIR}${PREFIX}/##' >> ${TMPPLIST}
+
+.include <bsd.port.mk>
diff --git a/net-p2p/sonarr-devel/distinfo b/net-p2p/sonarr-devel/distinfo
new file mode 100644
index 000000000000..dbd7a8c5fc9c
--- /dev/null
+++ b/net-p2p/sonarr-devel/distinfo
@@ -0,0 +1,3 @@
+TIMESTAMP = 1568844081
+SHA256 (Sonarr.phantom-develop.3.0.3.644.linux.tar.gz) = e2baed5e3ec1c1804813a173313101c9fabb4921da09aa42ca0197ff371246d4
+SIZE (Sonarr.phantom-develop.3.0.3.644.linux.tar.gz) = 10146222
diff --git a/net-p2p/sonarr-devel/files/sonarr.in b/net-p2p/sonarr-devel/files/sonarr.in
new file mode 100644
index 000000000000..95778eb19fcb
--- /dev/null
+++ b/net-p2p/sonarr-devel/files/sonarr.in
@@ -0,0 +1,45 @@
+#!/bin/sh
+#
+# Author: Mark Felder <feld@FreeBSD.org>
+#
+# $FreeBSD$
+#
+
+# PROVIDE: sonarr
+# REQUIRE: LOGIN
+# KEYWORD: shutdown
+
+# Add the following lines to /etc/rc.conf to enable sonarr:
+# sonarr_enable="YES"
+
+. /etc/rc.subr
+
+name="sonarr"
+rcvar=sonarr_enable
+
+load_rc_config $name
+
+: ${sonarr_enable="NO"}
+: ${sonarr_user:="sonarr"}
+: ${sonarr_data_dir:="%%PREFIX%%/sonarr"}
+
+pidfile="${sonarr_data_dir}/sonarr.pid"
+procname="%%PREFIX%%/bin/mono"
+command="/usr/sbin/daemon"
+command_args="-f ${procname} %%DATADIR%%/Sonarr.exe --nobrowser --data=${sonarr_data_dir}"
+start_precmd=sonarr_precmd
+
+sonarr_precmd()
+{
+ export XDG_CONFIG_HOME=${sonarr_data_dir}
+
+ if [ ! -d ${sonarr_data_dir} ]; then
+ install -d -o ${sonarr_user} ${sonarr_data_dir}
+ fi
+
+ # Unwritable pids allow the service to start, but fails to work
+ # Rare, but if you are debugging as root and accidentally start the service...
+ /bin/rm -f ${pidfile}
+}
+
+run_rc_command "$1"
diff --git a/net-p2p/sonarr-devel/pkg-descr b/net-p2p/sonarr-devel/pkg-descr
new file mode 100644
index 000000000000..6741d5b2e77d
--- /dev/null
+++ b/net-p2p/sonarr-devel/pkg-descr
@@ -0,0 +1,3 @@
+Sonarr is a PVR for Usenet and BitTorrent users.
+
+WWW: https://sonarr.tv