CGI/Perl Guide | Learning Center | Forums | Advertise | Login
Site Search: in

  Main Index MAIN
INDEX
Search Posts SEARCH
POSTS
Who's Online WHO'S
ONLINE
Log in LOG
IN

Home: Perl Programming Help: Intermediate:
Problems on cygwin with module Win32::API

 



umadan
New User

Mar 4, 2011, 3:37 AM

Post #1 of 1 (1353 views)
Problems on cygwin with module Win32::API Can't Post

Hi,

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
use strict;

use Win32API::CommPort;

print "Hello World\n";

Any help on what could be the issue is appreciated. I have also installed perl-libwin32 using cygwin setup.exe.

Thanks
-Madan

 
 


Search for (options) Powered by Gossamer Forum v.1.2.0

Web Applications & Managed Hosting Powered by Gossamer Threads
Visit our Mailing List Archives