On 2019/03/04 01:45, Anthony J. Bentley wrote: > Stuart Henderson writes: > > On 2019/03/03 01:53, Anthony J. Bentley wrote: > > > GNU Dico is a flexible modular implementation of DICT server (RFC 2229). > > > In contrast to other implementations, it does not depend on particular > > > database format. GNU Dico handles database accesses using loadable > > > modules. > > > > I imagine using it with books/gcide would be a pretty common use case. > > > > What do you think about shipping a sample config for that (files/dicod.conf > > installed under share/examples and @sample'd into /etc, with a comment > > saying > > that gcide is required to use this config) and having other pieces in place > > to work with that (i.e. @sample /var/dicod and have the rc script create > > /var/run/dicod with appropriate permissions)? > > Yes, definitely. Here's a new port with an example config. > I went ahead and reduced to a single directory /var/dico for both the > index and pidfile, as /var/run/dico isn't actually a default (the > default is actually /var/run/dicod.pid, which doesn't work unless the > server is started as root). > > > - there are commented-out rc_bg/rc_reload in dico.rc > > Removed. It does background and reload correctly via rcctl. > > > - the static libraries for the plugins don't seem useful, you can > > probably zap them with LIBTOOL_FLAGS = --tag=disable-static > > Sure. > > -- > Anthony J. Bentley
Slight tweak, otherwise OK: diff --git a/Makefile b/Makefile index 131fdc4..68ca97f 100644 --- a/Makefile +++ b/Makefile @@ -41,6 +41,6 @@ SUBST_VARS += V post-install: ${INSTALL_DATA_DIR} ${PREFIX}/share/examples/dico - ${INSTALL_DATA} ${FILESDIR}/dicod.conf ${PREFIX}/share/examples/dico + ${SUBST_CMD} -m 444 -c ${FILESDIR}/dicod.conf ${PREFIX}/share/examples/dico/dicod.conf .include <bsd.port.mk> diff --git a/files/dicod.conf b/files/dicod.conf index 9e8175d..91548c0 100644 --- a/files/dicod.conf +++ b/files/dicod.conf @@ -6,5 +6,5 @@ pidfile /var/dicod/dicod.pid; #load-module gcide; #database { # name "gcide"; -# handler "gcide dbdir=/usr/local/share/doc/gcide idxdir=/var/dicod"; +# handler "gcide dbdir=${LOCALBASE}/share/doc/gcide idxdir=/var/dicod"; #}