1
0
mirror of https://git.FreeBSD.org/ports.git synced 2025-01-30 10:38:37 +00:00

- fully utilize USE_RC_SUBR

itectu@: no more .sh
  dougb@: move load_config above variables checks
- Bump PORTREVISION

PR:             ports/125623
Approved by:    maintainer, gabor (mentor)
This commit is contained in:
Philip M. Gollucci 2008-07-31 16:12:03 +00:00
parent b08d7ca641
commit 18f529ff22
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=217882
2 changed files with 6 additions and 12 deletions

View File

@ -7,6 +7,7 @@
PORTNAME= autocd
PORTVERSION= 3.02.12b
PORTREVISION= 1
CATEGORIES= audio sysutils
MASTER_SITES= ftp://kot.spb.ru/pub/src/projects/autocd/
@ -21,16 +22,9 @@ MLINKS= cdctl.1 eject.1 cdctl.1 pause.1
PLIST_FILES= sbin/autocd bin/acdplay bin/cdctl bin/pause bin/eject
PORTDOCS= README.rus.html
USE_RC_SUBR= yes
RC_SUFX= .sh
SED_SCRIPT+= -e '{ s,%%PREFIX%%,${PREFIX},g; s,%%RC_SUBR%%,${RC_SUBR},g; }'
PLIST_FILES+= etc/rc.d/autocd${RC_SUFX}
post-build:
@${SED} ${SED_SCRIPT} ${FILESDIR}/autocd.sh >${WRKDIR}/autocd.sh
USE_RC_SUBR= autocd
post-install:
${INSTALL_SCRIPT} ${WRKDIR}/autocd.sh ${PREFIX}/etc/rc.d/autocd${RC_SUFX}
.if !defined(NOPORTDOCS)
${MKDIR} ${DOCSDIR}
${INSTALL_DATA} ${WRKSRC}/${PORTDOCS} ${DOCSDIR}

View File

@ -30,9 +30,9 @@ stop_cmd()
%%PREFIX%%/bin/cdctl die
}
# set defaults
autocd_enable=${autocd_enable:-"NO"}
autocd_flags=${autocd_flags:-""}
load_rc_config $name
# set defaults
autocd_flags=${autocd_flags-""}
run_rc_command "$1"