09-21-2006 02:25 PM
I HPUX-pa software developer with NCR. Currently we are having an issue with unresolved symbol in our 64bit library during run time. The unresolved symbol is __ShlTerm. The truss ouput shows that
/usr/lib/pa20_64/libCsup.2 is opened and mapped, and nm shows that __shlTerm is defined there.
Then these facts are true, what could be other factors causing __shlTerm not resolved?
09-25-2006 12:01 PM - edited 10-29-2011 01:55 AM
__shlTerm (not __ShlTerm) is exported from libCsup.2 so you should not be getting this unsat, provided you include libCsup.2 on your link line. Were there any other errors?
09-25-2006 01:27 PM
09-25-2006 01:43 PM - edited 10-29-2011 01:56 AM
>the linking was ok, because library did get built.
Since you don't usually get unsat errors when building shlibs, this is meaningless.
Can you explain when you are getting the error? At load or runtime? The latter means shl_load or dlopen.
And what do the errors look like? And what linker patch do you have?
09-25-2006 03:10 PM - edited 10-29-2011 01:57 AM
>when dlopen library A which uses the __shlTerm, dlopen failed
Now you need to answer the question implied by: This is only correct if you have a aC++ executable.
And what are your dlopen parms?
If this is a C executable, you need to follow the directions on:
09-26-2006 05:56 AM
Did you mean if there is aC++ executables on the system that builds the library or the runtime system?
The build system does have aCC executables and we use aCC to do the linking.
For the runtime system, I dont know if there is a aCC or aC++.
09-26-2006 11:29 AM - edited 10-29-2011 01:58 AM
>Did you mean if there is aC++ executables
No. I meant what type of application is doing the dlopen. Is it C or aC++?
(Also, what linker patch do you have installed?)
09-26-2006 12:02 PM
customer application calls our C library and the C library dlopen the C++ library. The C++ library uses __shlTerm.
Our C library is built with -lCsup by cc. C++ library is built by aCC without -lCsup.
Now sure what customer application is written in.
The dlopen param is
dlopen(C++ library name, RTLD_GLOBAL | RTLD_LAZY);
Not sure about the patch level of aCC, how do I find out?
09-26-2006 07:28 PM - edited 10-29-2011 01:59 AM
>customer application calls our C library and the C library dlopen the C++ library. Our C library is built with -lCsup by cc. C++ library is built by aCC without -lCsup.
While this is not what we recommend, it should work.
>Now sure what customer application is written in.
It probably doesn't matter if your lib has libCsup. Do you also have libstream and libstd on your lib?
>Not sure about the patch level of aCC, how do I find out?
I was asking about linker versions.
To find the patch, you need to use swlist:
/usr/sbin/swlist -l product | fgrep -i -e aC++ -e linker
A what(1) on the shlibs would also give you a version.