2 # Copyright (C) 2006 OpenWrt.org
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
9 include $(TOPDIR
)/rules.mk
12 PKG_VERSION
:=2.6.STABLE14
15 PKG_SOURCE
:=$(PKG_NAME
)-$(PKG_VERSION
).
tar.bz2
16 PKG_SOURCE_URL
:=http
://www.squid-cache.org
/Versions
/v2
/2.6/
17 PKG_MD5SUM
:=eadb138d48320df8b99349121159c6bf
19 include $(INCLUDE_DIR
)/package.mk
21 define Package
/squid
/Default
24 URL
:=http
://www.squid-cache.org
/
28 $(call Package
/squid
/Default
)
30 DEPENDS
:=+libopenssl
+libpthread @LINUX_2_6
31 TITLE
:=full-featured Web proxy cache
34 define Package
/squid
/description
35 Squid is a high-performance proxy caching server for web clients
,
36 supporting FTP
, gopher
, and HTTP data objects. Unlike traditional
37 caching software
, Squid handles
all requests in a single
,
38 non-blocking
, I
/O-driven process.
41 define Package
/squid
/conffiles
46 define Package
/squid-mod-cachemgr
47 $(call Package
/squid
/Default
)
49 TITLE
:=Web based proxy manager and reporting tool
52 define Package
/squid-mod-basic-auth-getpwnam
53 $(call Package
/squid
/Default
)
55 TITLE
:=getpwnam basic authentication helper
58 define Package
/squid-mod-basic-auth-ncsa
59 $(call Package
/squid
/Default
)
61 TITLE
:=NCSA basic authentication helper
64 define Package
/squid-mod-basic-auth-smb
65 $(call Package
/squid
/Default
)
67 TITLE
:=Samba basic authentication helper
70 define Package
/squid-mod-digest-auth-password
71 $(call Package
/squid
/Default
)
73 TITLE
:=Password digest authentication helper
76 define Package
/squid-mod-external-acl-ip-user
77 $(call Package
/squid
/Default
)
79 TITLE
:=IP user external ACL helper
82 define Package
/squid-mod-external-acl-unix-group
83 $(call Package
/squid
/Default
)
85 TITLE
:=Unix group external ACL helper
88 define Package
/squid-mod-ntlm-auth-fakeauth
89 $(call Package
/squid
/Default
)
91 TITLE
:=Fakeauth NTLM authentication helper
94 define Package
/squid-mod-ntlm-auth-smb-auth
95 $(call Package
/squid
/Default
)
97 TITLE
:=Samba NTLM authentication helper
100 define Build
/Configure
101 $(call Build
/Configure
/Default
, \
102 --datadir=/usr
/share
/squid \
103 --libexecdir
=/usr
/lib
/squid \
104 --sysconfdir
=/etc
/squid \
107 --enable-x-accelerator-vary \
111 --enable-kill-parent-hack \
115 --enable-err-languages
=English \
116 --enable-default-err-language
=English \
117 --enable-linux-netfilter \
119 --enable-external-acl-helpers
="" \
120 --enable-underscores \
121 --enable-cache-digests \
122 --enable-referer-log \
123 --enable-delay-pools \
124 --enable-useragent-log \
125 --with-openssl
=$(STAGING_DIR
)/usr \
126 --enable-auth
="basic digest ntlm" \
127 --enable-basic-auth-helpers
="getpwnam NCSA SMB" \
128 --enable-ntlm-auth-helpers
="fakeauth SMB" \
129 --enable-digest-auth-helpers
="password" \
130 --enable-external-acl-helpers
="ip_user unix_group" \
137 # pass INCLUDES to compile host sources against our OpenSSL, not the host one
138 $(MAKE
) -C
$(PKG_BUILD_DIR
)/lib \
139 INCLUDES
="-I$(STAGING_DIR)/usr/include -I$(STAGING_DIR)/include" \
141 $(MAKE
) -C
$(PKG_BUILD_DIR
) \
142 DESTDIR
="$(PKG_INSTALL_DIR)" \
147 define Package
/$(1)/install
148 $(INSTALL_DIR
) $$(1)/usr
/lib
/squid
149 $(CP
) $(PKG_INSTALL_DIR
)/usr
/lib
/squid
/$(2) $$(1)/usr
/lib
/squid
/
152 $$(eval
$$(call BuildPackage
,$(1)))
155 define Package
/squid
/install
156 $(INSTALL_DIR
) $(1)/etc
/squid
157 $(CP
) $(PKG_INSTALL_DIR
)/etc
/squid
/mime.conf
$(1)/etc
/squid
/
158 $(CP
) $(PKG_INSTALL_DIR
)/etc
/squid
/squid.conf
$(1)/etc
/squid
/
159 $(INSTALL_DIR
) $(1)/usr
/share
/squid
160 $(CP
) $(PKG_INSTALL_DIR
)/usr
/share
/squid
/* $(1)/usr
/share
/squid
/
161 $(INSTALL_DIR
) $(1)/usr
/sbin
162 $(INSTALL_BIN
) $(PKG_INSTALL_DIR
)/usr
/sbin
/squid
$(1)/usr
/sbin
/
163 $(INSTALL_DIR
) $(1)/usr
/lib
/squid
164 $(CP
) $(PKG_INSTALL_DIR
)/usr
/lib
/squid
/{unlinkd
,pinger
} $(1)/usr
/lib
/squid
/
167 define Package
/squid-mod-cachemgr
/install
168 $(INSTALL_DIR
) $(1)/www
/cgi-bin
/
169 $(CP
) $(PKG_INSTALL_DIR
)/usr
/lib
/squid
/cachemgr.cgi
$(1)/www
/cgi-bin
/
172 $(eval
$(call BuildPackage
,squid
))
173 $(eval
$(call BuildPackage
,squid-mod-cachemgr
))
174 $(eval
$(call BuildPlugin
,squid-mod-basic-auth-getpwnam
,getpwname_auth
))
175 $(eval
$(call BuildPlugin
,squid-mod-basic-auth-ncsa
,ncsa_auth
))
176 $(eval
$(call BuildPlugin
,squid-mod-basic-auth-smb
,smb_auth
))
177 $(eval
$(call BuildPlugin
,squid-mod-digest-auth-password
,digest_pw_auth
))
178 $(eval
$(call BuildPlugin
,squid-mod-external-acl-ip-user
,ip_user_check
))
179 $(eval
$(call BuildPlugin
,squid-mod-external-acl-unix-group
,squid_unix_group
))
180 $(eval
$(call BuildPlugin
,squid-mod-ntlm-auth-fakeauth
,fakeauth_auth
))
181 $(eval
$(call BuildPlugin
,squid-mod-ntlm-auth-smb-auth
,ntlm_auth
))
183 $(eval
$(call RequireHeader
,/usr
/include/openssl
/ssl.h
, \
184 $(PKG_NAME
) requires the openssl development
(named like libssl-dev
, \
185 depending of your package manager
) package be installed on the host-system. \