2

I trying to run a Perl script (taxid2wgs.pl) used in searching a taxonomic subset of WGS.

taxid2wgs.pl (available at ftp://ftp.ncbi.nlm.nih.gov/blast/WGS_TOOLS).

$ ./taxid2wgs.pl -title "Bacteria WGS" -alias_file bacteria-wgs 2

Here, 2 is the taxid for Bacteria. taxid2wgs.pl will produce the alias file "bacteria-wgs.nvl".

However I got an error message below.

Can't locate LWP/UserAgent.pm in @INC (you may need to install the LWP::UserAgent module) (@INC contains: /usr/local/lib/perl5/site_perl/5.24.0/x86_64-linux-thread-multi /usr/local/lib/perl5/site_perl/5.24.0 /usr/local/lib/perl5/5.24.0/x86_64-linux-thread-multi /usr/local/lib/perl5/5.24.0 .) at ./taxid2wgs.pl line 4.
BEGIN failed--compilation aborted at ./taxid2wgs.pl line 4.

What I do next is install the LWP perl module (libwww-perl-6.05).

~# perl Makefile.PL
Checking if your kit is complete...
perl: symbol lookup error: /root/perl5/lib/perl5/x86_64-linux-thread-multi/auto/List/Util/Util.so: undefined symbol: Perl_xs_handshake

Before posting, I've tried to another solution.

~# perl -MCPAN -e 'install Bundle::LWP'
perl: symbol lookup error: /root/perl5/lib/perl5/x86_64-linux-thread-multi/auto/List/Util/Util.so: undefined symbol: Perl_xs_handshake

To overcome the problem, I used YUM to install the required module named perl-libwww-perl.

~# yum install perl-libwww-perl

But it still doesn't work for my operation.

Sorry, I'm very new to this. Appreciate the help!

Penny Liu
  • 15,447
  • 5
  • 79
  • 98
  • maybe you can try yum install perl-Scalar-List-Utils to fix that. otherwise you can try cpan List::Util to fix that? – Fayland Lam Jun 07 '17 at 03:20
  • 1
    This usually indicates you are using a library that was compiled for a different `perl` than the one you are using. – ikegami Jun 07 '17 at 03:54
  • 4
    A big thank you, I see my problem now! The following worked for me: I check `locate UserAgent.pm` and `export PERL5LIB=/usr/share/perl5/`. – Penny Liu Jun 07 '17 at 06:24

1 Answers1

0

I had the same issue. And like others have said, this is because the program uses a different perl. I got the error when I used perl 5.24.0, but the program worked with perl-5.18.2.

fmin_aunt
  • 9
  • 3
  • If you had the same issue that others have addressed already then there's no need to post a new answer. – Claire Jun 17 '19 at 20:22