Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: HOSTCC/HOSTCFLAGS: Include PR and git commit #. Update formatting.

...

The NuttX build system uses several binary utilities that it compiles and runs on the host computer. To build these binaries, it needs to know the host C compiler and C flags. Previously, every board's scripts/Make.defs file had to provide this information via HOSTCC via HOSTCC and HOSTCFLAGS Definitions. As part of an effort to simplify the build system, these definitions are now automatically provided by logic in tools/Config.mk. Boards included in the NuttX repository have been updated, but if you are building NuttX for a custom board, you may want to make the following changes:

In your custom board's scripts/Make.defs file, remove lines like these:


Code Block
languagetext
HOSTCC = gcc

...


HOSTCFLAGS = -Wall -Wstrict-prototypes -Wshadow -Wundef -g -pipe




Sometimes they may look like this:


Code Block
languagetext
ifeq ($(CONFIG_WINDOWS_NATIVE),y)

...


  HOSTCC = mingw32-gcc.exe

...


else

...


  HOSTCC = gcc

...


endif

Note: These changes are OPTIONAL.

...

Also, you may override these definitions for a single run by providing them on the make command line. This is useful if, for example, you wish to build debug versions of these host binaries: define HOSTCFLAGS with -g on the command line.

See PR-1398, git commit #ee875b2a260cb4cc532b8ca303c2515e24c39b4e in the main NuttX repository.

Known Problems In This Release

...