mirror of
https://git.FreeBSD.org/ports.git
synced 2024-11-25 00:51:21 +00:00
- update to 0.3
- add a patch to have a cleaner rc script and make the port respect PREFIX PR: ports/156663 Submitted by: Jesse <jessefrgsmith _at_ yahoo.ca> (maintainer)
This commit is contained in:
parent
feab432e69
commit
2ae9169020
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=273248
@ -6,7 +6,7 @@
|
||||
#
|
||||
|
||||
PORTNAME= swapexd
|
||||
PORTVERSION= 0.1
|
||||
PORTVERSION= 0.3
|
||||
CATEGORIES= sysutils
|
||||
MASTER_SITES= http://makeapbi.sourceforge.net/${PORTNAME}/
|
||||
|
||||
@ -15,10 +15,15 @@ COMMENT= A tool for growing and shrinking on-disk swap space
|
||||
|
||||
WRKSRC= ${WRKDIR}/${PORTNAME}
|
||||
|
||||
PLIST_FILES= sbin/${PORTNAME} etc/${PORTNAME}.conf
|
||||
PLIST_FILES= sbin/${PORTNAME} etc/${PORTNAME}.conf etc/rc.d/swapexd
|
||||
|
||||
post-patch:
|
||||
@${REINPLACE_CMD} -e "s,%%PREFIX%%,${PREFIX},g" ${WRKSRC}/rc.d/swapexd
|
||||
@${REINPLACE_CMD} -e "s,/etc/,${PREFIX}/etc/,g" ${WRKSRC}/swapexd.h
|
||||
|
||||
do-install:
|
||||
${INSTALL_PROGRAM} ${WRKSRC}/${PORTNAME} ${PREFIX}/sbin/
|
||||
${INSTALL_DATA} ${WRKSRC}/${PORTNAME}.conf ${PREFIX}/etc/${PORTNAME}.conf
|
||||
${INSTALL_SCRIPT} ${WRKSRC}/rc.d/swapexd ${PREFIX}/etc/rc.d
|
||||
|
||||
.include <bsd.port.mk>
|
||||
|
@ -1,2 +1,2 @@
|
||||
SHA256 (swapexd-0.1.tar.gz) = e010703f2951e1f85f3f955d2001bdbe4476c47b9bb83d1172063e7895816b42
|
||||
SIZE (swapexd-0.1.tar.gz) = 7252
|
||||
SHA256 (swapexd-0.3.tar.gz) = 44fb12987dac7f855251f2ea06bbe427d6728873c01f71231f716e1dcfc71433
|
||||
SIZE (swapexd-0.3.tar.gz) = 7816
|
||||
|
46
sysutils/swapexd/files/patch-rc.d__swapexd
Normal file
46
sysutils/swapexd/files/patch-rc.d__swapexd
Normal file
@ -0,0 +1,46 @@
|
||||
--- ./rc.d/swapexd.orig 2011-04-26 18:37:13.000000000 +0200
|
||||
+++ ./rc.d/swapexd 2011-04-27 12:49:43.900653110 +0200
|
||||
@@ -7,37 +7,16 @@
|
||||
. /etc/rc.subr
|
||||
|
||||
name="swapexd"
|
||||
- rcvar=`set_rcvar`
|
||||
-
|
||||
-stop_cmd="swapexd_stop"
|
||||
-start_cmd="swapexd_start"
|
||||
-
|
||||
-load_rc_config $name
|
||||
+rcvar=`set_rcvar`
|
||||
|
||||
: ${swapexd_enable=NO}
|
||||
|
||||
-swapexd_start()
|
||||
-{
|
||||
- if [ -e "/var/run/swapexd.pid" ]
|
||||
- then
|
||||
- echo "swapexd already running?"
|
||||
- swapexd_stop
|
||||
- fi
|
||||
-
|
||||
- echo "Starting swapexd..."
|
||||
- (/usr/local/sbin/swapexd -d -p >/dev/null 2>/dev/null) &
|
||||
-}
|
||||
+procname="%%PREFIX%%/sbin/swapexd"
|
||||
+command="/usr/sbin/daemon"
|
||||
+pidfile="/var/run/swapexd.pid"
|
||||
+command_args="-f -p ${pidfile} ${procname} -d -p"
|
||||
|
||||
-swapexd_stop()
|
||||
-{
|
||||
- echo "Stoping swapexd..."
|
||||
- if [ -e "/var/run/swapexd.pid" ]
|
||||
- then
|
||||
- PID=`cat /var/run/swapexd.pid`
|
||||
- kill -9 $PID
|
||||
- rm /var/run/swapexd.pid
|
||||
- fi
|
||||
-}
|
||||
+load_rc_config $name
|
||||
|
||||
run_rc_command "$1"
|
||||
|
Loading…
Reference in New Issue
Block a user