diff options
-rw-r--r-- | net-p2p/sonarr/Makefile | 3 | ||||
-rw-r--r-- | net-p2p/sonarr/files/sonarr.in | 11 | ||||
-rw-r--r-- | net-p2p/sonarr/pkg-plist | 1 |
3 files changed, 11 insertions, 4 deletions
diff --git a/net-p2p/sonarr/Makefile b/net-p2p/sonarr/Makefile index 0a12d182b75e..56aa96837436 100644 --- a/net-p2p/sonarr/Makefile +++ b/net-p2p/sonarr/Makefile @@ -2,7 +2,7 @@ PORTNAME= sonarr PORTVERSION= 2.0.0.3645 -PORTREVISION= 2 +PORTREVISION= 3 CATEGORIES= net-p2p MASTER_SITES= http://download.sonarr.tv/v2/master/mono/ DISTNAME= NzbDrone.master.${PORTVERSION}.mono @@ -27,6 +27,5 @@ USERS= sonarr do-install: ${INSTALL} -d -m 755 ${STAGEDIR}/${DATADIR} cd ${WRKSRC} && ${COPYTREE_SHARE} \* ${STAGEDIR}/${DATADIR} - ${MKDIR} ${STAGEDIR}/${PREFIX}/sonarr .include <bsd.port.mk> diff --git a/net-p2p/sonarr/files/sonarr.in b/net-p2p/sonarr/files/sonarr.in index 9e775cc61c63..29ea352d6d72 100644 --- a/net-p2p/sonarr/files/sonarr.in +++ b/net-p2p/sonarr/files/sonarr.in @@ -27,6 +27,15 @@ pidfile="${sonarr_data_dir}/nzbdrone.pid" procname="%%PREFIX%%/bin/mono" command="/usr/sbin/daemon" command_args="-f ${procname} %%DATADIR%%/NzbDrone.exe --nobrowser --data=${sonarr_data_dir}" -start_precmd="export XDG_CONFIG_HOME=${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 +} run_rc_command "$1" diff --git a/net-p2p/sonarr/pkg-plist b/net-p2p/sonarr/pkg-plist index ff243f675122..2871b43a96bd 100644 --- a/net-p2p/sonarr/pkg-plist +++ b/net-p2p/sonarr/pkg-plist @@ -148,4 +148,3 @@ %%DATADIR%%/UI/templates.js %%DATADIR%%/UI/vendor.js %%DATADIR%%/UI/vendor.map -@dir(sonarr,wheel,755) sonarr |