Indexing a toolkit

Index a toolkit to make its artifacts available for use in applications or other toolkits.

About this task

The spl-make-toolkit command is used to index and re-index a toolkit. When instructed to index a toolkit directory, the command performs the following steps:
  1. Recursively searches the specified directory for SPL files, C++ code generation templates, function and operator model XML files, and compiled Java classes.
    Note: The command searches all directories except those with a leading .. The command will also not interpret common organizational directories as namespace directories.
  2. Creates C++ code generators from code generation templates, if any.
  3. Creates native.function directories and Java native function XML files in appropriate namespace directories if Java native functions are found.
  4. Creates primitive operator directories and operator model XML files within appropriate namespace directories if Java primitive operators are found.
  5. Creates a toolkit.xml file containing the list of public types, functions, and operators.
Warning: Some additional build steps may need to be performed prior to indexing the toolkit. For example, if the toolkit contains primitive Java operators, the Java classes need to be compiled before; otherwise spl-make-toolkit will not find them.

Procedure

  1. To index a toolkit, run the following command:
    spl-make-toolkit -i <toolkit-directory>
    For example, if the current working directory is a toolkit directory, the following command will index it:
    # cd toolkit-directory
    spl-make-toolkit -i .
  2. To clean up artifacts created by spl-make-toolkit, run the same command with -c:
    spl-make-toolkit -i . -c

What to do next

To start building applications with the toolkit locally, see working with toolkit paths to inform the SPL compiler about the toolkit.

If the toolkit needs to be bundled up and installed on another system, see Packaging a toolkit and Installing a toolkit.