[Csync2] [patch] fix build on FreeBSD and Ubuntu 10.04
Lars Ellenberg
lars.ellenberg at linbit.com
Fri Oct 28 10:56:41 CEST 2011
On Thu, Oct 27, 2011 at 07:08:18PM +0400, Andrey Zonov wrote:
> Hi,
>
> I've got a few patches which fixes configuring and building csync2 from git.
>
> Under Ubuntu 10.04 should be fixed configure.ac around checking gnutls [1]
>
> Under FreeBSD need some more patches:
> * Fix shebang in autogen.sh [2]
> * FreeBSD 8 already has strlcpy(3), so fix it [3]
> * Use one equal sign instead of double, to be more compatible with POSIX
> Bourne Shell [4]
>
> Platform independent:
> * Close listen socket in child. [5]
> * Use IPv4 for listen socket [6]. That's because of new systems already
> has IPv6 support and may have only link-local addresses and aren't be
> connected to the Internet or even local network via IPv6. So pretty fix is
> create more than one listen socket.
> [1] patch-ubuntu-configure.ac
ok.
> [2] patch-autogen.sh
s/bash/sh/ ...
Why? But anyways, I don't care either way ;-)
> [3] patch-strlcpy-configure.ac-rsync.c
ok.
> [4] patch-posix-shell-configure.ac
Yeah, see above. Ok.
> [5] patch-close-listen-csync2.c
ok.
just because it is correct that way,
or does it actually fix something?
> [6] patch-use-ipv4-csync2.c
If you want, you can add a "-4" or "-6" option.
But patching it to only allow IPv4 is certainly the wrong approach.
Actually, I think, the bind loop there should even prefer AF_INET6,
as sockets bound to :::xyz are reachable by IPv4 as well as IPv6
(at least on linux...).
So, no, [6] is rejected.
> --
> Andrey Zonov
Thanks for the effort, and for feeding it back upstream. Will commit
that soon, I have some other build fixes pending in my checkout that I
still need to commit, too...
Lars
--
: Lars Ellenberg
: LINBIT | Your Way to High Availability
: DRBD/HA support and consulting http://www.linbit.com
More information about the Csync2
mailing list