<html>
<head>
<meta http-equiv="content-type" content="text/html;
charset=windows-1252">
</head>
<body smarttemplateinserted="true" bgcolor="#FFFFFF" text="#000000">
<br>
Dear Sirs<br>
<br>
I tried compiling squid-3.5.0.4-20150106-r13714 running under
windows with wingw<br>
<br>
It still had a few bugs. I fixed them and now it compiles and runs,
but still can't resolve addresses (I have correctly specified the
name servers).<br>
I get:<br>
WARNING: Reply from unknown nameserver [::]:53<br>
<br>
I don't have more time to work it further. <br>
<br>
I would like to contribute with the fixes I wrote. Here are them. <br>
<br>
Obs.: the diff shows squid-3.5.0.4 against
squid-3.5.0.4-20150106-r13714, but it is actually my
squid-3.5.0.4-20150106-r13714 against squid-3.5.0.4-20150106-r13714
<br>
<br>
configure command used:<br>
./configure --enable-default-hostsfile=none
--prefix=C:/msys/1.0/squid<br>
mingw version: latest 32 bit.<br>
<br>
diffs:<br>
<br>
<br>
diff -r C:\msys\1.0\var\squid-3.5.0.4\compat\os\mswindows.h
C:\msys\1.0\var\squid-3.5.0.4-20150106-r13714\compat\os\mswindows.h<br>
625,630c624,629<br>
< /* commen out this function <br>
< inline char * <br>
< inet_ntop(int af, const void *src, char *dst, size_t size)<br>
< {<br>
< return (char*)InetNtopA(af, const_cast<void*>(src),
dst, size);<br>
< }<br>
< #define inet_ntop(a,s,d,l) Squid::inet_ntop(a,s,d,l) */<br>
---<br>
> inline char *<br>
> inet_ntop(int af, const void *src, char *dst, size_t size)<br>
> {<br>
> return (char*)InetNtopA(af, const_cast<void*>(src),
dst, size);<br>
> }<br>
> #define inet_ntop(a,s,d,l) Squid::inet_ntop(a,s,d,l)<br>
<br>
<br>
***************************<br>
<br>
diff -r
C:\msys\1.0\var\squid-3.5.0.4\helpers\basic_auth\SSPI\valid.h
C:\msys\1.0\var\squid-3.5.0.4-20150106-r13714\helpers\basic_auth\SSPI\valid.h<br>
41d40<br>
< typedef HANDLE SERVICE_STATUS_HANDLE;<br>
74c73<br>
< static const char *__foo;<br>
---<br>
> static char *__foo;<br>
95d93<br>
< int Valid_User(char *,char *, char *);<br>
<br>
<br>
**************************** <br>
<br>
<br>
diff -r
C:\msys\1.0\var\squid-3.5.0.4\helpers\external_acl\LM_group\ext_lm_group_acl.ccC:\msys\1.0\var\squid-3.5.0.4-20150106-r13714\helpers\external_acl\LM_group\ext_lm_group_acl.cc<br>
95d94<br>
< typedef HANDLE SERVICE_STATUS_HANDLE;<br>
<br>
<br>
**************************************<br>
<br>
diff -r
C:\msys\1.0\var\squid-3.5.0.4\helpers\ntlm_auth\SSPI\ntlm_sspi_auth.cc
C:\msys\1.0\var\squid-3.5.0.4-20150106-r13714\helpers\ntlm_auth\SSPI\ntlm_sspi_auth.cc<br>
82d81<br>
< typedef HANDLE SERVICE_STATUS_HANDLE;<br>
<br>
<br>
<br>
*********************<br>
<br>
squid-3.5.0.4-20150106-r13714<br>
<br>
diff getaddrinfo.cc<br>
26d25<br>
< #include "../src/debug.h"<br>
85c84<br>
< ret = (addrinfo*) malloc (sizeof (struct addrinfo));<br>
---<br>
> ret = malloc (sizeof (struct addrinfo));<br>
89c88<br>
< ret->ai_addr = (sockaddr*) malloc (addrlen);<br>
---<br>
> ret->ai_addr = malloc (addrlen);<br>
180c179<br>
< if (inet_pton(result.ai_family, nodename,
&sin.sin_addr) != 1)<br>
---<br>
> if (inet_pton(result.ai_family, nodename,
&sin.sin_addr))<br>
281c280<br>
< sai->ai_canonname = (char *) malloc (strlen
(hp->h_name) + 1);<br>
---<br>
> sai->ai_canonname = malloc (strlen (hp->h_name) +
1);<br>
<br>
*****************<br>
<br>
diff -r C:\msys\1.0\var\squid-3.5.0.4\compat\getnameinfo.cc
C:\msys\1.0\var\squid-3.5.0.4-20150106-r13714\compat\getnameinfo.cc<br>
151c151,159<br>
< int xgetnameinfo(const struct sockaddr *sa, socklen_t salen,
char *host, size_t hostlen, char *serv, size_t servlen, int flags)<br>
---<br>
> int<br>
> xgetnameinfo(sa, salen, host, hostlen, serv, servlen, flags)<br>
> const struct sockaddr *sa;<br>
> socklen_t salen;<br>
> char *host;<br>
> size_t hostlen;<br>
> char *serv;<br>
> size_t servlen;<br>
> int flags;<br>
<br>
<br>
******************<br>
<br>
diff -r C:\msys\1.0\var\squid-3.5.0.4\compat\inet_ntop.cc
C:\msys\1.0\var\squid-3.5.0.4-20150106-r13714\compat\inet_ntop.cc<br>
97,98c97,98<br>
< const char *inet_ntop4 (const u_char *src, char *dst, size_t
size);<br>
< const char *inet_ntop6 (const u_char *src, char *dst, size_t
size);<br>
---<br>
> static const char *inet_ntop4 (const u_char *src, char *dst,
size_t size);<br>
> static const char *inet_ntop6 (const u_char *src, char *dst,
size_t size);<br>
107,112c108,113<br>
< const char *<br>
< xinet_ntop(af, src, dst, size)<br>
< int af;<br>
< const void *src;<br>
< char *dst;<br>
< size_t size;<br>
---<br>
> const char *<br>
> xinet_ntop(af, src, dst, size)<br>
> int af;<br>
> const void *src;<br>
> char *dst;<br>
> size_t size;<br>
114d113<br>
< const char * xinet_ntop(int af, const void *src, char * dst,
size_t size)<br>
118c117<br>
< return (inet_ntop4((const u_char*) src, dst, size));<br>
---<br>
> return (inet_ntop4(src, dst, size));<br>
120c119<br>
< return (inet_ntop6((const u_char*) src, dst, size));<br>
---<br>
> return (inet_ntop6(src, dst, size));<br>
138,142c138,142<br>
< static const char *<br>
< inet_ntop4(src, dst, size)<br>
< const u_char *src;<br>
< char *dst;<br>
< size_t size;<br>
---<br>
> static const char *<br>
> inet_ntop4(src, dst, size)<br>
> const u_char *src;<br>
> char *dst;<br>
> size_t size;<br>
144d142<br>
< const char * inet_ntop4( const u_char *src, char *dst, size_t
size)<br>
149c147<br>
< if ((size_t) snprintf(tmp,
min(sizeof("255.255.255.255"),size), fmt, src[0], src[1], src[2],
src[3]) >= size) {<br>
---<br>
> if (snprintf(tmp, min(sizeof("255.255.255.255"),size), fmt,
src[0], src[1], src[2], src[3]) >= size) {<br>
162,166c161,165<br>
< static const char *<br>
< inet_ntop6(src, dst, size)<br>
< const u_char *src;<br>
< char *dst;<br>
< size_t size;<br>
---<br>
> static const char *<br>
> inet_ntop6(src, dst, size)<br>
> const u_char *src;<br>
> char *dst;<br>
> size_t size;<br>
168d165<br>
< const char * inet_ntop6( const u_char *src, char *dst, size_t
size)<br>
<br>
<br>
***************<br>
<br>
diff -r C:\msys\1.0\var\squid-3.5.0.4\compat\inet_pton.cc
C:\msys\1.0\var\squid-3.5.0.4-20150106-r13714\compat\inet_pton.cc<br>
106c106,110<br>
< int xinet_pton( int af, const char *src, void *dst)<br>
---<br>
> int<br>
> xinet_pton(af, src, dst)<br>
> int af;<br>
> const char *src;<br>
> void *dst;<br>
110c114<br>
< return (inet_pton4(src, (u_char*) dst));<br>
---<br>
> return (inet_pton4(src, dst));<br>
112c116<br>
< return (inet_pton6(src, (u_char*) dst));<br>
---<br>
> return (inet_pton6(src, dst));<br>
130c134,137<br>
< static int inet_pton4( const char *src, u_char *dst)<br>
---<br>
> static int<br>
> inet_pton4(src, dst)<br>
> const char *src;<br>
> u_char *dst;<br>
144c150<br>
< u_int nw = *tp * 10 + (pch - digits);<br>
---<br>
> u_int new = *tp * 10 + (pch - digits);<br>
148c154<br>
< if (nw > 255)<br>
---<br>
> if (new > 255)<br>
150c156<br>
< *tp = nw;<br>
---<br>
> *tp = new;<br>
162c168<br>
< break; //return (0);<br>
---<br>
> return (0);<br>
183c189,192<br>
< static int inet_pton6( const char *src, u_char *dst)<br>
---<br>
> static int<br>
> inet_pton6(src, dst)<br>
> const char *src;<br>
> u_char *dst;<br>
238c247<br>
< break; //return (0);<br>
---<br>
> return (0);<br>
<br>
***********************<br>
<br>
diff -r C:\msys\1.0\var\squid-3.5.0.4\src\comm\ModSelectWin32.cc
C:\msys\1.0\var\squid-3.5.0.4-20150106-r13714\src\comm\ModSelectWin32.cc<br>
20d19<br>
< #include "SquidConfig.h"<br>
25d23<br>
< #include "Globals.h"<br>
278c276<br>
< incoming_udp_interval += Config.comm_incoming.udp.average -
nevents;<br>
---<br>
> incoming_udp_interval += Config.comm_incoming.udp_average -
nevents;<br>
310c308<br>
< incoming_tcp_interval += Config.comm_incoming.tcp.average -
nevents;<br>
---<br>
> incoming_tcp_interval += Config.comm_incoming.tcp_average -
nevents;<br>
338,339c336<br>
< int calldns = 0;<br>
< int calludp = 0, calltcp = 0;<br>
---<br>
> int calldns = 0, callicp = 0, callhttp = 0;<br>
<br>
<br>
*************************<br>
<br>
diff -r C:\msys\1.0\var\squid-3.5.0.4\src\ipc_win32.cc
C:\msys\1.0\var\squid-3.5.0.4-20150106-r13714\src\ipc_win32.cc<br>
28,41d27<br>
< #else<br>
< #if HAVE_WINSOCK2_H<br>
< #define SO_CONNDATA 0x7000<br>
< #define SO_CONNOPT 0x7001<br>
< #define SO_DISCDATA 0x7002<br>
< #define SO_DISCOPT 0x7003<br>
< #define SO_CONNDATALEN 0x7004<br>
< #define SO_CONNOPTLEN 0x7005<br>
< #define SO_DISCDATALEN 0x7006<br>
< #define SO_DISCOPTLEN 0x7007<br>
< #define SO_OPENTYPE 0x7008<br>
< #define SO_SYNCHRONOUS_ALERT 0x10<br>
< #define SO_SYNCHRONOUS_NONALERT 0x20<br>
< #endif<br>
<br>
Thank you for providing squid to us all<br>
<br>
Best Regards,<br>
Dennis Felippa<br>
</body>
</html>