summaryrefslogtreecommitdiff
path: root/www/c-icap-modules
diff options
context:
space:
mode:
authoradam <adam>2011-05-11 04:29:18 +0000
committeradam <adam>2011-05-11 04:29:18 +0000
commitd5b46c14e1322f4bae3b3ab6cee078213c990629 (patch)
tree423df7c7cc28a897662fd9b41e1300ad0caf78a0 /www/c-icap-modules
parent7e0e677761e77367b65c3c9bf41385477cf3b302 (diff)
downloadpkgsrc-d5b46c14e1322f4bae3b3ab6cee078213c990629.tar.gz
c-icap is an implementation of an ICAP server. It can be used with HTTP proxies
that support the ICAP protocol to implement content adaptation and filtering services. Most of the commercial HTTP proxies must support the ICAP protocol. The open source Squid 3.x proxy server supports it.
Diffstat (limited to 'www/c-icap-modules')
-rw-r--r--www/c-icap-modules/DESCR6
-rw-r--r--www/c-icap-modules/Makefile29
-rw-r--r--www/c-icap-modules/PLIST5
-rw-r--r--www/c-icap-modules/distinfo8
-rw-r--r--www/c-icap-modules/options.mk27
-rw-r--r--www/c-icap-modules/patches/patch-configure29
-rw-r--r--www/c-icap-modules/patches/patch-services_clamav_Makefile.in16
-rw-r--r--www/c-icap-modules/patches/patch-services_url_check_Makefile.in26
8 files changed, 146 insertions, 0 deletions
diff --git a/www/c-icap-modules/DESCR b/www/c-icap-modules/DESCR
new file mode 100644
index 00000000000..bfabd642e2e
--- /dev/null
+++ b/www/c-icap-modules/DESCR
@@ -0,0 +1,6 @@
+c-icap is an implementation of an ICAP server. It can be used with HTTP proxies
+that support the ICAP protocol to implement content adaptation and filtering
+services.
+
+Most of the commercial HTTP proxies must support the ICAP protocol. The open
+source Squid 3.x proxy server supports it.
diff --git a/www/c-icap-modules/Makefile b/www/c-icap-modules/Makefile
new file mode 100644
index 00000000000..a21f7f4bfbf
--- /dev/null
+++ b/www/c-icap-modules/Makefile
@@ -0,0 +1,29 @@
+# $NetBSD: Makefile,v 1.1.1.1 2011/05/11 04:30:06 adam Exp $
+
+DISTNAME= c_icap_modules-0.1.5
+PKGNAME= ${DISTNAME:S/_/-/g}
+CATEGORIES= www
+MASTER_SITES= ${MASTER_SITE_SOURCEFORGE:=c-icap/}
+
+MAINTAINER= adam@NetBSD.org
+HOMEPAGE= http://c-icap.sourceforge.net/
+COMMENT= C-ICAP server modules
+LICENSE= gnu-gpl-v2
+
+PKG_DESTDIR_SUPPORT= user-destdir
+
+USE_LANGUAGES= c
+USE_LIBTOOL= yes
+GNU_CONFIGURE= yes
+CONFIGURE_ARGS= --with-c-icap=${BUILDLINK_PREFIX.c-icap}
+
+EGDIR= ${PREFIX}/share/c-icap
+CONF_FILES= ${EGDIR}/srv_url_check.conf.default ${PKG_SYSCONFDIR}/srv_url_check.conf
+
+INSTALLATION_DIRS= share/c-icap
+
+.include "options.mk"
+
+.include "../../www/c-icap/buildlink3.mk"
+.include "../../mk/dlopen.buildlink3.mk"
+.include "../../mk/bsd.pkg.mk"
diff --git a/www/c-icap-modules/PLIST b/www/c-icap-modules/PLIST
new file mode 100644
index 00000000000..ec4aef46671
--- /dev/null
+++ b/www/c-icap-modules/PLIST
@@ -0,0 +1,5 @@
+@comment $NetBSD: PLIST,v 1.1.1.1 2011/05/11 04:30:06 adam Exp $
+${PLIST.clamav}lib/c_icap/srv_clamav.la
+lib/c_icap/srv_url_check.la
+${PLIST.clamav}share/c-icap/srv_clamav.conf.default
+share/c-icap/srv_url_check.conf.default
diff --git a/www/c-icap-modules/distinfo b/www/c-icap-modules/distinfo
new file mode 100644
index 00000000000..4b01d74f6ef
--- /dev/null
+++ b/www/c-icap-modules/distinfo
@@ -0,0 +1,8 @@
+$NetBSD: distinfo,v 1.1.1.1 2011/05/11 04:30:06 adam Exp $
+
+SHA1 (c_icap_modules-0.1.5.tar.gz) = b19dbbe4dab9e30c42ad8b549f9b7af33225f5a9
+RMD160 (c_icap_modules-0.1.5.tar.gz) = ba8f1983fb80ad50021047c582f1a87f43b4080e
+Size (c_icap_modules-0.1.5.tar.gz) = 320945 bytes
+SHA1 (patch-configure) = dd712ea5e18de59535200caef9d7298d5668dc58
+SHA1 (patch-services_clamav_Makefile.in) = cb6b6445cbc2b9811f70b1cc115ff843d65dbbdd
+SHA1 (patch-services_url_check_Makefile.in) = 2033feaec3f6d8680c98106f17d24e862a3446dc
diff --git a/www/c-icap-modules/options.mk b/www/c-icap-modules/options.mk
new file mode 100644
index 00000000000..abc32dfbcb5
--- /dev/null
+++ b/www/c-icap-modules/options.mk
@@ -0,0 +1,27 @@
+# $NetBSD: options.mk,v 1.1.1.1 2011/05/11 04:30:06 adam Exp $
+
+PKG_OPTIONS_VAR= PKG_OPTIONS.c-icap
+PKG_SUPPORTED_OPTIONS= bdb clamav
+PKG_SUGGESTED_OPTIONS= bdb clamav
+
+.include "../../mk/bsd.options.mk"
+
+PLIST_VARS+= bdb clamav
+
+.if !empty(PKG_OPTIONS:Mbdb)
+PLIST.bdb= yes
+BDB_ACCEPTED= db5 db4
+CONFIGURE_ARGS+= --with-bdb=${BDBBASE}
+. include "../../mk/bdb.buildlink3.mk"
+.else
+CONFIGURE_ARGS+= --without-bdb
+.endif
+
+.if !empty(PKG_OPTIONS:Mclamav)
+PLIST.clamav= yes
+CONFIGURE_ARGS+= --with-clamav
+CONF_FILES+= ${EGDIR}/srv_clamav.conf.default ${PKG_SYSCONFDIR}/srv_clamav.conf
+. include "../../security/clamav/buildlink3.mk"
+.else
+CONFIGURE_ARGS+= --without-clamav
+.endif
diff --git a/www/c-icap-modules/patches/patch-configure b/www/c-icap-modules/patches/patch-configure
new file mode 100644
index 00000000000..7b24c48d88d
--- /dev/null
+++ b/www/c-icap-modules/patches/patch-configure
@@ -0,0 +1,29 @@
+$NetBSD: patch-configure,v 1.1.1.1 2011/05/11 04:30:06 adam Exp $
+
+Detect Berkeley DB.
+
+--- configure.orig 2011-05-05 13:16:38.000000000 +0000
++++ configure
+@@ -11053,11 +11053,11 @@ rm -f core conftest.err conftest.$ac_obj
+ # Save old CFLAGS/LDFLAGS
+ OLDCFLAGS=$CFLAGS
+ OLDLDFLAGS=$LDFLAGS
+- for DBVER in 49 48 47 46 45 44 43 42; do
++ for DBVER in 4 5 6; do
+ if test -d $libdbpath/include/db$DBVER; then
+ echo -n "checking for Berleley DB under $libdbpath/include/db$DBVER and $libdbpath/lib/db$DBVER... "
+ CFLAGS="-I$libdbpath/include/db$DBVER $OLDCFLAGS"
+- LDFLAGS="-L $libdbpath/lib/db$DBVER -ldb $OLDLDFLAGS"
++ LDFLAGS="-L $libdbpath/lib -ldb$DBVER $OLDLDFLAGS"
+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+ /* end confdefs.h. */
+
+@@ -11071,7 +11071,7 @@ rm -f core conftest.err conftest.$ac_obj
+
+ _ACEOF
+ if ac_fn_c_try_link "$LINENO"; then :
+- echo yes;BDB_ADD_LDFLAG="-L$libdbpath/lib/db$DBVER -ldb"; BDB_ADD_FLAG="-I$libdbpath/include/db$DBVER";libdb="yes";
++ echo yes;BDB_ADD_LDFLAG="-L$libdbpath/lib -ldb$DBVER"; BDB_ADD_FLAG="-I$libdbpath/include/db$DBVER";libdb="yes";
+ else
+ libdb="no"; echo "no";
+
diff --git a/www/c-icap-modules/patches/patch-services_clamav_Makefile.in b/www/c-icap-modules/patches/patch-services_clamav_Makefile.in
new file mode 100644
index 00000000000..d3d44e49b18
--- /dev/null
+++ b/www/c-icap-modules/patches/patch-services_clamav_Makefile.in
@@ -0,0 +1,16 @@
+$NetBSD: patch-services_clamav_Makefile.in,v 1.1.1.1 2011/05/11 04:30:06 adam Exp $
+
+Handle configuration files.
+
+--- services/clamav/Makefile.in.orig 2011-05-05 13:25:53.000000000 +0000
++++ services/clamav/Makefile.in
+@@ -548,8 +548,7 @@ uninstall-am: uninstall-cicapmoduleLTLIB
+
+
+ install-data-local:
+- $(INSTALL) srv_clamav.conf $(DESTDIR)$(CONFIGDIR)/srv_clamav.conf.default
+- if test ! -f $(DESTDIR)$(CONFIGDIR)/srv_clamav.conf; then $(INSTALL) srv_clamav.conf $(DESTDIR)$(CONFIGDIR)/srv_clamav.conf; fi
++ $(INSTALL) srv_clamav.conf $(DESTDIR)$(datadir)/c-icap/srv_clamav.conf.default
+
+ # Tell versions [3.59,3.63) of GNU make to not export all variables.
+ # Otherwise a system limit (for SysV at least) may be exceeded.
diff --git a/www/c-icap-modules/patches/patch-services_url_check_Makefile.in b/www/c-icap-modules/patches/patch-services_url_check_Makefile.in
new file mode 100644
index 00000000000..1b8eb324378
--- /dev/null
+++ b/www/c-icap-modules/patches/patch-services_url_check_Makefile.in
@@ -0,0 +1,26 @@
+$NetBSD: patch-services_url_check_Makefile.in,v 1.1.1.1 2011/05/11 04:30:06 adam Exp $
+
+Remove unwanted linker flag.
+Handle configuration files.
+
+--- services/url_check/Makefile.in.orig 2011-05-05 13:19:55.000000000 +0000
++++ services/url_check/Makefile.in
+@@ -34,7 +34,7 @@ PRE_UNINSTALL = :
+ POST_UNINSTALL = :
+ build_triplet = @build@
+ host_triplet = @host@
+-@USEBDB_TRUE@am__append_1 = @BDB_ADD_LDFLAG@ -ldb
++@USEBDB_TRUE@am__append_1 = @BDB_ADD_LDFLAG@
+ @USEBDB_TRUE@am__append_2 = @BDB_ADD_FLAG@
+ @USEBDB_TRUE@am__append_3 = sguardDB.c
+ subdir = services/url_check
+@@ -554,8 +554,7 @@ uninstall-am: uninstall-cicapmoduleLTLIB
+
+
+ install-data-local:
+- $(INSTALL) srv_url_check.conf $(DESTDIR)$(CONFIGDIR)/srv_url_check.conf.default
+- if test ! -f $(DESTDIR)$(CONFIGDIR)/srv_url_check.conf; then $(INSTALL) srv_url_check.conf $(DESTDIR)$(CONFIGDIR)/srv_url_check.conf; fi
++ $(INSTALL) srv_url_check.conf $(DESTDIR)$(datadir)/c-icap/srv_url_check.conf.default
+
+ # Tell versions [3.59,3.63) of GNU make to not export all variables.
+ # Otherwise a system limit (for SysV at least) may be exceeded.