.. _d7.01.01-build: Compile and test ================== .. _d7.01.01-build-ref: Compiling the reference version -------------------------------------- All construction operations are necessarily carried out in a container *shell* containing the latest version of the prerequisites. It is recommended to check that the compilation is correct with the version of reference. To do this, simply do: .. code-block:: shell cd $ HOME /dev/codeaster/src Git Checkout Main Git pull Make Bootstrap We go to the*main* branch, we update it with the remote repository. ``make bootstrap`` is a shortcut that does ``. /configure ", ``make`` (same as ``make install``) and ``make doc``. This is equivalent to the ``commands. /waf sets``, ``. /waf install`` and ". /waf doc``. Just do ``export BUILD =debug`` before running ``make bootstrap`` to build a version with *debug* symbols. It is recommended to run ``install_env" (or ``.. /devtools/bin/install_env") from ``src`` to complete the installation of the repositories and install the *hooks* automatically. .. _d7.01.01-build-branch: Exercise files ---------------------- The prefilled files are provided in a branch called ``tp-dev-cmd`` from the Git repository. To retrieve this branch (and rename it with your initials) ``xy`` to simulate a future integration request): The different name used for the local branch makes it possible to distinguish the different developers if we do exercises on GitLab for example. For exercise :ref:`d7.01.02`, use the branch name ``tp-dev-macro`` and ``xy-dev-macro`` for the local branch. .. code-block:: shell cd $ HOME /dev/codeaster/src git fetch origin tp-dev-cmd: xy-dev-cmd git checkout xy-dev-cmd .. _d7.01.01-build-dev: Build and test -------------------- It is not necessary to do the configuration every time (only when we get revisions from the remote repository). All you have to do is do: .. code-block:: shell cd $ HOME /dev/codeaster/src Make And to launch a test case: .. code-block:: shell Make # be Make tpdev01a # or Make tpdev01b The test case should be OK, with no alarm. The code should compile without*warning*. Verify that the output is as expected. Verify the source with :ref:`d7.01.01-regles-aslint`.