Tim Harsch writes:

[snipped description of environment and variables used...]

 >      We run Sun/Solaris (most versions are 5.7).  I compiled DBD::Sybase using
 > the Sybase Open Client libraries.
 > 
 >      So, my two questions are: 1) Why won't 11.0.1 libs work? and 2) Is the
 > Sybase Open Client lib package even necessary for the compile if connections
 > can be made using the standard 11.9.2 libraries?

There seems to be some confusion here.

OpenClient is the generic term for the Sybase client
libraries. Versions go from 4.0 to 12.5 (currently in beta). The
version of OC included in your 11.9.2 release is 11.1.1. The version
in your 11.0.1 distribution is 10.0.x (probably 10.0.4).

If you built DBD::Sybase with the 11.1.1 libraries (i.e. you built it
on the box that has the 11.9.2 installation) then you will have
problems using that build with the 10.0.x libraries, because there is
a difference in how these libraries interact and how they load
libtli.so at run time (it's libtli.so on Solaris and some other OSes,
it's libinsck.so on linux, HP-UX and some others).

A DBD::Sybase built with the 10.x libraries will work when run with
11.x libraries, but the opposite is (in general) not true.

Now - as to environment variables.

SYBASE is used by OpenClient to find the interfaces file, and to find
the locale files. If SYBASE is not set, then the home directory of the
"sybase" user (if it exists) is used.

LD_LIBRARY_PATH is, in general, not needed if the libraries are
located in the same directory where they were during the build. This
can be verified by running ldd Sybase.so in
.../lib/perl5/site_perl/5.005/sun4-solaris/auto/DBD/Sybase, like so:

troll (9:09AM):85 > ldd Sybase.so
        libct.so => /opt/sybase-11.9.2//lib/libct.so (0x40014000)
        libcs.so => /opt/sybase-11.9.2//lib/libcs.so (0x40071000)
        libsybtcl.so => /opt/sybase-11.9.2//lib/libsybtcl.so (0x4007e000)
        libcomn.so => /opt/sybase-11.9.2//lib/libcomn.so (0x400a0000)
        libintl.so => /opt/sybase-11.9.2//lib/libintl.so (0x400f6000)
        libm.so.6 => /lib/libm.so.6 (0x400fe000)
        libc.so.6 => /lib/libc.so.6 (0x4011b000)
        /lib/ld-linux.so.2 => /lib/ld-linux.so.2 (0x80000000)

(well, this is on linux, but you get the idea)

If ldd can't find the libraries then you need to set LD_LIBRARY_PATH
to point to the right directory (/sybase/lib, in your example) before
running the scripts/programs.

You can check the version of OpenClient by doing:

strings $SYBASE/lib/libct.a | grep Sybase

For example:

strings $SYBASE/$SYBASE_OCS/lib/libct.a | grep Sybase
Sybase Client-Library/12.5/P/Linux Intel/Linux 2.2.14-5.0smp i686/BUILD125-002/OPT/Fri 
Apr 27 17:03:40 2001

(Ignore the $SYBASE_OCS bit for now - with 12.0 Sybase changed the
directory structure somewhat)

All of the above is not linked to DBD::Sybase specifically, btw - it's
generic for any type of Sybase client app that uses OpenClient.

Hoopefully this will clear things up a little - if not, get back to me
:-)

Michael
-- 
Michael Peppler - Data Migrations Inc. - [EMAIL PROTECTED]
http://www.mbay.net/~mpeppler - [EMAIL PROTECTED]
International Sybase User Group - http://www.isug.com
Sybase on Linux mailing list: [EMAIL PROTECTED]

Reply via email to