[bear with me - details to follow]

I built a module (Authen::ACE4) on a non-64-bit machine (an Ultra5, 
details below).

LD_LIBRARY_PATH does NOT contain the libaceclnt.so (third party .so lib).
LD_RUN_PATH is empty. But the Perl glue module (XS) was built, 
and it somehow "knows" how to find the lib. I don't think I used any 
special options other than the usual 'perl Makefile.PL; make; make test; 
make install;'. It works fine, and loads the .so when 'use Authen::ACE4;' 
is run. The compiler is gcc.

I then built the same module with the same source code and library on
a 64-bit machine, (an E10K).

It was compiled this time with the Sun compiler, SUNWspro. 
Same LD_LIBRARY_PATH and LD_RUN_PATH situations. However, the module's
.so fails to load, saying it can't find the third-party lib.

I _can_ get it to run if I either add the location into LD_LIBRARY_PATH
or in LD_RUN_PATH. But I'm wondering why/how does the compile-time information
get into the gcc-built one and not in the SUNWspro-built one?
At this point, I'm thinking there's some link options I'm not getting
to "stick" with the SUNWSpro-built version.

Any suggestions? I'm not able to "recompile perl" with gcc on the E10K, BTW.
I'm also not wanting to alter the current LD_LIBRARY_PATH or LD_RUN_PATH.
But if that's my only/best option, I probably could live with it.
Then I can work back to patching the Makefile.PL to fix this.

TIA,
Mike808/

>From the WORKING NON-64-bit machine (an Ultra5 running Solaris8):
$ perl -V
Summary of my perl5 (revision 5.0 version 8 subversion 0) configuration:
  Platform:
    osname=solaris, osvers=2.8, archname=sun4-solaris
    uname='sunos solaris 5.8 generic_108528-11 sun4u sparc sunw,ultra-5_10 '
    config_args='-Dcc=gcc -B/usr/ccs/bin/'
    hint=recommended, useposix=true, d_sigaction=define
    usethreads=undef use5005threads=undef useithreads=undef 
usemultiplicity=undef
    useperlio=define d_sfio=undef uselargefiles=define usesocks=undef
    use64bitint=undef use64bitall=undef uselongdouble=undef
    usemymalloc=n, bincompat5005=undef
  Compiler:
    cc='gcc -B/usr/ccs/bin/', ccflags ='-fno-strict-aliasing -
D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64',
    optimize='-O',
    cppflags='-fno-strict-aliasing'
    ccversion='', gccversion='3.1', gccosandvers='solaris2.8'
    intsize=4, longsize=4, ptrsize=4, doublesize=8, byteorder=4321
    d_longlong=define, longlongsize=8, d_longdbl=define, longdblsize=16
    ivtype='long', ivsize=4, nvtype='double', nvsize=8, Off_t='off_t', 
lseeksize=8
    alignbytes=8, prototype=define
  Linker and Libraries:
    ld='gcc -B/usr/ccs/bin/', ldflags =' -L/usr/local/lib '
    libpth=/usr/local/lib /usr/lib /usr/ccs/lib
    libs=-lsocket -lnsl -lgdbm -ldl -lm -lc
    perllibs=-lsocket -lnsl -ldl -lm -lc
    libc=/lib/libc.so, so=so, useshrplib=false, libperl=libperl.a
    gnulibc_version=''
  Dynamic Linking:
    dlsrc=dl_dlopen.xs, dlext=so, d_dlsymun=undef, ccdlflags=' '
    cccdlflags='-fPIC', lddlflags='-G -L/usr/local/lib'


Characteristics of this binary (from libperl):
  Compile-time options: USE_LARGE_FILES
  Built under solaris
  Compiled at Jul 22 2002 02:55:19
  @INC:
    /usr/local/lib/perl5/5.8.0/sun4-solaris
    /usr/local/lib/perl5/5.8.0
    /usr/local/lib/perl5/site_perl/5.8.0/sun4-solaris
    /usr/local/lib/perl5/site_perl/5.8.0
    /usr/local/lib/perl5/site_perl
    .

And from the NON-working 64-bit machine (an E10K running Solaris8):
$ perl -V
Summary of my perl5 (revision 5.0 version 8 subversion 0) configuration:
  Platform:
    osname=solaris, osvers=2.8, archname=sun4-solaris-64int
    uname='sunos solaris 5.8 generic_108528-15 sun4u sparc sunw,ultra-enterpris
e-10000 '
    config_args=''
    hint=recommended, useposix=true, d_sigaction=define
    usethreads=undef use5005threads=undef useithreads=undef usemultiplicity=unde
f
    useperlio=define d_sfio=undef uselargefiles=define usesocks=undef
    use64bitint=define use64bitall=undef uselongdouble=undef
    usemymalloc=n, bincompat5005=undef
  Compiler:
    cc='/opt/SUNWspro/bin/cc', ccflags =' -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BIT
S=64',
    optimize='-O',
    cppflags=''
    ccversion='Sun WorkShop 6 update 2 C 5.3 Patch 111679-08 2002/05/09', gccver
sion='', gccosandvers=''
    intsize=4, longsize=4, ptrsize=4, doublesize=8, byteorder=87654321
    d_longlong=define, longlongsize=8, d_longdbl=define, longdblsize=16
    ivtype='long long', ivsize=8, nvtype='double', nvsize=8, Off_t='off_t', lsee
ksize=8
    alignbytes=8, prototype=define
  Linker and Libraries:
    ld='/opt/SUNWspro/bin/cc', ldflags =' -L/opt/SUNWspro/WS6U2/lib -L/opt/SUNWs
pro/lib -R/opt/SUNWspro/lib '
    libpth=/opt/SUNWspro/WS6U2/lib /usr/lib /usr/ccs/lib /opt/SUNWspro/lib
    libs=-lsocket -lnsl -ldl -lm -lc -lsunmath
    perllibs=-lsocket -lnsl -ldl -lm -lc -lsunmath
    libc=/lib/libc.so, so=so, useshrplib=true, libperl=libperl.so
    gnulibc_version=''
  Dynamic Linking:
    dlsrc=dl_dlopen.xs, dlext=so, d_dlsymun=undef, ccdlflags='  -R /usr/local/li
b/perl5/5.8.0/sun4-solaris-64int/CORE'
    cccdlflags='-KPIC', lddlflags='-G -L/opt/SUNWspro/WS6U2/lib -L/opt/SUNWspro/
lib -R/opt/SUNWspro/lib'


Characteristics of this binary (from libperl):
  Compile-time options: USE_64_BIT_INT USE_LARGE_FILES
  Built under solaris
  Compiled at Sep 20 2002 14:02:22
  @INC:
    /usr/local/lib/perl5/5.8.0/sun4-solaris-64int
    /usr/local/lib/perl5/5.8.0
    /usr/local/lib/perl5/site_perl/5.8.0/sun4-solaris-64int
    /usr/local/lib/perl5/site_perl/5.8.0
    /usr/local/lib/perl5/site_perl
    .

Mike808/

---------------------------------------------
http://www.valuenet.net


Reply via email to