How to make the Core Parser

This document describes how to re-generate all Core Parser related libraries and applications. The standard way to re-generate a project in UNIX is to use a make file.

Makefile

General usage of make files

If your make file is called "makefile" then just call make.

If the name of your make file is other then "makefile" then call make -f my_makefile_name

make file flags

flag   meaning  
none - compile only the outdated files  
all - re-generate the entire project (even if it is up to date)  
clean - erase all the files generated by make all  
release - first call to make all and then erase all intermediate files (like *.o) leaving the final results (library or application)  
rel-clean - internal flag, erase all intermediate files without calling make all  

Dependency tree

Make the entire project

The safest way to re-generate the entire project (all the libraries and small helper applications) is to use the file "makefile" in the root directory of the Core Parser. This will call the makefiles of all the components in the correct order.

If you are fixing a minor problem in one of the components and you are not sure which components should be re-generated, use the global make file, it will only re-generated the necessary components.

Make a single component

While you are updating a component you may want to re-compile only that component. Do not forget at the end, to use the global make file and update all the components.

Please note that if you re-compile component_b that uses component_a, and component_a is not up to date, then the makefile of component_b will not re-generate component_a. to be on the safe side, you must use the makefile for the entire project.

Make the Core Parser library

This is the basic element of the core project and must be compiled first.

Use "make -f make_CoreParse_Library" to re-compile.

You can use CoreParser.dsp for quick checks under windows (mainly to check that the compilation passes)

Make the Core Parser Stand Alone application

The stand alone application depends only on the Core Parser library.

use "make -f make_CoraParser_StandAlone" from the project base directory.

Make the Tree library

Use the makefile in the Tree sub-folder.

Since “Tree” depends on many of the header files from the “Core Parser” and since I expect one to change either the “Core Parser” or the “Tree” utility and to save in the dependency list, I decided to make every object file of “Tree” dependent on the “Core Parser” library rather on the long list of “Core Parser” header files.

Make the Flat library

Use the makefile in the Flat sub-folder.

Since “Flat” depends on many of the header files from the “Core Parser” and from the “Tree” utility and since I expect one to change either the “Core Parser”+“Tree” or the “Flat” utility and to save in the dependency list, I decided to make every object file of “Flat” dependent on the “Core Parser” + “Tree” libraries rather on the long list of “Core Parser” + “Tree” header files.

Originally  “Flat” was compiled using “Tree” version 1.0.

Make the “CDL data structure to XML translation (CdlDs2XML)” library

Use the makefile in the CdlDs_2_XML sub-folder.

Since “CdlDs2XML” depends on many of the header files from the “Core Parser” and since I expect one to change either the “Core Parser” or the “CdlDs2XML” utility and to save in the dependency list, I decided to make every object file of “CdlDs2XML” dependent on the “Core Parser” library rather on the long list of “Core Parser” header files.

Make Core to XML application

The Core to XML application depends on all the components in the project.

use "make -f make_cdl_2_xml" from the project base directory.