I'm trying to run this script on my computer (MAC)
http://mkweb.bcgsc.ca/color-summarizer/?download
It's the first time in my life touching the terminal... so you understand that I ask very basic questions. please do forgive me...
basically when i execute the script, I would always get this kind of message :
Can't locate Imager/File/GIF.pm in #INC (you may need to install the
Imager::File::GIF module) (#INC contains:
/Applications/colorsummarizer/colorsummarizer-0.77/bin/lib
/Applications/colorsummarizer/colorsummarizer-0.77/bin/../lib
/Applications/colorsummarizer/colorsummarizer-0.77/bin
/Library/Perl/5.18/darwin-thread-multi-2level /Library/Perl/5.18
/Network/Library/Perl/5.18/darwin-thread-multi-2level
/Network/Library/Perl/5.18 /Library/Perl/Updates/5.18.2/darwin-thread-
multi-2level /Library/Perl/Updates/5.18.2
/System/Library/Perl/5.18/darwin-thread-multi-2level
/System/Library/Perl/5.18 /System/Library/Perl/Extras/5.18/darwin-
thread-multi-2level /System/Library/Perl/Extras/5.18) at
/Library/Perl/5.18/darwin-thread-multi-2level/Imager.pm line 1677.
And so I use :
sudo cpan install Imager::File::GIF
for example. But the I get this :
Warning (mostly harmless): No library found for -lgif
GIF: Test code failed: Can't link/include 'gif_lib.h', 'stdio.h',
'errno.h', 'string.h', 'gif'
OS unsupported: GIF libraries or headers not found
Warning: No success on command[/usr/bin/perl Makefile.PL]
TONYC/Imager-File-GIF-0.91.tar.gz
/usr/bin/perl Makefile.PL -- NOT OK
Running make test
Make had some problems, won't test
Running make install
Make had some problems, won't install
Could not read metadata file. Falling back to other methods to determine prerequisites
And ! it seems like even when I appear to install something successfully, The system ask me to re-install them again and again and again...
Maybe I did some very fundamental mistakes ?
Thanks a lot for your attention
The issue identified by the following message is not harmless at all, actually:
Warning (mostly harmless): No library found for -lgif
GIF: Test code failed: Can't link/include 'gif_lib.h', 'stdio.h',
'errno.h', 'string.h', 'gif'
The module uses libgif to do all the heavy work, but it's not installed. Furthermore, the installation procedure needs the library's header files.
Imager::File::GIF provides GIF file format support for Imager.
It requires libgif to be installed, including development headers.
For Linux distributions this typically requires installation of the
associated -dev or -devel package.
Installing the required library and header files might be as simple as asking your OS's package manager to install libgif-dev or libgif-devel.
Try to just install Imager like this, it might be all you need:
sudo cpan Imager
After that it could open gifs for me.
Related
I'm trying to install the SQL::Translator module. Everything runs fine until it gets to this test:
DBD::SQLite::db do failed: not an error at t/sqlite-rename-field.t line 62.
# Failed test '-- Convert schema '' to '':;'
# at t/sqlite-rename-field.t line 62.
# died: Died at t/sqlite-rename-field.t line 62.
# Looks like you failed 1 test of 16.
Failed 1/72 test programs. 1/1901 subtests failed.
make: *** [test_dynamic] Error 1
Any help is much appreciated, I was not able to find any similar questions. Thanks.
cpan link: http://search.cpan.org/~ilmari/SQL-Translator-0.11021/lib/SQL/Translator.pm
It could be because of missing dependencies and/or mismatch in version of other perl modules. Try using CPANM to install your desired package. It will take care of dependencies for you.
You can also try to install libsql-translator-perl library if you are on debian based systems. I am sure there will be a compatible library on red hat based systems too.
Also if you want to install from cpan then use CPANM to install the module.
Personally i prefer to use distro libraries in place of installing modules.
In case anyone stumbles across this question, my solution was:
install perlbrew
install latest version of perl via perlbrew
download required libraries
install module
It was much easier than dealing with the older system
I am new to perl scripting.I am working on drag and drop file upload and using jquery file upload.I'll appreciate if you can help me in installing this perl module and how to use it.
I am trying to follow readme file but while doing "Perl Makefile.pl" some warnings are there
Warning: prerequisite Image::Magick 0 not found.
Warning: prerequisite JSON::XS 0 not found.
Warning: prerequisite Net::SSH2 0 not found.
Warning: prerequisite Net::SSH2::SFTP 0 not found.
WARNING: Setting ABSTRACT via file 'lib/jQuery/File/Upload.pm' failed
at /usr/lib/perl5/5.8.8/ExtUtils/MakeMaker.pm line 609
Writing Makefile for jQuery::File::Upload
Writing MYMETA.yml and MYMETA.json
i am not sure if it is installed or not.
Please help me for implementation.
Thanks,
Manish
It failed or you will likely gets problems anyway, and you will likely need to install the packages mentioned in the errors. You may also need to install some ssl dev lib bits. For example on mine (Linux Mint/Ubuntu), I needed to do the following...
#edit, looks like on yours you need to install Image::Magick as well
sudo cpan JSON::XS
sudo apt-get install libssh2-1-dev
sudo apt-get install libssl-dev
sudo cpan Net::SSH2
Note: the above packages you may want to see if you can find via your package manager rather than CPAN, however the above should steer you in the right direction of the things you probably need.
then back to the README
perl Makefile.PL
make
make test
make install
My ultimate goal is to run a twiki website for my research group.
I have space on RedHat server that is running Apache, etc., but upon which I do not have root access. Since I cannot install perl modules with the current permissions, I've decided to manually install a local version of perl. Got that working no problem. The following modules are required to get twiki to work:
FreezeThaw - http://search.cpan.org/~ilyaz/FreezeThaw
CGI::Session - http://search.cpan.org/~markstos/CGI-Session
Error - http://search.cpan.org/~shlomif/Error
GD - http://search.cpan.org/~lds/GD
HTML::Tree - http://search.cpan.org/~petek/HTML-Tree
Time-modules - http://search.cpan.org/~muir/Time-modules
I have installed FreezeThaw, CGI, Error, and it fails on GD with the following error:
UNRECOVERABLE ERROR Could not find gdlib-config in the search path.
Please install libgd 2.0.28 or higher. If you want to try to
compile anyway, please rerun this script with the option --ignore_missing_gd.
In searching for how to get around this newest obstacle, I found a previous SO question: How to install GD library with Strawberry Perl asked about installing this and the top answer suggested manually compiling gdlib. You'll note, however, that that link is broken. The base site: http://www.libgd.org/ is basically down saying to go to the project's bitbucket page.
So I got the tarball from that page and am trying to install it. The following problems occur when I follow the instructions included. README.TXT says: "If the sources have been fetched from CVS, run bootstrap.sh [options]."
Running bootstrap.sh yields:
configure.ac:64: warning: macro `AM_ICONV' not found in library
configure.ac:10: required directory ./config does not exist cp: cannot
create regular file `config/config.guess': No such file or directory
configure.ac:11: installing `config/config.guess' configure.ac:11:
error while copying cp: cannot create regular file
`config/config.sub': No such file or directory configure.ac:11:
installing `config/config.sub' configure.ac:11: error while
copying cp: cannot create regular file `config/install-sh': No such
file or directory configure.ac:28: installing `config/install-sh'
configure.ac:28: error while copying cp: cannot create regular
file `config/missing': No such file or directory configure.ac:28:
installing `config/missing' configure.ac:28: error while copying
configure.ac:577: required file `config/Makefile.in' not found
configure.ac:577: required file `config/gdlib-config.in' not found
configure.ac:577: required file `test/Makefile.in' not found
Makefile.am:14: Libtool library used but `LIBTOOL' is undefined
Makefile.am:14: The usual way to define `LIBTOOL' is to add
AC_PROG_LIBTOOL' Makefile.am:14: to configure.ac' and run
aclocal' and autoconf' again. Makefile.am:14: If `AC_PROG_LIBTOOL'
is in `configure.ac', make sure Makefile.am:14: its definition is in
aclocal's search path. cp: cannot create regular file
`config/depcomp': No such file or directory Makefile.am: installing
`config/depcomp' Makefile.am: error while copying Failed
And it says I should also install the following 3rd party libraries:
zlib, available from http://www.gzip.org/zlib/
Data compression library
libpng, available from http://www.libpng.org/pub/png/
Portable Network Graphics library; requires zlib
FreeType 2.x, available from http://www.freetype.org/
Free, high-quality, and portable font engine
JPEG library, available from http://www.ijg.org/
Portable JPEG compression/decompression library
XPM, available from http://koala.ilog.fr/lehors/xpm.html
X Pixmap library
Which I am ignoring for now.
Switching to the generic instructions it says follow the advice in the INSTALL file; which says: "cd to the directory containing the package's source code and type ./configure to configure the package for your system." Which flat does not work: I've cd'ed into every directory of the tarball and running that command does nothing.
So, trying to install twiki required me to install perl, which required me to install the perl modules: FreezeThaw, CGI, Error, HTML, Time-modules, and GD -- which itself required me to install gdlib -- which further suggested I install zlib, libpng, FreeType 2.x, JPEG library, and XPM. And of course, I'm stuck at the installing gdlib stage.
My question is: what other process can possibly demean humanity to such a level? I cannot fathom the depths of cruelty that lay ahead of me as I dive ever deeper into this misery onion. Should I just end it all? Can meaning be brought from this madness? Will the sun come up tomorrow, and if so, does it even matter?
But seriously, any suggestions on what to do differently/better would be much appreciated -- I can't remember what a child's laughter sounds like anymore.
Install the package gd-devel, it contains /usr/bin/gdlib-config.
This should work:
sudo apt-get -y install libgd2-xpm-dev build-essential
I am trying to get WWW::Mechanize to login to Yahoo using https; however, it requires the use of Crypt::SSLeay for sending over https.
Crypt::SSLeay installed succesfully, and openssl was already installed on the system.
However, it gives the error upon loading:
Can't load '/home/gen19/perl5/lib/perl5/lib/site_perl/5.10.1/i686-linux//auto/Crypt/SSLeay/SSLeay.so' for module Crypt::SSLeay: /home/gen19/perl5/lib/perl5/lib/site_perl/5.10.1/i686-linux//auto/Crypt/SSLeay/SSLeay.so: undefined symbol: PL_sv_undef at /usr/lib/perl5/5.8.0/i386-linux-thread-multi/DynaLoader.pm line 229.
at /home/gen19/lwp4 line 15
Compilation failed in require at /home/gen19/lwp4 line 15.
BEGIN failed--compilation aborted at /home/gen19/lwp4 line 15.
The installation of Crypt::SSLeay was successful, and could recognize the installation of openssl (here):
perl Makefile.PL
=======================================================
Only one OpenSSL installation found at /usr
Consider running 'perl Makefile.PL --default' the next
time Crypt::SSLeay is upgraded to select this directory
automatically thereby avoiding the following prompt.
=======================================================
Which SSL install path do you want to use? [/usr] /home/gen19/ssldir
BUILD INFORMATION
================================================
ssl library: OpenSSL 0.9.8 in /home/gen19/ssldir
ssl header: openssl/ssl.h
libraries: -L/home/gen19/ssldir/lib -lssl -lcrypto -lgcc
include dir: -I/home/gen19/ssldir/include/openssl -I/usr/kerberos/include
================================================
Note (probably harmless): No library found for -lgcc
Writing Makefile for Crypt::SSLeay
The test suite can attempt to connect to public servers
to ensure that the code is working properly. If you are
behind a strict firewall or have no network connectivity,
these tests may fail (through no fault of the code).
Do you want to run the live tests (y/N) ? [N]
NOTE: recently installed Perl v5.10.1 using App::perlbrew, due to LWP::UserAgent's needing it. I installed Crypt::SSLeay using my new version of Perl.
I don't have root priveldiges, as I am doing this on a remote server at school. Please tell me why it's giving the error even though it installed succesfully. I know it has something to do with the shared libraries, but the installation recognized them.
SIDE NOTE: my script works fine if I don't say "use Crypt::SSLeay;" at the start, but it gives the error when I use https that it's not a supported protocol, and needs LWP::protocol::https installed. Installing that always fails.
EDIT: Thanks for your help, CJM. Apparently it was using the old version of Perl when I executed, but now I've fixed that.
It doesn't give that error anymore; however, it still says
Error GETing https://login.yahoo.com/config/login_verify2?&.src=ym: Protocol scheme 'https' is not supported (LWP::Protocol::https not installed) at lwp4 line 14
I thought Crypt::SSLeay was supposed to take care of this.
If you examine the error message, you'll notice it mentions both 5.10.1 and 5.8.0 (in the Perl library paths). This indicates that you're trying to use a module built for one version of Perl with a different version. XS-based Perl modules (i.e. ones that include C code) are not binary compatible between major releases of Perl.
It appears you installed Crypt::SSLeay using Perl 5.10.1, and are trying to use it with 5.8.0. That won't work. Use only Perl 5.10.x with that installation. If you need to use it with Perl 5.8.0 also, install another copy in a different directory.
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