comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Call_External and referenced symbol not found
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
Re: Call_External and referenced symbol not found [message #30658 is a reply to message #30583] Mon, 13 May 2002 02:03 Go to previous messageGo to previous message
Nigel Wade is currently offline  Nigel Wade
Messages: 286
Registered: March 1998
Senior Member
Todd David halter wrote:

> I made a mistake in my initial post. The function that is giving me
> trouble is in libsocket.a. From my so file (zlog.so) I am calling the
> function usy_init () which is located is libsocket.a, which is located in
> /usr/lib. The way I am compiling it is:
>
> cc -g -G -K pic -xarch=v9 -I/apps/base/rsi/idl_5.4/external -c zlog.c -o
> obj/zlog.o
> cc -B static -G -K pic -xarch=v9 -L/usr/lib -lsocket -o zlog.so
> obj/zlog.o

^^^^^^^^

>
> The v9 tell it to create 64bit code not 32bit. I am still getting the
> same error. I will keep playing with it, but if anyone can see what I am
> doing wrong please let me know. Thanks.
>
> Todd

I think the problem is the order of the arguments to cc (and therefore to
ld).

The arguments to ld (which is used by cc to do the linking) are order
dependent. Libraries are scanned in the position in which they occur on the
command line, and they are scanned only once. At the time libsocket is
scanned, the externals in zlog.o are not undefined, so ld does not include
them in the resultant DSO. Try changing the order of the arguments to cc,
placing libraries *after* the objects.

--
-----------------------------------------------------------
Nigel Wade, System Administrator, Space Plasma Physics Group,
University of Leicester, Leicester, LE1 7RH, UK
E-mail : nmw@ion.le.ac.uk
Phone : +44 (0)116 2523568, Fax : +44 (0)116 2523555
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Previous Topic: CURVEFIT.PRO standard deviations?
Next Topic: Re: Returning C struct to IDL

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Wed Oct 08 19:56:09 PDT 2025

Total time taken to generate the page: 0.00420 seconds