Обсуждение: Problems installing DBI

Поиск
Список
Период
Сортировка

Problems installing DBI

От
"E.Boyd"
Дата:
Hi. I am completely new to CYGWIN, having installed it on my Win 2000
machine yesterday. I have installed PostgreSQL (through the CYGWIN setup),
and that's running fine.

I have installed Perl too (also through the CYGWIN setup), but am now having
trouble installing DBI and Pg. I am trying to use CPAN to install these, and
below are the results when I attempt to install DBI. (My apologies if a
similar problem has already been posted; I couldn't find an answer in the
archives).

---

$ cpan

cpan shell -- CPAN exploration and modules installation (v1.59_54)
ReadLine support enabled

cpan> install DBI
Going to read /home/Emily.Boyd/.cpan/sources/authors/01mailrc.txt.gz
CPAN: Compress::Zlib loaded ok
Going to read
/home/Emily.Boyd/.cpan/sources/modules/02packages.details.txt.gz
  Database was generated on Thu, 22 Aug 2002 22:52:17 GMT
  HTTP::Date not available

  There's a new CPAN.pm version (v1.62) available!
  [Current version is v1.59_54]
  You might want to try
    install Bundle::CPAN
    reload cpan
  without quitting the current session. It should be a seamless upgrade
  while we are running...

Going to read /home/Emily.Boyd/.cpan/sources/modules/03modlist.data.gz
Running install for module DBI
Running make for T/TI/TIMB/DBI-1.30.tar.gz
CPAN: MD5 loaded ok
Checksum for
/home/Emily.Boyd/.cpan/sources/authors/id/T/TI/TIMB/DBI-1.30.tar.gz
 ok
Scanning cache /home/Emily.Boyd/.cpan/build for sizes
DBI-1.30/
DBI-1.30/DBI.xs
DBI-1.30/t/
DBI-1.30/t/80proxy.t
DBI-1.30/t/30subclass.t
DBI-1.30/t/70shell.t
DBI-1.30/t/60preparse.t
DBI-1.30/t/20meta.t
DBI-1.30/t/40profile.t
DBI-1.30/t/15array.t
DBI-1.30/t/10examp.t
DBI-1.30/t/04mods.t
DBI-1.30/t/02dbidrv.t
DBI-1.30/t/01basics.t
DBI-1.30/t/05thrclone.t
DBI-1.30/t/03hleak.t
DBI-1.30/Driver_xst.h
DBI-1.30/lib/
DBI-1.30/lib/DBD/
DBI-1.30/lib/DBD/Proxy.pm
DBI-1.30/lib/DBD/NullP.pm
DBI-1.30/lib/DBD/Sponge.pm
DBI-1.30/lib/DBD/ExampleP.pm
DBI-1.30/lib/DBI/
DBI-1.30/lib/DBI/Const/
DBI-1.30/lib/DBI/Const/GetInfoType.pm
DBI-1.30/lib/DBI/Const/GetInfo/
DBI-1.30/lib/DBI/Const/GetInfo/ODBC.pm
DBI-1.30/lib/DBI/Const/GetInfo/ANSI.pm
DBI-1.30/lib/DBI/Const/GetInfoReturn.pm
DBI-1.30/lib/DBI/Format.pm
DBI-1.30/lib/DBI/FAQ.pm
DBI-1.30/lib/DBI/W32ODBC.pm
DBI-1.30/lib/DBI/Shell.pm
DBI-1.30/lib/DBI/Profile.pm
DBI-1.30/lib/DBI/ProxyServer.pm
DBI-1.30/lib/DBI/DBD.pm
DBI-1.30/lib/DBI/PurePerl.pm
DBI-1.30/lib/Bundle/
DBI-1.30/lib/Bundle/DBI.pm
DBI-1.30/lib/Win32/
DBI-1.30/lib/Win32/DBIODBC.pm
DBI-1.30/Changes
DBI-1.30/DBIXS.h
DBI-1.30/MANIFEST
DBI-1.30/dbiproxy.PL
DBI-1.30/Perl.xs
DBI-1.30/dbish.PL
DBI-1.30/Driver.xst
DBI-1.30/dbi_sql.h
DBI-1.30/dbd_xsh.h
DBI-1.30/DBI.pm
DBI-1.30/ToDo
DBI-1.30/test.pl
DBI-1.30/dbipport.h
DBI-1.30/README
DBI-1.30/Makefile.PL
Removing previously used /home/Emily.Boyd/.cpan/build/DBI-1.30

  CPAN.pm: Going to build T/TI/TIMB/DBI-1.30.tar.gz

*** Note:
    The optional PlRPC-modules (RPC::PlServer etc) are not installed.
    If you want to use the DBD::Proxy driver and DBI::ProxyServer
    modules, then you'll need to install the RPC::PlServer, RPC::PlClient,
    Storable and Net::Daemon modules. The CPAN Bundle::DBI may help you.
    You can install them any time after installing the DBI.
    You do *not* need these modules for typical DBI usage.

Optional modules are available from any CPAN mirror, in particular
    http://www.perl.com/CPAN/modules/by-module
    http://www.perl.org/CPAN/modules/by-module
    ftp://ftp.funet.fi/pub/languages/perl/CPAN/modules/by-module

Creating extra DBI::PurePerl test: t/zz_01basics_pp.t
Creating extra DBI::PurePerl test: t/zz_02dbidrv_pp.t
Creating extra DBI::PurePerl test: t/zz_03hleak_pp.t
Creating extra DBI::PurePerl test: t/zz_04mods_pp.t
Creating extra DBI::PurePerl test: t/zz_05thrclone_pp.t
Creating extra DBI::PurePerl test: t/zz_10examp_pp.t
Creating extra DBI::PurePerl test: t/zz_15array_pp.t
Creating extra DBI::PurePerl test: t/zz_20meta_pp.t
Creating extra DBI::PurePerl test: t/zz_30subclass_pp.t
Creating extra DBI::PurePerl test: t/zz_40profile_pp.t
Creating extra DBI::PurePerl test: t/zz_60preparse_pp.t
Creating extra DBI::PurePerl test: t/zz_70shell_pp.t
Creating extra DBI::PurePerl test: t/zz_80proxy_pp.t
Checking if your kit is complete...
Looks good
Writing Makefile for DBI

    Remember to actually *read* the README file!
    Use  'make' to build the software (dmake or nmake on Windows).
    Then 'make test' to execute self tests.
    Then 'make install' to install the DBI and then delete this working
    directory before unpacking and building any DBD::* drivers.

/usr/bin/perl -I/usr/lib/perl5/5.6.1/cygwin-multi -I/usr/lib/perl5/5.6.1 -ME
xtUtils::Command -e mkpath blib/lib/DBI
rm -f blib/lib/DBI/Changes.pm
cp Changes blib/lib/DBI/Changes.pm
cp Driver_xst.h blib/arch/auto/DBI/Driver_xst.h
cp DBIXS.h blib/arch/auto/DBI/DBIXS.h
cp lib/DBD/NullP.pm blib/lib/DBD/NullP.pm
cp dbipport.h blib/arch/auto/DBI/dbipport.h
cp lib/DBI/Format.pm blib/lib/DBI/Format.pm
cp lib/DBI/Const/GetInfoReturn.pm blib/lib/DBI/Const/GetInfoReturn.pm
cp dbd_xsh.h blib/arch/auto/DBI/dbd_xsh.h
cp lib/DBI/Const/GetInfo/ANSI.pm blib/lib/DBI/Const/GetInfo/ANSI.pm
cp lib/DBI/PurePerl.pm blib/lib/DBI/PurePerl.pm
cp lib/DBI/Profile.pm blib/lib/DBI/Profile.pm
cp lib/DBI/Shell.pm blib/lib/DBI/Shell.pm
cp lib/DBI/FAQ.pm blib/lib/DBI/FAQ.pm
cp DBI.pm blib/lib/DBI.pm
cp lib/DBD/ExampleP.pm blib/lib/DBD/ExampleP.pm
cp lib/Bundle/DBI.pm blib/lib/Bundle/DBI.pm
cp lib/Win32/DBIODBC.pm blib/lib/Win32/DBIODBC.pm
cp lib/DBI/W32ODBC.pm blib/lib/DBI/W32ODBC.pm
cp lib/DBI/DBD.pm blib/lib/DBI/DBD.pm
cp lib/DBI/Const/GetInfoType.pm blib/lib/DBI/Const/GetInfoType.pm
cp lib/DBI/ProxyServer.pm blib/lib/DBI/ProxyServer.pm
cp lib/DBD/Proxy.pm blib/lib/DBD/Proxy.pm
cp dbi_sql.h blib/arch/auto/DBI/dbi_sql.h
cp Driver.xst blib/arch/auto/DBI/Driver.xst
cp lib/DBI/Const/GetInfo/ODBC.pm blib/lib/DBI/Const/GetInfo/ODBC.pm
cp lib/DBD/Sponge.pm blib/lib/DBD/Sponge.pm
/usr/bin/perl -p -e "s/~DRIVER~/Perl/g" < blib/arch/auto/DBI/Driver.xst >
Perl.xsi
/usr/bin/perl -I/usr/lib/perl5/5.6.1/cygwin-multi -I/usr/lib/perl5/5.6.1
/usr/lib/perl5/5.6.1/ExtUtils/xsubpp  -typemap
/usr/lib/perl5/5.6.1/ExtUtils/typemap Perl.xs > Perl.xsc && mv Perl.xsc
Perl.c
gcc -c  -DPERL_USE_SAFE_PUTENV -fno-strict-aliasing -I/usr/local/include -DU
SEIM
ORTLIB -O2   -DVERSION=\"1.30\" -DXS_VERSION=\"1.30\"  -I/usr/lib/perl5/5.6.
1/cygwin-multi/CORE -Wall -Wno-comment -DDBI_NO_THREADS Perl.c
dbipport.h:529: warning: `my_sv_2pvbyte' defined but not used
/usr/bin/perl -I/usr/lib/perl5/5.6.1/cygwin-multi -I/usr/lib/perl5/5.6.1
/usr/lib/perl5/5.6.1/ExtUtils/xsubpp  -typemap
/usr/lib/perl5/5.6.1/ExtUtils/typemap DBI.xs > DBI.xsc && mv DBI.xsc DBI.c
gcc -c  -DPERL_USE_SAFE_PUTENV -fno-strict-aliasing -I/usr/local/include -DU
SEIM
ORTLIB -O2   -DVERSION=\"1.30\" -DXS_VERSION=\"1.30\"  -I/usr/lib/perl5/5.6.
1/cygwin-multi/CORE -Wall -Wno-comment -DDBI_NO_THREADS DBI.c
DBI.xs: In function `dbih_clearcom':
DBI.xs:974: warning: unused variable `my_perl'
DBI.xs:973: warning: unused variable `Perl___notused'
DBI.xs: In function `dbih_get_fbav':
DBI.xs:1113: warning: unused variable `Perl___notused'
DBI.xs: In function `dbih_set_attr_k':
DBI.xs:1279: warning: unused variable `Perl___notused'
DBI.xs:1205: warning: unused variable `Perl___notused'
DBI.xs: In function `log_where':
DBI.xs:1728: warning: unused variable `Perl___notused'
DBI.xs: In function `XS_DBI_dispatch':
DBI.xs:2410: warning: unused variable `Perl___notused'
DBI.c: At top level:
dbipport.h:529: warning: `my_sv_2pvbyte' defined but not used
DBIXS.h:411: warning: `get_dbistate' defined but not used
Running Mkbootstrap for DBI ()
chmod 644 DBI.bs
rm -f blib/arch/auto/DBI/DBI.dll
LD_RUN_PATH="" ld2  -s -L/usr/local/lib DBI.o  -o blib/arch/auto/DBI/DBI.dll
/usr/lib/perl5/5.6.1/cygwin-multi/CORE/libperl5_6_1.a
dllwrap --dllname DBI.dll --driver-name gcc --dlltool
dlltool --export-all-symbols --as as --output-def libDBI.def --output-lib
libDBI.a \
-s -L/usr/local/lib DBI.o
/usr/lib/perl5/5.6.1/cygwin-multi/CORE/libperl5_6_1.a

dllwrap: no export definition file provided.
Creating one, but that may not be what you want
/usr/lib/gcc-lib/i686-pc-cygwin/2.95.3-5/../../../../i686-pc-cygwin/bin/ld:
cannot find -luser32
collect2: ld returned 1 exit status
dllwrap: gcc exited with status 1
perlld: *** system() failed to execute
dllwrap --dllname DBI.dll --driver-name gcc --dlltool
dlltool --export-all-symbols --as as --output-def libDBI.def --output-lib
libDBI.a \
-s -L/usr/local/lib DBI.o
/usr/lib/perl5/5.6.1/cygwin-multi/CORE/libperl5_6_1.a


make: *** [blib/arch/auto/DBI/DBI.dll] Error 1
  /usr/bin/make  -- NOT OK
Running make test
  Can't test without successful make
Running make install
  make had returned bad status, install seems impossible

cpan>

---

I am wondering if I've missed something that should have been installed
earlier, or if I'm doing something completely wrong here. I would really
appreciate any suggestions. Thanks!

Emily


Re: Problems installing DBI

От
Greg Matheson
Дата:
On Fri, 23 Aug 2002, E.Boyd wrote:

> I have installed Perl too (also through the CYGWIN setup), but am now having
> trouble installing DBI and Pg. I am trying to use CPAN to install these, and
> below are the results when I attempt to install DBI.

What happens when you try to install the perl Makefile.PL; make;
make test; make install way? By hand, that is?

Sometimes I find CPAN doesn't do it right.

--
Greg Matheson                    Success is going from failure
Chinmin College                  to failure without a loss of
                                 enthusiasm-- Churchill
Taiwan Penpals Archive <URL: http://netcity.hinet.net/kurage>

Re: Problems installing DBI

От
"E.Boyd"
Дата:
On Fri, 23 Aug 2002, Greg Matheson wrote:

> What happens when you try to install the perl Makefile.PL; make;
> make test; make install way? By hand, that is?
>
> Sometimes I find CPAN doesn't do it right.

Same error - at the end of make it gave:
make: *** [blib/arch/auto/DBI/DBI.dll] Error 1

I tried to proceed with make test and make install anyway, but it just kept
repeating this error.

Any ideas?

Emily

> --
> Greg Matheson                    Success is going from failure
> Chinmin College                  to failure without a loss of
>                                  enthusiasm-- Churchill
> Taiwan Penpals Archive <URL: http://netcity.hinet.net/kurage>


Re: Problems installing DBI

От
Jason Tishler
Дата:
Emily,

On Fri, Aug 23, 2002 at 11:32:19PM +1000, E.Boyd wrote:
> /usr/lib/gcc-lib/i686-pc-cygwin/2.95.3-5/../../../../i686-pc-cygwin/bin/ld:
> cannot find -luser32
              ^^^^^^^^
> collect2: ld returned 1 exit status

Install the w32api package.

Jason

Re: Problems installing DBI

От
"E.Boyd"
Дата:
On Sat, 24 Aug 2002, Jason Tishler wrote:

> Install the w32api package.

Thanks Jason! DBI installed fine after I did that.

I'm having some trouble installing DBD::Pg now; I think I've missed
something here too (same error when installing by hand or CPAN):

---

$ perl Makefile.PL
Configuring Pg
Remember to actually read the README file !
please set environment variables POSTGRES_INCLUDE and POSTGRES_LIB !

$ make
make: *** No targets specified and no makefile found.  Stop.

---

From the README, I gather that the environment variables have to be set, or
it won't work. As I installed PostgreSQL through the CYGWIN setup, I'm not
sure what the values should be, or even how to set them.

Can someone please enlighten me? :)

Thanks!

Emily

> Jason


Re: Problems installing DBI

От
"Gerrit P. Haase"
Дата:
Hallo E.Boyd,

> I'm having some trouble installing DBD::Pg now; I think I've missed
> something here too (same error when installing by hand or CPAN):

> ---

> $ perl Makefile.PL
> Configuring Pg
> Remember to actually read the README file !
> please set environment variables POSTGRES_INCLUDE and POSTGRES_LIB !

> $ make
> make: *** No targets specified and no makefile found.  Stop.

> ---

> From the README, I gather that the environment variables have to be set, or
> it won't work. As I installed PostgreSQL through the CYGWIN setup, I'm not
> sure what the values should be, or even how to set them.

> Can someone please enlighten me? :)

$ set | grep POSTGRES
POSTGRES_INCLUDE=/usr/include/postgresql
POSTGRES_LIB=/usr/lib


Gerrit
--
=^..^=


Re: Problems installing DBI

От
"E.Boyd"
Дата:
On Mon, 26 Aug 2002, Gerrit P. Haase wrote:

> $ set | grep POSTGRES
> POSTGRES_INCLUDE=/usr/include/postgresql
> POSTGRES_LIB=/usr/lib

Thanks Gerrit, I tried this... but I'm still getting the same error when I
try to install DBD::Pg. Is there possibly anything else that I need to set
or install first?

Thanks for your help :)

Emily