Makefile revision 5452
5696N/A#
5696N/A# CDDL HEADER START
5696N/A#
5696N/A# The contents of this file are subject to the terms of the
5696N/A# Common Development and Distribution License (the "License").
5696N/A# You may not use this file except in compliance with the License.
5696N/A#
5696N/A# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
5696N/A# or http://www.opensolaris.org/os/licensing.
5696N/A# See the License for the specific language governing permissions
5696N/A# and limitations under the License.
5696N/A#
5696N/A# When distributing Covered Code, include this CDDL HEADER in each
5696N/A# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
5696N/A# If applicable, add the following below this CDDL HEADER, with the
5696N/A# fields enclosed by brackets "[]" replaced with your own identifying
5696N/A# information: Portions Copyright [yyyy] [name of copyright owner]
5696N/A#
5696N/A# CDDL HEADER END
5696N/A#
5696N/A
5696N/A#
5696N/A# Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved.
5696N/A#
5696N/A
5696N/ACOMPILER = gcc
5696N/A
5696N/Ainclude ../../make-rules/shared-macros.mk
5696N/A
5696N/APATH=/usr/bin:/usr/gnu/bin:/usr/sbin:/usr/perl5/bin
5696N/A
5696N/ACOMPONENT_NAME= squid
5696N/ACOMPONENT_VERSION= 3.5.5
5696N/ACOMPONENT_PROJECT_URL= http://www.squid-cache.org/
5696N/ACOMPONENT_SRC= $(COMPONENT_NAME)-$(COMPONENT_VERSION)
5696N/ACOMPONENT_ARCHIVE= $(COMPONENT_SRC).tar.xz
5696N/ACOMPONENT_ARCHIVE_HASH= \
5696N/A sha256:23793da6b23871765188becae59a6f4b6c3672c256ba9be90743b46a3c7921cf
5696N/ACOMPONENT_ARCHIVE_URL= $(COMPONENT_PROJECT_URL)Versions/v3/3.5/$(COMPONENT_ARCHIVE)
5696N/ACOMPONENT_BUGDB= utility/squid
5696N/A
5696N/ATPNO= 23264
5696N/A
5696N/Ainclude $(WS_MAKE_RULES)/prep.mk
5696N/Ainclude $(WS_MAKE_RULES)/configure.mk
5696N/Ainclude $(WS_MAKE_RULES)/ips.mk
5696N/A
5696N/ACC += $(CC_BITS)
5696N/ACXX += $(CC_BITS)
5696N/A
5696N/ACFLAGS += -I/usr/include/kerberosv5
5696N/ACFLAGS += $(CPP_LARGEFILES)
5696N/A
5696N/ACONFIGURE_BINDIR.64 = $(CONFIGURE_PREFIX)/bin
5696N/ACONFIGURE_LIBDIR.64 = $(CONFIGURE_PREFIX)/lib
5696N/ACONFIGURE_OPTIONS.64 += LDFLAGS="$(LDFLAGS) -m64"
5696N/ACONFIGURE_OPTIONS.64 += LIBS="-m64"
5696N/A
5696N/A# Squid has own prefix
5696N/ACONFIGURE_PREFIX = /usr/squid
5696N/A
5696N/ACONFIGURE_OPTIONS += CFLAGS="$(CFLAGS)"
5696N/ACONFIGURE_OPTIONS += --libexecdir=$(CONFIGURE_PREFIX)/libexec
5696N/ACONFIGURE_OPTIONS += --localstatedir=/var/squid
5696N/ACONFIGURE_OPTIONS += --sharedstatedir=/var/squid
5696N/ACONFIGURE_OPTIONS += --sysconfdir=$(ETCDIR)/squid
5696N/ACONFIGURE_OPTIONS += --mandir=$(CONFIGURE_PREFIX)/man
5696N/ACONFIGURE_OPTIONS += --sbindir=$(CONFIGURE_PREFIX)/sbin
5696N/ACONFIGURE_OPTIONS += --enable-arp-acl
5696N/ACONFIGURE_OPTIONS += --enable-auth-basic='DB,NCSA,NIS,LDAP,PAM,getpwnam,MSNT-multi-domain,POP3,SMB,SMB_LM,SASL'
5696N/ACONFIGURE_OPTIONS += --enable-cache-digests
5696N/ACONFIGURE_OPTIONS += --enable-carp
5696N/ACONFIGURE_OPTIONS += --enable-coss-aio-ops
5696N/ACONFIGURE_OPTIONS += --enable-delay-pools
5696N/ACONFIGURE_OPTIONS += --enable-auth-digest='file,LDAP'
5696N/ACONFIGURE_OPTIONS += --enable-external-acl-helpers='file_userip,unix_group,LDAP_group,wbinfo_group'
5696N/ACONFIGURE_OPTIONS += --enable-follow-x-forwarded-for
5696N/ACONFIGURE_OPTIONS += --enable-forward-log
5696N/ACONFIGURE_OPTIONS += --enable-forw-via-db
5696N/ACONFIGURE_OPTIONS += --enable-htcp
5696N/ACONFIGURE_OPTIONS += --enable-icmp
5696N/ACONFIGURE_OPTIONS += --enable-large-cache-files
5696N/ACONFIGURE_OPTIONS += --enable-multicast-miss
5696N/ACONFIGURE_OPTIONS += --enable-auth-negotiate='kerberos'
5696N/ACONFIGURE_OPTIONS += --enable-auth-ntlm='smb_lm,fake'
5696N/ACONFIGURE_OPTIONS += --enable-ntlm-fail-open
5696N/ACONFIGURE_OPTIONS += --enable-removal-policies='heap,lru'
5696N/ACONFIGURE_OPTIONS += --enable-snmp
5696N/ACONFIGURE_OPTIONS += --enable-ssl
5696N/ACONFIGURE_OPTIONS += --enable-storeio='aufs,diskd,ufs'
CONFIGURE_OPTIONS += --enable-x-accelerator-vary
CONFIGURE_OPTIONS += --with-aio
CONFIGURE_OPTIONS += --with-aufs-threads=8
CONFIGURE_OPTIONS += --with-build-environment=POSIX_V6_ILP32_OFFBIG
CONFIGURE_OPTIONS += --with-pthreads
CONFIGURE_OPTIONS += --without-nettle
CONFIGURE_OPTIONS += --disable-arch-native
COMPONENT_BUILD_ARGS += CFLAGS="$(CFLAGS)"
# Appends the following line to the end of the squid.conf configuration
# file. This line is necessary for running squid for testing.
# This starts up squid as user webservd.
COMPONENT_POST_INSTALL_ACTION += \
(cd $(PROTO_DIR)/etc/squid ; \
echo '\ncache_effective_user webservd' >> squid.conf)
ASLR_MODE = $(ASLR_ENABLE)
# common targets
configure: $(CONFIGURE_64)
build: $(BUILD_64)
install: $(INSTALL_64)
# configure says it needs cppunit to test with.
# After some work I can get cppunit to build but it quickly
# falls over during test so giving up.
# I don't think the test suite really tests squid's functionality anyways.
#
# To test manually follow along in the book
# Squid Proxy Server 3.1 Beginner's Guide Page 34
#
# Add this to the top of /etc/squid/squid.conf:
# cache_dir ufs /var/squid/cache/ 500 16 256
# acl my_machine src 192.0.2.21 # Replace with your desktop's IP address
# http_access allow my_machine
#
# You will probably need to remove or comment out the following lines or Squid
# will fail to start:
# # acl manager proto cache_object
#
# Make sure apache is running.
# # svcs apache22
# Start squid:
# # svcadm enable squid
# On your desktop set your web browser to proxy through this squid:
# Edit -> Preferences -> Advanced -> Network -> Settings
# Check: Manual proxy configuration
# HTTP Proxy: <squid servers IP address> Port: 3128
# Save
# Enter <squid server URL> in your web browser. You should be accessing squid
# and seeing files stored in the http server on that machine.
# Enter <squid server URL>:897 in your web browser and squid should complain.
# Squid is working properly.
test: $(NO_TESTS)
system-test: $(NO_TESTS)
REQUIRED_PACKAGES += library/libtool/libltdl
REQUIRED_PACKAGES += library/security/openssl
REQUIRED_PACKAGES += runtime/perl-512
REQUIRED_PACKAGES += runtime/perl-520
REQUIRED_PACKAGES += shell/ksh93
REQUIRED_PACKAGES += system/core-os
REQUIRED_PACKAGES += system/library
REQUIRED_PACKAGES += system/library/gcc/gcc-c-runtime
REQUIRED_PACKAGES += system/library/gcc/gcc-c++-runtime
REQUIRED_PACKAGES += system/library/math
REQUIRED_PACKAGES += system/library/security/crypto
REQUIRED_PACKAGES += system/library/security/gss
REQUIRED_PACKAGES += system/library/security/libsasl
REQUIRED_PACKAGES += system/library/security/libsasl2
REQUIRED_PACKAGES += system/network
REQUIRED_PACKAGES += service/security/kerberos-5