Computer Hope

Software => Computer programming => Topic started by: Ädamas on April 23, 2010, 01:35:11 AM

Title: Perl cardiac computer emu'
Post by: Ädamas on April 23, 2010, 01:35:11 AM
adamas@nara:~/Desktop/cardiac$ Perl pe.pl
Can't locate Tk.pm in @INC (@INC contains: /etc/perl /usr/local/lib/perl/5.10.0 /usr/local/share/perl/5.10.0 /usr/lib/perl5 /usr/share/perl5 /usr/lib/perl/5.10 /usr/share/perl/5.10 /usr/local/lib/site_perl .) at pe.pl line 4.
BEGIN failed--compilation aborted at pe.pl line 4.
adamas@nara:~/Desktop/cardiac$

what is wrong with the perl program
source of program
http://dale-miller.com/cardiac-cardboard-illustrative-aid-to-computation/

[recovering disk space - old attachment deleted by admin]
Title: Re: Perl cardiac computer emu'
Post by: BC_Programmer on April 23, 2010, 01:51:51 AM
your missing the perl/tk module, or more precisely, it hasn't been part of the default perl install for a while.

try installing the module through CPAN:

Code: [Select]
cpan -i Tk
you might need to run that as root:
Code: [Select]
sudo cpan -i Tk


That might not work though- CPAN sometimes has issues and reports errors, in that case, you can do it the "hard" way:

download the archive straight from CPAN: http://search.cpan.org/CPAN/authors/id/S/SR/SREZIC/Tk-804.028.tar.gz

Extract/untar and enter the directory, and run the following:
Code: [Select]
perl Makefile.PL
make
make test
make install