1
0
mirror of https://git.FreeBSD.org/ports.git synced 2024-10-22 20:41:26 +00:00

Update to v0.21.0.

Other (minor) changes are listed below:

* Update additional patches also.
* Add new perl module dependency which POPFile newly 'use'ed.
* Add new runtime dependency option, WITH_POPFILE_UPGRADE_FROM_0_20.
	If you're using previous version of POPFile, you may want to make
	this port with WITH_POPFILE_UPGRADE_FROM_0_20=YES.
* Display compile-time option introduction.
* Introduce popfile.sh, per-user bases startup script.  Since v0.21.0
  supports multi-user, you don't have to have your _own_ copy of POPFile.
  setup-popfile.sh is also removed; it doesn't need anymore.
This commit is contained in:
Makoto Matsushita 2004-03-17 13:47:27 +00:00
parent a846bc3e65
commit 202756df9a
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=104289
6 changed files with 73 additions and 76 deletions

View File

@ -6,23 +6,23 @@
#
PORTNAME= popfile
PORTVERSION= 0.20.1
PORTREVISION= 1
PORTVERSION= 0.21.0
#PORTREVISION= 0
CATEGORIES= mail
MASTER_SITES= ${MASTER_SITE_SOURCEFORGE}:sf \
${MASTER_SITE_SOURCEFORGE_JP}:sfjp
MASTER_SITE_SUBDIR= ${PORTNAME}/:sf ${PORTNAME}/6747/:sfjp
DISTFILES= ${DISTNAME}${EXTRACT_SUFX}:sf \
${PORTNAME}_jpn.zip:sfjp
MASTER_SITES= ${MASTER_SITE_SOURCEFORGE}
MASTER_SITE_SUBDIR= ${PORTNAME}
DIST_SUBDIR= ${PORTNAME}
PATCH_SITES= http://home.jp.FreeBSD.org/~matusita/distfiles/
PATCHFILES= popfile-0.20.0rc5-apop.patch
PATCHFILES= popfile-0.21.0-apop.patch
MAINTAINER= matusita@FreeBSD.org
COMMENT=Automatic mail classification tool, acts as a POP3 proxy
RUN_DEPENDS= ${SITE_PERL}/${PERL_ARCH}/BerkeleyDB.pm:${PORTSDIR}/databases/p5-BerkeleyDB
# DBI module is also required but intentionally not listed here,
# since ports/databases/p5-DBD-SQLite knows which to be installed.
RUN_DEPENDS= ${SITE_PERL}/${PERL_ARCH}/DBD/SQLite.pm:${PORTSDIR}/databases/p5-DBD-SQLite \
${SITE_PERL}/HTML/Tagset.pm:${PORTSDIR}/www/p5-HTML-Tagset
NO_BUILD= yes
NO_WRKSUBDIR= yes
@ -31,35 +31,62 @@ USE_REINPLACE= yes
USE_ZIP= yes
USE_PERL5_RUN= yes
START_SCRIPTS_SUB= DATADIR=${DATADIR}
.include <bsd.port.pre.mk>
.if defined(WITH_JAPANESE)
.if defined(WITH_POPFILE_UPGRADE_FROM_0_20)
RUN_DEPENDS= ${SITE_PERL}/${PERL_ARCH}/BerkeleyDB.pm:${PORTSDIR}/databases/p5-BerkeleyDB
.endif
.if defined(WITH_POPFILE_JAPANESE)
RUN_DEPENDS+= ${SITE_PERL}/${PERL_ARCH}/Text/Kakasi.pm:${PORTSDIR}/japanese/p5-Text-Kakasi
.endif
.if ${PERL_LEVEL} < 500800
RUN_DEPENDS+= ${SITE_PERL}/${PERL_ARCH}/MIME/Base64.pm:${PORTSDIR}/converters/p5-MIME-Base64 \
${SITE_PERL}/${PERL_ARCH}/Digest/MD5.pm:${PORTSDIR}/security/p5-Digest-MD5
.if defined(WITH_JAPANESE)
.if defined(WITH_POPFILE_JAPANESE)
RUN_DEPENDS+= ${SITE_PERL}/jcode.pl:${PORTSDIR}/japanese/p5-jcode.pl
PATCHFILES+= popfile-0.20.1-use-jcode.pl.patch
PATCHFILES+= popfile-0.21.0-use-jcode.pl.patch
.endif
.endif
post-extract:
${INSTALL_SCRIPT} ${FILESDIR}/setup-popfile.sh ${WRKSRC}
${CP} ${WRKDIR}/0_20_1_1/POPFile/0.20.1/Classifier/Bayes.pm \
${WRKSRC}/Classifier/Bayes.pm
pre-fetch:
@${ECHO_CMD} "This port has some compile options:"
@${ECHO_CMD} ""
@${ECHO_CMD} " * make WITH_POPFILE_UPGRADE_FROM_0_20=YES"
@${ECHO_CMD} " Since v0.21.0, The corpus format Is changed from BerkeyDB to SQLite."
@${ECHO_CMD} " If you have old (v0.20.1 or before) corpus and want to use it with"
@${ECHO_CMD} " new POPFile, use this option. BerkeleyDB module will be installed"
@${ECHO_CMD} " and POPFile automatically convert from the old corpus to a new one."
@${ECHO_CMD} " Note that this is just for _upgrade_ time only; once you have"
@${ECHO_CMD} " converted your corpus or you are a new user since v0.21.0,"
@${ECHO_CMD} " you don't need this option next time."
@${ECHO_CMD} ""
@${ECHO_CMD} " * make WITH_POPFILE_JAPANESE=YES"
@${ECHO_CMD} " Even if POPFile supports Japanese help message, parsing Japanese"
@${ECHO_CMD} " email is enabled not by POPFile itself, but by KAKASI (Kanji Kana"
@${ECHO_CMD} " Simple Inverter.) If you need Japanese email support, use this"
@${ECHO_CMD} " option. KAKASI perl5 module is also installed."
.if ${PERL_LEVEL} < 500800
@${ECHO_CMD} " If you still using perl 5.6 or before, a hacky patch is also"
@${ECHO_CMD} " applied to POPFile itself, and install japanese/p5-jcode.pl."
.endif
@${ECHO_CMD} ""
@${ECHO_CMD} "Both option are just add runtime (perl) module dependency; you can"
@${ECHO_CMD} "install databases/p5-BerkeleyDB and japanese/p5-Text-Kakasi separately."
@${ECHO_CMD} ""
post-patch:
${REINPLACE_CMD} -e "s|__DATADIR__|${DATADIR}|" \
${WRKSRC}/setup-popfile.sh
${RM} -f ${WRKSRC}/setup-popfile.sh.bak
${CHMOD} +x ${WRKSRC}/popfile.pl
${FIND} ${PATCH_WRKSRC} -name '*.orig' -delete
do-install:
${MKDIR} ${DATADIR}
${CP} -R ${WRKSRC}/* ${DATADIR}
@${SED} ${START_SCRIPTS_SUB:S/$/!g/:S/^/ -e s!%%/:S/=/%%!/} \
${FILESDIR}/popfile.sh > ${WRKDIR}/popfile.sh
${INSTALL_SCRIPT} ${WRKDIR}/popfile.sh ${PREFIX}/sbin
.include <bsd.port.post.mk>

View File

@ -1,8 +1,6 @@
MD5 (popfile/popfile-0.20.1.zip) = f37bbd25aa81e98f3846389b26390062
SIZE (popfile/popfile-0.20.1.zip) = 1912427
MD5 (popfile/popfile_jpn.zip) = f821a1e8cd06ca987ff5db4dafe9a85f
SIZE (popfile/popfile_jpn.zip) = 44725
MD5 (popfile/popfile-0.20.0rc5-apop.patch) = c4e71f4d80ffd0210a9efdaa20dec6ef
SIZE (popfile/popfile-0.20.0rc5-apop.patch) = 7054
MD5 (popfile/popfile-0.20.1-use-jcode.pl.patch) = 544ccccaec1c386f2fa043d4c7460c04
SIZE (popfile/popfile-0.20.1-use-jcode.pl.patch) = 1148
MD5 (popfile/popfile-0.21.0.zip) = 4ed3a9409cc2cf6e85c38c75be19cc9e
SIZE (popfile/popfile-0.21.0.zip) = 1508915
MD5 (popfile/popfile-0.21.0-apop.patch) = cb7e61caf4237dd2bce4088a179d1da3
SIZE (popfile/popfile-0.21.0-apop.patch) = 7718
MD5 (popfile/popfile-0.21.0-use-jcode.pl.patch) = 34f4dccb788cb993608d6adcce10a5c6
SIZE (popfile/popfile-0.21.0-use-jcode.pl.patch) = 1826

View File

@ -0,0 +1,10 @@
#!/bin/sh
#
# $FreeBSD$
#
export POPFILE_ROOT=%%DATADIR%%
export POPFILE_USER=${HOME}/.popfile
mkdir -p ${POPFILE_USER}
cd ${POPFILE_USER}
%%DATADIR%%/popfile.pl >/dev/null 2>&1 &

View File

@ -1,31 +0,0 @@
#!/bin/sh
#
# setup-popfile.sh: a script for setup popfile instance
# $FreeBSD$
#
ask_noyes()
{
local key
echo -n "$1 [y/N]: "
read key
case "$key" in
[Yy]*)
return 0;;
*)
return 1;;
esac
}
echo "This script will 1) create 'popfile' directory and 2) setup 'popfile' directory for your popfile instance."
if ask_noyes "Are you ready?"; then
mkdir ./popfile
if [ -d ./popfile ]; then
cp -R __DATADIR__/* ./popfile
fi
echo "done."
else
echo "Stopped."
exit 1
fi

View File

@ -4,10 +4,11 @@ training. You can give it a simple job, like separating out junk e-mail, or
a complicated one -- like filing mail into a dozen folders. Think of it as a
personal assistant for your inbox.
Before using this ports, use ${LOCALDIR}/share/popfile/popfile-setup.sh
script to create _your_ own popfile instance.
Since v0.21.0, POPFile supports multiple user with a single instance.
Using ${LOCALDIR}/sbin/popfile.sh, you can start your own POPFile easily;
it uses ${HOME}/.popfile as a working directory.
For 'Nihongo' users: this ports also imports the bugfix of Japanese
character parsing, versioned as 0.20.1.1.
Note for old POPFile users: copy messages/ and corpus/ directory to
your ${HOME}/.popfile directory (if not, create it), then start popfile.sh.
WWW: http://popfile.sourceforge.net/

View File

@ -1,17 +1,14 @@
%%DATADIR%%/0_20_1_1/POPFile/0.20.0/Classifier/Bayes.pm
%%DATADIR%%/0_20_1_1/POPFile/0.20.1/Classifier/Bayes.pm
%%DATADIR%%/0_20_1_1/README_euc
%%DATADIR%%/0_20_1_1/README_sjis
%%DATADIR%%/0_20_1_1/license
%%DATADIR%%/0_20_1_1/popfile_jpn.nsi
sbin/popfile.sh
%%DATADIR%%/Classifier/Bayes.pm
%%DATADIR%%/Classifier/MailParse.pm
%%DATADIR%%/Classifier/WordMangle.pm
%%DATADIR%%/Classifier/popfile.sql
%%DATADIR%%/POPFile/Configuration.pm
%%DATADIR%%/POPFile/Loader.pm
%%DATADIR%%/POPFile/Logger.pm
%%DATADIR%%/POPFile/MQ.pm
%%DATADIR%%/POPFile/Module.pm
%%DATADIR%%/POPFile/popfile_version
%%DATADIR%%/Proxy/POP3.pm
%%DATADIR%%/Proxy/Proxy.pm
%%DATADIR%%/UI/HTML.pm
@ -20,6 +17,7 @@
%%DATADIR%%/black.gif
%%DATADIR%%/favicon.ico
%%DATADIR%%/insert.pl
%%DATADIR%%/languages/Arabic.msg
%%DATADIR%%/languages/Bulgarian.msg
%%DATADIR%%/languages/Chinese-Simplified.msg
%%DATADIR%%/languages/Chinese-Traditional.msg
@ -93,7 +91,6 @@
%%DATADIR%%/pipe.pl
%%DATADIR%%/pix.gif
%%DATADIR%%/popfile.pl
%%DATADIR%%/setup-popfile.sh
%%DATADIR%%/skins/CoolBlue.css
%%DATADIR%%/skins/CoolBrown.css
%%DATADIR%%/skins/CoolGreen.css
@ -104,6 +101,7 @@
%%DATADIR%%/skins/PRJBlueGrey.css
%%DATADIR%%/skins/PRJSteelBeach.css
%%DATADIR%%/skins/SimplyBlue.css
%%DATADIR%%/skins/Sleet-RTL.css
%%DATADIR%%/skins/Sleet.css
%%DATADIR%%/skins/StrawberryRose.css
%%DATADIR%%/skins/blue.css
@ -143,13 +141,7 @@
%%DATADIR%%/skins/white.css
%%DATADIR%%/skins/windows.css
%%DATADIR%%/stopwords
%%DATADIR%%/v0.20.1.change
@dirrm %%DATADIR%%/0_20_1_1/POPFile/0.20.0/Classifier
@dirrm %%DATADIR%%/0_20_1_1/POPFile/0.20.0
@dirrm %%DATADIR%%/0_20_1_1/POPFile/0.20.1/Classifier
@dirrm %%DATADIR%%/0_20_1_1/POPFile/0.20.1
@dirrm %%DATADIR%%/0_20_1_1/POPFile
@dirrm %%DATADIR%%/0_20_1_1
%%DATADIR%%/v0.21.0.change
@dirrm %%DATADIR%%/Classifier
@dirrm %%DATADIR%%/POPFile
@dirrm %%DATADIR%%/Proxy