Re: CALL_EXTERNAL failure. [message #16348] |
Tue, 20 July 1999 00:00  |
Octavi Fors
Messages: 13 Registered: March 1999
|
Junior Member |
|
|
<!doctype html public "-//w3c//dtd html 4.0 transitional//en">
<html>
"Eric J. Korpela" wrote:
<blockquote TYPE=CITE>In article <3794B8F8.8EEB716@fajnm1.am.ub.es>,
<br>Octavi Fors <octavi@fajnm1.am.ub.es> wrote:
<br>>ld.so.1: /usr/local/rsi/idl_5/bin/bin.solaris2.sparc/idlde:
<br>>fatal: relocation error: symbol not found: __s_wsle_nv: referenced
in
<br>>/home/octavi/idl/example.so
<p>The problem with using fortran from within IDL is that the fortran
<br>libraries aren't already in memory. You'll need to do something
to ensure
<br>the fortran libraries are loaded either by statically linking them
with
<br>your .so</blockquote>
How could I do this? From your words, I understand that my previous
<br>link command
<p><font size=-1>$ /usr/ucb/ld -o example.so -z text -G example.o example1.o</font>
<p>doesn't load fortran libraries. Is there any other <font size=-1>/usr/ucb/ld</font>
option to really load
<br>them?
<p>You may have seen I'm using gcc and /usr/ucb/ld (both from GNU) with
f77
<br>(from SUN). Maybe there's some incovenient? What do you think?
<br>I know it would be better to use g77 (GNU) to uniformize compilers
and linkers,
<br>but I still don't have it installed (I've to talk with superuser).
<p>Another option would be to use cc, f77 and ld (all of them from SUN),
with the
<br>following procedure:
<p><font size=-1>$ cc -G -Kpic -fsingle -c example.c</font>
<br><font size=-1>$ f77 -c -pic example1.for</font>
<br><font size=-1>$ ld -G -o example.so example.o example1.o /opt/SUNWspro/SC4.2/lib/libF77.a</font>
<br><font size=-1>
/opt/SUNWspro/SC4.2/lib/libm.a</font>
<p>apparently it gives no problem, but when you go to IDL, and try to make:
<p><font size=-1>IDL> value = CALL_EXTERNAL('/home/octavi/example.so','example',
$</font>
<br><font size=-1>
n1, x1, y1, var1, rlimit1,n2, x2, y2, var2, rlimit2)</font><font size=-1></font>
<p>you obtain:
<p><font size=-1>% CALL_EXTERNAL: Error loading sharable executable.</font>
<br><font size=-1>
Symbol: cdmtriang, File =</font>
<br><font size=-1>
/home/octavi/example.so</font>
<br><font size=-1>
ld.so.1: /usr/local/rsi/idl_5/bin/bin.solaris2.sparc/idlde:</font>
<br><font size=-1>
fatal: relocation error: symbol not found: __fp_class:</font>
<br><font size=-1>
referenced in /home/octavi/example.so</font>
<br><font size=-1>
% Execution halted at: $MAIN$</font><font size=-1></font>
<p>:-( Do you know what does it mean? (Sorry for ignorance :-)
<br>
<p>Thanks in advance,
<p>Octavi.
<p><font size=-1> ============================================================ ===== </font><font size=-1></font>
<p><font size=-1>Octavi Fors Aldrich</font><font size=-1></font>
<p><font size=-1>Astronomy Department</font>
<br><font size=-1>Physics Faculty</font>
<br><font size=-1>Avgda. Diagonal 647</font>
<br><font size=-1>08028 Barcelona</font>
<br><font size=-1>SPAIN</font><font size=-1></font>
<p><font size=-1>Telf: 34-934021122</font>
<br><font size=-1>Fax: 34-934021133</font>
<br><font size=-1>e-mail: octavi@fajnm1.am.ub.es</font><font size=-1></font>
<p><font size=-1> ============================================================ ===== </font>
<br><font size=-1></font>
<br> </html>
|
|
|