- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- shl_load / shl_findsym problem with Cobol Shared L...
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Discussions
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-31-2005 03:35 AM
03-31-2005 03:35 AM
We have a large quantity of Cobol .sl libraries compiled with Microfocus, which we load dinamically with shl_load.
Everything worked together in a HP-UX 10.20 system and we are doing the recompilation to HP-UX 11.11 in 32 bits.
The code looks like this:
(MID_ID_T *,void *, void *,short *,long *) funLlama;
handle=shl_load(NomDll,BIND_IMMEDIATE | BIND_NONFATAL, 0L);
if (handle!=NULL) {
sRet = shl_findsym(&handle, tSimbol, TYPE_PROCEDURE, (void *) &funLlama);
if (sRet == 0) {
sRet = (*funLlama)(&uId,(void *)pMsjBin, (void *)pMsjRetBin, &sNumMens,&sTipMens);
}
}
It works until we want to execute the external "funLlama" procedure.
I have done my homework looking for a solution in this great forum, and I almost everything I found, but without success...
Can anyone help me? Any ideas?
Thanks in advance.
Jordi
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-31-2005 05:29 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-31-2005 05:50 PM
03-31-2005 05:50 PM
Re: shl_load / shl_findsym problem with Cobol Shared Libraries
I get a "Segmentation Fault" (SIGSEVR signal).
Jordi
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-31-2005 09:47 PM
03-31-2005 09:47 PM
Re: shl_load / shl_findsym problem with Cobol Shared Libraries
2. Try it without the BIND_NONFATAL and see what happens.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-31-2005 11:39 PM
03-31-2005 11:39 PM
Re: shl_load / shl_findsym problem with Cobol Shared Libraries
1) It contains "START9000" which is defined as then PROGRAM-ID at the Cobol program. It worked before at HP-UX 10.20....
2) Without BIND_NONFATAL I get the error "ENOSYM" after the execution of shl_load, both using BIND_IMMEDIATE or BIND_DEFERRED. In the HP-UX 10.20 only BIND_DEFERRED was used but I tried with "BIND_IMMEDIATE | BIND_NONFATAL" because this was the only way I didn't get an error after trying to load the library.
Thanx.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-02-2005 12:50 AM
04-02-2005 12:50 AM
Re: shl_load / shl_findsym problem with Cobol Shared Libraries
2) Without BIND_NONFATAL I get the error "ENOSYM" after the execution of shl_load, both using BIND_IMMEDIATE or BIND_DEFERRED. In the HP-UX 10.20 only BIND_DEFERRED was used but I tried with "BIND_IMMEDIATE | BIND_NONFATAL" because this was the only way I didn't get an error after trying to load the library.
---------
are you sure? BIND_DEFERRED should leave the symbol binding for later, so you seem to be saying it reverse.
you should try to resolve the ENOSYM first. it is possible that your library depends on something external (say something in libc or cobol runtime libraries) that changed between 10.20 and 11.11.
an easy way to get an error message from dld about which symbol caused ENOSYM - just link the program directly with the library (or LD_PRELOAD it) and run it, you may see an error at startup.
please also make sure you have the latest linker/loader patches installed.
--
ranga
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-06-2005 02:35 AM
04-06-2005 02:35 AM
Re: shl_load / shl_findsym problem with Cobol Shared Libraries
We have tried "shl_load" with new simple C and Cobol built shared library and It works only in C (both are "Hello World" like simple programs...).
As a result, we are working on the "update patch" solution...
Thank you again.
Jordi
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-13-2005 07:20 PM
04-13-2005 07:20 PM
Re: shl_load / shl_findsym problem with Cobol Shared Libraries
Thanks for your time!
Jordi
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-13-2005 07:21 PM
04-13-2005 07:21 PM