mirror of
https://git.FreeBSD.org/ports.git
synced 2024-12-25 04:43:33 +00:00
- Better use of rc_subr framework
- Updated startup script - Fixed pkg-plist PR: ports/94802 Submitted by: Freddie Cash <fcash@sd73.bc.ca> (maintainer)
This commit is contained in:
parent
f0df633c49
commit
4a2fb110ae
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=159114
@ -7,7 +7,7 @@
|
|||||||
|
|
||||||
PORTNAME= dansguardian
|
PORTNAME= dansguardian
|
||||||
PORTVERSION= 2.8.0.6
|
PORTVERSION= 2.8.0.6
|
||||||
PORTREVISION= 1
|
PORTREVISION= 2
|
||||||
CATEGORIES= www
|
CATEGORIES= www
|
||||||
MASTER_SITES= # empty, see below
|
MASTER_SITES= # empty, see below
|
||||||
DISTNAME= ${PORTNAME}-${PORTVERSION}.source
|
DISTNAME= ${PORTNAME}-${PORTVERSION}.source
|
||||||
@ -17,8 +17,7 @@ COMMENT= A fast, feature-rich web content filter for Squid proxy servers
|
|||||||
|
|
||||||
RUN_DEPENDS= ${LOCALBASE}/sbin/squid:${PORTSDIR}/www/squid
|
RUN_DEPENDS= ${LOCALBASE}/sbin/squid:${PORTSDIR}/www/squid
|
||||||
|
|
||||||
USE_RC_SUBR= yes
|
USE_RC_SUBR= dansguardian.sh
|
||||||
RC_SCRIPTS_SUB= PREFIX=${PREFIX} RC_SUBR=${RC_SUBR}
|
|
||||||
|
|
||||||
CONFLICTS= dansguardian-2.[67]*
|
CONFLICTS= dansguardian-2.[67]*
|
||||||
LATEST_LINK= dansguardian
|
LATEST_LINK= dansguardian
|
||||||
@ -36,15 +35,15 @@ CONFIGURE_ARGS= --bindir=/sbin/ \
|
|||||||
MAN8= dansguardian.8
|
MAN8= dansguardian.8
|
||||||
NOMANCOMPRESSED= yes
|
NOMANCOMPRESSED= yes
|
||||||
|
|
||||||
OPTIONS= DG_APACHE "Enable Apache support." on \
|
OPTIONS= DG_APACHE "Enable Apache support for access denied page" on \
|
||||||
DG_PHRASELISTS "Install new phraselists over the old ones." off
|
DG_PHRASELISTS "Install new phraselists over the old ones." off
|
||||||
|
|
||||||
DG_URL= http://dansguardian.org/index.php?page=copyright2
|
DG_URL= http://dansguardian.org/index.php?page=copyright2
|
||||||
CONFDIR= ${PREFIX}/etc/dansguardian
|
CONFDIR= ${PREFIX}/etc/dansguardian
|
||||||
|
|
||||||
NO_CDROM= "Commercial download is restricted. Check ${DG_URL} for more info"
|
NO_CDROM= Commercial download is restricted. Check ${DG_URL} for more info
|
||||||
NO_PACKAGE= "Redistribution is restricted. Check ${DG_URL} for more info"
|
NO_PACKAGE= Redistribution is restricted. Check ${DG_URL} for more info
|
||||||
RESTRICTED= "${NO_PACKAGE}"
|
RESTRICTED= ${NO_PACKAGE}
|
||||||
|
|
||||||
.include <bsd.port.pre.mk>
|
.include <bsd.port.pre.mk>
|
||||||
|
|
||||||
@ -64,10 +63,6 @@ USE_APACHE= 1.3+
|
|||||||
IGNORE="Commercial source download is restricted. Please visit and read ${DG_URL} and download ${DISTNAME}${EXTRACT_SUFX} into ${DISTDIR} before running make"
|
IGNORE="Commercial source download is restricted. Please visit and read ${DG_URL} and download ${DISTNAME}${EXTRACT_SUFX} into ${DISTDIR} before running make"
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
post-extract:
|
|
||||||
@${SED} ${RC_SCRIPTS_SUB:S/$/!g/:S/^/ -e s!%%/:S/=/%%!/} \
|
|
||||||
${FILESDIR}/dansguardian.sh > ${WRKSRC}/dansguardian.sh
|
|
||||||
|
|
||||||
pre-install:
|
pre-install:
|
||||||
# Configure pkg-plist based on whether phraselists are to be installed or not
|
# Configure pkg-plist based on whether phraselists are to be installed or not
|
||||||
.if defined(WITH_DG_PHRASELISTS)
|
.if defined(WITH_DG_PHRASELISTS)
|
||||||
@ -86,8 +81,8 @@ post-install:
|
|||||||
.endif
|
.endif
|
||||||
|
|
||||||
# Install startup script
|
# Install startup script
|
||||||
@${ECHO_MSG} "===> Installing startup script into ${PREFIX}/etc/rc.d"
|
# @${ECHO_MSG} "===> Installing startup script into ${PREFIX}/etc/rc.d"
|
||||||
@${INSTALL_SCRIPT} ${WRKSRC}/dansguardian.sh ${PREFIX}/etc/rc.d/start-dg.sh
|
# @${INSTALL_SCRIPT} ${WRKSRC}/dansguardian.sh ${PREFIX}/etc/rc.d/start-dg.sh
|
||||||
|
|
||||||
# Display post-install message
|
# Display post-install message
|
||||||
@${CAT} pkg-message
|
@${CAT} pkg-message
|
||||||
|
@ -2,9 +2,9 @@
|
|||||||
# $FreeBSD$
|
# $FreeBSD$
|
||||||
|
|
||||||
# PROVIDE: dansguardian
|
# PROVIDE: dansguardian
|
||||||
# REQUIRE: DAEMON squid
|
# REQUIRE: NETWORKING SERVERS squid
|
||||||
# BEFORE: LOGIN
|
# BEFORE: DAEMON
|
||||||
# KEYWORD: shutdown
|
# KEYWORD: FreeBSD shutdown
|
||||||
|
|
||||||
# Define these dansguardian_* variables in one of these files:
|
# Define these dansguardian_* variables in one of these files:
|
||||||
# /etc/rc.conf
|
# /etc/rc.conf
|
||||||
@ -13,9 +13,9 @@
|
|||||||
#
|
#
|
||||||
# DO NOT CHANGE THESE DEFAULT VALUES HERE
|
# DO NOT CHANGE THESE DEFAULT VALUES HERE
|
||||||
#
|
#
|
||||||
dansguardian_enable=${dansguardian_enable-"NO"}
|
dansguardian_enable=${dansguardian_enable:-"NO"}
|
||||||
dansguardian_flags=${dansguardian_flags-""}
|
dansguardian_flags=${dansguardian_flags:-""}
|
||||||
dansguardian_pidfile=${dansguardian_pidfile-"/var/run/dansguardian.pid"}
|
dansguardian_pidfile=${dansguardian_pidfile:-"/var/run/dansguardian.pid"}
|
||||||
|
|
||||||
. %%RC_SUBR%%
|
. %%RC_SUBR%%
|
||||||
|
|
@ -1,10 +1,15 @@
|
|||||||
===> Please Note:
|
===> Please Note:
|
||||||
|
|
||||||
*******************************************************************************
|
*******************************************************************************
|
||||||
This port has placed a log file in /var/log/ named dansguardian.log
|
All initial config files have been placed under a samples/ directory.
|
||||||
This log file can get quite large. Please read the newsyslog(8) man
|
You will need to copy these files into the config directory before
|
||||||
page for instructions on setting up log rotation and compression.
|
running DansGuardian for the first time.
|
||||||
|
|
||||||
WARNING: This port uses RCng. Please read the comments in the startup
|
This port has created a log file named dansguardian.log that can get
|
||||||
script for instructions on enabling the daemon.
|
quite large. Please read the newsyslog(8) man page for instructions
|
||||||
|
on setting up log rotation and compression.
|
||||||
|
|
||||||
|
This port hasa been converted to the new RC framework and should work
|
||||||
|
correctly via rcorder. Please read the comments in the startup script
|
||||||
|
for instructions on enabling the daemon.
|
||||||
*******************************************************************************
|
*******************************************************************************
|
||||||
|
@ -8,7 +8,6 @@
|
|||||||
@exec mkdir -p etc/dansguardian/languages/danish
|
@exec mkdir -p etc/dansguardian/languages/danish
|
||||||
@exec mkdir -p etc/dansguardian/languages/french
|
@exec mkdir -p etc/dansguardian/languages/french
|
||||||
@exec mkdir -p etc/dansguardian/languages/german
|
@exec mkdir -p etc/dansguardian/languages/german
|
||||||
@exec mkdir -p etc/dansguardian/languages/german2
|
|
||||||
@exec mkdir -p etc/dansguardian/languages/hebrew
|
@exec mkdir -p etc/dansguardian/languages/hebrew
|
||||||
@exec mkdir -p etc/dansguardian/languages/indonesian
|
@exec mkdir -p etc/dansguardian/languages/indonesian
|
||||||
@exec mkdir -p etc/dansguardian/languages/italian
|
@exec mkdir -p etc/dansguardian/languages/italian
|
||||||
@ -16,6 +15,9 @@
|
|||||||
@exec mkdir -p etc/dansguardian/languages/mxspanish
|
@exec mkdir -p etc/dansguardian/languages/mxspanish
|
||||||
@exec mkdir -p etc/dansguardian/languages/polish
|
@exec mkdir -p etc/dansguardian/languages/polish
|
||||||
@exec mkdir -p etc/dansguardian/languages/portuguese
|
@exec mkdir -p etc/dansguardian/languages/portuguese
|
||||||
|
@exec mkdir -p etc/dansguardian/languages/russian-1251
|
||||||
|
@exec mkdir -p etc/dansguardian/languages/slovak
|
||||||
|
@exec mkdir -p etc/dansguardian/languages/spanish
|
||||||
@exec mkdir -p etc/dansguardian/languages/swedish
|
@exec mkdir -p etc/dansguardian/languages/swedish
|
||||||
@exec mkdir -p etc/dansguardian/languages/turkish
|
@exec mkdir -p etc/dansguardian/languages/turkish
|
||||||
@exec mkdir -p etc/dansguardian/languages/ukenglish
|
@exec mkdir -p etc/dansguardian/languages/ukenglish
|
||||||
@ -82,8 +84,6 @@ etc/dansguardian/languages/french/messages
|
|||||||
etc/dansguardian/languages/french/template.html
|
etc/dansguardian/languages/french/template.html
|
||||||
etc/dansguardian/languages/german/messages
|
etc/dansguardian/languages/german/messages
|
||||||
etc/dansguardian/languages/german/template.html
|
etc/dansguardian/languages/german/template.html
|
||||||
etc/dansguardian/languages/german2/messages
|
|
||||||
etc/dansguardian/languages/german2/template.html
|
|
||||||
etc/dansguardian/languages/hebrew/messages
|
etc/dansguardian/languages/hebrew/messages
|
||||||
etc/dansguardian/languages/hebrew/template.html
|
etc/dansguardian/languages/hebrew/template.html
|
||||||
etc/dansguardian/languages/indonesian/messages
|
etc/dansguardian/languages/indonesian/messages
|
||||||
@ -97,6 +97,7 @@ etc/dansguardian/languages/mxspanish/template.html
|
|||||||
etc/dansguardian/languages/polish/messages
|
etc/dansguardian/languages/polish/messages
|
||||||
etc/dansguardian/languages/polish/template.html
|
etc/dansguardian/languages/polish/template.html
|
||||||
etc/dansguardian/languages/portuguese/messages
|
etc/dansguardian/languages/portuguese/messages
|
||||||
|
etc/dansguardian/languages/portuguese/messagesaccents
|
||||||
etc/dansguardian/languages/portuguese/template.html
|
etc/dansguardian/languages/portuguese/template.html
|
||||||
etc/dansguardian/languages/swedish/messages
|
etc/dansguardian/languages/swedish/messages
|
||||||
etc/dansguardian/languages/swedish/template.html
|
etc/dansguardian/languages/swedish/template.html
|
||||||
@ -104,6 +105,12 @@ etc/dansguardian/languages/turkish/messages
|
|||||||
etc/dansguardian/languages/turkish/template.html
|
etc/dansguardian/languages/turkish/template.html
|
||||||
etc/dansguardian/languages/ukenglish/messages
|
etc/dansguardian/languages/ukenglish/messages
|
||||||
etc/dansguardian/languages/ukenglish/template.html
|
etc/dansguardian/languages/ukenglish/template.html
|
||||||
|
etc/dansguardian/languages/spanish/messages
|
||||||
|
etc/dansguardian/languages/spanish/template.html
|
||||||
|
etc/dansguardian/languages/slovak/messages
|
||||||
|
etc/dansguardian/languages/slovak/template.html
|
||||||
|
etc/dansguardian/languages/russian-1251/messages
|
||||||
|
etc/dansguardian/languages/russian-1251/template.html
|
||||||
%%PHRASELISTS%%etc/dansguardian/phraselists/chat/weighted
|
%%PHRASELISTS%%etc/dansguardian/phraselists/chat/weighted
|
||||||
%%PHRASELISTS%%etc/dansguardian/phraselists/drugadvocacy/weighted
|
%%PHRASELISTS%%etc/dansguardian/phraselists/drugadvocacy/weighted
|
||||||
%%PHRASELISTS%%etc/dansguardian/phraselists/dutchbadwords/weighted
|
%%PHRASELISTS%%etc/dansguardian/phraselists/dutchbadwords/weighted
|
||||||
@ -127,7 +134,6 @@ etc/dansguardian/languages/ukenglish/template.html
|
|||||||
%%PHRASELISTS%%etc/dansguardian/phraselists/violence/weighted
|
%%PHRASELISTS%%etc/dansguardian/phraselists/violence/weighted
|
||||||
%%PHRASELISTS%%etc/dansguardian/phraselists/warezhacking/weighted
|
%%PHRASELISTS%%etc/dansguardian/phraselists/warezhacking/weighted
|
||||||
%%PHRASELISTS%%etc/dansguardian/phraselists/weapons/weighted
|
%%PHRASELISTS%%etc/dansguardian/phraselists/weapons/weighted
|
||||||
etc/rc.d/start-dg.sh
|
|
||||||
sbin/dansguardian
|
sbin/dansguardian
|
||||||
@dirrm etc/dansguardian/languages/arspanish
|
@dirrm etc/dansguardian/languages/arspanish
|
||||||
@dirrm etc/dansguardian/languages/bulgarian
|
@dirrm etc/dansguardian/languages/bulgarian
|
||||||
@ -138,7 +144,6 @@ sbin/dansguardian
|
|||||||
@dirrm etc/dansguardian/languages/dutch
|
@dirrm etc/dansguardian/languages/dutch
|
||||||
@dirrm etc/dansguardian/languages/french
|
@dirrm etc/dansguardian/languages/french
|
||||||
@dirrm etc/dansguardian/languages/german
|
@dirrm etc/dansguardian/languages/german
|
||||||
@dirrm etc/dansguardian/languages/german2
|
|
||||||
@dirrm etc/dansguardian/languages/hebrew
|
@dirrm etc/dansguardian/languages/hebrew
|
||||||
@dirrm etc/dansguardian/languages/indonesian
|
@dirrm etc/dansguardian/languages/indonesian
|
||||||
@dirrm etc/dansguardian/languages/italian
|
@dirrm etc/dansguardian/languages/italian
|
||||||
@ -146,6 +151,9 @@ sbin/dansguardian
|
|||||||
@dirrm etc/dansguardian/languages/mxspanish
|
@dirrm etc/dansguardian/languages/mxspanish
|
||||||
@dirrm etc/dansguardian/languages/polish
|
@dirrm etc/dansguardian/languages/polish
|
||||||
@dirrm etc/dansguardian/languages/portuguese
|
@dirrm etc/dansguardian/languages/portuguese
|
||||||
|
@dirrm etc/dansguardian/languages/russian-1251
|
||||||
|
@dirrm etc/dansguardian/languages/slovak
|
||||||
|
@dirrm etc/dansguardian/languages/spanish
|
||||||
@dirrm etc/dansguardian/languages/swedish
|
@dirrm etc/dansguardian/languages/swedish
|
||||||
@dirrm etc/dansguardian/languages/turkish
|
@dirrm etc/dansguardian/languages/turkish
|
||||||
@dirrm etc/dansguardian/languages/ukenglish
|
@dirrm etc/dansguardian/languages/ukenglish
|
||||||
|
Loading…
Reference in New Issue
Block a user