1
0
mirror of https://git.FreeBSD.org/ports.git synced 2025-01-03 06:04:53 +00:00

Update to 2.82

Remove incredibly naive pkg-deinstall script, and do general cleaning up

Reminded by:	Stefan Bethke <stb@lassitu.de>
Feature safe:	yes
This commit is contained in:
Chris Rees 2013-04-16 18:54:41 +00:00
parent 44232e67f3
commit 8923042431
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=315885
4 changed files with 26 additions and 102 deletions

View File

@ -1,16 +1,10 @@
# Ports collection Makefile for: get_iplayer
# Date created: 2nd March 2011
# Whom: Chris Rees <utisoft@gmail.com>
#
# $FreeBSD$
#
PORTNAME= get_iplayer
PORTVERSION= 2.80
PORTVERSION= 2.82
CATEGORIES= net multimedia
MASTER_SITES= ftp://ftp.infradead.org/pub/${PORTNAME}/ \
http://www.bayofrum.net/dist/${PORTNAME}/
PKGNAMEPREFIX= uk-
MAINTAINER= crees@FreeBSD.org
COMMENT= Search, index, or stream archive video from BBC iPlayer
@ -22,25 +16,21 @@ NO_BUILD= yes
USE_RC_SUBR= ${PORTNAME}
USERS = get_iplayer
GROUPS = get_iplayer
USERS= get_iplayer
GROUPS= get_iplayer
MAN1= get_iplayer.1
MAN1= get_iplayer.1
SCRIPTS= ${PORTNAME} ${PORTNAME}.cgi
PLIST_FILES= bin/${PORTNAME} ${SCRIPTS:C,^,${WWWDIR_REL}/,}
PLIST_FILES= bin/${PORTNAME} ${SCRIPTS:S,^,${WWWDIR_REL}/,}
.if !defined(NOPORTDATA)
DATADIR= ${WWWDIR}
PORTDATA= html plugins
.else
PLIST_DIRS= ${WWWDIR_REL}
.endif
.if !defined(NOPORTDOCS)
PORTDOCS= CHANGELOG-get_iplayer.cgi.txt CHANGELOG.txt \
README-get_iplayer.cgi.txt README.txt web.sh
.endif
.include <bsd.port.options.mk>
post-patch:
${REINPLACE_CMD} -e "s|/usr/bin/get_iplayer|${PREFIX}/bin/${PORTNAME}|" \
@ -51,18 +41,16 @@ post-patch:
${WRKSRC}/get_iplayer
do-install:
@${MKDIR} ${WWWDIR}
@(cd ${WRKSRC}; ${INSTALL_SCRIPT} ${SCRIPTS} ${WWWDIR})
@${LN} -sf ${WWWDIR}/${PORTNAME} ${PREFIX}/bin/${PORTNAME}
@${INSTALL_MAN} ${WRKSRC}/${PORTNAME}.1 ${MAN1PREFIX}/man/man1
.if !defined(NOPORTDATA)
${MKDIR} ${WWWDIR}
(cd ${WRKSRC}; ${INSTALL_SCRIPT} ${SCRIPTS} ${WWWDIR})
${LN} -sf ${WWWDIR}/${PORTNAME} ${PREFIX}/bin/${PORTNAME}
${INSTALL_MAN} ${WRKSRC}/${PORTNAME}.1 ${MAN1PREFIX}/man/man1
.for DIR in html plugins
@(cd ${WRKSRC} && ${COPYTREE_SHARE} ${DIR} ${WWWDIR})
(cd ${WRKSRC} && ${COPYTREE_SHARE} ${DIR} ${WWWDIR})
.endfor
.endif
.if !defined(NOPORTDOCS)
@${MKDIR} ${DOCSDIR}
@(cd ${WRKSRC}; ${INSTALL_DATA} ${PORTDOCS} ${DOCSDIR})
.if ${PORT_OPTIONS:MDOCS}
${MKDIR} ${DOCSDIR}
(cd ${WRKSRC}; ${INSTALL_DATA} ${PORTDOCS} ${DOCSDIR})
.endif
post-install:

View File

@ -1,2 +1,2 @@
SHA256 (get_iplayer-2.80.tar.gz) = c849afec269e7be3e9cd8ce73b54f79bc398ae1d584c07c35e43b1ef7d6ecac2
SIZE (get_iplayer-2.80.tar.gz) = 230377
SHA256 (get_iplayer-2.82.tar.gz) = d5841aa402f3856fb3b4b290a3bb6d68447143dd8bc3e4a911a546e876b7bd27
SIZE (get_iplayer-2.82.tar.gz) = 248177

View File

@ -27,26 +27,21 @@
. /etc/rc.subr
name="get_iplayer"
name=get_iplayer
rcvar=get_iplayer_enable
load_rc_config $name
: ${get_iplayer_enable="NO"}
: ${get_iplayer_bind_port="9370"}
: ${get_iplayer_listen_address="127.0.0.1"}
: ${get_iplayer_chdir="/tmp"}
: ${get_iplayer_enable:=NO}
: ${get_iplayer_bind_port=9370}
: ${get_iplayer_listen_address=127.0.0.1}
: ${get_iplayer_chdir=/tmp}
command="/usr/sbin/daemon"
command=/usr/sbin/daemon
command_args="-f -u ${name} -p /var/run/${name}/${name}.pid %%WWWDIR%%/${name}.cgi -p ${get_iplayer_bind_port} -l ${get_iplayer_listen_address} --getiplayer %%WWWDIR%%/${name}"
procname="/usr/bin/perl"
pidfile="/var/run/${name}/${name}.pid"
procname=/usr/bin/perl
pidfile=/var/run/${name}/${name}.pid
start_precmd="${name}_prestart"
get_iplayer_prestart()
{
install -d -o ${name} -m755 /var/run/${name}
}
start_precmd="install -d -o ${name} -m755 /var/run/${name}"
run_rc_command "$1"

View File

@ -1,59 +0,0 @@
#! /bin/sh
#
# taken from net/cvsup-mirror
PATH=/bin:/usr/sbin
ask() {
local question default answer
question=$1
default=$2
if [ -z "${PACKAGE_BUILDING}" -a -z "${BATCH}" ]; then
read -p "${question} [${default}]? " answer
fi
if [ x${answer} = x ]; then
answer=${default}
fi
echo ${answer}
}
yesno() {
local dflt question answer
question=$1
dflt=$2
while :; do
answer=$(ask "${question}" "${dflt}")
case "${answer}" in
[Yy]*) return 0;;
[Nn]*) return 1;;
esac
echo "Please answer yes or no."
done
}
delete_account() {
local u g home
u=$1
g=$2
if yesno "Do you want me to remove group \"${g}\"" y; then
pw groupdel -n ${g}
echo "Done."
fi
if yesno "Do you want me to remove user \"${u}\"" y; then
eval home=~${u}
pw userdel -n ${u}
echo "Done."
if [ -d "${home}" ]; then
echo "Please remember to remove the home directory \"${home}\""
fi
fi
}
if [ x$2 != xDEINSTALL ]; then
exit
fi
delete_account get_iplayer get_iplayer