Mon Jan 24 15:38:51 2011: Request 65052 was acted upon. Transaction: Correspondence added by rur...@x-ray.at Queue: Win32-OLE Subject: Re: [rt.cpan.org #65052] Cannot create ADODB.Connection object under Cygwin Broken in: 0.1709 Severity: Important Owner: Nobody Requestors: rkito...@cpan.org Status: open Ticket <URL: https://rt.cpan.org/Ticket/Display.html?id=65052 >
>> This is on 64bit Windows 7. >> >> On Cygwin: >> >> $ perl -Mblib -MData::Dumper -MWin32::OLE -le 'print Dumper(Win32::OLE- >> >new("ADODB.Connection"))' >> $VAR1 = undef; > > Can you please run with warnings enabled? Win32::OLE will print > additional diagnostics on OLE calls when warnings are on. $ perl -MWin32::OLE -wle 'print Win32::OLE->new("ADODB.Connection")' Win32::OLE(0.1709) error 0x8007007e: "The specified module could not be found" at -e line 1 eval {...} called at -e line 1 Use of uninitialized value in print at -e line 1. With a debugging OLE lib and perl: $ perl5.13.8d-nt -Mblib -we'use Win32::OLE; Win32::OLE->new(q(ADODB.Connection))' Win32::OLE(0.1709) error 0x8007007e: "The specified module could not be found" at -e line 1 eval {...} called at -e line 1 $ gdb perl5.13.8d-nt (gdb) run -Mblib -we'use Win32::OLE; print Win32::OLE->new(q(ADODB.Connection))' Starting program: /usr/local/bin/perl5.13.8d-nt -Mblib -we'use Win32::OLE; print Win32::OLE->new(q(ADODB.Connection))' [New thread 8308.0xa88] [New thread 8308.0xb10] [New thread 8308.0x2380] [New thread 8308.0x1ccc] [New thread 8308.0xd8c] [New thread 8308.0x22d8] [New thread 8308.0x125c] Win32::OLE=HASH(0xb56348) This needs now printf debugging, oh my. >> On ActiveState Perl 32 bit: > > Is this just 32-bit ActivePerl on the same machine, or on a different > one? I crosschecked with strawberry on the same machine, where ADODB.Connection is registered. c:\strawberry> perl -MData::Dumper -MWin32::OLE -le "print Dumper(Win32::OLE->new(q(ADODB.Connection)))" $VAR1 = bless( { 'Properties' => bless( { 'Count' => 14, 'Item' => undef }, 'Win32::OLE' ), 'ConnectionString' => 'Provider=MSDASQL.1', 'CommandTimeout' => 30, 'ConnectionTimeout' => 15, 'Version' => '6.1', 'Errors' => bless( { 'Count' => 0, 'Item' => undef }, 'Win32::OLE' ), 'DefaultDatabase' => undef, 'IsolationLevel' => 4096, 'Attributes' => 0, 'CursorLocation' => 2, 'Mode' => 0, 'Provider' => 'MSDASQL.1', 'State' => 0 }, 'Win32::OLE' ); > Also, which Cygwin version are you using? Your example works fine > with my (obsolete) Cygwin 1.5 install. Latest 1.7.8 with my official perl -- Reini Urban http://phpwiki.org/ http://murbreak.at/