| @@ -1,93 +1,91 @@ | | | @@ -1,93 +1,91 @@ |
1 | # $NetBSD: Makefile,v 1.16 2021/04/21 13:25:32 adam Exp $ | | 1 | # $NetBSD: Makefile,v 1.17 2021/04/25 06:13:05 wiz Exp $ |
2 | | | 2 | |
3 | DISTNAME= squid-4.14 | | 3 | DISTNAME= squid-4.14 |
4 | PKGREVISION= 1 | | 4 | PKGREVISION= 1 |
5 | CATEGORIES= www | | 5 | CATEGORIES= www |
6 | MASTER_SITES= http://www.squid-cache.org/Versions/v4/ | | 6 | MASTER_SITES= http://www.squid-cache.org/Versions/v4/ |
7 | MASTER_SITES+= ftp://ftp.squid-cache.org/pub/squid/ | | | |
8 | MASTER_SITES+= ftp://ftp.squid-cache.org/pub/archive/4/ | | | |
9 | EXTRACT_SUFX= .tar.xz | | 7 | EXTRACT_SUFX= .tar.xz |
10 | | | 8 | |
11 | MAINTAINER= pkgsrc-users@NetBSD.org | | 9 | MAINTAINER= pkgsrc-users@NetBSD.org |
12 | HOMEPAGE= http://www.squid-cache.org/ | | 10 | HOMEPAGE= http://www.squid-cache.org/ |
13 | COMMENT= Post-Harvest_cached WWW proxy cache and accelerator | | 11 | COMMENT= Post-Harvest_cached WWW proxy cache and accelerator |
14 | LICENSE= gnu-gpl-v2 | | 12 | LICENSE= gnu-gpl-v2 |
15 | | | 13 | |
16 | USE_LANGUAGES= c c++11 | | 14 | USE_LANGUAGES= c c++11 |
17 | USE_TOOLS+= perl:run gmake | | 15 | USE_TOOLS+= perl:run gmake |
18 | GNU_CONFIGURE= yes | | 16 | GNU_CONFIGURE= yes |
19 | GNU_CONFIGURE_STRICT= no # has sub-configure in libltdl | | 17 | GNU_CONFIGURE_STRICT= no # has sub-configure in libltdl |
20 | CONFIGURE_ARGS+= --sysconfdir=${PKG_SYSCONFDIR} | | 18 | CONFIGURE_ARGS+= --sysconfdir=${PKG_SYSCONFDIR} |
21 | CONFIGURE_ARGS+= --localstatedir=${SQUID_DATADIR} | | 19 | CONFIGURE_ARGS+= --localstatedir=${SQUID_DATADIR} |
22 | CONFIGURE_ARGS+= --datarootdir=${PREFIX}/share/squid | | 20 | CONFIGURE_ARGS+= --datarootdir=${PREFIX}/share/squid |
23 | CONFIGURE_ARGS+= --disable-arch-native | | 21 | CONFIGURE_ARGS+= --disable-arch-native |
24 | CONFIGURE_ARGS+= --enable-cachemgr-hostname=localhost | | 22 | CONFIGURE_ARGS+= --enable-cachemgr-hostname=localhost |
25 | CONFIGURE_ARGS+= --enable-delay-pools | | 23 | CONFIGURE_ARGS+= --enable-delay-pools |
26 | CONFIGURE_ARGS+= --enable-icap-client | | 24 | CONFIGURE_ARGS+= --enable-icap-client |
27 | CONFIGURE_ARGS+= --enable-icmp | | 25 | CONFIGURE_ARGS+= --enable-icmp |
28 | CONFIGURE_ARGS+= --enable-poll | | 26 | CONFIGURE_ARGS+= --enable-poll |
29 | CONFIGURE_ARGS+= --enable-removal-policies=lru,heap | | 27 | CONFIGURE_ARGS+= --enable-removal-policies=lru,heap |
30 | CONFIGURE_ARGS+= --enable-storeio=${SQUID_BACKENDS:Q} | | 28 | CONFIGURE_ARGS+= --enable-storeio=${SQUID_BACKENDS:Q} |
31 | CONFIGURE_ARGS+= --with-aio | | 29 | CONFIGURE_ARGS+= --with-aio |
32 | CONFIGURE_ARGS+= --with-default-user=${SQUID_USER} | | 30 | CONFIGURE_ARGS+= --with-default-user=${SQUID_USER} |
33 | CONFIGURE_ARGS+= --with-pidfile=${VARBASE}/run/squid.pid | | 31 | CONFIGURE_ARGS+= --with-pidfile=${VARBASE}/run/squid.pid |
34 | | | 32 | |
35 | # Let 'purge' find correct config file by default. | | 33 | # Let 'purge' find correct config file by default. |
36 | CPPFLAGS+= -DDEFAULT_SQUID_CONF=\"${PKG_SYSCONFDIR}/squid.conf\" | | 34 | CPPFLAGS+= -DDEFAULT_SQUID_CONF=\"${PKG_SYSCONFDIR}/squid.conf\" |
37 | | | 35 | |
38 | BUILDLINK_TRANSFORM+= rm:-Werror | | 36 | BUILDLINK_TRANSFORM+= rm:-Werror |
39 | | | 37 | |
40 | MAKE_ENV+= INSTALL_SCRIPT=${INSTALL_SCRIPT:Q} | | 38 | MAKE_ENV+= INSTALL_SCRIPT=${INSTALL_SCRIPT:Q} |
41 | MAKE_ENV+= PKG_PREFIX=${PREFIX} VARBASE=${VARBASE} | | 39 | MAKE_ENV+= PKG_PREFIX=${PREFIX} VARBASE=${VARBASE} |
42 | REPLACE_PERL+= contrib/url-normalizer.pl contrib/user-agents.pl \ | | 40 | REPLACE_PERL+= contrib/url-normalizer.pl contrib/user-agents.pl \ |
43 | scripts/AnnounceCache.pl scripts/access-log-matrix.pl \ | | 41 | scripts/AnnounceCache.pl scripts/access-log-matrix.pl \ |
44 | scripts/cache-compare.pl scripts/cachetrace.pl \ | | 42 | scripts/cache-compare.pl scripts/cachetrace.pl \ |
45 | scripts/calc-must-ids.pl scripts/check_cache.pl \ | | 43 | scripts/calc-must-ids.pl scripts/check_cache.pl \ |
46 | scripts/fileno-to-pathname.pl scripts/find-alive.pl \ | | 44 | scripts/fileno-to-pathname.pl scripts/find-alive.pl \ |
47 | scripts/flag_truncs.pl scripts/icp-test.pl \ | | 45 | scripts/flag_truncs.pl scripts/icp-test.pl \ |
48 | scripts/icpserver.pl scripts/tcp-banger.pl \ | | 46 | scripts/icpserver.pl scripts/tcp-banger.pl \ |
49 | scripts/trace-job.pl scripts/trace-master.pl \ | | 47 | scripts/trace-job.pl scripts/trace-master.pl \ |
50 | scripts/udp-banger.pl scripts/upgrade-1.0-store.pl \ | | 48 | scripts/udp-banger.pl scripts/upgrade-1.0-store.pl \ |
51 | tools/helper-ok-dying.pl tools/helper-ok.pl | | 49 | tools/helper-ok-dying.pl tools/helper-ok.pl |
52 | EGFILES= src/mime.conf.default src/squid.conf.default \ | | 50 | EGFILES= src/mime.conf.default src/squid.conf.default \ |
53 | errors/errorpage.css tools/cachemgr.conf | | 51 | errors/errorpage.css tools/cachemgr.conf |
54 | EGDIR= share/examples/squid | | 52 | EGDIR= share/examples/squid |
55 | .for f in cachemgr.conf errorpage.css mime.conf squid.conf | | 53 | .for f in cachemgr.conf errorpage.css mime.conf squid.conf |
56 | CONF_FILES+= ${PREFIX}/${EGDIR}/${f} ${PKG_SYSCONFDIR}/${f} | | 54 | CONF_FILES+= ${PREFIX}/${EGDIR}/${f} ${PKG_SYSCONFDIR}/${f} |
57 | .endfor | | 55 | .endfor |
58 | OWN_DIRS= ${SQUID_DATADIR} | | 56 | OWN_DIRS= ${SQUID_DATADIR} |
59 | OWN_DIRS_PERMS+= ${SQUID_DATADIR}/cache ${SQUID_USER} ${SQUID_GROUP} 0750 \ | | 57 | OWN_DIRS_PERMS+= ${SQUID_DATADIR}/cache ${SQUID_USER} ${SQUID_GROUP} 0750 \ |
60 | ${SQUID_DATADIR}/logs ${SQUID_USER} ${SQUID_GROUP} 0750 | | 58 | ${SQUID_DATADIR}/logs ${SQUID_USER} ${SQUID_GROUP} 0750 |
61 | | | 59 | |
62 | .include "Makefile.common" | | 60 | .include "Makefile.common" |
63 | .include "options.mk" | | 61 | .include "options.mk" |
64 | | | 62 | |
65 | # Incorrect check for <netinet/ip_icmp.h> on FreeBSD: | | 63 | # Incorrect check for <netinet/ip_icmp.h> on FreeBSD: |
66 | CONFIGURE_ENV.FreeBSD+= ac_cv_header_netinet_ip_icmp_h=yes | | 64 | CONFIGURE_ENV.FreeBSD+= ac_cv_header_netinet_ip_icmp_h=yes |
67 | | | 65 | |
68 | INSTALLATION_DIRS= ${EGDIR} | | 66 | INSTALLATION_DIRS= ${EGDIR} |
69 | | | 67 | |
70 | SPECIAL_PERMS+= libexec/pinger ${SETUID_ROOT_PERMS} | | 68 | SPECIAL_PERMS+= libexec/pinger ${SETUID_ROOT_PERMS} |
71 | | | 69 | |
72 | RCD_SCRIPTS= squid | | 70 | RCD_SCRIPTS= squid |
73 | RCD_SCRIPT_SRC.squid= files/squid.sh | | 71 | RCD_SCRIPT_SRC.squid= files/squid.sh |
74 | SMF_NAME= squid | | 72 | SMF_NAME= squid |
75 | | | 73 | |
76 | SUBST_CLASSES+= confs | | 74 | SUBST_CLASSES+= confs |
77 | SUBST_STAGE.confs= pre-configure | | 75 | SUBST_STAGE.confs= pre-configure |
78 | SUBST_FILES.confs= src/cf.data.pre | | 76 | SUBST_FILES.confs= src/cf.data.pre |
79 | SUBST_SED.confs= -e "s/@DEFAULT_CACHE_EFFECTIVE_USER@/${SQUID_USER}/" | | 77 | SUBST_SED.confs= -e "s/@DEFAULT_CACHE_EFFECTIVE_USER@/${SQUID_USER}/" |
80 | SUBST_MESSAGE.confs= Fixing configuration files. | | 78 | SUBST_MESSAGE.confs= Fixing configuration files. |
81 | | | 79 | |
82 | post-build: | | 80 | post-build: |
83 | cd ${WRKSRC}/src && ${CP} -pf squid.conf.documented squid.conf.default | | 81 | cd ${WRKSRC}/src && ${CP} -pf squid.conf.documented squid.conf.default |
84 | | | 82 | |
85 | post-install: | | 83 | post-install: |
86 | .for f in ${EGFILES} | | 84 | .for f in ${EGFILES} |
87 | ${INSTALL_DATA} ${WRKSRC}/${f} \ | | 85 | ${INSTALL_DATA} ${WRKSRC}/${f} \ |
88 | ${DESTDIR}${PREFIX}/${EGDIR}/`basename ${f} .default` | | 86 | ${DESTDIR}${PREFIX}/${EGDIR}/`basename ${f} .default` |
89 | .endfor | | 87 | .endfor |
90 | | | 88 | |
91 | .include "../../devel/libltdl/buildlink3.mk" | | 89 | .include "../../devel/libltdl/buildlink3.mk" |
92 | .include "../../mk/atomic64.mk" | | 90 | .include "../../mk/atomic64.mk" |
93 | .include "../../mk/bsd.pkg.mk" | | 91 | .include "../../mk/bsd.pkg.mk" |