Prepare COBOL programs
Notes to users
- 32 bit COBOL copy books are installed in the following directory:
/opt/mqm/inc/cobcpy32and symbolic links are created in:/opt/mqm/inc64 bit COBOL copy books are installed in the following directory:
/opt/mqm/inc/cobcpy64- In the following examples set COBCPY to:
/opt/mqm/inc/cobcpy32for 32 bit applications, and:/opt/mqm/inc/cobcpy64for 64 bit applications.
Compile the programs using Micro Focus compiler. The copy files that declare the structures are in /opt/mqm/inc:
- $ export LIB=/opt/mqm/lib:$LIB
- $ export COBCPY="<COBCPY>"
Compiling 32 bit programs:
- $ cob32 -xv amqs0put0.cbl -L /opt/mqm/lib -lmqmcb
Server for COBOL
- $ cob32 -xv amqs0put0.cbl -L /opt/mqm/lib -lmqicb
Client for COBOL
- $ cob32 -xtv amqs0put0.cbl -L /opt/mqm/lib -lmqmcb_r
Threaded Server for COBOL
- $ cob32 -xtv amqs0put0.cbl -L /opt/mqm/lib -lmqicb_r
Threaded Client for COBOL
Compiling 64-bit programs:
- $ cob64 -xv amqs0put0.cbl -L /opt/mqm/lib64 -lmqmcb
Server for COBOL
- $ cob64 -xv amqs0put0.cbl -L /opt/mqm/lib64 -lmqicb
Client for COBOL
- $ cob64 -xtv amqs0put0.cbl -L /opt/mqm/lib64 -lmqmcb_r
Threaded Server for COBOL
- $ cob64 -xtv amqs0put0.cbl -L /opt/mqm/lib64 -lmqicb_r
Threaded Client for COBOL
where amqs0put0.cbl is a sample program
You need to link your program with one of the following:
- libmqmcb.sl
Server for COBOL
- libmqicb.sl
Client for COBOL
- libmqmcb_r.sl
Threaded Server applications
- libmqicb_r.sl
Threaded Client applications
Parent topic:
Building your application on Solaris
fg16600_