The idl.list is used by two utilities:
It's read by the genmkgen.pl tool. The tools generates makefile_idl.gen file from each idl.list. These files are used to generate makefiles that drive compilation and linking of Massiv programs and libraries. The genmkgen.pl uses contents of idl.list to determine which IDL files exist, which files should be generated from the IDL files, how to generate the sources and dependencies of the generated files.
The classlist.pl tool read the file to determine set of all managed classes that exist and to write their list and generate sources that instantiate and register metaobjects of all the classes at program startup.
The programmer has to write an idl.list in each directory that contains a project that either defines or references a managed class.
The format of idl.list files is line-oriented. Empty lines and lines beginning with a hash character (#) are skipped. Other lines may contain the following commands:
depends dirname
Specifies a directory containing another idl.list file that contains IDL files required by projects in this directory. An IDL file is required if a C++ source includes a source generated from the IDL file.
This command will also add the dirname to the list of directories to search when importing or including an IDL file. Moreover, it's used by the class_list command as described later.
directory dirname
This command specifies the directory which the IDL processor should search when an IDL file includes or imports another IDL file. All the directories specified by the depends commands will be searched too.
idl filename
This line specifies one IDL file that should be processed. All existing IDL files must be listed in exactly one idl.list.
class_list
The Core needs to know list of all managed classes that are defined in a node executable to correctly instantiate their metaobjects and factories on node startup. This list must be generated in exactly one library (or program), that is linked to the resulting executable. To build the list, use the class_list command in the idl.list of the library (or program). The idl.list that contains the class_list command must specify all libraries with managed classes that will be linked to the exectuable as its depends.
Makefiles generated for the library (or program) project with the class_list command will generate class_list.cpp and class_list.h sources from the idl.list, using the classlist.pl tool. The sources will define single function, Massiv::Generated::register_classes(), which registers all managed classes to the Massiv Core. Pointer to this function is used at node startup, as described in Section 15.2, “Initializing the Core”.
![]() | Note |
---|---|
Each of the commands except class_list may be used multiple times. |