2016-07-04 23:15:42 +08:00
|
|
|
.. _apps_overview:
|
2015-08-13 03:46:55 +08:00
|
|
|
|
2016-07-04 23:15:42 +08:00
|
|
|
Application Overview
|
|
|
|
####################
|
2015-08-13 03:46:55 +08:00
|
|
|
|
2016-07-04 23:15:42 +08:00
|
|
|
A Zephyr application is a collection of user-supplied files that can be built
|
|
|
|
into an application image that executes on a board.
|
|
|
|
|
|
|
|
Each application resides in a distinct directory created by the developer.
|
|
|
|
The directory has the following structure.
|
2015-08-13 03:46:55 +08:00
|
|
|
|
2015-10-22 03:08:58 +08:00
|
|
|
* **Application source code files**: An application typically provides one
|
|
|
|
or more application-specific files, written in C or assembly language. These
|
|
|
|
files are usually located in a sub-directory called :file:`src`.
|
|
|
|
|
2016-10-29 04:06:44 +08:00
|
|
|
* **Kernel configuration files**: An application typically provides
|
|
|
|
a configuration file (:file:`.conf`) that specifies values for one or more
|
|
|
|
kernel configuration options. If omitted, the application's existing kernel
|
|
|
|
configuration option values are used; if no existing values are provided,
|
|
|
|
the kernel's default configuration values are used.
|
2015-10-22 03:08:58 +08:00
|
|
|
|
2016-10-29 04:06:44 +08:00
|
|
|
* **Makefile**: This file typically contains a handful of lines that tell
|
|
|
|
the build system where to find the files mentioned above, as well as
|
|
|
|
the desired target board configuration.
|
2015-08-13 03:46:55 +08:00
|
|
|
|
2015-10-22 03:08:58 +08:00
|
|
|
Once the application has been defined, it can be built with a single command.
|
2016-10-29 04:06:44 +08:00
|
|
|
The results of the build process are located in a sub-directory
|
|
|
|
called :file:`outdir/BOARD`. This directory contains the files generated
|
|
|
|
by the build process, the most notable of which are listed below.
|
|
|
|
|
|
|
|
* The :file:`.config` file that contains the configuration settings
|
|
|
|
used to build the application.
|
|
|
|
|
|
|
|
* The various object files (:file:`.o` files and :file:`.a` files) containing
|
|
|
|
custom-built kernel and application-specific code.
|
|
|
|
|
|
|
|
* The :file:`zephyr.elf` file that contains the final application image.
|