Hi Maxim,<div><br></div><div>Thanks so much. Your patch worked great.</div><div><br></div><div>The build was failing without that change.</div><div><br></div><div>Is there any way that patch can be incorporated into the main source, so that it doesn't happen again in 1.5.4?</div>
<div><br></div><div>Thanks again, I really appreciate it.</div><div><br clear="all"><div>Best regards,<br>Kevin<br>--<br>Kevin Worthington<br><a href="http://kevinworthington.com/" target="_blank">http://kevinworthington.com/</a><br>
<a href="http://twitter.com/kworthington" target="_blank">http://twitter.com/kworthington</a></div>
<br><br><div class="gmail_quote">On Sat, Aug 3, 2013 at 6:47 AM, Maxim Dounin <span dir="ltr"><<a href="mailto:mdounin@mdounin.ru" target="_blank">mdounin@mdounin.ru</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Hello!<br>
<div class="im"><br>
On Fri, Aug 02, 2013 at 09:17:03PM -0400, Kevin Worthington wrote:<br>
<br>
> I'm trying to build nginx 1.5.3 on Cygwin using Windows 7. I see the<br>
> following output during "make":<br>
<br>
</div>[...]<br>
<div class="im"><br>
> cc1: warnings being treated as errors<br>
> src/core/ngx_inet.c: In function `ngx_sock_ntop':<br>
> src/core/ngx_inet.c:236: error: comparison between signed and unsigned<br>
> make[1]: *** [objs/src/core/ngx_inet.o] Error 1<br>
> make[1]: Leaving directory `/home/kworthington/nginx-1.5.3'<br>
> make: *** [build] Error 2<br>
><br>
> I would appreciate any help to fix this. Thank you!<br>
<br>
</div>Looks like socklen_t is signed in your environment, which results<br>
in a warning. Try the following patch:<br>
<br>
--- a/src/core/ngx_inet.c<br>
+++ b/src/core/ngx_inet.c<br>
@@ -233,7 +233,7 @@ ngx_sock_ntop(struct sockaddr *sa,<br>
<br>
/* on Linux sockaddr might not include sun_path at all */<br>
<br>
- if (socklen <= offsetof(struct sockaddr_un, sun_path)) {<br>
+ if (socklen <= (socklen_t) offsetof(struct sockaddr_un, sun_path)) {<br>
p = ngx_snprintf(text, len, "unix:%Z");<br>
<br>
} else {<br>
<br>
Alternatively, you may just ignore the warning, it's harmless.<br>
<span class="HOEnZb"><font color="#888888"><br>
--<br>
Maxim Dounin<br>
<a href="http://nginx.org/en/donation.html" target="_blank">http://nginx.org/en/donation.html</a><br>
<br>
_______________________________________________<br>
nginx mailing list<br>
<a href="mailto:nginx@nginx.org">nginx@nginx.org</a><br>
<a href="http://mailman.nginx.org/mailman/listinfo/nginx" target="_blank">http://mailman.nginx.org/mailman/listinfo/nginx</a><br>
</font></span></blockquote></div><br></div>