How to use module in Guile? `$ guile copy.scm; ERROR: no code for module (gnome-2)` - gtk

I learnt basisc about Scheme and want to try Guile.
When copied this sample here the first one and run as a script, an Error occured,
$ guile copy.scm
ERROR: no code for module (gnome-2)
My laptop runs Fedora 16 x86_64, with yum install guile*
How to deal with Guile's modules?

May be you need guile-gnome-plataform-devel?

Related

Error installing perl module (cpan and manually)

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

BOBTFISH/Task-Catalyst installation error

I am using CentOS 5.7 perl 5.14.2. While installing CPAN module Task::Catalyst
cpan -i Task::Catalyst
i am getting the error:
http://pastebin.com/N1p1UMAH
3 modules Catalyst::Authentication::Credential::HTTP, Catalyst::View::Email and Catalyst::Plugin::Session::Store::DBIC are giving installation errors
When i tried to manually install the modules , say Catalyst::View::Email
i downloaded the tar file, and then after running the ./Makefile.pl
i got the error
http://pastebin.com/ZSDLtqii
Please suggest?
Makefile.PL is just a perl script, that is generally invoked as perl Makefile.PL, and its output is a regular 'make' style makefile.
Have a look at its contents - perhaps it's been corrupted somehow. In the case of C::V::Email, it should be 39 lines long, and look exactly like this.

installing perl module Class-Load-XS

I tried to install module Class-Load-XS-0.04 manually. I saw the following error:
$ perl Build.PL
Warning: ExtUtils::CBuilder not installed or no compiler detected
Proceeding with configuration, but compilation may fail during Build
However, the execution of perl -e 'use ExtUtils::CBuilder' was perfectly fine. I even tried to re-install ExtUtils::CBuilder, but it still does not work.
Could you please help?
I tried on my Win 7 machine, and it shows some warnings like this when I do perl Build.pl:
collect2: ld returned 1 exit status
Checking prerequisites...
requires:
! Class::Load is not installed
build_requires:
! Class::Load is not installed
! Module::Implementation is not installed
! Test::Fatal is not installed
! Test::Requires is not installed
ERRORS/WARNINGS FOUND IN PREREQUISITES. You may wish to install the versions
of the modules indicated above before proceeding with this installation
Then I installed the above mentioned modules, and things went fine then.
You may try install these modules first.
Hope it helps.
It looks to me like you don't have a compiler. Try this:
perl -e 'use ExtUtils::CBuilder; $cb = ExtUtils::CBuilder->new; print $cb->have_compiler ? "have\n" : "dont have\n";'
Can I guess that you are on Windows using ActiveState Perl? If so perhaps try Strawberry Perl which comes with a compiler.
Had a similar problem installing a different module (Win32::Mutex). This isn't a great fix, but it got the job done. From the build directory (e.g., ~/.cpan/build/The-Module-mYyzLx)
First, set the CC environment variable yourself
SET CC=C:\strawberry\c\bin\g++.exe [Windows]
export CC=/usr/bin/g++.exe [Cygwin]
and try to build (perl Build.PL, perl Build, ...). If it is still complaining about missing programs (g++, dlltool, etc.):
Second, copy pieces of your tool chain into the build directory
COPY C:\strawberry\c\bin\g++.exe . [Windows]
COPY C:\strawberry\c\bin\dlltool.exe .
cp /usr/bin/g++ . [Cygwin]
cp /usr/bin/dlltool .
If the build still complains about missing programs, copy those to your build directory too.
The fix and the symptoms are consistent with ExtUtils::CBuilder not being able to use the current PATH setting, though I have no idea what that would be so difficult.
I'd suggest installing these first:
apt-get install libc6-dev
and
apt-get install libtest-exception-perl
By the way you describe the problem it looks like you have these two perl modules missing. On the other hand it takes just a couple of seconds to double-check if those are installed, but these 'seconds' could help you save on a lot of head ache.

Why does Perl module Crypt::SSLeay give an error upon loading?

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.

Why can't DynaLoader.pm load SSleay.dll for Net::SSLeay and Crypt::SSLeay?

I have Perl v5.10. I am trying to install Net::SSLeay 1.30 and Crypt::SSLeay 0.57.
I have already installed OpenSSL 0.9.8e.
For Net::SSLeay 1.30 I followed these steps:
perl Makefile.PL -windows C:\openssl
nmake
nmake test -- test fails
nmake install
perl test.pl
but I got an fatal error as:
D:\perl\Net_SSLeay.pm-1.30>perl -w test.pl
1..20
Can't load 'D:/perl/site/lib/auto/Net/SSLeay/SSLeay.dll' for module Net::SSLeay: load_file:The specified module could not be found at D:/perl/lib/DynaLoader.pm line 203.
at test.pl line 25
Compilation failed in require at test.pl line 25.
BEGIN failed--compilation aborted at test.pl line 25.
I got the same results for Crypt::SSLeay 0.57.
Randy Kobes has an answer for this on the Perl Win32 mailing list. Does your PATH environment variable contain the directory that contains libeay32.dll or ssleay32.dll?
There are many other answers that you can find in Google too. In cases like these, I take the whole error message and shove it into the Google search bar. I start cutting out parts of the error message, such as the specific paths, until I get some search results. This almost always works for me since I'm rarely the first person to have a problem.
Shared libs often have external dependencies, and on some operating systems those dependencies need to be immediately fulfilled when the first shared library is loaded, like your SSLeay.dll, which usually needs the two crypto libs. On linux you can check with ldd the run-time behavior, if all libs are found.
To debug this add the env var PERL_DL_DEBUG=5, like set PERL_DL_DEBUG=5 and try again or use the external tool depends.exe to see what dll's exactly are missing.
I had a similar problem with Windows Par::Packer. The resulting myprogram.exe had trouble loading rurban's hint with PERL_DL_DEBUG
Can't load 'temp\7e717f68.xs.dll' for module Crypt::SSLeay: load_file:Das angegebene Modul wurde nicht gefunden at <embedded>/DynaLoader.pm line 193.
at <embedded>/PAR/Heavy.pm line 95.
I was not able to find out which dlls to include with pp. After these hints I was simply looking to the dll-file with a hex editor and found this string: libgcc_s_dw2-1.dll - this was the dll to include into my "compiled" exe-program:
pp -M Crypt::SSLeay ^
-l c:/strawberry/perl/vendor/lib/auto/Crypt/SSLeay/SSLeay.xs.dll ^
-l c:/strawberry/c/bin/libgcc_s_dw2-1.dll ....
I'm having this same problem with a fresh install of Strawberry Perl 5.30. Googling the error just gives a bunch of unanswered, or half answered questions. Rurban is pointing in the right direction with using depends.exe. Opening ssleay.xs.dll and waiting for it to finishing throwing errors shows 5 main dll's that it depends on. 2 of which are windows core dll's, and 3 from openssl and perl. In the strawberry install, the 2 dll's related to crypto are in the [perlinstallpath]\c\bin folder. Add this to your windows %PATH% variable and it will start working.