in reply to HP-UX 11.11 Your vendor has not defined Socket macro AF_INET6

What is socket.ph and where do I get it?
It's a perl4-style file defining values for system networking constants. Sometimes it is built using h2ph when Perl is installed, but other times it is not. Modern programs "use Socket;" instead.
You may need to reinstall socket and make sure AF_INET6 is defined

http://public.activestate.com/pub/apc/perl-current/ext/Socket/

  • Comment on Re: HP-UX 11.11 Your vendor has not defined Socket macro AF_INET6

Replies are listed 'Best First'.
Re^2: HP-UX 11.11 Your vendor has not defined Socket macro AF_INET6
by somuchh8 (Novice) on Apr 09, 2008 at 13:49 UTC
    Nope, that wasn't it but I you did start to get me thinking about the original Socket module. I checked the changelog of Socket6 and saw that they made the export of AF_INET6 optional in the Socket6 module I was building. It's optional because in perl 5.10 the Socket module was exporting AF_INET6 and then were would be a conflict with the Socket6 export. I removed the check making it 'optional' since I am using perl 5.82.

    Here are the lines I changed in Socket6.pm:
    Original: push @EXPORT, qw(AF_INET6) unless defined Socket::AF_INET6; push @EXPORT, qw(PF_INET6) unless defined Socket::PF_INET6; Fixed: push @EXPORT, qw(AF_INET6); push @EXPORT, qw(PF_INET6);

    Now I don't get the error that AF_INET6 isn't defined I've tested that I can indeed communicate via SNMP using an IPv6 address. Hooray!
      If you have perl 5.8 version of Socket module, which apparently does not export AF_INET6, then should not the original code (in new Socket6) have stuffed *F_INET6 in @EXPORT? That raises the question: do you have perl 5.10 installed too?
        I am seeing this very same issue on Solaris. Not only did I have to remove the if statement from Socket6.pm, I also had to explicitly import AF_INET6 in INET6.pm, to get everything working. This doesn't make much sense to me. With ActiveState Perl 5.10 everything works as I would expect, I don't have to do anything special, but with 5.8 I have issues. I compared the Socket.pm file between the two and as far as AF_INET6 is concerned they are the same.