IBM Support

Using shared library with COBOL dynamic CALL

Question & Answer


Question

Can you put more than one subroutine into a shared library and call it dynamically?

Cause

The COBOL Programming Guide documents how to use shared objects library (files that are suffixed with .so) in chapter 28. There is an explanation on how to use them with static calls but not with dynamic calls.

Answer

It is not possible to put more than one subroutine into a shared library then call it dynamically.

Support does not exist in this version of COBOL for AIX.

You must compile and link each subroutine into its own executable binary file.

Put all of those binaries into a directory, then set the environment variable COBPATH to point to it.

Related Information

[{"Product":{"code":"SS6SGM","label":"COBOL for AIX"},"Business Unit":{"code":"BU058","label":"IBM Infrastructure w\/TPS"},"Component":"Runtime","Platform":[{"code":"PF002","label":"AIX"}],"Version":"3.1;4.1;4.1.1","Edition":"","Line of Business":{"code":"LOB17","label":"Mainframe TPS"}}]

Document Information

Modified date:
08 August 2018

UID

swg21417401