The Makefile is very basic: it is standard GNU makefile format.
More...
The Makefile is very basic: it is standard GNU makefile format.
It has to declare three variables:
- THIS_REPO: the name of the repository that the given directory is in. Examples are "wavepacket-lib" or "folio".
- BUILD_DIR: relative path to the build directory.
- MODULE: the module specification (type and name). Examples are "[LIB]/graph" for a library named "graph", or "[APP]/folium" for an application named "folium".
There is an additional optional variable the Makefile can declare:
- DEPEND_REPOS: other repositories upon which this module depends. This is a comma-separated list of repository names (no spaces!).
Finally, the Makefile includes the main build file default.inc (in the build directory), and that does the heavy lifting.
To build a module (library or application) just cd to the relevant directory, and type:
There are 4 supported build targets:
- all : (this is the default). This makes this module and all dependencies. If the current module is an application, it will also be linked.
- clean : a "make clean" will delete all object files for this module.
- nuke : a "make nuke" will recursively delete all object files for this module and all of its dependencies.