Microsoft KB Archive/65106

COBOL 3.00 Can Link with DOSCALLS.LIB Included with OS/2

PSS ID Number: Q65106 Article last modified on 11-19-1990

3.00 3.00a OS/2

Summary: When creating COBOL versions 3.00 and 3.00a protected mode programs that make calls to OS/2 API functions, the DOSCALLS.LIB library needs to be linked in. This library allows the linker to resolve external references to the API functions. However, the DOSCALLS.LIB that comes with COBOL 3.00 and 3.00a will not allow the linker to resolve references to all of the API functions. This version of DOSCALLS.LIB was designed to support only a subset of them. The linker can use the DOSCALLS.LIB that comes with OS/2 to resolve those external references to API functions that are not supported by the COBOL version of DOSCALLS.LIB. This information applies to Microsoft COBOL Compiler versions 3.00 and 3.00a for MS OS/2.

More Information: Microsoft has verified that the COBOL 3.00/3.00a version of the DOSCALLS.LIB library will not allow the linker to resolve external references to OS/2 API functions having to do with named pipes. For more information, query in this Knowledge Base on the following words: COBOL and named and pipes If an API function is not supported by the COBOL version of DOSCALLS.LIB, the linker will generate an “Unresolved external” error if it finds a call to the unsupported function in an object file. To remedy this situation, the program must be linked with the OS/2 version of DOSCALLS.LIB. This version of DOSCALLS.LIB is usually placed in the main OS/2 directory (C:, for example) by the OS/2 installation program. In Microsoft COBOL Professional Development System (PDS) 4.00, OS2.LIB is used to resolve external references to OS/2 API functions. This OS2.LIB file is a lot larger and supports more API functions (such as named pipes) than DOSCALLS.LIB. A separate article found with the above query explains how to use named pipes with COBOL 4.00.

Copyright Microsoft Corporation 1990.