2004-01-24 16:18:32 +01:00
|
|
|
# $NetBSD: Makefile,v 1.49 2004/01/24 15:23:47 grant Exp $
|
1998-06-06 19:03:58 +02:00
|
|
|
|
2002-11-08 16:39:55 +01:00
|
|
|
DISTNAME= wwwoffle-2.7f
|
2003-12-23 17:43:56 +01:00
|
|
|
PKGREVISION= 2
|
1998-06-06 19:03:58 +02:00
|
|
|
CATEGORIES= www
|
2002-09-05 18:56:54 +02:00
|
|
|
MASTER_SITES= ${MASTER_SITE_SUNSITE:=apps/www/servers/} \
|
|
|
|
ftp://ftp.demon.co.uk/pub/unix/httpd/ \
|
|
|
|
http://www.gedanken.freeserve.co.uk/download-wwwoffle/
|
1998-06-06 19:03:58 +02:00
|
|
|
EXTRACT_SUFX= .tgz
|
|
|
|
|
2003-07-18 00:50:55 +02:00
|
|
|
MAINTAINER= fredb@NetBSD.org
|
1998-08-20 17:16:34 +02:00
|
|
|
HOMEPAGE= http://www.gedanken.demon.co.uk/wwwoffle/
|
2001-02-17 18:21:28 +01:00
|
|
|
COMMENT= WWW proxy with support for offline browsing
|
1998-06-06 19:03:58 +02:00
|
|
|
|
2004-01-24 16:18:32 +01:00
|
|
|
USE_GNU_TOOLS+= make
|
2003-08-29 11:25:40 +02:00
|
|
|
USE_PKGINSTALL= yes
|
2002-03-10 23:14:29 +01:00
|
|
|
GNU_CONFIGURE= yes
|
1998-06-06 19:03:58 +02:00
|
|
|
|
2002-08-10 19:03:26 +02:00
|
|
|
CONFIGURE_ARGS+= --with-confdir=${PKG_SYSCONFDIR}
|
2002-03-10 23:14:29 +01:00
|
|
|
CONFIGURE_ARGS+= --with-spooldir=/var/wwwoffle
|
1998-07-13 20:20:08 +02:00
|
|
|
|
2003-08-29 11:25:40 +02:00
|
|
|
PKG_SYSCONFSUBDIR= wwwoffle
|
|
|
|
PLIST_SUBST+= GTAR="${GTAR}"
|
|
|
|
INSTALL_EXTRA_TMPL= ${PKGDIR}/INSTALL
|
|
|
|
|
|
|
|
RCD_SCRIPTS= wwwoffled
|
1999-12-07 09:50:49 +01:00
|
|
|
|
1998-06-06 19:03:58 +02:00
|
|
|
post-build:
|
2002-03-10 23:14:29 +01:00
|
|
|
cd ${WRKSRC}/cache/search/htdig/scripts; \
|
2001-03-12 19:05:24 +01:00
|
|
|
for f in wwwoffle-ht*; do \
|
|
|
|
${MV} $$f $$f.old; \
|
|
|
|
${SED} -e '/htsearch/s#^#${PREFIX}/libexec/cgi-bin/#' \
|
2002-08-10 19:03:26 +02:00
|
|
|
-e 's#/usr/local#${PREFIX}#' $$f.old > $$f; \
|
2001-03-12 19:05:24 +01:00
|
|
|
${RM} $$f.old; \
|
|
|
|
done
|
1998-06-06 19:03:58 +02:00
|
|
|
|
2002-09-05 18:56:54 +02:00
|
|
|
# For bulk-build machines: a one-time install/deinstall, if wwwoffle
|
|
|
|
# is never run, leaves an incomplete cache directory, which the install
|
|
|
|
# target incorrectly calculates to be a pre-2.2 cache. This tricks it
|
|
|
|
# into setting up the cache directory properly.
|
|
|
|
pre-install:
|
|
|
|
${MKDIR} /var/wwwoffle/prevtime1
|
|
|
|
|
1998-06-06 19:03:58 +02:00
|
|
|
post-install:
|
2002-08-10 19:03:26 +02:00
|
|
|
if [ -f ${PKG_SYSCONFDIR}/wwwoffle.conf.install ]; then \
|
|
|
|
${CP} -p ${PKG_SYSCONFDIR}/wwwoffle.conf.install \
|
|
|
|
${PREFIX}/share/examples/wwwoffle.conf; \
|
|
|
|
elif [ -f ${PKG_SYSCONFDIR}/wwwoffle.conf ]; then \
|
|
|
|
${CP} -p ${PKG_SYSCONFDIR}/wwwoffle.conf \
|
|
|
|
${PREFIX}/share/examples/wwwoffle.conf; \
|
1999-09-03 23:07:36 +02:00
|
|
|
fi
|
2002-03-10 23:14:29 +01:00
|
|
|
${INSTALL_PROGRAM} ${WRKSRC}/src/convert-cache \
|
2001-03-12 20:08:37 +01:00
|
|
|
${PREFIX}/sbin/wwwoffle-convert-cache
|
2002-03-10 23:14:29 +01:00
|
|
|
${INSTALL_PROGRAM} ${WRKSRC}/src/uncompress-cache \
|
|
|
|
${PREFIX}/sbin/wwwoffle-uncompress-cache
|
|
|
|
${INSTALL_SCRIPT} ${WRKSRC}/conf/upgrade-config.pl \
|
2001-03-12 20:08:37 +01:00
|
|
|
${PREFIX}/sbin/wwwoffle-upgrade-config.pl
|
2002-03-10 23:14:29 +01:00
|
|
|
${INSTALL_SCRIPT} ${WRKSRC}/conf/upgrade-config-2.x-2.5.pl \
|
2001-03-12 20:08:37 +01:00
|
|
|
${PREFIX}/sbin/wwwoffle-upgrade-config-2.x-2.5.pl
|
2002-03-10 23:14:29 +01:00
|
|
|
# Directories other than html and search are automatically created at run time
|
|
|
|
${GTAR} czCf / ${PREFIX}/libdata/wwwoffle-spool.tar.gz \
|
|
|
|
var/wwwoffle/html var/wwwoffle/search
|
2001-03-12 19:05:24 +01:00
|
|
|
@${ECHO}
|
|
|
|
@${ECHO} ==+===+===+===+===+===+===+===+===+===+===+===+===+===+===+=
|
|
|
|
@${ECHO}
|
|
|
|
@${ECHO} Attention pkgsrc source users:
|
|
|
|
@${ECHO}
|
2002-03-25 10:17:55 +01:00
|
|
|
@${ECHO} 'Please run' "\`make finish'" 'from this directory *after*'
|
|
|
|
@${ECHO} '(optionally) running' "\`make package'", 'in order to fix'
|
|
|
|
@${ECHO} 'up the installed "wwwoffle.pac" files to your hostname'
|
|
|
|
@${ECHO} 'and convert your config file and cache to the new format.'
|
2001-03-12 19:05:24 +01:00
|
|
|
@${ECHO}
|
|
|
|
@${ECHO} ==+===+===+===+===+===+===+===+===+===+===+===+===+===+===+=
|
|
|
|
@${ECHO}
|
1998-06-06 19:03:58 +02:00
|
|
|
|
2002-03-25 10:17:55 +01:00
|
|
|
# We don't do the following automatically, as that would inconvenience
|
|
|
|
# package build machines, not to mention putting the wrong information
|
|
|
|
# into the "wwwoffle.pac" files.
|
|
|
|
finish:
|
2002-08-10 19:03:26 +02:00
|
|
|
${SETENV} CONFDIR="${PKG_SYSCONFDIR}" PKG_PREFIX="${PREFIX}" \
|
|
|
|
${SH} INSTALL _ POST-INSTALL
|
2002-03-25 10:17:55 +01:00
|
|
|
|
2002-03-10 23:14:29 +01:00
|
|
|
.include "../../mk/bsd.prefs.mk"
|
|
|
|
|
2002-08-21 04:43:44 +02:00
|
|
|
.if defined(USE_INET6) && ${USE_INET6} == "YES"
|
2002-03-10 23:14:29 +01:00
|
|
|
CONFIGURE_ARGS+= --with-ipv6
|
|
|
|
.endif
|
|
|
|
|
1998-06-06 19:03:58 +02:00
|
|
|
.include "../../mk/bsd.pkg.mk"
|