The Application .adef and Component.cdef files are used to define components, applications, and collections of interacting applications ("systems") in a way that's easy to read and hand-code using a plain text viewer/editor. This design works well with collaborative source code management tools (e.g., Gerrit) and standard revision control systems (e.g., Subversion and Git). The design also ensures definition files are easy to parse so syntax highlighters, build tools, and IDEs also work well.
Application .adef and Component.cdef files have the same basic format; they're divided into sections with content specific to each section.
Comments can use C++ style one-line syntax, like this:
// starts with "//" and runs to the end of this line
C-style multi-line comments can also be used, like this:
/* starts with "/*" and runs until it ends with "*/" */
Except for the sources: section in the Component.cdef (at least one source file must exist for any component), all sections in the .adef and Component.cdef are optional (they can be empty).
Sections can be in any order, multiple occurrences are permitted, and some sections have sub-sections. Line-terminating characters (e.g., new-line and carriage-return) are treated like spaces and tabs; the choice of formatting within these files is relatively unrestricted (e.g., hard tabs or spaces can be used for indentation).
Two are used:
The default search path “.” is the current working directory where the build tool ran.
Search paths can be changed through command-line options:
Most settings in the Component.cdef file become configuration settings for that component.
Many settings in the .adef file are also configuration settings, and inherit settings from Component.cdef files.
If the same setting appears in an .adef and a Component.cdef, the .adef setting overrides the .cdef file.
All configuration settings can be overridden on the target device at runtime, but they may not take effect until the app is restarted.
Legato adef Files
Legato cdef Files
Or move to the next level:
Build Tools
Legato Demo Applications
Copyright (C) Sierra Wireless, Inc. 2014. All rights reserved. Use of this work is subject to license.