2 # Copyright (C) 2006-2010 OpenWrt.org
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
8 include $(TOPDIR
)/rules.mk
11 PKG_VERSION
:=2.7.STABLE9
14 PKG_SOURCE
:=$(PKG_NAME
)-$(PKG_VERSION
).
tar.bz2
15 PKG_SOURCE_URL
:=http
://www.squid-cache.org
/Versions
/v2
/2.7/
16 PKG_MD5SUM
:=3c6642c85470b1079207d43bba25a819
18 include $(INCLUDE_DIR
)/package.mk
20 define Package
/squid
/Default
23 URL
:=http
://www.squid-cache.org
/
27 $(call Package
/squid
/Default
)
29 DEPENDS
:=+libopenssl
+libpthread @LINUX_2_6
30 TITLE
:=full-featured Web proxy cache
33 define Package
/squid
/description
34 Squid is a high-performance proxy caching server for web clients
,
35 supporting FTP
, gopher
, and HTTP data objects. Unlike traditional
36 caching software
, Squid handles
all requests in a single
,
37 non-blocking
, I
/O-driven process.
40 define Package
/squid
/conffiles
45 define Package
/squid-mod-cachemgr
46 $(call Package
/squid
/Default
)
48 TITLE
:=Web based proxy manager and reporting tool
51 define Package
/squid-mod-basic-auth-getpwnam
52 $(call Package
/squid
/Default
)
54 TITLE
:=getpwnam basic authentication helper
57 define Package
/squid-mod-basic-auth-ncsa
58 $(call Package
/squid
/Default
)
60 TITLE
:=NCSA basic authentication helper
63 define Package
/squid-mod-basic-auth-smb
64 $(call Package
/squid
/Default
)
66 TITLE
:=Samba basic authentication helper
69 define Package
/squid-mod-digest-auth-password
70 $(call Package
/squid
/Default
)
72 TITLE
:=Password digest authentication helper
75 define Package
/squid-mod-external-acl-ip-user
76 $(call Package
/squid
/Default
)
78 TITLE
:=IP user external ACL helper
81 define Package
/squid-mod-external-acl-unix-group
82 $(call Package
/squid
/Default
)
84 TITLE
:=Unix group external ACL helper
87 define Package
/squid-mod-ntlm-auth-fakeauth
88 $(call Package
/squid
/Default
)
90 TITLE
:=Fakeauth NTLM authentication helper
93 define Package
/squid-mod-ntlm-auth-smb-auth
94 $(call Package
/squid
/Default
)
96 TITLE
:=Samba NTLM authentication helper
100 --datadir=/usr
/share
/squid \
101 --libexecdir
=/usr
/lib
/squid \
102 --sysconfdir
=/etc
/squid \
105 --enable-x-accelerator-vary \
109 --enable-kill-parent-hack \
113 --enable-err-languages
=English \
114 --enable-default-err-language
=English \
115 --enable-linux-netfilter \
117 --enable-external-acl-helpers
="" \
118 --enable-underscores \
119 --enable-cache-digests \
120 --enable-referer-log \
121 --enable-delay-pools \
122 --enable-useragent-log \
123 --with-openssl
=$(STAGING_DIR
)/usr \
124 --enable-auth
="basic digest ntlm" \
125 --enable-basic-auth-helpers
="getpwnam NCSA SMB" \
126 --enable-ntlm-auth-helpers
="fakeauth SMB" \
127 --enable-digest-auth-helpers
="password" \
128 --enable-external-acl-helpers
="ip_user unix_group" \
133 ac_cv_header_linux_netfilter_ipv4_h
=yes \
134 ac_cv_epoll_works
=yes \
137 # pass INCLUDES to compile host sources against our OpenSSL, not the host one
138 $(MAKE
) -C
$(PKG_BUILD_DIR
)/lib \
140 $(MAKE
) -C
$(PKG_BUILD_DIR
) \
141 DESTDIR
="$(PKG_INSTALL_DIR)" \
146 define Package
/$(1)/install
147 $(INSTALL_DIR
) $$(1)/usr
/lib
/squid
148 $(CP
) $(PKG_INSTALL_DIR
)/usr
/lib
/squid
/$(2) $$(1)/usr
/lib
/squid
/
151 $$(eval
$$(call BuildPackage
,$(1)))
154 define Package
/squid
/install
155 $(INSTALL_DIR
) $(1)/etc
/squid
156 $(CP
) $(PKG_INSTALL_DIR
)/etc
/squid
/mime.conf
$(1)/etc
/squid
/
157 $(CP
) $(PKG_INSTALL_DIR
)/etc
/squid
/squid.conf
$(1)/etc
/squid
/
158 $(INSTALL_DIR
) $(1)/usr
/share
/squid
159 $(CP
) $(PKG_INSTALL_DIR
)/usr
/share
/squid
/* $(1)/usr
/share
/squid
/
160 $(INSTALL_DIR
) $(1)/usr
/sbin
161 $(INSTALL_BIN
) $(PKG_INSTALL_DIR
)/usr
/sbin
/squid
$(1)/usr
/sbin
/
162 $(INSTALL_DIR
) $(1)/usr
/lib
/squid
163 $(CP
) $(PKG_INSTALL_DIR
)/usr
/lib
/squid
/{unlinkd
,pinger
,logfile-daemon
} $(1)/usr
/lib
/squid
/
166 define Package
/squid-mod-cachemgr
/install
167 $(INSTALL_DIR
) $(1)/www
/cgi-bin
/
168 $(CP
) $(PKG_INSTALL_DIR
)/usr
/lib
/squid
/cachemgr.cgi
$(1)/www
/cgi-bin
/
171 $(eval
$(call RequireHeader
,/usr
/include/openssl
/ssl.h
, \
172 $(PKG_NAME
) requires the openssl development
(named like libssl-dev
, \
173 depending of your package manager
) package be installed on the host-system. \
176 $(eval
$(call BuildPackage
,squid
))
177 $(eval
$(call BuildPackage
,squid-mod-cachemgr
))
178 $(eval
$(call BuildPlugin
,squid-mod-basic-auth-getpwnam
,getpwname_auth
))
179 $(eval
$(call BuildPlugin
,squid-mod-basic-auth-ncsa
,ncsa_auth
))
180 $(eval
$(call BuildPlugin
,squid-mod-basic-auth-smb
,smb_auth
))
181 $(eval
$(call BuildPlugin
,squid-mod-digest-auth-password
,digest_pw_auth
))
182 $(eval
$(call BuildPlugin
,squid-mod-external-acl-ip-user
,ip_user_check
))
183 $(eval
$(call BuildPlugin
,squid-mod-external-acl-unix-group
,squid_unix_group
))
184 $(eval
$(call BuildPlugin
,squid-mod-ntlm-auth-fakeauth
,fakeauth_auth
))
185 $(eval
$(call BuildPlugin
,squid-mod-ntlm-auth-smb-auth
,ntlm_auth
))