Why can't I build Perl modules that load Socket.so on Solaris 10?

瘦欲@ 提交于 2019-12-06 09:05:56

Note: this answer is pure conjecture as I don't have a Solaris machine to test this on.

It looks like Solaris doesn't put inet_aton in libsocket, which is presumably what is being linked against when you build Socket. Instead, it looks like you need to add -lresolv to the LIBS line in the Makefile (I don't know if this is in the Makefile.PL for Socket...).

Like I said, this is pure conjecture. I'm pulling this answer mostly from this bug report for DBMail. I hope it gets you somewhere, though.

I don't have a Perl 5.12 installation, but I do have access to Solaris 10, and I can confirm that Solaris' libsocket does not have inet_aton (it has inet_pton instead).

But the resolver library (libresolv) does have inet_aton, so a workaround may be to add

-lresolv

to the Makefile's LDFLAGS, and build/install it yourself outside of cpan.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!