1 ################################################################################
5 ################################################################################
7 SQUID_VERSION_MAJOR
= 3.5
8 SQUID_VERSION
= $(SQUID_VERSION_MAJOR
).24
9 SQUID_SOURCE
= squid-
$(SQUID_VERSION
).
tar.xz
10 SQUID_SITE
= http
://www.squid-cache.org
/Versions
/v3
/$(SQUID_VERSION_MAJOR
)
11 SQUID_LICENSE
= GPLv2
+
12 SQUID_LICENSE_FILES
= COPYING
13 # For 0001-assume-get-certificate-ok.patch
14 SQUID_AUTORECONF
= YES
15 SQUID_DEPENDENCIES
= libcap host-libcap host-pkgconf \
16 $(if
$(BR2_PACKAGE_LIBNETFILTER_CONNTRACK
),libnetfilter_conntrack
)
18 ac_cv_epoll_works
=yes \
19 ac_cv_func_setresuid
=yes \
20 ac_cv_func_va_copy
=yes \
21 ac_cv_func___va_copy
=yes \
22 ac_cv_func_strnstr
=no \
23 ac_cv_have_squid
=yes \
24 BUILXCXX
="$(HOSTCXX)" \
25 BUILDCXXFLAGS
="$(HOST_CXXFLAGS)"
28 $(if
$(BR2_TOOLCHAIN_USES_MUSL
),--disable-linux-netfilter
,--enable-linux-netfilter
) \
29 --enable-removal-policies
="lru,heap" \
30 --with-filedescriptors
=1024 \
31 --disable-ident-lookups \
33 --enable-auth-basic
="fake getpwnam" \
34 --enable-auth-digest
="file" \
35 --enable-auth-negotiate
="wrapper" \
36 --enable-auth-ntlm
="fake" \
37 --disable-strict-error-checking \
38 --enable-external-acl-helpers
="file_userip" \
39 --with-logdir
=/var
/log
/squid
/ \
40 --with-pidfile
=/var
/run
/squid.pid \
41 --with-swapdir
=/var
/cache
/squid
/ \
42 --with-default-user
=squid
44 # Atomics in Squid use __sync built-ins on 4 and 8 bytes. However, the
45 # configure script tests them using AC_TRY_RUN, so we have to give
47 ifeq ($(BR2_TOOLCHAIN_HAS_SYNC_4
)$(BR2_TOOLCHAIN_HAS_SYNC_8
),yy
)
48 SQUID_CONF_ENV
+= squid_cv_gnu_atomics
=yes
50 SQUID_CONF_ENV
+= squid_cv_gnu_atomics
=no
53 # On uClibc librt needs libpthread
54 ifeq ($(BR2_TOOLCHAIN_HAS_THREADS
)$(BR2_TOOLCHAIN_USES_UCLIBC
),yy
)
55 SQUID_CONF_ENV
+= ac_cv_search_shm_open
="-lrt -lpthread"
58 ifeq ($(BR2_PACKAGE_OPENSSL
),y
)
59 SQUID_CONF_OPTS
+= --with-openssl
60 SQUID_DEPENDENCIES
+= openssl
62 SQUID_CONF_OPTS
+= --without-openssl
65 ifeq ($(BR2_PACKAGE_GNUTLS
),y
)
66 SQUID_CONF_OPTS
+= --with-gnutls
67 SQUID_DEPENDENCIES
+= gnutls
69 SQUID_CONF_OPTS
+= --without-gnutls
72 define SQUID_CLEANUP_TARGET
73 rm -f
$(addprefix $(TARGET_DIR
)/usr
/bin
/, \
75 rm -f
$(addprefix $(TARGET_DIR
)/etc
/, \
76 cachemgr.conf mime.conf.default squid.conf.default
)
79 SQUID_POST_INSTALL_TARGET_HOOKS
+= SQUID_CLEANUP_TARGET
82 squid
-1 squid
-1 * - - - Squid proxy cache
85 define SQUID_INSTALL_INIT_SYSV
86 $(INSTALL
) -m
755 -D package
/squid
/S97squid \
87 $(TARGET_DIR
)/etc
/init.d
/S97squid
90 define SQUID_INSTALL_INIT_SYSTEMD
91 $(INSTALL
) -D
-m
0644 $(@D
)/tools
/systemd
/squid.service \
92 $(TARGET_DIR
)/usr
/lib
/systemd
/system
/squid.service
93 mkdir
-p
$(TARGET_DIR
)/etc
/systemd
/system
/multi-user.target.wants
94 ln
-sf ..
/..
/..
/..
//usr
/lib
/systemd
/system
/squid.service \
95 $(TARGET_DIR
)/etc
/systemd
/system
/multi-user.target.wants
/squid.service
98 $(eval
$(autotools-package
))