Project structure

Here is the Project window with its context menu (accessible by clicking on the right mouse button).

Figure 4-1Project window

The Project window displays the project's automake hierarchy organized into groups of targets. Groups correspond to directories in your project and targets correspond to normal automake targets (not to be confused with make targets). The Project window actually has two parts: the lower part shows the complete project hierarchy and the upper part lists important targets directly. Important targets include executable and library targets; the view makes these easily accessible. This is particularly useful in large projects where the hierarchy can be deep and hard to navigate from the tree alone. Targets are, in turn, composed of source files.

  • Groups are used to logically organize targets. A project can contain any number of groups. Each group can have subgroups as well as targets. In automake projects, groups are just subdirectories in the project. The top-level group is always labeled "/".
  • Targets are the build targets in the project, such as programs (executable binaries), scripts, libraries and miscellaneous data. Not all target types are built from sources; some exist just to organize sources and therefore may not exist physically (e.g. a Miscellaneous Data target). Targets exist under groups. See "Adding targets" for a full list of available target types.
  • Source files may be used to build targets, though some source files simply belong to targets. They exist only under targets. Many target types expect certain type of source files (e.g. the Programs and Libraries target types), but some can accept any file (e.g. a Miscellaneous Data target).

Each project group and target is configurable in the standard automake way. You can set compiler and linker flags directly for each target, or set configure variables. Groups allow you to set an installation destination for their targets.

Just like the file manager, the project manager view also has convenience actions (accessible from the context menu) for source files and targets.

Many command-line tools are available to maintain and manage a project, and each tool has its own specific rules and capabilities. Anjuta tries to automate most common operations using plugins. However, you might occasionally still need to perform certain operations manually.

You may modify a project's structure using external tools or by hand-editing the project files. It doesn't matter whether the project is loaded in Anjuta or not. Anjuta will update itself with any external changes made to a project.