Beefy Boxes and Bandwidth Generously Provided by pair Networks
P is for Practical
 
PerlMonks  

perl DBI and DBD

by bluethundr (Pilgrim)
on May 27, 2012 at 02:38 UTC ( [id://972659]=perlquestion: print w/replies, xml ) Need Help??

bluethundr has asked for the wisdom of the Perl Monks concerning the following question:

hey guys,
a couple of days ago I created a post about interfacing perl with Oracle. I realize now that I need both the perl DBI and Oracle DBD.
So I downloaded both from CPAN. And DBI gives me this error on make:
cc: DBI.o: No such file or directory cc: no input files *** Error code 1 make: Fatal error: Command failed for target `blib/arch/auto/DBI/DBI.s +o'

And on make for DBD-Oracle I get this error on make:
cc: Oracle.o: No such file or directory cc: dbdimp.o: No such file or directory cc: oci8.o: No such file or directory *** Error code 1 make: Fatal error: Command failed for target `blib/arch/auto/DBD/Oracl +e/Oracle.so'

How can I correct these and proceed to create this oracle script?
thank you monks!

Replies are listed 'Best First'.
Re: perl DBI and DBD
by Tux (Canon) on May 27, 2012 at 08:44 UTC

    Looks like you do not have a (working) C-compiler. Did you (try to) read the README file(s)?

    When DBI fails, there is no point in eventrying to build DBD::Oracle (or any other DBD driver), as it won't work without DBI.


    Enjoy, Have FUN! H.Merijn
Re: perl DBI and DBD
by Anonymous Monk on May 27, 2012 at 03:03 UTC

    So I downloaded both from CPAN. And DBI gives me this error on make:

    start a fresh session, and show everything from  perl Makefile.PL && make

      Hello and thanks for your reply.

      Here's everything from that perl Makefile.pl && make session:
      [db07-dc2:~/DBI-1.618] user% perl Makefile.PL && make 2>&1 >& perlbug. +txt Skip blib/arch/auto/DBI/Driver_xst.h (unchanged) Skip blib/lib/DBD/Proxy.pm (unchanged) Skip blib/lib/DBI/Gofer/Response.pm (unchanged) Skip blib/lib/DBI/Gofer/Transport/Base.pm (unchanged) Skip blib/lib/DBI/Util/_accessor.pm (unchanged) Skip blib/lib/DBD/DBM.pm (unchanged) Skip blib/arch/auto/DBI/DBIXS.h (unchanged) Skip blib/lib/dbixs_rev.pl (unchanged) Skip blib/lib/DBI/Const/GetInfoType.pm (unchanged) Skip blib/lib/DBI/Gofer/Serializer/DataDumper.pm (unchanged) Skip blib/lib/DBI/DBD/Metadata.pm (unchanged) Skip blib/lib/DBD/Gofer/Transport/pipeone.pm (unchanged) Skip blib/lib/DBI/Const/GetInfo/ODBC.pm (unchanged) Skip blib/lib/DBI/ProfileDumper/Apache.pm (unchanged) Skip blib/lib/DBD/File/Roadmap.pod (unchanged) Skip blib/arch/auto/DBI/Driver.xst (unchanged) Skip blib/lib/DBD/File.pm (unchanged) Skip blib/lib/DBI/Util/CacheMemory.pm (unchanged) Skip blib/lib/DBD/NullP.pm (unchanged) Skip blib/lib/DBI/ProfileSubs.pm (unchanged) Skip blib/arch/auto/DBI/dbi_sql.h (unchanged) Skip blib/lib/DBD/File/HowTo.pod (unchanged) Skip blib/lib/DBD/Gofer.pm (unchanged) Skip blib/arch/auto/DBI/dbivport.h (unchanged) Skip blib/arch/auto/DBI/dbd_xsh.h (unchanged) Skip blib/lib/DBI/DBD/SqlEngine/HowTo.pod (unchanged) Skip blib/arch/auto/DBI/dbixs_rev.h (unchanged) Skip blib/lib/DBD/Gofer/Transport/Base.pm (unchanged) Skip blib/lib/DBD/Gofer/Transport/corostream.pm (unchanged) Skip blib/lib/DBI/FAQ.pm (unchanged) Skip blib/lib/DBD/Gofer/Policy/rush.pm (unchanged) Skip blib/lib/DBI/SQL/Nano.pm (unchanged) Skip blib/lib/DBI/Const/GetInfo/ANSI.pm (unchanged) Skip blib/lib/DBI/Gofer/Request.pm (unchanged) Skip blib/lib/DBD/Gofer/Transport/stream.pm (unchanged) Skip blib/lib/DBD/Gofer/Policy/classic.pm (unchanged) Skip blib/lib/DBI/Const/GetInfoReturn.pm (unchanged) Skip blib/lib/DBD/Gofer/Policy/Base.pm (unchanged) Skip blib/lib/DBI.pm (unchanged) Skip blib/lib/DBI/Gofer/Serializer/Storable.pm (unchanged) Skip blib/lib/DBI/Gofer/Transport/stream.pm (unchanged) Skip blib/lib/DBD/Sponge.pm (unchanged) Skip blib/lib/DBD/Gofer/Policy/pedantic.pm (unchanged) Skip blib/lib/DBI/W32ODBC.pm (unchanged) Skip blib/lib/DBI/DBD/SqlEngine/Developers.pod (unchanged) Skip blib/lib/DBI/Gofer/Transport/pipeone.pm (unchanged) Skip blib/lib/DBD/Gofer/Transport/null.pm (unchanged) Skip blib/lib/Bundle/DBI.pm (unchanged) Skip blib/lib/DBD/File/Developers.pod (unchanged) Skip blib/lib/DBI/Profile.pm (unchanged) Skip blib/lib/DBI/ProfileDumper.pm (unchanged) Skip blib/lib/DBI/ProxyServer.pm (unchanged) Skip blib/lib/DBI/Gofer/Serializer/Base.pm (unchanged) Skip blib/arch/auto/DBI/dbipport.h (unchanged) Skip blib/lib/DBI/Gofer/Execute.pm (unchanged) Skip blib/lib/DBI/DBD.pm (unchanged) Skip blib/lib/DBI/DBD/SqlEngine.pm (unchanged) Skip blib/lib/Win32/DBIODBC.pm (unchanged) Skip blib/lib/DBI/PurePerl.pm (unchanged) Skip blib/lib/DBD/ExampleP.pm (unchanged) Skip blib/lib/DBI/ProfileData.pm (unchanged) cc -c -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -xarch=v8 -D_TS_ER +RNO -xO3 -xspace -xildoff -DVERSION=\"1.618\" -DXS_VERSION=\"1.61 +8\" -KPIC "-I/usr/perl5/5.8.4/lib/sun4-solaris-64int/CORE" -DDBI_NO_ +THREADS Perl.c cc: unrecognized option `-KPIC' cc: language ildoff not recognized cc: Perl.c: linker input file unused because linking not done /bin/perl /usr/perl5/5.8.4/lib/ExtUtils/xsubpp -typemap /usr/perl5/5. +8.4/lib/ExtUtils/typemap -typemap typemap DBI.xs > DBI.xsc && mv DBI +.xsc DBI.c cc -c -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -xarch=v8 -D_TS_ER +RNO -xO3 -xspace -xildoff -DVERSION=\"1.618\" -DXS_VERSION=\"1.61 +8\" -KPIC "-I/usr/perl5/5.8.4/lib/sun4-solaris-64int/CORE" -DDBI_NO_ +THREADS DBI.c cc: unrecognized option `-KPIC' cc: language ildoff not recognized cc: DBI.c: linker input file unused because linking not done Running Mkbootstrap for DBI () chmod 644 DBI.bs rm -f blib/arch/auto/DBI/DBI.so cc -G DBI.o -o blib/arch/auto/DBI/DBI.so \ \ cc: DBI.o: No such file or directory cc: no input files *** Error code 1 make: Fatal error: Command failed for target `blib/arch/auto/DBI/DBI.s +o'


      It seems like it might be a compiler issue, but when I try out gcc and cc on their own they seem fine.

      [db07-dc2:~/DBI-1.618] root% cc -v Reading specs from /usr/local/lib/gcc/sparc-sun-solaris2.10/3.4.6/spec +s Configured with: ../configure --with-as=/usr/ccs/bin/as --with-ld=/usr +/ccs/bin/ld --enable-shared --enable-languages=c,c++,f77 Thread model: posix gcc version 3.4.6 [db07-dc2:~] root% gcc -v Reading specs from /usr/local/lib/gcc/sparc-sun-solaris2.10/3.4.6/spec +s Configured with: ../configure --with-as=/usr/ccs/bin/as --with-ld=/usr +/ccs/bin/ld --enable-shared --enable-languages=c,c++,f77 Thread model: posix gcc version 3.4.6


      Before running configure and make I set my CC and GCC settings like this:
      [db07-dc2:~/DBI-1.618] root% echo $GCC /usr/local/bin/gcc [db07-dc2:~/DBI-1.618] root% echo $cc /usr/local/bin/cc


      Also, I realize that DBD won't function without DBI. I was just curious to see if DBD would compile or give a similar error to DBI and fail. :-)

      Thanks for your input I hope I can get this working.
      Best!

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: perlquestion [id://972659]
Approved by Corion
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others chanting in the Monastery: (8)
As of 2024-04-19 12:27 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found