import imapfilter
IMAPFilter is a mail filtering utility. It connects to remote mail servers using the Internet Message Access Protocol (IMAP), sends searching queries to the server and processes mailboxes based on the results. It can be used to delete, copy, move, flag, etc. messages residing in mailboxes at the same or different mail servers. The 4rev1 and 4 versions of the IMAP protocol are supported. IMAPFilter uses the Lua programming language as a configuration and extension language. feedback & ok kili@
This commit is contained in:
parent
fcf6c86cf3
commit
e93cf5a7e3
40
mail/imapfilter/Makefile
Normal file
40
mail/imapfilter/Makefile
Normal file
@ -0,0 +1,40 @@
|
||||
# $OpenBSD: Makefile,v 1.1.1.1 2007/09/02 18:35:22 simon Exp $
|
||||
|
||||
COMMENT= remote IMAP filtering utility
|
||||
|
||||
DISTNAME= imapfilter-2.0.3
|
||||
CATEGORIES= mail
|
||||
|
||||
HOMEPAGE= http://imapfilter.hellug.gr/
|
||||
|
||||
MASTER_SITES= ${HOMEPAGE}source/
|
||||
|
||||
MAINTAINER= Simon Bertrang <simon@openbsd.org>
|
||||
|
||||
# MIT/X
|
||||
PERMIT_PACKAGE_CDROM= Yes
|
||||
PERMIT_PACKAGE_FTP= Yes
|
||||
PERMIT_DISTFILES_CDROM= Yes
|
||||
PERMIT_DISTFILES_FTP= Yes
|
||||
WANTLIB= c crypto m ssl
|
||||
|
||||
LIB_DEPENDS= pcre::devel/pcre \
|
||||
lua::lang/lua
|
||||
|
||||
CONFIGURE_STYLE=simple
|
||||
CONFIGURE_ARGS= -d ${WRKINST} \
|
||||
-p ${LOCALBASE} \
|
||||
-b ${LOCALBASE}/bin \
|
||||
-s ${LOCALBASE}/share/imapfilter \
|
||||
-m ${LOCALBASE}/man \
|
||||
-o ssltls=yes -o crammd5=yes
|
||||
MAKE_ENV+= CC="${CC}"
|
||||
|
||||
NO_REGRESS= Yes
|
||||
|
||||
post-install:
|
||||
${INSTALL_DATA_DIR} ${PREFIX}/share/examples/imapfilter
|
||||
${INSTALL_DATA} ${WRKSRC}/sample.{config,extend}.lua \
|
||||
${PREFIX}/share/examples/imapfilter
|
||||
|
||||
.include <bsd.port.mk>
|
5
mail/imapfilter/distinfo
Normal file
5
mail/imapfilter/distinfo
Normal file
@ -0,0 +1,5 @@
|
||||
MD5 (imapfilter-2.0.3.tar.gz) = oP1WTsK3/THNTC21eqnpbQ==
|
||||
RMD160 (imapfilter-2.0.3.tar.gz) = j0MVRdf4cI0RGeFVOTcACYYw4ok=
|
||||
SHA1 (imapfilter-2.0.3.tar.gz) = jJZD6FfmuO4DG/3Lqq0VEjkl7sw=
|
||||
SHA256 (imapfilter-2.0.3.tar.gz) = vJUwSbLRfviwgf19cjhv7oQnbLx5lm9HzoNFCjKoXBk=
|
||||
SIZE (imapfilter-2.0.3.tar.gz) = 46134
|
170
mail/imapfilter/patches/patch-configure
Normal file
170
mail/imapfilter/patches/patch-configure
Normal file
@ -0,0 +1,170 @@
|
||||
$OpenBSD: patch-configure,v 1.1.1.1 2007/09/02 18:35:22 simon Exp $
|
||||
--- configure.orig Sat Jun 30 22:38:47 2007
|
||||
+++ configure Fri Aug 31 14:47:10 2007
|
||||
@@ -2,10 +2,11 @@
|
||||
|
||||
# Default values
|
||||
|
||||
-destdir="/usr/local"
|
||||
-bindir="$destdir/bin"
|
||||
-sharedir="$destdir/share/imapfilter"
|
||||
-mandir="$destdir/man"
|
||||
+destdir=""
|
||||
+prefix="/usr/local"
|
||||
+bindir="$prefix/bin"
|
||||
+sharedir="$prefix/share/imapfilter"
|
||||
+mandir="$prefix/man"
|
||||
|
||||
ssltls="yes"
|
||||
crammd5="yes"
|
||||
@@ -13,7 +14,7 @@ crammd5="yes"
|
||||
incdirs="-I/usr/local/include"
|
||||
libdirs="-L/usr/local/lib"
|
||||
|
||||
-mycflags="-Wall -O"
|
||||
+mycflags="${CFLAGS}"
|
||||
myldflags=""
|
||||
|
||||
libs="-lm -llua -lpcre"
|
||||
@@ -27,15 +28,18 @@ bin="imapfilter"
|
||||
|
||||
# Get options and arguments
|
||||
|
||||
-while getopts "d:b:s:m:o:h" opt
|
||||
+while getopts "d:p:b:s:m:o:h" opt
|
||||
do
|
||||
case $opt in
|
||||
d)
|
||||
destdir=$OPTARG
|
||||
- bindir=$destdir/bin
|
||||
- sharedir=$destdir/share/imapfilter
|
||||
- mandir=$destdir/man
|
||||
;;
|
||||
+ p)
|
||||
+ prefix=$OPTARG
|
||||
+ bindir=$prefix/bin
|
||||
+ sharedir=$prefix/share/imapfilter
|
||||
+ mandir=$prefix/man
|
||||
+ ;;
|
||||
b)
|
||||
bindir=$OPTARG
|
||||
;;
|
||||
@@ -63,12 +67,13 @@ do
|
||||
h | *)
|
||||
cat << EOF
|
||||
Usage:
|
||||
- configure [-h] [-d destdir] [-b bindir] [-s sharedir] [-m mandir]
|
||||
+ configure [-h] [-d destdir] [-p prefix] [-b bindir] [-s sharedir] [-m mandir]
|
||||
[-o option=argument]
|
||||
|
||||
Description:
|
||||
-h This brief usage and description message.
|
||||
- -d destdir Installation path for program's files [$destdir]
|
||||
+ -d destdir Installation base for all files [$destdir]
|
||||
+ -p prefix Installation path for program's files [$prefix]
|
||||
-b bindir Installation path for binaries [$bindir]
|
||||
-s sharedir Installation path for libraries [$sharedir]
|
||||
-m mandir Installation path for manual pages [$mandir]
|
||||
@@ -89,6 +94,7 @@ done
|
||||
|
||||
cat << EOF
|
||||
Destination directory: $destdir
|
||||
+Base directory: $prefix
|
||||
Binaries directory: $bindir
|
||||
Architecture independent libraries: $sharedir
|
||||
Manual pages directory: $mandir
|
||||
@@ -141,6 +147,7 @@ mv -f Makefile Makefile~
|
||||
|
||||
cat > Makefile << EOF
|
||||
DESTDIR = $destdir
|
||||
+PREFIX = $prefix
|
||||
BINDIR = $bindir
|
||||
SHAREDIR = $sharedir
|
||||
MANDIR = $mandir
|
||||
@@ -191,47 +198,47 @@ auth.o cert.o imap.o imapfilter.o log.o request.o resp
|
||||
imapfilter.o: version.h
|
||||
|
||||
install: \$(BIN)
|
||||
- if test ! -d \$(BINDIR); then mkdir -p \$(BINDIR); fi
|
||||
- cp -f \$(BIN) \$(BINDIR) && chmod 0755 \$(BINDIR)/\$(BIN)
|
||||
- if test ! -d \$(SHAREDIR); then mkdir -p \$(SHAREDIR); fi
|
||||
- cp -f \$(COMMON_LUA) \$(SHAREDIR) && \\
|
||||
- chmod 0644 \$(SHAREDIR)/\$(COMMON_LUA)
|
||||
- cp -f \$(SET_LUA) \$(SHAREDIR) && \\
|
||||
- chmod 0644 \$(SHAREDIR)/\$(SET_LUA)
|
||||
- cp -f \$(REGEX_LUA) \$(SHAREDIR) && \\
|
||||
- chmod 0644 \$(SHAREDIR)/\$(REGEX_LUA)
|
||||
- cp -f \$(ACCOUNT_LUA) \$(SHAREDIR) && \\
|
||||
- chmod 0644 \$(SHAREDIR)/\$(ACCOUNT_LUA)
|
||||
- cp -f \$(MAILBOX_LUA) \$(SHAREDIR) && \\
|
||||
- chmod 0644 \$(SHAREDIR)/\$(MAILBOX_LUA)
|
||||
- cp -f \$(MESSAGE_LUA) \$(SHAREDIR) && \\
|
||||
- chmod 0644 \$(SHAREDIR)/\$(MESSAGE_LUA)
|
||||
- cp -f \$(OPTIONS_LUA) \$(SHAREDIR) && \\
|
||||
- chmod 0644 \$(SHAREDIR)/\$(OPTIONS_LUA)
|
||||
- cp -f \$(AUXILIARY_LUA) \$(SHAREDIR) && \\
|
||||
- chmod 0644 \$(SHAREDIR)/\$(AUXILIARY_LUA)
|
||||
- cp -f \$(DEPRECATED_LUA) \$(SHAREDIR) && \\
|
||||
- chmod 0644 \$(SHAREDIR)/\$(DEPRECATED_LUA)
|
||||
- if test ! -d \$(MANDIR)/man1; then mkdir -p \$(MANDIR)/man1; fi
|
||||
- cp -f \$(MAN_BIN) \$(MANDIR)/man1 && \\
|
||||
- chmod 0644 \$(MANDIR)/man1/\$(MAN_BIN)
|
||||
- if test ! -d \$(MANDIR)/man5; then mkdir -p \$(MANDIR)/man5; fi
|
||||
- cp -f \$(MAN_CONFIG) \$(MANDIR)/man5 && \\
|
||||
- chmod 0644 \$(MANDIR)/man5/\$(MAN_CONFIG)
|
||||
+ if test ! -d \$(DESTDIR)\$(BINDIR); then mkdir -p \$(DESTDIR)\$(BINDIR); fi
|
||||
+ cp -f \$(BIN) \$(DESTDIR)\$(BINDIR) && chmod 0755 \$(DESTDIR)\$(BINDIR)/\$(BIN)
|
||||
+ if test ! -d \$(DESTDIR)\$(SHAREDIR); then mkdir -p \$(DESTDIR)\$(SHAREDIR); fi
|
||||
+ cp -f \$(COMMON_LUA) \$(DESTDIR)\$(SHAREDIR) && \\
|
||||
+ chmod 0644 \$(DESTDIR)\$(SHAREDIR)/\$(COMMON_LUA)
|
||||
+ cp -f \$(SET_LUA) \$(DESTDIR)\$(SHAREDIR) && \\
|
||||
+ chmod 0644 \$(DESTDIR)\$(SHAREDIR)/\$(SET_LUA)
|
||||
+ cp -f \$(REGEX_LUA) \$(DESTDIR)\$(SHAREDIR) && \\
|
||||
+ chmod 0644 \$(DESTDIR)\$(SHAREDIR)/\$(REGEX_LUA)
|
||||
+ cp -f \$(ACCOUNT_LUA) \$(DESTDIR)\$(SHAREDIR) && \\
|
||||
+ chmod 0644 \$(DESTDIR)\$(SHAREDIR)/\$(ACCOUNT_LUA)
|
||||
+ cp -f \$(MAILBOX_LUA) \$(DESTDIR)\$(SHAREDIR) && \\
|
||||
+ chmod 0644 \$(DESTDIR)\$(SHAREDIR)/\$(MAILBOX_LUA)
|
||||
+ cp -f \$(MESSAGE_LUA) \$(DESTDIR)\$(SHAREDIR) && \\
|
||||
+ chmod 0644 \$(DESTDIR)\$(SHAREDIR)/\$(MESSAGE_LUA)
|
||||
+ cp -f \$(OPTIONS_LUA) \$(DESTDIR)\$(SHAREDIR) && \\
|
||||
+ chmod 0644 \$(DESTDIR)\$(SHAREDIR)/\$(OPTIONS_LUA)
|
||||
+ cp -f \$(AUXILIARY_LUA) \$(DESTDIR)\$(SHAREDIR) && \\
|
||||
+ chmod 0644 \$(DESTDIR)\$(SHAREDIR)/\$(AUXILIARY_LUA)
|
||||
+ cp -f \$(DEPRECATED_LUA) \$(DESTDIR)\$(SHAREDIR) && \\
|
||||
+ chmod 0644 \$(DESTDIR)\$(SHAREDIR)/\$(DEPRECATED_LUA)
|
||||
+ if test ! -d \$(DESTDIR)\$(MANDIR)/man1; then mkdir -p \$(DESTDIR)\$(MANDIR)/man1; fi
|
||||
+ cp -f \$(MAN_BIN) \$(DESTDIR)\$(MANDIR)/man1 && \\
|
||||
+ chmod 0644 \$(DESTDIR)\$(MANDIR)/man1/\$(MAN_BIN)
|
||||
+ if test ! -d \$(DESTDIR)\$(MANDIR)/man5; then mkdir -p \$(DESTDIR)\$(MANDIR)/man5; fi
|
||||
+ cp -f \$(MAN_CONFIG) \$(DESTDIR)\$(MANDIR)/man5 && \\
|
||||
+ chmod 0644 \$(DESTDIR)\$(MANDIR)/man5/\$(MAN_CONFIG)
|
||||
|
||||
deinstall:
|
||||
- rm -f \$(BINDIR)/\$(BIN) \\
|
||||
- \$(SHAREDIR)/\$(COMMON_LUA) \\
|
||||
- \$(SHAREDIR)/\$(SET_LUA) \\
|
||||
- \$(SHAREDIR)/\$(REGEX_LUA) \\
|
||||
- \$(SHAREDIR)/\$(ACCOUNT_LUA) \\
|
||||
- \$(SHAREDIR)/\$(MAILBOX_LUA) \\
|
||||
- \$(SHAREDIR)/\$(MESSAGE_LUA) \\
|
||||
- \$(SHAREDIR)/\$(OPTIONS_LUA) \\
|
||||
- \$(SHAREDIR)/\$(AUXILIARY_LUA) \\
|
||||
- \$(SHAREDIR)/\$(DEPRECATED_LUA) \\
|
||||
- \$(MANDIR)/man1/\$(MAN_BIN) \\
|
||||
- \$(MANDIR)/man5/\$(MAN_CONFIG)
|
||||
+ rm -f \$(DESTDIR)\$(BINDIR)/\$(BIN) \\
|
||||
+ \$(DESTDIR)\$(SHAREDIR)/\$(COMMON_LUA) \\
|
||||
+ \$(DESTDIR)\$(SHAREDIR)/\$(SET_LUA) \\
|
||||
+ \$(DESTDIR)\$(SHAREDIR)/\$(REGEX_LUA) \\
|
||||
+ \$(DESTDIR)\$(SHAREDIR)/\$(ACCOUNT_LUA) \\
|
||||
+ \$(DESTDIR)\$(SHAREDIR)/\$(MAILBOX_LUA) \\
|
||||
+ \$(DESTDIR)\$(SHAREDIR)/\$(MESSAGE_LUA) \\
|
||||
+ \$(DESTDIR)\$(SHAREDIR)/\$(OPTIONS_LUA) \\
|
||||
+ \$(DESTDIR)\$(SHAREDIR)/\$(AUXILIARY_LUA) \\
|
||||
+ \$(DESTDIR)\$(SHAREDIR)/\$(DEPRECATED_LUA) \\
|
||||
+ \$(DESTDIR)\$(MANDIR)/man1/\$(MAN_BIN) \\
|
||||
+ \$(DESTDIR)\$(MANDIR)/man5/\$(MAN_CONFIG)
|
||||
|
||||
uninstall: deinstall
|
||||
|
30
mail/imapfilter/patches/patch-imapfilter_config_5
Normal file
30
mail/imapfilter/patches/patch-imapfilter_config_5
Normal file
@ -0,0 +1,30 @@
|
||||
$OpenBSD: patch-imapfilter_config_5,v 1.1.1.1 2007/09/02 18:35:22 simon Exp $
|
||||
--- imapfilter_config.5.orig Fri Aug 31 15:56:54 2007
|
||||
+++ imapfilter_config.5 Fri Aug 31 15:56:59 2007
|
||||
@@ -67,7 +67,7 @@ options.namespace = false
|
||||
.Ed
|
||||
.Pp
|
||||
Available options are:
|
||||
-.Bl -tag
|
||||
+.Bl -tag -width Ds
|
||||
.It Va create
|
||||
According to the IMAP specification, when trying to write a message to a
|
||||
non-existent mailbox, the server must send a hint to the client, whether it
|
||||
@@ -147,7 +147,7 @@ myaccount = IMAP {
|
||||
An account
|
||||
.Vt table
|
||||
must have the following elements:
|
||||
-.Bl -tag
|
||||
+.Bl -tag -width Ds
|
||||
.It Va server
|
||||
The hostname of the IMAP server to connect to. It takes a
|
||||
.Vt string
|
||||
@@ -161,7 +161,7 @@ as a value.
|
||||
An account
|
||||
.Vt table
|
||||
can also have the following optional elements:
|
||||
-.Bl -tag
|
||||
+.Bl -tag -width Ds
|
||||
.It Va password
|
||||
User's secret keyword. If a password wasn't supplied the user will be asked to
|
||||
enter one interactively the first time it will be needed. It takes a
|
9
mail/imapfilter/pkg/DESCR
Normal file
9
mail/imapfilter/pkg/DESCR
Normal file
@ -0,0 +1,9 @@
|
||||
IMAPFilter is a mail filtering utility. It connects to remote mail
|
||||
servers using the Internet Message Access Protocol (IMAP), sends
|
||||
searching queries to the server and processes mailboxes based on the
|
||||
results. It can be used to delete, copy, move, flag, etc. messages
|
||||
residing in mailboxes at the same or different mail servers. The 4rev1
|
||||
and 4 versions of the IMAP protocol are supported.
|
||||
|
||||
IMAPFilter uses the Lua programming language as a configuration and
|
||||
extension language.
|
17
mail/imapfilter/pkg/PLIST
Normal file
17
mail/imapfilter/pkg/PLIST
Normal file
@ -0,0 +1,17 @@
|
||||
@comment $OpenBSD: PLIST,v 1.1.1.1 2007/09/02 18:35:22 simon Exp $
|
||||
bin/imapfilter
|
||||
@man man/man1/imapfilter.1
|
||||
@man man/man5/imapfilter_config.5
|
||||
share/examples/imapfilter/
|
||||
share/examples/imapfilter/sample.config.lua
|
||||
share/examples/imapfilter/sample.extend.lua
|
||||
share/imapfilter/
|
||||
share/imapfilter/account.lua
|
||||
share/imapfilter/auxiliary.lua
|
||||
share/imapfilter/common.lua
|
||||
share/imapfilter/deprecated.lua
|
||||
share/imapfilter/mailbox.lua
|
||||
share/imapfilter/message.lua
|
||||
share/imapfilter/options.lua
|
||||
share/imapfilter/regex.lua
|
||||
share/imapfilter/set.lua
|
Loading…
Reference in New Issue
Block a user