On 05/10/2010 17:44, Scott T. Hildreth wrote:
On Sun, 2010-10-03 at 18:45 +0200, Eric Yellin wrote:
Hi,


I am trying to compile DBD::Oracle that will work with Oracle 10g on
FreeBSD 6.3


Eric,
    Are you compiling a linux Perl?  It won't work with out it.  I have
the port emulators/linux_dist-gentoo-stage3 installed.  With a chroot
to the gentoo dir, I am able to compile a linux Perl and DBI,
DBD::Oracle...etc.  I copied the Perl install to /usr/compat/linux.

Thanks Scott,


I am not using a linux compiled Perl so tried following your instructions but got stuck when trying to chroot to /usr/local/gentoo-stage3:

chroot: /bin/csh: No such file or directory


I also tried setting a chrooted environment and logged in that way, but when trying to run the perl configure script (./Configure -de) I received the following:
./Configure: line 69: 4: Bad file descriptor

Thanks, Eric



Here is what I have done so far:

1. Installed the 3 Oracle Instant Client ports:

- linux-oracle-instantclient-basic
- linux-oracle-instantclient-sdk
- linux-oracle-instantclient-sqlplus

These install as follows:
_The "basic files install in:_
/usr/compat/linux/usr/lib/Oracle/10.2.0.3/client/lib

_The sqlplus installes in _:
/usr/compat/linux/usr/lib/Oracle/10.2.0.3/client/bin

_The sdk split between:_
/usr/compat/linux/usr/include/Oracle/10.2.0.3/client/lib (the include
directory)
and:
/usr/compat/linux/usr/share/Oracle/10.2.0.3/client/lib (the demo directory)

2. Downloaded latest DBD::Oracle (1.25)

3.  Set Environment variables as follows:
setenv LD_LIBRARY_PATH /usr/compat/linux/usr/lib/oracle/10.2.0.3/client/lib
setenv ORACLE_HOME /usr/compat/linux/usr/lib/oracle/10.2.0.3/client

4. Ran perl Makefile.PL for DBD:Oracle and recieved the follwoing error:
/"Unable to locate an oracle.mk, proc.mk or other suitable *.mk"/

5. changed the ORACLE_HOME variable to: setenv ORACLE_HOME
/usr/compat/linux/usr/lib/oracle/10.2.0.3/client/lib and ran "perl
Makefile.PL" again and now received the following message:
/"I can't find the header files I need in your Oracle installation.
You probably need to install some more Oracle components.
For Instant Client that means the SDK package...."/

6. Copied the "sdk" files directly from the ports "work" directory
leaving them in the original structure and placing them under the
/usr/compat/linux/usr/lib/oracle/10.2.0.3/client/lib directory and ran
perl Makefile.PL again. Now it built the Makefile succesfully with a few
warnings:

/WARNING: If you have problems you may need to rebuild perl with
threading enabled.
WARNING: If you have problems you may need to rebuild perl with
-Uusemymalloc.
WARNING: META_MERGE is not a known parameter.
'META_MERGE' is not a known MakeMaker parameter name./

7. Ran 'make' and it compiled smoothly.

8. Ran 'make test'  and got the following error:
/Failed to load Oracle extension and/or shared libraries:
install_driver(Oracle) failed: Can't load
'/home/packages/Oracle/DBD-Oracle-1.25/blib/arch/auto/DBD/Oracle/Oracle.so'
for module DBD::Oracle: Shared object "libdl.so.2" not found, required
by "libclntsh.so.10.1" at /usr/local/lib/perl5/5.8.8/mach/DynaLoader.pm
line 230.
   at (eval 9) line 3
Compilation failed in require at (eval 9) line 3.
Perhaps a required shared library or dll isn't installed where expected
   at t/01base.t line 19
The remaining tests will probably also fail with the same error./

The libdl.so.2 file is located in "/usr/compat/linux/lib" and the
compiled DBD::Oracle module does 'know' not see that directory.

How can I move on from here to link the necessary shared libraries
during runtime ? (Tried doing this with symlinks, but kept getting
errors and eventually reached a dead end where symlinking did not help
anymore. I assume there must be a different way to do it)

Thanks,  Eric




\n\n\n\n

------------------------------------------------------\n
This email is protected by Reflexion Total Control\n
http://www.migvan.co.il/Reflexion\n
------------------------------------------------------\n

Reply via email to