Mar 4, 2011, 3:37 AM
Post #1 of 1
Problems on cygwin with module Win32::API
I wanted to send and read from serial port (COM1) on Windows. I have cygwin and perl installed (perl 5.10). I have also installed the necessary modules for working with Com port (Ex., SerialPort.pm, API.pm, Commport.pm). However when I execute my program which uses these modules I get the following error.
"Can't locate loadable object for module Win32::API in @INC (@INC contains: /usr/lib/perl5/5.10/i686-cygwin /usr/lib/perl5/5.10 /usr/lib/perl5/site_perl/5.10/i686-cygwin /usr/lib/perl5/site_perl/5.10 /usr/lib/perl5/vendor_perl/5.10/i686-cygwin /usr/lib/perl5/vendor_perl/5.10 /usr/lib/perl5/vendor_per
l/5.10 /usr/lib/perl5/site_perl/5.8 /usr/lib/perl5/vendor_perl/5.8 .) at /usr/lib/perl5/5.10/Win32API/CommPort.pm line 8
Compilation failed in require at /usr/lib/perl5/5.10/Win32API/CommPort.pm line 8.
BEGIN failed--compilation aborted at /usr/lib/perl5/5.10/Win32API/CommPort.pm line 8.
Compilation failed in require at /usr/lib/perl5/5.10/i686-cygwin/Win32/SerialPort.pm line 7.
BEGIN failed--compilation aborted at /usr/lib/perl5/5.10/i686-cygwin/Win32/SerialPort.pm line 7.
Compilation failed in require at test.pl line 5.
BEGIN failed--compilation aborted at test.pl line 5."
I have just pasted a simple hello world program that uses Commport but not yet done any programming for accessing the port.
#! /usr/bin/perl -w
print "Hello World\n";
Any help on what could be the issue is appreciated. I have also installed perl-libwin32 using cygwin setup.exe.