[erlang-questions] R11B-5 fails to build on FreeBSD 6.2

Per Hedeland per@REDACTED
Sat Jan 12 21:53:53 CET 2008

"Martin Logan" <martinjlogan@REDACTED> wrote:
>the build fails with:


>connect/ei_resolve.c: In function `ei_gethostbyname_r':
>connect/ei_resolve.c:624: warning: passing arg 5 of `gethostbyname_r' from
>incompatible pointer type
>connect/ei_resolve.c:624: error: too few arguments to function
>connect/ei_resolve.c:624: warning: return makes pointer from integer without
>a cast

Do you specifically need R11B-5? Otherwise just use the current port,
which has R12B-0 + OSP1 patch. Or, with a bit of creative cvsup'ing you
can get the R11B-5 version of the port - from ~ July 4 2007 should be
fine. Or, you can apply the patch for this from the current port, it's
the same as for R11B-5 (and I dare say it's not the "proper" way to fix
it, 'configure' should be taught about the issue, but it should work) -

There might be some other issues though, I haven't built Erlang from
current "virgin" source on FreeBSD for quite a while - I happen to have
the erlang-r11b5_1,1 version of the port (that's where it was at when I
installed it) installed and running fine on FreeBSD 6.2-STABLE-200709

--Per Hedeland

$FreeBSD: ports/lang/erlang/files/patch-lib_erl__interface_src_connect_ei__resolve.c,v 1.1 2006/11/25 16:47:07 olgeni Exp $

--- lib/erl_interface/src/connect/ei_resolve.c.orig
+++ lib/erl_interface/src/connect/ei_resolve.c
@@ -621,7 +621,8 @@
   return result;
-  return gethostbyname_r(name,hostp,buffer,buflen,h_errnop);
+  struct hostent *dummy;
+  return gethostbyname_r(name,hostp,buffer,buflen,&dummy,h_errnop);

More information about the erlang-questions mailing list