On 03/11/14 16:54, Rainer Orth wrote:
> I noticed that the new libcc1 wasn't built on Solaris.  This happens
> because socketpair doesn't live in libc, but in libsocket instead.  To
> deal with this, I've copied the libgo (and libjava) code to detect the
> need for libsocket and libnsl.  Once the build was attempted, two
> failures had to be dealt with:
>
> * FD_ZERO and friends need <string.h> for a memset declaration.
>
> * On Solaris 10, AF_LOCAL isn't defined in system headers, while AF_UNIX
>   is.  In both libgo and libjava, there are unconditional uses of
>   AF_UNIX, so I've followed their lead.
>
> Those changes allowed libcc1.so to build.
>
> Bootstrapped without regressions on i386-pc-solaris2.1[01] and
> x86_64-unknown-linux-gnu, ok for mainline?
>
> Btw., MAINTAINERS doesn't currently list a libcc1 maintainer.  I believe
> it should.
>
>     Rainer
>
>
> 2014-10-31  Rainer Orth  <r...@cebitec.uni-bielefeld.de>
>
>     * configure.ac (libcc1_cv_lib_sockets): Check for -lsocket -lnsl.
>     * configure: Regenerate.
>     * connection.cc: Include <string.h>.
>         * libcc1.cc (libcc1_compile): Use AF_UNIX instead of AF_LOCAL.

The configure change is fine.  Also the include.  (From a libcc
authorship point of view).  I am not aware of the history of AF_UNIX
over AF_LOCAL so I have no comment on that.  Please await permission
from a GCC maintainer (I am not one).

Cheers

Phil

Reply via email to