Skip to content

Commit

Permalink
Sanitizers moved to main build
Browse files Browse the repository at this point in the history
  • Loading branch information
mikee47 committed Jul 4, 2024
1 parent 2eae760 commit c2b1773
Show file tree
Hide file tree
Showing 2 changed files with 30 additions and 27 deletions.
27 changes: 0 additions & 27 deletions Sming/Arch/Host/README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -230,33 +230,6 @@ Configuration
On MacOS builds are 64-bit only. Default for other systems is 32-bit.


.. envvar:: ENABLE_SANITIZERS

default: 0 (off)

Enable this option to build with lots of runtime checking.

This provides some of the capabilities of valgrind but by instrumenting
the code when it is compiled, rather than patching at runtime.

It also links in some additional runtime support libraries.

Run a full rebuild after changing this setting (or :envvar:`SANITIZERS`)::

make clean components-clean
make

.. note::

If using :envvar:`CLANG_BUILD` then all runtime libraries should already be available.
For GCC you will also need to install ``libasan`` and ``libubsan``.


.. envvar:: SANITIZERS

Selects which sanitizers are used. See :envvar:`ENABLE_SANITIZERS`.


Components
----------

Expand Down
30 changes: 30 additions & 0 deletions Sming/README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,36 @@ Change it like this::
When enabled, warnings are not treated as errors.


.. envvar:: ENABLE_SANITIZERS

default: 0 (off)

Enable this option to build with lots of runtime checking.

This provides some of the capabilities of valgrind but by instrumenting
the code when it is compiled, rather than patching at runtime.

It also links in some additional runtime support libraries.

Run a full rebuild after changing this setting (or :envvar:`SANITIZERS`)::

make clean components-clean
make

.. note::

Applications cannot link when this setting is enabled as sanitizer runtime libraries
are not currently available for embedded toolchains.

With Host builds using :envvar:`CLANG_BUILD`, all runtime libraries should already be available.
For GCC you will also need to install ``libasan`` and ``libubsan``.


.. envvar:: SANITIZERS

Selects which sanitizers are used. See :envvar:`ENABLE_SANITIZERS`.


Release builds
~~~~~~~~~~~~~~

Expand Down

0 comments on commit c2b1773

Please sign in to comment.