Makefile revision 1703
0cb2e8eb55e70f8ebe1e8349bdf49e4cbe5d8834Timo Sirainen# CDDL HEADER START
16f816d3f3c32ae3351834253f52ddd0212bcbf3Timo Sirainen# The contents of this file are subject to the terms of the
0cb2e8eb55e70f8ebe1e8349bdf49e4cbe5d8834Timo Sirainen# Common Development and Distribution License (the "License").
0cb2e8eb55e70f8ebe1e8349bdf49e4cbe5d8834Timo Sirainen# You may not use this file except in compliance with the License.
0cb2e8eb55e70f8ebe1e8349bdf49e4cbe5d8834Timo Sirainen# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
0cb2e8eb55e70f8ebe1e8349bdf49e4cbe5d8834Timo Sirainen# See the License for the specific language governing permissions
0cb2e8eb55e70f8ebe1e8349bdf49e4cbe5d8834Timo Sirainen# and limitations under the License.
56561d472db25ebda35ae6afdc7f7deb75c323fcTimo Sirainen# When distributing Covered Code, include this CDDL HEADER in each
687794a61c9e3bf27c712b442b8fc8836c63ae44Timo Sirainen# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
94a8cb0ee1d85569ad1a2acacd92d3ce22f8a1cbTimo Sirainen# If applicable, add the following below this CDDL HEADER, with the
687794a61c9e3bf27c712b442b8fc8836c63ae44Timo Sirainen# fields enclosed by brackets "[]" replaced with your own identifying
0cb2e8eb55e70f8ebe1e8349bdf49e4cbe5d8834Timo Sirainen# information: Portions Copyright [yyyy] [name of copyright owner]
0cb2e8eb55e70f8ebe1e8349bdf49e4cbe5d8834Timo Sirainen# CDDL HEADER END
5a58037ad75b88356d82240fab2bc604de03107eTimo Sirainen# Copyright (c) 2011, 2013, Oracle and/or its affiliates. All rights reserved.
2a6af811ea3de3cf9e2f15e446674dd21b0705f3Timo SirainenPATH=/usr/bin:/usr/gnu/bin:/usr/sbin:/usr/perl5/bin
94a8cb0ee1d85569ad1a2acacd92d3ce22f8a1cbTimo SirainenCOMPONENT_PROJECT_URL= http://www.squid-cache.org/
94a8cb0ee1d85569ad1a2acacd92d3ce22f8a1cbTimo SirainenCOMPONENT_SRC= $(COMPONENT_NAME)-$(COMPONENT_VERSION)
b032dc80e358f09893f09999f172ff12f5dbbb8eTimo Sirainen sha256:ba5f6a7000a032f2315923c1b8d0b37458d33a7f59d603facecf9e8c12470b34
b032dc80e358f09893f09999f172ff12f5dbbb8eTimo SirainenCOMPONENT_ARCHIVE_URL= $(COMPONENT_PROJECT_URL)Versions/v3/3.1/$(COMPONENT_ARCHIVE)
2a6af811ea3de3cf9e2f15e446674dd21b0705f3Timo Sirainen# Squid has own prefix
b032dc80e358f09893f09999f172ff12f5dbbb8eTimo SirainenCONFIGURE_OPTIONS += --libexecdir=$(CONFIGURE_PREFIX)/libexec
94a8cb0ee1d85569ad1a2acacd92d3ce22f8a1cbTimo SirainenCONFIGURE_OPTIONS += --localstatedir=/var/squid
b032dc80e358f09893f09999f172ff12f5dbbb8eTimo SirainenCONFIGURE_OPTIONS += --sharedstatedir=/var/squid
b032dc80e358f09893f09999f172ff12f5dbbb8eTimo SirainenCONFIGURE_OPTIONS += --sysconfdir=$(ETCDIR)/squid
b032dc80e358f09893f09999f172ff12f5dbbb8eTimo SirainenCONFIGURE_OPTIONS += --mandir=$(CONFIGURE_PREFIX)/man
b032dc80e358f09893f09999f172ff12f5dbbb8eTimo SirainenCONFIGURE_OPTIONS += --enable-auth='basic,digest,negotiate,ntlm'
b032dc80e358f09893f09999f172ff12f5dbbb8eTimo SirainenCONFIGURE_OPTIONS += --enable-basic-auth-helpers='DB,NCSA,YP,LDAP,PAM,getpwnam,MSNT,POP3,multi-domain-NTLM,SMB,SASL'
b032dc80e358f09893f09999f172ff12f5dbbb8eTimo SirainenCONFIGURE_OPTIONS += --enable-digest-auth-helpers='ldap,password'
b032dc80e358f09893f09999f172ff12f5dbbb8eTimo SirainenCONFIGURE_OPTIONS += --enable-external-acl-helpers='ip_user,unix_group,ldap_group,wbinfo_group'
b032dc80e358f09893f09999f172ff12f5dbbb8eTimo SirainenCONFIGURE_OPTIONS += --enable-follow-x-forwarded-for
b032dc80e358f09893f09999f172ff12f5dbbb8eTimo SirainenCONFIGURE_OPTIONS += --enable-large-cache-files
b032dc80e358f09893f09999f172ff12f5dbbb8eTimo SirainenCONFIGURE_OPTIONS += --enable-negotiate-auth-helpers='squid_kerb_auth'
b032dc80e358f09893f09999f172ff12f5dbbb8eTimo SirainenCONFIGURE_OPTIONS += --enable-ntlm-auth-helpers='smb_lm,fakeauth,no_check'
b032dc80e358f09893f09999f172ff12f5dbbb8eTimo SirainenCONFIGURE_OPTIONS += --enable-removal-policies='heap,lru'
b032dc80e358f09893f09999f172ff12f5dbbb8eTimo SirainenCONFIGURE_OPTIONS += --enable-storeio='aufs,diskd,ufs'
b032dc80e358f09893f09999f172ff12f5dbbb8eTimo SirainenCONFIGURE_OPTIONS += --enable-x-accelerator-vary
b032dc80e358f09893f09999f172ff12f5dbbb8eTimo SirainenCONFIGURE_OPTIONS += --with-build-environment=POSIX_V6_ILP32_OFFBIG
ae8817f05005f57bba32479a610b52d083e2b6ebTimo Sirainen# common targets
ae8817f05005f57bba32479a610b52d083e2b6ebTimo Sirainen# configure says it needs cppunit to test with.
a050ca9def13949dbaa67bd6574a41c4f397ae26Timo Sirainen# After some work I can get cppunit to build but it quickly
a050ca9def13949dbaa67bd6574a41c4f397ae26Timo Sirainen# falls over during test so giving up.
ae8817f05005f57bba32479a610b52d083e2b6ebTimo Sirainen# I don't think the test suite really tests squid's functionality anyways.
ae8817f05005f57bba32479a610b52d083e2b6ebTimo Sirainen# To test manually follow along in the book
ae8817f05005f57bba32479a610b52d083e2b6ebTimo Sirainen# Squid Proxy Server 3.1 Beginner's Guide Page 34
ae8817f05005f57bba32479a610b52d083e2b6ebTimo Sirainen# Add this to the top of /etc/squid/squid.conf:
ae8817f05005f57bba32479a610b52d083e2b6ebTimo Sirainen# cache_dir ufs /var/squid/cache/ 500 16 256
ae8817f05005f57bba32479a610b52d083e2b6ebTimo Sirainen# acl my_machine src 192.0.2.21 # Replace with your desktop's IP address
ae8817f05005f57bba32479a610b52d083e2b6ebTimo Sirainen# http_access allow my_machine
ae8817f05005f57bba32479a610b52d083e2b6ebTimo Sirainen# Make sure apache is running.
ae8817f05005f57bba32479a610b52d083e2b6ebTimo Sirainen# # svcs apache22
ae8817f05005f57bba32479a610b52d083e2b6ebTimo Sirainen# Start squid:
ae8817f05005f57bba32479a610b52d083e2b6ebTimo Sirainen# # svcadm enable squid
ae8817f05005f57bba32479a610b52d083e2b6ebTimo Sirainen# On your desktop set your web browser to proxy through this squid:
ae8817f05005f57bba32479a610b52d083e2b6ebTimo Sirainen# Edit -> Preferences -> Advanced -> Network -> Settings
ae8817f05005f57bba32479a610b52d083e2b6ebTimo Sirainen# Check: Manual proxy configuration
a050ca9def13949dbaa67bd6574a41c4f397ae26Timo Sirainen# HTTP Proxy: <squid servers IP address> Port: 3128
a050ca9def13949dbaa67bd6574a41c4f397ae26Timo Sirainen# Enter <squid server URL> in your web browser. You should be accessing squid
e3689d0f073341e844638f34e1e4d0b7bb053cc8Timo Sirainen# and seeing files stored in the http server on that machine.
ae8817f05005f57bba32479a610b52d083e2b6ebTimo Sirainen# Enter <squid server URL>:897 in your web browser and squid should complain.
ae8817f05005f57bba32479a610b52d083e2b6ebTimo Sirainen# Squid is working properly.