I got a error message tryinh to install Prokka - perl

I am trying to install a software called prokka(http://www.vicbioinformatics.com/software.prokka.shtml)
But i got a error in installation.
I tried install as indicated via git hub clone:
and got this:
Can't locate XML/Simple.pm in #INC (you may need to install the XML::Simple module) (#INC contains: /home/paulo/anaconda3/lib/site_perl/5.26.2/x86_64-linux-thread-multi /home/paulo/anaconda3/lib/site_perl/5.26.2 /home/paulo/anaconda3/lib/5.26.2/x86_64-linux-thread-multi /home/paulo/anaconda3/lib/5.26.2 .) at /home/paulo/prokka/bin/prokka line 29.
BEGIN failed--compilation aborted at /home/paulo/prokka/bin/prokka line 29.
I tried to install the XML with:
sudo cpan install
But not worked to.
I also installed successively all other dependencies as asked but seems not work.
Then I tried with conda and got this:
ERROR conda.core.link:_execute(700): An error occurred while
installing package 'bioconda::perl-algorithm-diff-1.1903-pl526_2'.
Rolling back transaction: done [Errno 13] Permission denied:
'/home/paulo/anaconda3/lib/site_perl/5.26.2/Algorithm' ()
Now I dont know what else to do.
Any help?
Thank you by your time.
Paulo

I tried to install the XML with: sudo cpan install But not worked to.
It would be helpful to know exactly how this failed. What error messages you got.
You don't say what kind of system you're trying to work on, but if you're using a Linux distribution, it's almost certain that there's a pre-build package for XML::Simple. Try sudo dnf install Perl-XML-Simple on a Red Hat-based system and sudo apt-get install libxml-simple-perl on a Debian-based system.

Just make a conda update all, crate a env prokka and it was done.
Thank you for your help and time guys.
Paulo

Related

Building from Singularity recipes problems

I am a beginner in Singularity and I would like having help in building from a recipe.
I want to use GARM, a genome assemblies reconciliation tool, to reconciliate two genomes I have assembled. Since I am working on a HPC server, I don't have the permissions to install the required perl packages for this tool (which are Parallel::ForkManager and List::MoreUtils) and R. I found there are two possible solutions for that (and please tell me if I am wrong or if there are other things I can do):
install R and perl modules locally (but in this case I should change all the scripts references to them)
build a Singularity container containing all the dependencies needed and GARM, since the server has Singularity 2.6 installed.
I choosen the second solution and decided to use a recipe to build the container, which is the following:
Bootstrap: docker
From: ubuntu
%files
GARM_0.7.4
%post -c /bin/bash
apt-get update
apt-get install -y --force-yes perl build-essential cpanminus r-base
cpanm Parallel::ForkManager List::MoreUtils
export GARMBIN=/GARM_0.7.4/bin
export GARMLIB=/GARM_0.7.4/lib
export MUMBIN=/GARM_0.7.4/MUMmer3.22
export AMOSBIN=/GARM_0.7.4/amos-3.0.0/bin
export AMOSLIB=/GARM_0.7.4/amos-3.0.0/lib
%runscript
exec perl /GARM_0.7.4/GARM.pl
where GARM_0.7.4 is the folder downloaded containing everything the software needs, except R and perl modules.
I use sudo singularity build garm.simg recipe-garm to build the container.
Then using singularity run garm.simg --help to see if the container works, it comes out this:
Can't open perl script "/GARM_0.7.4/GARM.pl": Permission denied
Now, even if on the server I cannot use sudo, on my PC I tried anyway it with sudo singularity run garm.simg --help, and the output is:
Empty compile time value given to use lib at /GARM_0.7.4/GARM.pl line 12.
Can't locate GARM_main.pm in #INC (you may need to install the GARM_main module) (#INC contains: /etc/perl /usr/local/lib/x86_64-linux-gnu/perl/5.30.0 /usr/local/share/perl/5.30.0 /usr/lib/x86_64-linux-gnu/perl5/5.30 /usr/share/perl5 /usr/lib/x86_64-linux-gnu/perl/5.30 /usr/share/perl/5.30 /usr/local/lib/site_perl /usr/lib/x86_64-linux-gnu/perl-base) at /GARM_0.7.4/GARM.pl line 13.
BEGIN failed--compilation aborted at /GARM_0.7.4/GARM.pl line 13.
I don't know what is wrong. I can't get if the problem is the garm folder not copied inside the container so that the garm script can't be run, or if there are sintax problem in the recipe and the container does not run the script.
EDIT: added exports as README.txt from the tool suggests, but the situation does not change.

Gtk-Message: Failed to load module "canberra-gtk-module" Unable to connect to dbus - Sublime text

I'm working on a remote server (Ubuntu 14.04) through SSH -X. I have installed Sublime Text and when I try to open it I get
Gtk-Message: Failed to load module "canberra-gtk-module"
Unable to connect to dbus
How do I solve this?
sudo apt-get install libcanberra-gtk*
if you run that install it will get 120+ mb of libs, mostly. to get rid of that module error, you only need to install 70k. i fixed the same error with this single package:
sudo apt-get install libcanberra-gtk-module
that should do the trick. if that doesnt work try installing only the canberra libs, you don't need all those Xlibs, or you'd have them already ;)
here's just canberra packages apt listed:
libcanberra-gtk-common-dev libcanberra-gtk-dev libcanberra-gtk-module
libcanberra-gtk-module-dbg libcanberra-gtk0 libcanberra-gtk0-dbg
libcanberra-gtk3-0-dbg libcanberra-gtk3-dev libcanberra-gtk3-module-dbg
libcanberra-dev
10 total packages, instead of over 100 packages with that * wildcard. save space, boot time, sys speed etc, always, if you can :)
As I found at the end of this thread, it appears to be a problem with the libcanberra dependencies, I stumbled upon this and the solution worked for me on Sublime Text 2/Debian 8.
So try running this:
sudo apt-get install libcanberra-gtk*
This got rid of the GTK message, but the "Unable to connect to dbus..." stuff disappeared when I executed sublime as a non-root user.
On Debian Stretch:
sudo apt install libcanberra-gtk-module
This will install:
The following additional packages will be installed:
libcanberra-gtk0
The following NEW packages will be installed:
libcanberra-gtk-module libcanberra-gtk0

Can't locate unicore/Canonical.pl in #INC

I tried to upgrade my custom perl version from 5.10.1 to 5.16.3, and now I am getting following errors in my logs:
[Wed May 21 00:05:32 2014] [error] Can't locate unicore/Canonical.pl
in #INC (#INC contains: /opt/test/perl/lib/5.10.1/i686-linux
/opt/test/perl/lib/5.10.1
/opt/test/perl/lib/site_perl/5.10.1/i686-linux
/opt/test/perl/lib/site_perl/5.10.1 . /opt/test/httpd) at
/opt/test/perl/lib/5.10.1/utf8_heavy.pl line 139.\n
Can anyone please help me to sort it out?
try re-installing the missing modules using cpan.
the "upgrade" probably created a second, parallel Perl installation on your system...
did you then remove the 'old' version?
Follow below commands:
1/ Install cpan with yum install cpan or apt-get install cpan
2/ On the command prompt enter: cpan install unicore:Canonical

pcap.h header file problem

anyone know how to fix the problem regarding header file in ubuntu 10.10.
I am executing a sniffing program which makes use of this header file. My system shows libcap package is installed. Still, on compiling the code, an error is coming which reads:
fatal error: pcap.h: No such file or directory
compilation terminated.
Please help me out.
Thanks all:)
The system won't let me correct Eric Fossum's comment, because I lack reputation. There is a typo ("libcap" vs. "libpcap") and his suggested command should read the following:
sudo apt-get install libpcap-dev
sudo apt-get install libpcap0.8-dev
If you are using yum, then
sudo yum install install libpcap-devel
You don't have the pcap.h file in your include path. You need to add the location of pcap.h to your include path when compiling:
-I/path/to/pcap.h
If you're using linuxbrew, you can just brew install libpcap. In my case I was trying to install nethogs and it failed with this error.
First install libpcap:
sudo apt-get install libpcap0.8-dev
then create its shortcut for header file:
ln -s /usr/include/pcap/bpf.h /usr/include/net/bpf.h

Why do I get this module error: "Can't locate Error.pm in #INC"?

I tried running:
perl -e "use Error;"
from cmd in windows 7. (active perl 5.12 installed on system) and I am getting the error
Can't locate Error.pm in #INC (#INC
contains: C:/Perl64/site/lib
C:/Perl64/lib )
I manually searched and found Error.pm in C:/Perl64/lib/CPANPLUS.
Does anyone have an idea what could be going on here?
You have to install the module Error that can be found on CPAN.
But be aware of this warning:
Using the "Error" module is no longer recommended due to the black-magical
nature of its syntactic sugar, which often tends to break. Its maintainers
have stopped actively writing code that uses it, and discourage people from
doing so. See the "SEE ALSO" section below for better recommendations.
lib/CPANPLUS/Error.pm is a core "CPANPLUS::Error" module. It is used by CPANPLUS. If you want to use non-core "Error" module, you need to install it. Do "ppm install Error". Also, you can use similar modules Try::Tiny and TryCatch. They are non-core too, so you also would need to install them.
I'm on CentOS 7.3, and I have git-1.8.3.1-23 and perl-Error-0.17014-1 rpm packages installed and still got this error. I didn't want to mess with installing perl modules via CPAN. I figured out the path where perl-Error is installed (rpm -ql perl-Error) and am now running git commands like so:
PERL5LIB="/usr/lib/perl5/vendor_perl/5.8.8" git add -p someFile.sh
This works fine for me. Note that the path may be different for you.
On Centos 8, you can installing perl-Error to get this module:
sudo dnf install perl-Error
you could set PERL5LIB to prepend a directory to #INC
PERL5LIB="C:/Perl64/lib/CPANPLUS"
I forget how to set env variables permanently in windows (or if this is even the right syntax for the shell.)
also to see your #INC perl -V