


Using cblutil with helper applications
Regardless of your compiler version, you can use the cblutil utility to package your applications in a single library file. Version 4.0 and later of this utility has been enhanced to allow the inclusion of resources, specifically bitmapped images. Resources are pieces of static data that must be embedded directly into an object file. The program treats the resource as if it were a disk file, but the resource is not actually a separate file in the target environment.
The syntax for "cblutil -lib" is documented in the ACUCOBOL-GT User's Guide. Using Version 4.0 or later of the compiler, you can specify any type of file as an input file. If an input file is a COBOL object, then cblutil includes it in the resulting library as a COBOL object. If an input file is another library, then each component of the library is individually added to the resulting library. Any other file is included as a resource.
Use the cblutil utility program as follows:
cblutil -lib [options] main_program modules
Be sure to add the main or initial program to the library first, because programs are executed in the order they are placed in the library.
For example, using Version 4.0 and later of the compiler, you might use cblutil as follows:
cblutil -lib -v -o mylib.out prog1.obj prog2.obj logo.bmp
Starting with Version 4.3, you can also include extended file descriptor (XFD) files in the library so that you can use the runtime as a helper application to access relational data via Acu4GL. (Acu4GL is Acucorp's RDBMS-to-COBOL bridge.) In this case, you add the name of the XFD files to the cblutil command line. For example:
cblutil -lib -v -o mylib.out prog1.obj prog2.obj logo.bmp data1.xfd data2.xfd data3.xfd