This commit fixes the generation of autoconf headers.
The `write_autoconf` function in the RIOT wrapper was overriding
the default value of the `header` arg to None in Kconfiglib's `write_autoconf`.
It's now set to the default header.
Previously, external modules had to be individually added to both
EXTERNAL_MODULE_DIRS and USEMODULE. If those where not in sync, this
resulted in build errors.
With this commit, search folders for external modules are added to
EXTERNAL_MODULE_DIRS instead. So lets say the file system structure is
like this
```
└── /path/to/external/modules
├── mod_a
│ ├── Makefile
│ ├── Makefile.dep
│ ├── Makefile.include
│ ├── foo.c
│ └── include
│ └── external_module.h
└── mod_b
├── Makefile
└── bar.c
```
One now adds `/path/to/external/modules` to EXTERNAL_MODULES and only
with `USEMODULE += mod_a` the corresponding module, dependencies and
include settings are actually used. Hence, it is possible to configure
`EXTERNAL_MODULE_DIRS` from `~/.profile` or `~/.bashrc` once and never
needs to worry about them again.
By running make compile-commands a `compile_commands.json` in the RIOT base
directory. With the environment variable `COMPILE_COMMANDS` the path of
this file can be changed to a custom location.
The `compile_commands.json` will contain the exact compile command, but
as additional flag `-I/usr/$(TARGET)/include` is added to work around
`clangd` not being able to locate the newlib system headers. The
additional includes can be overwritten using the environment variable
`COMPILE_COMMANDS_EXTRA_INCLUDES`.
There are some Linux distributions that gdb-multiarch doesn't work as
expected and debug section not start. Since AVARICE is dedicated to
AVR architecture, let's check first by the default tool then multiarch
version.
Signed-off-by: Gerson Fernando Budke <nandojve@gmail.com>
If the help is only printed on failure, if the script does not detect failure
and programming still fails, the user has no idea how to get the full information.
Always print help on how to disable this feature.
`cosy` is a graphical memory usage analyzer.
It is a great tool, but pretty hidden.
Add it as a build target so it can be easiely summoned for any application and board.