aboutsummaryrefslogtreecommitdiffstats
path: root/net
diff options
context:
space:
mode:
authorpgollucci <pgollucci@FreeBSD.org>2010-09-23 10:36:19 +0800
committerpgollucci <pgollucci@FreeBSD.org>2010-09-23 10:36:19 +0800
commitf4897920d5e2d5f2e0adc1571a3e018054692b2a (patch)
tree4e987708b102df37e6e9d4ad9d1a73397fdc56ca /net
parenta94477fbb8f48704df4c8423cf214561e5183d51 (diff)
downloadfreebsd-ports-graphics-f4897920d5e2d5f2e0adc1571a3e018054692b2a.tar.gz
freebsd-ports-graphics-f4897920d5e2d5f2e0adc1571a3e018054692b2a.tar.zst
freebsd-ports-graphics-f4897920d5e2d5f2e0adc1571a3e018054692b2a.zip
Dico is an implementation of DICT server (RFC 2229). It is fully
modular: the daemon itself (dicod) provides only the server functionality, but it knows nothing about database formats. Actual searches are performed by functions supplied in loadable modules. A single module can serve one or more databases. The package includes the following database modules: dictorg, guile, python, and outline. WWW: http://www.gnu.org/software/dico/ PR: ports/142504 Submitted by: Goran Tal
Diffstat (limited to 'net')
-rw-r--r--net/Makefile1
-rw-r--r--net/gnu-dico/Makefile80
-rw-r--r--net/gnu-dico/distinfo3
-rw-r--r--net/gnu-dico/files/dicod.conf49
-rw-r--r--net/gnu-dico/files/dicod.sh.in20
-rw-r--r--net/gnu-dico/files/pkg-message.in16
-rw-r--r--net/gnu-dico/pkg-descr8
-rw-r--r--net/gnu-dico/pkg-plist43
8 files changed, 220 insertions, 0 deletions
diff --git a/net/Makefile b/net/Makefile
index 6f182068482..c56a3352994 100644
--- a/net/Makefile
+++ b/net/Makefile
@@ -194,6 +194,7 @@
SUBDIR += gnome-nettool
SUBDIR += gnome-vnc
SUBDIR += gnosamba
+ SUBDIR += gnu-dico
SUBDIR += gnu-radius
SUBDIR += gofish
SUBDIR += googlecl
diff --git a/net/gnu-dico/Makefile b/net/gnu-dico/Makefile
new file mode 100644
index 00000000000..c3e2eef661c
--- /dev/null
+++ b/net/gnu-dico/Makefile
@@ -0,0 +1,80 @@
+# New ports collection makefile for: gnu dico
+# Date created: 27-12-2009
+# Whom: Goran Tal
+#
+# $FreeBSD$
+#
+
+PORTNAME= dico
+PORTVERSION= 2.0
+CATEGORIES= net textproc
+MASTER_SITES= ${MASTER_SITE_GNU}
+MASTER_SITE_SUBDIR= ${PORTNAME}
+PKGNAMEPREFIX= gnu-
+
+MAINTAINER= goran.tal@gmail.com
+COMMENT= Flexible modular implementation of DICT server
+
+USE_LDCONFIG= yes
+USE_GMAKE= yes
+USE_AUTOTOOLS= libltdl:22 libtool:22
+
+GNU_CONFIGURE= yes
+CONFIGURE_ENV= CPPFLAGS="-I${LOCALBASE}/include" \
+ LDFLAGS="-L${LOCALBASE}/lib"
+CONFIGURE_ARGS= --localstatedir=/var
+
+OPTIONS= PYTHON "With PYTHON support" on \
+ GUILE "With GUILE support" on \
+ GSASL "With GSASL support" off
+
+.include <bsd.port.options.mk>
+
+.if defined(WITH_PYTHON)
+USE_PYTHON= yes
+PLIST_SUB+= PYTHON=""
+.else
+CONFIGURE_ARGS+=--without-python
+PLIST_SUB+= PYTHON="@comment "
+.endif
+
+.if defined(WITH_GUILE)
+LIB_DEPENDS+= guile.20:${PORTSDIR}/lang/guile
+PLIST_SUB+= GUILE=""
+.else
+CONFIGURE_ARGS+=--without-guile
+PLIST_SUB+= GUILE="@comment "
+.endif
+
+.if defined(WITH_GSASL)
+LIB_DEPENDS+= gsasl.13:${PORTSDIR}/security/gsasl
+CONFIGURE_ARGS+=--with-gsasl
+.else
+CONFIGURE_ARGS+=--without-gsasl
+.endif
+
+.if !defined(WITHOUT_NLS)
+USE_GETTEXT= yes
+PLIST_SUB+= NLS=""
+.else
+CONFIGURE_ARGS+=--disable-nls
+PLIST_SUB+= NLS="@comment "
+.endif
+
+INFO= dico
+
+PLIST_SUB+= PORTVERSION=${PORTVERSION}
+SUB_FILES+= pkg-message
+USE_RC_SUBR= dicod.sh
+
+post-patch:
+ @${REINPLACE_CMD} 's/ENODATA/EIO/' ${WRKSRC}/lib/utf8.c
+ @${REINPLACE_CMD} 's/@bindir@/@sbindir@/' ${WRKSRC}/dicod/Makefile.in
+ @${REINPLACE_CMD} 's/(bindir)\//(bindir)\/g/' ${WRKSRC}/dico/Makefile.in
+ @${REINPLACE_CMD} '/INSTALL.*charset/d' ${WRKSRC}/gnu/Makefile.in
+
+post-install:
+ @${INSTALL_DATA} ${FILESDIR}/dicod.conf ${PREFIX}/etc/dicod.conf.sample
+ @${CAT} ${PKGMESSAGE}
+
+.include <bsd.port.mk>
diff --git a/net/gnu-dico/distinfo b/net/gnu-dico/distinfo
new file mode 100644
index 00000000000..0b04f43dd3c
--- /dev/null
+++ b/net/gnu-dico/distinfo
@@ -0,0 +1,3 @@
+MD5 (dico-2.0.tar.gz) = 0dffe580c6fb687568be87e0ca117a08
+SHA256 (dico-2.0.tar.gz) = 7b26a51ce26502cf60963e28528640ebb6bb7d3d52fa5d13ec65eb254d78970d
+SIZE (dico-2.0.tar.gz) = 1717078
diff --git a/net/gnu-dico/files/dicod.conf b/net/gnu-dico/files/dicod.conf
new file mode 100644
index 00000000000..ffa2962941a
--- /dev/null
+++ b/net/gnu-dico/files/dicod.conf
@@ -0,0 +1,49 @@
+/* A sample configuration for GNU dicod */
+
+capability (mime,xversion);
+timing yes;
+access-log-file "/var/log/dictd-access_log";
+access-log-format "%h %l %u %t \"%r\" %>s %b \"\" \"%C\"";
+
+load-module dict {
+ command "dictorg dbdir=/usr/local/share/dict";
+}
+
+load-module guile {
+ command "guile debug";
+}
+
+load-module python {
+ command "python";
+}
+
+database {
+ name "devdict";
+ handler "dict database=devils";
+}
+
+database {
+ name "plnum";
+ handler "guile"
+ " init-script=/usr/local/share/dict/example.scm"
+ " init-fun=example-init"
+ " example.db";
+}
+
+database {
+ name "cznum";
+ handler "python "
+ "load-path=/usr/local/share/dict "
+ "init-script=example "
+ "/usr/local/share/dict/example.text";
+}
+
+listen (localhost:dict, "/var/tmp/dict.sock");
+max-children 10;
+inactivity-timeout 5;
+
+log-tag "Dico dictd";
+
+server-info <<EOT
+This is a test Dico server.
+EOT;
diff --git a/net/gnu-dico/files/dicod.sh.in b/net/gnu-dico/files/dicod.sh.in
new file mode 100644
index 00000000000..612e7a0de7f
--- /dev/null
+++ b/net/gnu-dico/files/dicod.sh.in
@@ -0,0 +1,20 @@
+#!/bin/sh
+#
+# PROVIDE: dicod
+# REQUIRE: DAEMON
+#
+# Add the following line to /etc/rc.conf to enable dicod:
+#
+# dicod_enable="YES"
+#
+
+dicod_enable=${dicod_enable-"NO"}
+
+. %%RC_SUBR%%
+
+name=dicod
+rcvar=`set_rcvar`
+command=%%PREFIX%%/sbin/dicod
+
+load_rc_config $name
+run_rc_command "$1"
diff --git a/net/gnu-dico/files/pkg-message.in b/net/gnu-dico/files/pkg-message.in
new file mode 100644
index 00000000000..558081c3e51
--- /dev/null
+++ b/net/gnu-dico/files/pkg-message.in
@@ -0,0 +1,16 @@
+================================================================
+
+This port installs Dict server dicod and Dict client gdico.
+
+To enable the server, add the following line to /etc/rc.conf:
+
+ dicod_enable="YES"
+
+Before you can start dicod, you have to install dictionaries
+and configure them in %%PREFIX%%/etc/dicod.conf
+
+See %%PREFIX%%/etc/dicod.conf.sample for examples.
+
+For help see info documentation: info Dico
+
+================================================================
diff --git a/net/gnu-dico/pkg-descr b/net/gnu-dico/pkg-descr
new file mode 100644
index 00000000000..7dc8cdea171
--- /dev/null
+++ b/net/gnu-dico/pkg-descr
@@ -0,0 +1,8 @@
+Dico is an implementation of DICT server (RFC 2229). It is fully
+modular: the daemon itself (dicod) provides only the server
+functionality, but it knows nothing about database formats. Actual
+searches are performed by functions supplied in loadable modules. A
+single module can serve one or more databases. The package includes
+the following database modules: dictorg, guile, python, and outline.
+
+WWW: http://www.gnu.org/software/dico/
diff --git a/net/gnu-dico/pkg-plist b/net/gnu-dico/pkg-plist
new file mode 100644
index 00000000000..654de816ac8
--- /dev/null
+++ b/net/gnu-dico/pkg-plist
@@ -0,0 +1,43 @@
+bin/gdico
+etc/dicod.conf.sample
+include/dico/argcv.h
+include/dico/assoc.h
+include/dico/diag.h
+include/dico/dico.h
+include/dico/filter.h
+include/dico/list.h
+include/dico/markup.h
+include/dico/parseopt.h
+include/dico/strat.h
+include/dico/stream.h
+include/dico/types.h
+include/dico/url.h
+include/dico/utf8.h
+include/dico/util.h
+include/dico/xlat.h
+lib/dico/dictorg.a
+lib/dico/dictorg.la
+lib/dico/dictorg.so
+%%GUILE%%lib/dico/guile.a
+%%GUILE%%lib/dico/guile.la
+%%GUILE%%lib/dico/guile.so
+lib/dico/outline.a
+lib/dico/outline.la
+lib/dico/outline.so
+%%PYTHON%%lib/dico/python.a
+%%PYTHON%%lib/dico/python.la
+%%PYTHON%%lib/dico/python.so
+lib/libdico.a
+lib/libdico.la
+lib/libdico.so
+lib/libdico.so.0
+sbin/dicod
+%%DATADIR%%/%%PORTVERSION%%/include/pp-setup
+%%DATADIR%%/gjdict.xbm
+%%NLS%%share/locale/pl/LC_MESSAGES/dico.mo
+%%NLS%%share/locale/uk/LC_MESSAGES/dico.mo
+@dirrm share/dico/%%PORTVERSION%%/include
+@dirrm share/dico/%%PORTVERSION%%
+@dirrm share/dico
+@dirrmtry lib/dico
+@dirrm include/dico