How to Build Squid 3.5 for Windows on CygwinΒΆ
Note
We now have a new project - Web Filtering Proxy for Microsoft Windows. It combines best features of Web Safety but runs natively on Windows. No need to use Hyper-V or dive into Linux specifics. You can enable proxy authentication, HTTPS decryption and filtering with several mouse clicks from Microsoft Management Console. See https://webproxy.diladele.com/.
This post explains how to build latest Squid 3.5 for Microsoft Windows using Cygwin.
Install Cygwin (tested with 64 bit) including:
gcc core
gcc g++
gcc tools epoch
gcc make dep
gdb (if you would like to debug squid in case of any problems)
make
automake (and automake last version)
autoconf
libtool
For some of the advanced external modules consider also installing:
cppunit
libcom_err-devel
libcrypt-devel
libdb-devel
libexpat-devel
libkrb5-devel
libiconv-devel
openldap-devel
openssl-devel
libsasl2-devel
libxml2-devel
perl-DBI
Download latest stable version of Squid from http://www.squid-cache.org/Versions/v3/3.5/, for example 3.5.11.tar.gz to the /usr/src
Unpack squid: tar -xvf squid-3.5.11.tar.gz
Download
this patch
and apply it inside the /usr/src/squid-3.5.11 (the patch allows increasing the number of file descriptors from 256 to 3200 on cygwin)patch -p1 < 3-5-11.patch
for configure we use this command (written as ONE line!)
./configure --bindir=/bin/squid --sbindir=/usr/sbin/squid --sysconfdir=/etc/squid --datadir=/usr/share/squid --libexecdir=/usr/lib/squid --disable-strict-error-checking --with-logdir=/var/log/squid --with-swapdir=/var/cache/squid --with-pidfile=/var/run/squid.pid --enable-ssl --enable-delay-pools --enable-ssl-crtd --enable-icap-client --enable-esi --disable-eui --localstatedir=/var/run/squid --sharedstatedir=/var/run/squid --datarootdir=/usr/share/squid --enable-disk-io="AIO,Blocking,DiskThreads,IpcIo,Mmapped" --enable-auth-basic="DB,LDAP,NCSA,POP3,RADIUS,SASL,SMB,fake,getpwnam" --enable-auth-ntlm='fake' --enable-auth-negotiate='kerberos,wrapper' --enable-external-acl-helpers='LDAP_group,SQL_session,eDirectory_userip,file_userip,kerberos_ldap_group,session,time_quota,unix_group,wbinfo_group' --with-openssl --with-filedescriptors=65536 --enable-removal-policies="lru,heap"
make
make install
Wait until Squid is built and watch out for possible errors!