The patch for IPv6 functionality in the openssl ebuild adds a call to gethostbyname2() for IPv6 address resolution.
gethostbyname2() is a GNU extension.
Created attachment 378886 [details]
i686-w64-mingw32 - emerge --info
Created attachment 378888 [details]
i686-w64-mingw32 - build.log
Same result on x86_64-w64-mingw32 than attachment #378886 [details]
man 2 gethostbyname say :
Glibc2 also has a gethostbyname2() that works like gethostbyname(), but
permits to specify the address family to which the address must belong.
See Also: http://rt.openssl.org/Ticket/Display.html?id=2051
still broken on x86_64-w64-mingw32 for dev-libs/openssl-1.0.2k
Do you have getipnodebyname available? In Prefix we carry the following patch, but perhaps it can go without the extra ifdef (linux and darwin seem to have getipnodebyname too):
@@ -718,8 +718,13 @@
if (domain == AF_INET)
ret = gethostbyname(name);
# if OPENSSL_USE_IPV6
+# if defined (__SVR4) && defined (__sun)
+ ret = getipnodebyname(name, AF_INET6, AI_DEFAULT, NULL);
ret = gethostbyname2(name, AF_INET6);
if (ret == NULL)
To be frank I have no idea how I'd check if I had that or not. would you say that just dropping that as a patch into the user patches dir should work?
(In reply to Fabian Groffen from comment #6)
> Do you have getipnodebyname available? In Prefix we carry the following
> patch, but perhaps it can go without the extra ifdef (linux and darwin seem
> to have getipnodebyname too):
> --- apps/s_socket.c
> +++ apps/s_socket.c
> @@ -718,8 +718,13 @@
> if (domain == AF_INET)
> ret = gethostbyname(name);
> # if OPENSSL_USE_IPV6
> +# if defined (__SVR4) && defined (__sun)
> + else
> + ret = getipnodebyname(name, AF_INET6, AI_DEFAULT, NULL);
> +# else
> ret = gethostbyname2(name, AF_INET6);
> +# endif
> # endif
> if (ret == NULL)
> return (NULL);
A quick recursive grep seems to show this is not available under the mingw64-runtime
Presumably, 1.1.x contains proper ipv6 support.
Akamai has a patch that uses getaddrinfo (like it should)
The problem is mostly for mingw if I understand correctly.
Can we disable ipv6 support for that platform for 1.0.x?