Socket6 won't install

I am using Strawberry on WinXP. I need to test some IPv6 connectivity
but can't get Socket6 to install. It all boils down to two errors during
the compile stage.

Socket6.o:Socket6.c:(.text+0xa47): undefined reference to `inet_pton'
Socket6.o:Socket6.c:(.text+0xd11): undefined reference to `inet_ntop'
collect2: ld returned 1 exit status

How do I resolve this problem?

Bob McConnell

--
To unsubscribe, e-mail: beginners-unsubscribe [at] perl.org
For additional commands, e-mail: beginners-help [at] perl.org
http://learn.perl.org/
Bob McConnell [ Di, 23 August 2011 22:00 ] [ ID #2063564 ]

Re: Socket6 won't install

----- Original Message -----
From: "Bob McConnell"

>I am using Strawberry on WinXP. I need to test some IPv6 connectivity
> but can't get Socket6 to install. It all boils down to two errors during
> the compile stage.
>
> Socket6.o:Socket6.c:(.text+0xa47): undefined reference to `inet_pton'
> Socket6.o:Socket6.c:(.text+0xd11): undefined reference to `inet_ntop'
> collect2: ld returned 1 exit status
>
> How do I resolve this problem?

Applying this patch to Socket6.xs should fix the problem:

###########################
--- Socket6.xs_orig Mon Dec 13 21:33:48 2010
+++ Socket6.xs Mon Dec 13 21:40:56 2010
[at] [at] -101,6 +101,11 [at] [at]
#define HAVE_INET_PTON 1
#endif

+#ifdef __MINGW32__
+#include "inet_ntop.c"
+#include "inet_pton.c"
+#endif
+
#ifndef HAVE_PL_SV_UNDEF
#define PL_sv_undef sv_undef
#endif

##########################

(Worked for me.)

Cheers,
Rob

--
To unsubscribe, e-mail: beginners-unsubscribe [at] perl.org
For additional commands, e-mail: beginners-help [at] perl.org
http://learn.perl.org/
sisyphus1 [ Mi, 24 August 2011 03:12 ] [ ID #2063599 ]

RE: Socket6 won't install

From: Sisyphus
> From: "Bob McConnell"
>
>>I am using Strawberry on WinXP. I need to test some IPv6 connectivity
>> but can't get Socket6 to install. It all boils down to two errors
during
>> the compile stage.
>>
>> Socket6.o:Socket6.c:(.text+0xa47): undefined reference to `inet_pton'
>> Socket6.o:Socket6.c:(.text+0xd11): undefined reference to `inet_ntop'
>> collect2: ld returned 1 exit status
>>
>> How do I resolve this problem?
>
> Applying this patch to Socket6.xs should fix the problem:
>
> ###########################
> --- Socket6.xs_orig Mon Dec 13 21:33:48 2010
> +++ Socket6.xs Mon Dec 13 21:40:56 2010
> [at] [at] -101,6 +101,11 [at] [at]
> #define HAVE_INET_PTON 1
> #endif
>
> +#ifdef __MINGW32__
> +#include "inet_ntop.c"
> +#include "inet_pton.c"
> +#endif
> +
> #ifndef HAVE_PL_SV_UNDEF
> #define PL_sv_undef sv_undef
> #endif
>
> ##########################
>
> (Worked for me.)
>

How do I insert that in the middle of an install? CPAN is downloading a
fresh copy of the source each time it runs.

Thanks,

Bob McConnell

--
To unsubscribe, e-mail: beginners-unsubscribe [at] perl.org
For additional commands, e-mail: beginners-help [at] perl.org
http://learn.perl.org/
Bob McConnell [ Mi, 24 August 2011 15:30 ] [ ID #2063604 ]

Re: Socket6 won't install

On Wed, 24 Aug 2011 09:30:35 -0400
"Bob McConnell" <rvm [at] CBORD.com> wrote:

> From: Sisyphus
> > From: "Bob McConnell"
> >
> >>I am using Strawberry on WinXP. I need to test some IPv6 connectivity
> >> but can't get Socket6 to install. It all boils down to two errors
> during
> >> the compile stage.
> >>
> >> Socket6.o:Socket6.c:(.text+0xa47): undefined reference to `inet_pton'
> >> Socket6.o:Socket6.c:(.text+0xd11): undefined reference to `inet_ntop'
> >> collect2: ld returned 1 exit status
> >>
> >> How do I resolve this problem?
> >
> > Applying this patch to Socket6.xs should fix the problem:
> >
> > ###########################
> > --- Socket6.xs_orig Mon Dec 13 21:33:48 2010
> > +++ Socket6.xs Mon Dec 13 21:40:56 2010
> > [at] [at] -101,6 +101,11 [at] [at]
> > #define HAVE_INET_PTON 1
> > #endif
> >
> > +#ifdef __MINGW32__
> > +#include "inet_ntop.c"
> > +#include "inet_pton.c"
> > +#endif
> > +
> > #ifndef HAVE_PL_SV_UNDEF
> > #define PL_sv_undef sv_undef
> > #endif
> >
> > ##########################
> >
> > (Worked for me.)
> >
>
> How do I insert that in the middle of an install? CPAN is downloading a
> fresh copy of the source each time it runs.
>

You cannot do it using the "perl -MCPAN" shell. Instead, download the source
archive, unpack it, patch it, and run "perl Makefile.PL", "make", "make
test" and "make install".

Regards,

Shlomi Fish

> Thanks,
>
> Bob McConnell
>



--
------------------------------------------------------------ -----
Shlomi Fish http://www.shlomifish.org/
Interview with Ben Collins-Sussman - http://shlom.in/sussman

Judaism: God is all the shit, all the non=E2=80=90shit and all the intermed=
iate
demi=E2=80=90shits in between.

Please reply to list if it's a mailing list post - http://shlom.in/reply .

--
To unsubscribe, e-mail: beginners-unsubscribe [at] perl.org
For additional commands, e-mail: beginners-help [at] perl.org
http://learn.perl.org/
Shlomi Fish [ Mi, 24 August 2011 17:14 ] [ ID #2063606 ]
Perl » gmane.comp.lang.perl.beginners » Socket6 won't install

Vorheriges Thema: CPAN on Windows Box
Nächstes Thema: 3-argument open on STDIN