[patch] Correct configure test for sin_len to compile on Tru64 Unix

Shinichi Maruyama marya at st.jip.co.jp
Tue Mar 16 01:01:19 GMT 2004

wayned> > So, it looks like we need 2 configure tests and separate defines for
wayned> > sa_len and sin_len.
wayned> How about the appended patch?  This applies to the very latest CVS
wayned> source and would require the running of "autoconf" and "autoheader"
wayned> after applying it.

	I use rsync 2.6.1cvs on FreeBSD 4.X machines.
	This OS has sin_len in struct sockaddr_in. But after
configure, HAVE_SOCKADDR_SIN_LEN remains undef in config.h.
	Needs patch like this ?

Index: configure.in
RCS file: /cvsroot/rsync/configure.in,v
retrieving revision 1.186
diff -u -r1.186 configure.in
--- configure.in	27 Feb 2004 07:22:39 -0000	1.186
+++ configure.in	16 Mar 2004 00:51:14 -0000
@@ -396,12 +396,13 @@
 #include <sys/socket.h>
-AC_CHECK_MEMBER([struct sockaddr.sin_len],
+AC_CHECK_MEMBER([struct sockaddr_in.sin_len],
 		[ AC_DEFINE(HAVE_SOCKADDR_SIN_LEN, 1, [Do we have sockaddr.sin_len?]) ],
 #include <sys/types.h>
 #include <sys/socket.h>
+#include <netinet/in.h>
 AC_MSG_CHECKING(struct sockaddr_storage)

Yes, I'm in panic.
Shinichi Maruyama (marya at st.jip.co.jp)

More information about the rsync mailing list