Bug 10715 - IPv6 configure test fails on musl c-library
Summary: IPv6 configure test fails on musl c-library
Status: NEW
Alias: None
Product: rsync
Classification: Unclassified
Component: core (show other bugs)
Version: 3.1.1
Hardware: All All
: P5 normal (vote)
Target Milestone: ---
Assignee: Wayne Davison
QA Contact: Rsync QA Contact
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-07-14 08:51 UTC by Timo Teräs
Modified: 2017-09-04 21:09 UTC (History)
1 user (show)

See Also:


Attachments
Proposed patch to fix the issue (3.92 KB, patch)
2017-09-04 21:09 UTC, Pierre-Olivier Mercier
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Timo Teräs 2014-07-14 08:51:32 UTC
The autoconfigure tests for IPv6 relies on C-library internals, and it currently fails for musl c-library based linux. For Alpine Linux bug report see http://bugs.alpinelinux.org/issues/3158.

A better test (and non-OS dependent) would be to try creating AF_INET6 socket, if it succeeds, then IPv6 is supported.

See e.g.:
 http://ftp.netbsd.org/pub/NetBSD/NetBSD-release-6/src/crypto/dist/ipsec-tools/configure.ac (and search for --disable-ipv6)
Comment 1 Pierre-Olivier Mercier 2017-09-04 21:09:51 UTC
Created attachment 13546 [details]
Proposed patch to fix the issue

Please find attached a proposal patch following Timo's suggestion: I replace the long specific C library detection (which in our case forgot musl's users) by a single feature test that all C libraries have to implement in order to have a compiling rsync with IPv6 support.

After applying this patch, I was able to compile an IPv6 ready rsync with musl, while keeping the same behaviour with the glibc under Linux. This should be tested against others libc I don't have access to.