mirror of
https://git.FreeBSD.org/ports.git
synced 2024-11-24 00:45:52 +00:00
Add mail/mailest, hyper estraier search engine backend for mail/mew.
This commit is contained in:
parent
bee941dbd5
commit
a8eb7c738b
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=391687
@ -215,6 +215,7 @@
|
|||||||
SUBDIR += mailagent
|
SUBDIR += mailagent
|
||||||
SUBDIR += maildirsync
|
SUBDIR += maildirsync
|
||||||
SUBDIR += maildrop
|
SUBDIR += maildrop
|
||||||
|
SUBDIR += mailest
|
||||||
SUBDIR += mailfmt
|
SUBDIR += mailfmt
|
||||||
SUBDIR += mailfront
|
SUBDIR += mailfront
|
||||||
SUBDIR += mailgraph
|
SUBDIR += mailgraph
|
||||||
|
34
mail/mailest/Makefile
Normal file
34
mail/mailest/Makefile
Normal file
@ -0,0 +1,34 @@
|
|||||||
|
# $FreeBSD$
|
||||||
|
|
||||||
|
PORTNAME= mailest
|
||||||
|
PORTVERSION= 0.9.20
|
||||||
|
CATEGORIES= mail
|
||||||
|
|
||||||
|
MAINTAINER= hrs@FreeBSD.org
|
||||||
|
COMMENT= Hyper Estraier backend for Mew
|
||||||
|
|
||||||
|
LICENSE= BSD2CLAUSE ISCL LGPL21
|
||||||
|
LICENSE_COMB= multi
|
||||||
|
LICENSE_FILE_BSD2CLAUSE=${WRKSRC}/LICENSE.BSD2CLAUSE
|
||||||
|
LICENSE_FILE_ISCL= ${WRKSRC}/LICENSE.ISCL
|
||||||
|
LICENSE_FILE_LGPL21= ${WRKSRC}/LICENSE.LGPL21
|
||||||
|
|
||||||
|
LIB_DEPENDS= libevent.so:${PORTSDIR}/devel/libevent2 \
|
||||||
|
libqdbm.so:${PORTSDIR}/databases/qdbm
|
||||||
|
RUN_DEPENDS= mewl:${PORTSDIR}/mail/mew \
|
||||||
|
estcmd:${PORTSDIR}/textproc/hyperestraier
|
||||||
|
|
||||||
|
USES= iconv
|
||||||
|
USE_EMACS= yes
|
||||||
|
USE_GITHUB= yes
|
||||||
|
GH_ACCOUNT= yasuoka
|
||||||
|
GH_TAGNAME= ${PORTNAME}-${PORTVERSION}
|
||||||
|
MAKE_ENV= USE_BSDMAKE=true WITH_INSTALL_AS_USER=true
|
||||||
|
|
||||||
|
post-extract:
|
||||||
|
${SED} "/\*-/,/*\//!d" ${WRKSRC}/bytebuf.c > ${LICENSE_FILE_BSD2CLAUSE}
|
||||||
|
${SED} "/^\/\*/,/ *\//!d" ${WRKSRC}/mailestctl.c > ${LICENSE_FILE_ISCL}
|
||||||
|
${SED} "/^\/\*\*/,/\*\*\//!d" ${WRKSRC}/estdraft.c \
|
||||||
|
> ${LICENSE_FILE_LGPL21}
|
||||||
|
|
||||||
|
.include <bsd.port.mk>
|
2
mail/mailest/distinfo
Normal file
2
mail/mailest/distinfo
Normal file
@ -0,0 +1,2 @@
|
|||||||
|
SHA256 (yasuoka-mailest-0.9.20-mailest-0.9.20_GH0.tar.gz) = f51cde2047422c993425eee8102e5f7a914094b60a1a039a0b84502e5d22c5f8
|
||||||
|
SIZE (yasuoka-mailest-0.9.20-mailest-0.9.20_GH0.tar.gz) = 171958
|
29
mail/mailest/files/patch-mailestd-Makefile
Normal file
29
mail/mailest/files/patch-mailestd-Makefile
Normal file
@ -0,0 +1,29 @@
|
|||||||
|
--- mailestd/Makefile.orig 2015-05-27 12:18:27.000000000 +0900
|
||||||
|
+++ mailestd/Makefile 2015-06-05 16:09:10.228594000 +0900
|
||||||
|
@@ -2,9 +2,9 @@
|
||||||
|
|
||||||
|
PROG= mailestd
|
||||||
|
SRCS= bytebuf.c mailestd.c mailestctl.c parse.y parser.c
|
||||||
|
-LINKS= ${BINDIR}/mailestd ${LOCALBASE}/bin/mailestctl
|
||||||
|
+LINKS= ${BINDIR}/${PROG} ${BINDIR}/mailestctl
|
||||||
|
CFLAGS+= -DHAVE_LIBESTDRAFT -DMONITOR_KQUEUE
|
||||||
|
-LIBESTDRAFTOBJ!=cd ${.CURDIR}/../libestdraft; ${MAKE} _whereobj
|
||||||
|
+LIBESTDRAFTOBJ!=cd ${.CURDIR}/../libestdraft; ${MAKE} -V.OBJDIR
|
||||||
|
LDFLAGS= -L${LOCALBASE}/lib
|
||||||
|
LDADD= -lestraier -levent -lqdbm
|
||||||
|
DPADD= ${LIBESTRAIER} ${LIBEVENT} ${LIBQDBM}
|
||||||
|
@@ -21,13 +21,7 @@
|
||||||
|
DPADD+= ${LIBPTHREAD}
|
||||||
|
.endif
|
||||||
|
|
||||||
|
-beforeinstall:
|
||||||
|
- ${INSTALL} ${INSTALL_COPY} -o ${BINOWN} -g ${BINGRP} -m ${BINMODE} \
|
||||||
|
- ${.CURDIR}/../mew-mailest.sh ${PREFIX}/bin/mew-mailest
|
||||||
|
- ${INSTALL} ${INSTALL_COPY} -o ${BINOWN} -g ${BINGRP} -m ${BINMODE} \
|
||||||
|
- ${.CURDIR}/../cmew-mailest.sh ${PREFIX}/bin/cmew-mailest
|
||||||
|
- ${INSTALL} ${INSTALL_COPY} -o ${BINOWN} -g ${BINGRP} -m ${BINMODE} \
|
||||||
|
- ${.CURDIR}/../smew-mailest.sh ${PREFIX}/bin/smew-mailest
|
||||||
|
+SCRIPTS= mew-mailest.sh cmew-mailest.sh smew-mailest.sh
|
||||||
|
|
||||||
|
LDFLAGS+= -L${LIBESTDRAFTOBJ}
|
||||||
|
LDADD+= -lestdraft
|
47
mail/mailest/files/patch-mailestd.c
Normal file
47
mail/mailest/files/patch-mailestd.c
Normal file
@ -0,0 +1,47 @@
|
|||||||
|
--- mailestd.c.orig 2015-05-27 12:18:27.000000000 +0900
|
||||||
|
+++ mailestd.c 2015-06-05 16:21:58.350309000 +0900
|
||||||
|
@@ -809,8 +809,6 @@
|
||||||
|
|
||||||
|
RB_INIT(&folders);
|
||||||
|
ctx = mailestd_get_gather(_this, task->gather_id);
|
||||||
|
- mailestd_log(LOG_DEBUG, "Gathering %s ...", mailestd_folder_name(
|
||||||
|
- _this, folder, buf, sizeof(buf)));
|
||||||
|
if (folder[0] == '/')
|
||||||
|
strlcpy(rdir, folder, sizeof(rdir));
|
||||||
|
else {
|
||||||
|
@@ -818,6 +816,8 @@
|
||||||
|
strlcat(rdir, "/", sizeof(rdir));
|
||||||
|
strlcat(rdir, folder, sizeof(rdir));
|
||||||
|
}
|
||||||
|
+ mailestd_log(LOG_DEBUG, "Gathering %s ...", mailestd_folder_name(
|
||||||
|
+ _this, rdir, buf, sizeof(buf)));
|
||||||
|
paths[0] = rdir;
|
||||||
|
paths[1] = NULL;
|
||||||
|
lrdir = strlen(rdir);
|
||||||
|
@@ -853,7 +853,7 @@
|
||||||
|
}
|
||||||
|
|
||||||
|
mailestd_log(LOG_DEBUG, "Gathered %s (Total: %d Remove: %d Update: %d)",
|
||||||
|
- mailestd_folder_name(_this, folder, buf, sizeof(buf)),
|
||||||
|
+ mailestd_folder_name(_this, rdir, buf, sizeof(buf)),
|
||||||
|
total, delete, update);
|
||||||
|
out:
|
||||||
|
if (ctx != NULL) {
|
||||||
|
@@ -2638,6 +2638,7 @@
|
||||||
|
mailestd_monitor_folder(struct mailestd *_this, const char *dirpath)
|
||||||
|
{
|
||||||
|
int fd = -1;
|
||||||
|
+ char buf[PATH_MAX];
|
||||||
|
struct folder *fld, fld0;
|
||||||
|
|
||||||
|
MAILESTD_ASSERT(_thread_self() == _this->monitorworker.thread);
|
||||||
|
@@ -2659,7 +2660,8 @@
|
||||||
|
fld->fd = fd;
|
||||||
|
fld->path = xstrdup(dirpath);
|
||||||
|
RB_INSERT(folder_tree, &_this->monitors, fld);
|
||||||
|
- mailestd_log(LOG_DEBUG, "Start monitoring %s", dirpath);
|
||||||
|
+ mailestd_log(LOG_DEBUG, "Start monitoring %s",
|
||||||
|
+ mailestd_folder_name(_this, dirpath, buf, sizeof(buf)));
|
||||||
|
}
|
||||||
|
|
||||||
|
static void
|
4
mail/mailest/pkg-descr
Normal file
4
mail/mailest/pkg-descr
Normal file
@ -0,0 +1,4 @@
|
|||||||
|
mailest provides a search backend and id index database for
|
||||||
|
Mew using Hyper Estraier.
|
||||||
|
|
||||||
|
WWW: https://github.com/yasuoka/mailest
|
29
mail/mailest/pkg-message
Normal file
29
mail/mailest/pkg-message
Normal file
@ -0,0 +1,29 @@
|
|||||||
|
------------
|
||||||
|
How to start
|
||||||
|
------------
|
||||||
|
|
||||||
|
+ For existing `mewest` user, backup and/or delete the database
|
||||||
|
(`~/Mail/casket`)
|
||||||
|
|
||||||
|
- Since "mailestd" can work with the old database, so OK to skip deleting
|
||||||
|
`~/Mail/casket`, but remark that `V` will not work against the mails
|
||||||
|
which are indexed by `mewest`. To make `V` work against them, delete
|
||||||
|
the database in advance.
|
||||||
|
|
||||||
|
+ Add the below line to `.mew.el` to let Mew use "Hyper Estrairer" for
|
||||||
|
search.
|
||||||
|
|
||||||
|
((setq mew-search-method 'est)
|
||||||
|
|
||||||
|
+ Add the below lines to `~/.emacs` use use the "mailest" instead of
|
||||||
|
existing "mewest".
|
||||||
|
|
||||||
|
(defvar mew-prog-est "mew-mailest")
|
||||||
|
(defvar mew-prog-est-update "mew-mailest")
|
||||||
|
(defvar mew-prog-cmew "cmew-mailest")
|
||||||
|
(defvar mew-prog-smew "smew-mailest")
|
||||||
|
(defvar mew-id-db-file ".mailest.sock")
|
||||||
|
|
||||||
|
+ Try `km`, `kM`, `k/`, `k?`, `V` in Mew. See
|
||||||
|
http://mew.org/en/info/release/mew_6.html#dbsearch for search commands
|
||||||
|
in Mew.
|
11
mail/mailest/pkg-plist
Normal file
11
mail/mailest/pkg-plist
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
sbin/cmew-mailest
|
||||||
|
sbin/mailestctl
|
||||||
|
sbin/mew-mailest
|
||||||
|
sbin/smew-mailest
|
||||||
|
sbin/mailestd
|
||||||
|
man/man1/cmew-mailest.1.gz
|
||||||
|
man/man1/mailestctl.1.gz
|
||||||
|
man/man1/mew-mailest.1.gz
|
||||||
|
man/man1/smew-mailest.1.gz
|
||||||
|
man/man5/mailestd.conf.5.gz
|
||||||
|
man/man8/mailestd.8.gz
|
Loading…
Reference in New Issue
Block a user