Class::Date [RESOLVIDO]

1. Class::Date [RESOLVIDO]

SEBASTIÃO HILÁRIO
sebasti

(usa Outra)

Enviado em 17/06/2011 - 20:35h

Pessoal, Depois de um tempo lutando com o Debian, agora surge um novo problema.
ao executar um CGI, dá aseguinte mensagem:

Can't locate Class/Date.pm in @INC (@INC contains: /etc/perl /usr/local/lib/perl/5.10.1 /usr/local/share/perl/5.10.1 /usr/lib/perl5 /usr/share/perl5 /usr/lib/perl/5.10 /usr/share/perl/5.10 /usr/local/lib/site_perl .)

Tentei instalar a biblioteca Class:Date pelo CPAN
# perl -MCPAN -e shell
cpan[1]> install DateTime

RESULTADO FINAL:

CPAN: YAML loaded ok (v0.73)
Running Build test
Can't test without successful make
Running Build install
Make had returned bad status, install seems impossible
Failed during this command:
DROLSKY/DateTime-0.70.tar.gz : make NO

E O ERROR CONTINUA E NÃO CONSIGO INSTALAR A BIBLIOTECA.
DETALHE, usando o comando locate, veja onde encontrei.

root@228876:/var/log/apache2# locate Date.pm
/root/.cpan/build/Class-Date-1.1.10-BWS0YS/Date.pm
/root/.cpan/build/Class-Date-1.1.10-YWFlX6/Date.pm
/root/.cpan/build/HTTP-Date-6.00-UViEst/lib/HTTP/Date.pm
/usr/share/perl5/HTTP/Date.pm
/usr/share/perl5/Mail/Field/Date.pm

Se alguem puder me ajudar, ficarei grato.

Sebasti




  


2. MELHOR RESPOSTA

Renato Carneiro Pacheco
renato_pacheco

(usa Debian)

Enviado em 18/06/2011 - 14:39h

Olha, eu quero saber quais foram as msgs q deram no momento da instalação. Teste esse comando abaixo:

# aptitude install build-essential

Note q está no singular, não no plural. Às vezes eu tenha errado no comando, por isso pedi pra vc postar a saída deles.

3. Re: Class::Date [RESOLVIDO]

Renato Carneiro Pacheco
renato_pacheco

(usa Debian)

Enviado em 17/06/2011 - 23:28h

Instale o build-essentials:

# aptitude install build-essentials

Se num der certo, instale o make msm:

# aptitude install make


4. Class:Date

SEBASTIÃO HILÁRIO
sebasti

(usa Outra)

Enviado em 18/06/2011 - 07:51h

A todos um BOM DIA
Renato,
Obrigado por me responder.

Fiz como você orientou, mas continua com o erro, tem mais alguma coisa que é preciso fazer após essas instalações?

Grato,

Sebasti



5. Class DBI

SEBASTIÃO HILÁRIO
sebasti

(usa Outra)

Enviado em 18/06/2011 - 08:23h

Pessoal,

Além do problema da Class:Date persistir, agora tenho outro problema com a DBI, segue o trecho da instalação:
--- INICIO ---
cpan[11]> install Class::DBI

Running install for module 'Class::DBI'
Running make for T/TM/TMTM/Class-DBI-v3.0.17.tar.gz
Checksum for /root/.cpan/sources/authors/id/T/TM/TMTM/Class-DBI-v3.0.17.tar.gz ok
Class-DBI-v3.0.17/
..... FINAL ...
Running make install
make test had returned bad status, won't install without force
Failed during this command:
RDF/Clone-0.31.tar.gz : make NO
TMTM/Class-DBI-v3.0.17.tar.gz : make_test NO one dependency not OK (Clone); additionally test harness failed
--------------
O QUE PODE ESTAR ACONTECENDO? NÃO CONSIGO CONCLUIR A INSTALAÇÃO DESTAS
BIBLIOTECAS, ESTA ULTIMA É DE GRANDE IMPORTÂNCIA NO ACESSO A BASE DE DADOS.

Vejam trecho do script e o erro que dá na aplicação:
#--------------------
use DBI;
my $dbh = DBI->connect ("DBI:mysql:$system_db:$system_db_address", "$system_db_user", "$system_db_pass");
my $consulta = "SELECT nome, cpf, rg FROM cad_func Where id_func = \"$fromweb{if_func}\";
my $sth1 = $dbh->prepare($consulta);
$sth1->execute();
#--------------------
ERRO:
Software error:
Can't call method "prepare" on an undefined value at /var/www/cgi-bin/nome_do_script.cgi

POR FAVOR ME AJUDEM!!

Sebasti.




6. Re: Class::Date [RESOLVIDO]

Renato Carneiro Pacheco
renato_pacheco

(usa Debian)

Enviado em 18/06/2011 - 14:20h

Eu t orientei, mas instalou? Vc conferiu? Tentou dos dois modos?


7. Classe:Date

SEBASTIÃO HILÁRIO
sebasti

(usa Outra)

Enviado em 18/06/2011 - 14:26h

Renato,

Desculpe não mencionar o que fiz.
Sim fiz das duas formas e verifiquei e não instalou.

Abraço.



8. Classe:Date

SEBASTIÃO HILÁRIO
sebasti

(usa Outra)

Enviado em 18/06/2011 - 14:28h

Como proceder para desistalar tudo e começar do zero denovo?

Obrigado.


9. Classe::Date

SEBASTIÃO HILÁRIO
sebasti

(usa Outra)

Enviado em 18/06/2011 - 17:18h

Prezado Renato,

Ok, ai está a primeira saida após efetuar o comando, aguardando uma resposta, respondi (Y).
... NOTE QUE NÃO FOI O MESMO COMANDO QUE VC INDICOU NA PRIMEIRA VEZ, OK! ...

Last login: Sat Jun 18 10:37:32 2011 from 189.61.173.146
root@228876:~# aptitude install build-essential
Reading package lists... Done
Building dependency tree
Reading state information... Done
Reading extended state information... Done
Initializing package states... Done
Reading task descriptions... Done
The following NEW packages will be installed:
binutils{a} build-essential bzip2{a} dpkg-dev{a} fakeroot{a} g++{a} g++-4.4{a} gcc{a} gcc-4.4{a} libalgorithm-diff-perl{a}
libalgorithm-diff-xs-perl{a} libalgorithm-merge-perl{a} libc-dev-bin{a} libc6-dev{a} libdpkg-perl{a} libstdc++6-4.4-dev{a} linux-libc-dev{a}
manpages-dev{a}
The following packages will be upgraded:
cpp
1 packages upgraded, 18 newly installed, 0 to remove and 22 not upgraded.
Need to get 20.7MB/20.8MB of archives. After unpacking 63.2MB will be used.
Do you want to continue? [Y/n/?] Y
....CONTINUAÇÃO... FINALIZAÇÃO DO COMANDO ....
Writing extended state information... Done
Get:1 http://security.debian.org squeeze/updates/main linux-libc-dev 2.6.32-34squeeze1 [844kB]
Get:2 http://ftp.debian.org squeeze/main binutils 2.20.1-16 [3993kB]
Get:3 http://ftp.debian.org squeeze/main libc-dev-bin 2.11.2-10 [207kB]
Get:4 http://ftp.debian.org squeeze/main libc6-dev 2.11.2-10 [2587kB]
Get:5 http://ftp.debian.org squeeze/main cpp 4:4.4.5-1 [15.0kB]
Get:6 http://ftp.debian.org squeeze/main gcc-4.4 4.4.5-8 [2688kB]
Get:7 http://ftp.debian.org squeeze/main gcc 4:4.4.5-1 [4970B]
Get:8 http://ftp.debian.org squeeze/main libstdc++6-4.4-dev 4.4.5-8 [1526kB]
Get:9 http://ftp.debian.org squeeze/main g++-4.4 4.4.5-8 [5515kB]
Get:10 http://ftp.debian.org squeeze/main g++ 4:4.4.5-1 [1376B]
Get:11 http://ftp.debian.org squeeze/main libdpkg-perl 1.15.8.10 [689kB]
Get:12 http://ftp.debian.org squeeze/main dpkg-dev 1.15.8.10 [807kB]
Get:13 http://ftp.debian.org squeeze/main build-essential 11.5 [7178B]
Get:14 http://ftp.debian.org squeeze/main fakeroot 1.14.4-1 [100kB]
Get:15 http://ftp.debian.org squeeze/main libalgorithm-diff-perl 1.19.02-2 [51.5kB]
Get:16 http://ftp.debian.org squeeze/main libalgorithm-diff-xs-perl 0.04-1 [13.4kB]
Get:17 http://ftp.debian.org squeeze/main libalgorithm-merge-perl 0.08-2 [13.5kB]
Get:18 http://ftp.debian.org squeeze/main manpages-dev 3.27-1 [1639kB]
Fetched 20.7MB in 5s (3983kB/s)
Reading changelogs... Done
Selecting previously deselected package binutils.
(Reading database ... 24663 files and directories currently installed.)
Unpacking binutils (from .../binutils_2.20.1-16_amd64.deb) ...
Selecting previously deselected package libc-dev-bin.
Unpacking libc-dev-bin (from .../libc-dev-bin_2.11.2-10_amd64.deb) ...
Selecting previously deselected package linux-libc-dev.
Unpacking linux-libc-dev (from .../linux-libc-dev_2.6.32-34squeeze1_amd64.deb) ...
Selecting previously deselected package libc6-dev.
Unpacking libc6-dev (from .../libc6-dev_2.11.2-10_amd64.deb) ...
Preparing to replace cpp 4:4.4.3-1 (using .../cpp_4%3a4.4.5-1_amd64.deb) ...
Unpacking replacement cpp ...
Selecting previously deselected package gcc-4.4.
Unpacking gcc-4.4 (from .../gcc-4.4_4.4.5-8_amd64.deb) ...
Selecting previously deselected package gcc.
Unpacking gcc (from .../gcc_4%3a4.4.5-1_amd64.deb) ...
Selecting previously deselected package libstdc++6-4.4-dev.
Unpacking libstdc++6-4.4-dev (from .../libstdc++6-4.4-dev_4.4.5-8_amd64.deb) ...
Selecting previously deselected package g++-4.4.
Unpacking g++-4.4 (from .../g++-4.4_4.4.5-8_amd64.deb) ...
Selecting previously deselected package g++.
Unpacking g++ (from .../g++_4%3a4.4.5-1_amd64.deb) ...
Selecting previously deselected package libdpkg-perl.
Unpacking libdpkg-perl (from .../libdpkg-perl_1.15.8.10_all.deb) ...
Selecting previously deselected package bzip2.
Unpacking bzip2 (from .../bzip2_1.0.5-6_amd64.deb) ...
Selecting previously deselected package dpkg-dev.
Unpacking dpkg-dev (from .../dpkg-dev_1.15.8.10_all.deb) ...
Selecting previously deselected package build-essential.
Unpacking build-essential (from .../build-essential_11.5_amd64.deb) ...
Selecting previously deselected package fakeroot.
Unpacking fakeroot (from .../fakeroot_1.14.4-1_amd64.deb) ...
Selecting previously deselected package libalgorithm-diff-perl.
Unpacking libalgorithm-diff-perl (from .../libalgorithm-diff-perl_1.19.02-2_all.deb) ...
Selecting previously deselected package libalgorithm-diff-xs-perl.
Unpacking libalgorithm-diff-xs-perl (from .../libalgorithm-diff-xs-perl_0.04-1_amd64.deb) ...
Selecting previously deselected package libalgorithm-merge-perl.
Unpacking libalgorithm-merge-perl (from .../libalgorithm-merge-perl_0.08-2_all.deb) ...
Selecting previously deselected package manpages-dev.
Unpacking manpages-dev (from .../manpages-dev_3.27-1_all.deb) ...
Processing triggers for man-db ...
Setting up binutils (2.20.1-16) ...
Setting up libc-dev-bin (2.11.2-10) ...
Setting up linux-libc-dev (2.6.32-34squeeze1) ...
Setting up libc6-dev (2.11.2-10) ...
Setting up cpp (4:4.4.5-1) ...
Setting up gcc-4.4 (4.4.5-8) ...
Setting up gcc (4:4.4.5-1) ...
Setting up libdpkg-perl (1.15.8.10) ...
Setting up bzip2 (1.0.5-6) ...
Setting up dpkg-dev (1.15.8.10) ...
Setting up fakeroot (1.14.4-1) ...
update-alternatives: using /usr/bin/fakeroot-sysv to provide /usr/bin/fakeroot (fakeroot) in auto mode.
Setting up libalgorithm-diff-perl (1.19.02-2) ...
Setting up libalgorithm-diff-xs-perl (0.04-1) ...
Setting up libalgorithm-merge-perl (0.08-2) ...
Setting up manpages-dev (3.27-1) ...
Setting up libstdc++6-4.4-dev (4.4.5-8) ...
Setting up g++-4.4 (4.4.5-8) ...
Setting up g++ (4:4.4.5-1) ...
update-alternatives: using /usr/bin/g++ to provide /usr/bin/c++ (c++) in auto mode.
Setting up build-essential (11.5) ...
Reading package lists... Done
Building dependency tree
Reading state information... Done
Reading extended state information... Done
Initializing package states... Done
Writing extended state information... Done
Reading task descriptions... Done
---- FINA ....
Current status: 22 updates [-1].
root@228876:~#



10. Classe:Date

SEBASTIÃO HILÁRIO
sebasti

(usa Outra)

Enviado em 18/06/2011 - 17:20h

Desculpe Renato,

Mas esqueci de reporta, o erro ainda continua, lembrando que o primeiro comando foi dado realmente no plural.

Sebasti.


11. Classe:Date

SEBASTIÃO HILÁRIO
sebasti

(usa Outra)

Enviado em 18/06/2011 - 17:29h

Renato,

Depois deste comando, executei também o CPAN, desta vez a saida foi diferente, segue abaixo um trecho da parte final, pois é muito grande, confere ai.

cpan[1]> install DateTime
CPAN: Storable loaded ok (v2.20)
Going to read '/root/.cpan/Metadata'
Database was generated on Fri, 17 Jun 2011 20:31:20 GMT
Running install for module 'DateTime'
.CONTINUA.....FINAL..
Building DateTime
Files found in blib/arch: installing files in blib/lib into architecture dependent library tree
Installing /usr/local/lib/perl/5.10.1/auto/DateTime/DateTime.so
Installing /usr/local/lib/perl/5.10.1/auto/DateTime/DateTime.bs
Installing /usr/local/lib/perl/5.10.1/DateTimePP.pm
Installing /usr/local/lib/perl/5.10.1/DateTime.pm
Installing /usr/local/lib/perl/5.10.1/DateTimePPExtra.pm
Installing /usr/local/lib/perl/5.10.1/DateTime/Infinite.pm
Installing /usr/local/lib/perl/5.10.1/DateTime/Duration.pm
Installing /usr/local/lib/perl/5.10.1/DateTime/LeapSecond.pm
Installing /usr/local/lib/perl/5.10.1/DateTime/Helpers.pm
Installing /usr/local/man/man3/DateTime::Duration.3pm
Installing /usr/local/man/man3/DateTime::Infinite.3pm
Installing /usr/local/man/man3/DateTime.3pm
Installing /usr/local/man/man3/DateTime::LeapSecond.3pm
DROLSKY/DateTime-0.70.tar.gz
./Build install -- OK

cpan[2]> o conf commit
commit: wrote '/etc/perl/CPAN/Config.pm'




12. Re: Class::Date [RESOLVIDO]

Renato Carneiro Pacheco
renato_pacheco

(usa Debian)

Enviado em 18/06/2011 - 18:02h

Agora, sim! Instalou, percebeu? Faltava os aplicativos d compilação (gcc, make etc.).



01 02



Patrocínio

Site hospedado pelo provedor RedeHost.
Linux banner

Destaques

Artigos

Dicas

Tópicos

Top 10 do mês

Scripts