.. _apps_common_procedures:

Common Procedures
#################

Instructions that are common to many procedures are provided here
and referred to from the procedures that require them.

Procedures
**********

* `Setting Environment Variables`_

Setting Environment Variables
=============================

Set environment variables every time you open a terminal console to work on
|codename| applications.

Steps
-----

1. In a shell terminal console, enter an :command:`export` command that is
  consistent with your toolchain.

   a) For a Yocto toolchain:

    .. code-block:: bash

     $ export ZEPHYR_GCC_VARIANT=yocto
     $ export YOCTO_SDK_INSTALL_DIR=<yocto-installation-path>

   Go to Step 2.

   b) For an Xtools toolchain:

    .. code-block:: bash

     $ export ZEPHYR_GCC_VARIANT=xtools
     $ export XTOOLS_TOOLCHAIN_PATH=/opt/otc_viper/x-tools/
     $ export QEMU_BIN_PATH=/usr/local/bin

2. Navigate to the |codename| installation directory and enter:

  .. code-block:: bash

   $ source zephyr-env.sh

  To set the environment variable :envvar:`$(ZEPHYR_BASE)`.
Edit the application development common procedures.
doc: Edit the application development common procedures.

Corrected the :envvar: markup. Rewrote the text to be less patronizing.

Change-Id: I09ec541ae41ad682106dc73a6e4495216dfa34d3
Signed-off-by: L.S. Cook <2c8ffdbb27eb9faeeac367751f77804563aa8470@intel.com>
Signed-off-by: Rodrigo Caballero <e74c61adb7ade025bc8e83a25052d36636c989a9@intel.com>
