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

Home » Public Forums » archive » CALL_EXTERNAL/shared libraries on HP
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
CALL_EXTERNAL/shared libraries on HP [message #1198] Thu, 01 July 1993 11:56 Go to previous message
keith is currently offline  keith
Messages: 7
Registered: July 1993
Junior Member
Seeking advice for linking a shared library on the HP...

I've written C code that I'm using with CALL_EXTERNAL in IDL. I'm
trying to port the code to the HP (a 9000/720 with HPUX 8.07) and am
having link errors from trying to create a shared library. I'm pretty
closely following the notes from RSI for external C code on the HP.
Here's what I'm doing:

(1) I create an object file with position independent code (PIC):
cc -v +z -c pic1.c -I../include

This file contains references to other C functions I have
written and also contains global variables.

(2) I link this with other libraries:
ld -v -o pic1.sl -b pic1.o -L../lib -lmylib1 -lmylib2

Normally I create only archive versions of the other libraries (e.g.
libmylib1.a). In this case I get the following link error:

ld: Unsatisfied symbols:
$global$ (data)
_end (data)
ld: DP-Relative Code in file libmylib1.a(func1.o) - Shared
Library must be Position-Independent

As a test, I tried recompiling all the functions in my archive
libraries as PIC and linked them into shared libraries (e.g.
libmylib1.sl). When I do this I still get a link error on step (2):

ld: Unsatisfied symbols:
$global$ (data)

Have any IDL users on the HP tried doing this? What am I doing wrong
here? This same code links fine on IBM AIX and Sunos (with different
system-dependent linker options, of course). Any suggestions would be
welcome (I don't normally develop software on the HP). Thanks.

------------------------------------------------------------ --------------
Keith Searight, Research Programmer keith@vista.atmos.uiuc.edu
Univ. of Illinois, Atmospheric Sciences Ph. (217) 333-8132
105 S. Gregory Ave., Urbana, IL 61801 Fax (217) 244-4393
------------------------------------------------------------ --------------
[Message index]
 
Read Message
Read Message
Read Message
Previous Topic: TEX
Next Topic: bug in tvtwm (X11R5 version)

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

Current Time: Fri Oct 10 08:30:27 PDT 2025

Total time taken to generate the page: 0.16146 seconds