Mailing List Archive

sockaddr_un (Was: 5.001mx -> 5.002beta1 Change summary.)
On Wed, 22 Nov 1995, Tom Christiansen wrote:

> Hm.. I have a fixed lib/socket.t I didn't send. Writing Socket as an
> extension is a little weird, because it doesn't have a useful make
> test of its own, but expects it to be from the lib directory.

Yes. The whole Configure/build/test/install process for supplied
extensions is inextricably but explicably tangled in the Configure/build/
test/install process for the full distribution. Just comment out
the BEGIN block and you can run the test under Socket for testing.

>
> > 4. Socket-1.4 won't compile on systems that don't have <sys/un.h>.
>
> What is then the normal place to find a sockaddr_un? Is it in <sys/socket.h>
> or do you have to go hunting?

I've done some hunting and haven't found sockaddr_un anywhere. This is
on Interactive, a rather standard SVR3 system. It could be I've
missed it. (This machine does double duty as a DOS machine in the freshman
physics lab, so I don't have access to it most of the time.)

Andy Dougherty doughera@lafcol.lafayette.edu
Re: sockaddr_un (Was: 5.001mx -> 5.002beta1 Change summary.) [ In reply to ]
Andy Dougherty wrote :
|| > > 4. Socket-1.4 won't compile on systems that don't have <sys/un.h>.
|| >
|| > What is then the normal place to find a sockaddr_un? Is it in <sys/socket.h>
|| > or do you have to go hunting?
||
|| I've done some hunting and haven't found sockaddr_un anywhere. This is
|| on Interactive, a rather standard SVR3 system. It could be I've
|| missed it. (This machine does double duty as a DOS machine in the freshman
|| physics lab, so I don't have access to it most of the time.)

On IBM AIX 3.2.5 and HP/UX 9 and on NEC (mumble - a moderately
recent SVR4), it is in <sys/un.h>

--
Maybe we can fix reality one of these days. | John Macdonald
<- Larry Wall Carl Dichter -> | jmm@Elegant.COM
I'd be happy if we could just index it. |
Re: sockaddr_un (Was: 5.001mx -> 5.002beta1 Change summary.) [ In reply to ]
John Macdonald wrote :
>Andy Dougherty wrote :
>||> What is then the normal place to find a sockaddr_un? Is it in <sys/socket.h>
>||> or do you have to go hunting?
>||
>|| I've done some hunting and haven't found sockaddr_un anywhere. This is
>|| on Interactive, a rather standard SVR3 system.

Well, what does the `man 4 unix' or `man -k "unix domain"' say that bind()
should get for unix domain sockets on machines where un.h does not exist?
Does this work?
#ifdef I_SYS_UN_H /* Has <sys/un.h> */
# include <sys/un.h>
#else
struct sockaddr_un {
short sun_family;
char sun_path[108];
};
#endif


> On IBM AIX 3.2.5 and HP/UX 9 and on NEC (mumble - a moderately
> recent SVR4), it is in <sys/un.h>

Also on Ultrix4 (RISC-ultrix), OSF1 (alpha-dec_osf), Sun[34], Solaris,
irix 5.3 (IP22-irix) and Linux (where <sys/un.h> #includes <linux/un.h>).


Regards,

Hallvard
Re: sockaddr_un (Was: 5.001mx -> 5.002beta1 Change summary.) [ In reply to ]
>I've done some hunting and haven't found sockaddr_un anywhere. This is
>on Interactive, a rather standard SVR3 system. It could be I've
>missed it. (This machine does double duty as a DOS machine in the freshman
>physics lab, so I don't have access to it most of the time.)

Does that mean you get <sockaddr_un>s for free? They must
come from somewhere.

--tom