I do experience problems when I try to install an uptodate version of DBD::Oracle.
So far we have been using this oracle: ORACLE_HOME="/app/local/oracle/product/8.1.7", but now the company installed 9.2.0 on all devopment and production machines, so my boss told me to get DBD::Oracle running with 9.2.0, both on the client and on the server side.
Characteristics of this binary (from libperl): Compile-time options: USE_LARGE_FILES Built under solaris Compiled at Jan 15 2003 03:22:35 @INC: /app/idsp22/cronus1/usr/local/lib/perl5/5.6.1/sun4-solaris /app/idsp22/cronus1/usr/local/lib/perl5/5.6.1 /app/idsp22/cronus1/usr/local/lib/perl5/site_perl/5.6.1/sun4-solaris /app/idsp22/cronus1/usr/local/lib/perl5/site_perl/5.6.1 /app/idsp22/cronus1/usr/local/lib/perl5/site_perl . ================================================================================
First I simply tried this:
perl -MCPAN -e 'install DBD::Oracle'
but this is how it ended:
================================================================================ LD_RUN_PATH="/app/local/oracle/product/9.2.0/lib:/app/local/oracle/product/9.2.0/rdbms/lib" gcc -G -L/usr/local/lib Oracle.o dbdimp.o oci7.o oci8.o -L/opt/SUNWcluster/lib -R/opt/SUNWcluster/lib -o build -L/app/local/oracle/product/9.2.0/rdbms/lib/ -L/app/local/oracle/product/9.2.0/lib/ -lclntsh -lnbeq9 -lnhost9 -lnus9 -lnldap9 -lldapclnt9 -lnsslb9 -lnnis9 -lnoname9 -lntcp9 -lntcps9 -lnsslb9 -lntcp9 -lntns9 -lnsl -lsocket -lgen -ldl -R/app/local/oracle/product/9.2.0/lib -laio -lposix4 -lkstat -lm -lthread -o blib/arch/auto/DBD/Oracle/Oracle.so ld: warning: option -o appears more than once, first setting taken ld: fatal: file /app/local/oracle/product/9.2.0/lib//libclntsh.so: wrong ELF class: ELFCLASS64 ld: fatal: File processing errors. No output written to build collect2: ld returned 1 exit status make: *** [blib/arch/auto/DBD/Oracle/Oracle.so] Error 1 /app/idse22/cronus/usr/local/bin/make -- NOT OK ================================================================================
Bad, right?!
So I followed the README, now have a look at this, pls:
================================================================================ cronus@rsx94220 $ perl Makefile.PL -p Using DBI 1.38 installed in /app/idsp22/cronus1/usr/local/lib/perl5/site_perl/5.6.1/sun4-solaris/auto/DBI
Configuring DBD::Oracle ...
Remember to actually *READ* the README file!
Especially if you have any problems.
Using Oracle in /app/local/oracle/product/9.2.0
Oracle version 9.2.0.0.0 Found header files in rdbms/public rdbms/demo. Found /app/local/oracle/product/9.2.0/rdbms/demo/demo_rdbms.mk Found /app/local/oracle/product/9.2.0/otrace/demo/atmoci.mk Using /app/local/oracle/product/9.2.0/rdbms/demo/demo_rdbms.mk Reading /app/local/oracle/product/9.2.0/rdbms/demo/demo_rdbms.mk Reading /app/local/oracle/product/9.2.0/rdbms/lib/env_rdbms.mk Deleting ORA_NLS = $(ORACLE_HOME)/ocommon/nls/admin/data/ because it is not already set in the environment and it can cause ORA-01019 errors. Deleting ORA_NLS33 = $(ORACLE_HOME)/ocommon/nls/admin/data/ because it is not already set in the environment and it can cause ORA-01019 errors.
Attempting to discover Oracle OCI build rules gcc -c -I/app/local/oracle/product/9.2.0/rdbms/demo -I/app/local/oracle/product/9.2.0/rdbms/public -I/app/local/oracle/product/9.2.0/plsql/public -I/app/local/oracle/product/9.2.0/network/public -I/app/local/oracle/product/9.2.0/rdbms/demo -I/app/local/oracle/product/9.2.0/rdbms/public -I/app/local/oracle/product/9.2.0/rdbms/demo -I/app/idsp22/cronus1/usr/local/lib/perl5/site_perl/5.6.1/sun4-solaris/auto/DBI -fno-strict-aliasing -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -O -DVERSION=\"1.14\" -DXS_VERSION=\"1.14\" -fPIC -I/app/idsp22/cronus1/usr/local/lib/perl5/5.6.1/sun4-solaris/CORE -DUTF8_SUPPORT DBD_ORA_OBJ.c cc1: warning: changing search order for system directory "/usr/local/include" cc1: warning: as it has already been specified as a non-system directory by executing: (make -f /app/local/oracle/product/9.2.0/rdbms/demo/demo_rdbms.mk build ECHODO=echo ECHO=echo GENCLNTSH='echo genclntsh' CC=echo OPTIMIZE= CCFLAGS= EXE=DBD_ORA_EXE OBJS=DBD_ORA_OBJ.o) Oracle oci build command: + -L/opt/SUNWcluster/lib -R/opt/SUNWcluster/lib -o build -L/app/local/oracle/product/9.2.0/rdbms/lib/ -L/app/local/oracle/product/9.2.0/lib/ -o DBD_ORA_EXE DBD_ORA_OBJ.o -lclntsh -lnbeq9 -lnhost9 -lnus9 -lnldap9 -lldapclnt9 -lnsslb9 -lnnis9 -lnoname9 -lntcp9 -lntcps9 -lnsslb9 -lntcp9 -lntns9 -lnsl -lsocket -lgen -ldl -R/app/local/oracle/product/9.2.0/lib -laio -lposix4 -lkstat -lm -lthread
System: perl5.006001 sunos rsx94220 5.8 generic_112953-02 sun4u sparc Compiler: gcc -O -fno-strict-aliasing -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 Linker: /usr/ccs/bin/ld Sysliblist: -lnsl -lsocket -lgen -ldl Oracle makefiles would have used these definitions but we override them: CC: cc
Argument "9.200.0.0" isn't numeric in numeric ge (>=) at Makefile.PL line 669.
Warning: If you have problems you may need to rebuild perl with threading enabled.
LD_RUN_PATH=/app/local/oracle/product/9.2.0/lib:/app/local/oracle/product/9.2.0/rdbms/lib Using DBD::Oracle 1.14. Using DBI 1.38 installed in /app/idsp22/cronus1/usr/local/lib/perl5/site_perl/5.6.1/sun4-solaris/auto/DBI Writing Makefile for DBD::Oracle
*** If you have problems... read all the log printed above, and the README and README.help files. (Of course, you have read README by now anyway, haven't you?)
The "perl -MCPAN -e 'install DBD::Oracle'" simply ignored that problem, but I am not sure, I really should, so I lay this case before you, hoping for a hint or two, or maybe a patch.
I am quite willing to try a lot -- if you give me hints what to try.
Cheers, Jochen - wasting his life in the autumnly sad Munich
Andy Crichton 27 November 2003 15:46:36 [ permanent link ]
This is caused by trying to link 32bit perl with 64bit oracle libraries (which live in $ORACLE_HOME/lib). What happens if you specify $ORACLE_HOME/lib32 in your LD_LIBRARY_PATH (before any other oracle paths which may be in there).
Q/ Does DBD::Oracle use LD_LIBRARY_PATH or assume $ORACLE_HOME/lib is the setting for the oracle libs?
Well, that's just like what I have done before, as I first simply tried this (and I wrote that already in my first posting):
perl -MCPAN -e 'install DBD::Oracle'
and this is how it ended:
============================================================================ ==== LD_RUN_PATH="/app/local/oracle/product/9.2.0/lib:/app/local/oracle/product/9 .2.0/rdbms/lib" gcc -G -L/usr/local/lib Oracle.o dbdimp.o oci7.o oci8.o -L/opt/SUNWcluster/lib -R/opt/SUNWcluster/lib -o build -L/app/local/oracle/product/9.2.0/rdbms/lib/ -L/app/local/oracle/produ ct/9.2.0/lib/ -lclntsh -lnbeq9 -lnhost9 -lnus9 -lnldap9 -lldapclnt9 -lnssl b9 -lnnis9 -lnoname9 -lntcp9 -lntcps9 -lnsslb9 -lntcp9 -lntns9 -lnsl -lsocke t -lgen -ldl -R/app/local/oracle/product/9.2.0/lib -laio -lposix4 -lkstat -l m -lthread -o blib/arch/auto/DBD/Oracle/Oracle.so ld: warning: option -o appears more than once, first setting taken ld: fatal: file /app/local/oracle/product/9.2.0/lib//libclntsh.so: wrong ELF class: ELFCLASS64 ld: fatal: File processing errors. No output written to build collect2: ld returned 1 exit status make: *** [blib/arch/auto/DBD/Oracle/Oracle.so] Error 1 /app/idse22/cronus/usr/local/bin/make -- NOT OK ============================================================================ ====
and that's not so much different to my initial attempt and result -- joke!! it is *exactly* the same, have a look:
============================================================================ ==== cronus@rsx94220 $ make [...] LD_RUN_PATH="/app/local/oracle/product/9.2.0/lib:/app/local/oracle/product/9 .2.0/rdbms/lib" gcc -G -L/usr/local/lib Oracle.o dbdimp.o oci7.o oci8.o -L/opt/SUNWcluster/lib -R/opt/SUNWcluster/lib -o build -L/app/local/oracle/product/9.2.0/rdbms/lib/ -L/app/local/oracle/produ ct/9.2.0/lib/ -lclntsh -lnbeq9 -lnhost9 -lnus9 -lnldap9 -lldapclnt9 -lnssl b9 -lnnis9 -lnoname9 -lntcp9 -lntcps9 -lnsslb9 -lntcp9 -lntns9 -lnsl -lsocke t -lgen -ldl -R/app/local/oracle/product/9.2.0/lib -laio -lposix4 -lkstat -l m -lthread -o blib/arch/auto/DBD/Oracle/Oracle.so ld: warning: option -o appears more than once, first setting taken ld: fatal: file /app/local/oracle/product/9.2.0/lib//libclntsh.so: wrong ELF class: ELFCLASS64 ld: fatal: File processing errors. No output written to build collect2: ld returned 1 exit status make: *** [blib/arch/auto/DBD/Oracle/Oracle.so] Error 1 ============================================================================ ====
[...]
Should I repeat my "perl -V"?
I am still quite willing to try a lot -- if you give me hints what to try.
Cheers, Jochen
________________________________________________________________________ This e-mail has been scanned for all viruses by Star Internet. The service is powered by MessageLabs. For more information on a proactive anti-virus service working around the clock, around the globe, visit: http://www.star.net.uk ________________________________________________________________________
__________________________ This email and any files transmitted with it are confidential and intended solely for the use of the individual or entity to whom they are addressed. The contents are confidential and may be privileged. Any views or opinions expressed are those of the sender and may not reflect the views or opinions of the company and the company accepts no liability in respect thereof. If you have received this email in error please notify postmaster@abibuildingdata.com immediately.
________________________________________________________________________ This e-mail has been scanned for all viruses by Star Internet. The service is powered by MessageLabs. For more information on a proactive anti-virus service working around the clock, around the globe, visit: http://www.star.net.uk ________________________________________________________________________
Michael A Chase 27 November 2003 16:05:48 [ permanent link ]
On Thu, 27 Nov 2003 12:46:36 -0000 Andy Crichton <andy.crichton@abibuildingdata.com> wrote:
This is caused by trying to link 32bit perl with 64bit oracle> libraries (which live in $ORACLE_HOME/lib). What happens if you> specify $ORACLE_HOME/lib32 in your LD_LIBRARY_PATH (before any other> oracle paths which may be in there).
This _might_ work at runtime, but it won't help the build process.
Q/ Does DBD::Oracle use LD_LIBRARY_PATH or assume $ORACLE_HOME/lib> is the setting for the oracle libs?
As best I can tell, no, at least at build time.
The most recent 'fix' I recall is to hand edit Makefile to replace $OH/lib with $OH/lib32 throughout.
Tim,
Has a patch been submitted yet to have Makefile.PL decide whether to use $OH/lib or $OH/lib32? It appears that one would be useful since Oracle seems to be using 64 bit binaries by default in most platforms while Perl is still normally compiled 32 bit.
-- Mac :}) ** I usually forward private questions to the appropriate mail list. ** Ask Smarter: http://www.catb.org/~esr/faqs/smart-questions.html Give a hobbit a fish and he eats fish for a day. Give a hobbit a ring and he eats fish for an age.
This is caused by trying to link 32bit perl with 64bit oracle libraries>(which live in $ORACLE_HOME/lib). What happens if you specify>$ORACLE_HOME/lib32 in your LD_LIBRARY_PATH (before any other oracle paths>which may be in there).>
Q/ Does DBD::Oracle use LD_LIBRARY_PATH or assume $ORACLE_HOME/lib is the>setting for the oracle libs?>
Andy>
there was also something recent on p5p, with an apparent solution.
On Thu, Nov 27, 2003 at 05:05:48AM -0800, Michael A Chase wrote:> On Thu, 27 Nov 2003 12:46:36 -0000 Andy Crichton> <andy.crichton@abibuildingdata.com> wrote:>
This is caused by trying to link 32bit perl with 64bit oracle> > libraries (which live in $ORACLE_HOME/lib). What happens if you> > specify $ORACLE_HOME/lib32 in your LD_LIBRARY_PATH (before any other> > oracle paths which may be in there).>
This _might_ work at runtime, but it won't help the build process.>
Q/ Does DBD::Oracle use LD_LIBRARY_PATH or assume $ORACLE_HOME/lib> > is the setting for the oracle libs?>
As best I can tell, no, at least at build time.>
The most recent 'fix' I recall is to hand edit Makefile to replace> $OH/lib with $OH/lib32 throughout.>
Tim,>
Has a patch been submitted yet to have Makefile.PL decide whether> to use $OH/lib or $OH/lib32? It appears that one would be useful since> Oracle seems to be using 64 bit binaries by default in most platforms> while Perl is still normally compiled 32 bit.
I think so. It'll certainly be in the next release. (Thanks.)
I've just released DBI 1.39 and then I'm away for the next week. The next DBD::Oracle should be released sometime in December (it's about ready to go, but there are a few more things I want to get into it first.)
Jochen Hayek 2 December 2003 23:23:20 [ permanent link ]
Tim Bunce writes:
t/ph_type....ok 11/19 expected 'trailing' but got 'trailing ' for VARCHAR2 > t/ph_type....FAILED test 12
And guess what'll happen when you google for that ...
I guess I shall be ashamed for wasting your time here, as this is what I could find:
[...] Oracle 9.2 does it, Oracle >9.2 doesn't. Sure seems like an Oracle bug/feature (unless it's an obscure side effect of the way I'm using OCI calls, but that seems unlikely). I think someone has opened a TAR with Oracle on this issue (I hope so). But I've no news yet. [...]
If you would like to report an abuse of our service, such as a spam message, please . Если Вы хотите пожаловаться на содержимое этой страницы, пожалуйста .