Custom configurations

As mentined in ‘Sample use case’, build relies on a Lua language feature to check if a function exists by it’s name. Customizing configurations for projects is done by adding functions that have a name composed of a known prefix with appended name of the project that is being customized.

For example, providing additional include path for a project ‘MyProject’ can be done this way:

There are 5 ways to provide additional configuration for projects, here are the prefixes used along with additional details:

  • projectExtraConfig_
    This function is used to provide any additional configuration a project may need, like additional include and library paths, defines, flags, etc.

  • projectExtraConfigExecutable_
    Some projects need to propagate their configuration to executables that are using them as dependencies. The simplest example would be some system library that is required by the project and needs to be linked to executable, but anything else can be setup here as well.

  • projectDependencies_
    This function should return a table that is a list of dependencies for the project.

  • projectDependencyConfig_
    This feature allows projects to override one or more of their dependencies and use other projects instead.

  • projectDescription_
    Returns a table that describes the project, used for executables only. This table is used during deployment stage, see code for details.