Necessary so that build_git_version.h is generated before version.c is
compiled.
Error before:
../src/lib/version/version.c:152:31: error: 'PX4_GIT_TAG_STR' undeclared (first use in this function)
return version_tag_to_number(PX4_GIT_TAG_STR);
Since the git hashes were being generate by cmake it would only be
generated if the header file was not present. Simple test:
$ make aerofc-v1_default
$ touch a
$ git add a
$ git commit -m tmp
$ make aerofc-v1_default
The file build_aerofc-v1_default/build_git_version.h should have the new
hashes and the correspondent .c/c.pp files should be rebuilt, but they
aren't. The end result is that checking the version with "ver git" in
the nsh console will point to the wrong commit.
This moves the generation of the header to a separate tool and enforces
the command to be executed every time.
in particular:
- SW release version (in addition to the git hash)
- OS version (tag + git hash if exists)
- mcu version & revision & UUID
- toolchain version
The uuid can be disabled via parameter, it's enabled by default.
_global_pos_sub->update(&_global_pos_time, &global_pos); could return
false and in that case global_pos was not set but still accessed.
This is prevented by checking if timestamp == 0.
boards define BOARD_NAME, so board_name() is not necessary. HW_ARCH was
just a wrapper around board_name().
This patch simplifies to having only one common method px4_board_name().
1) Ensure if CONFIG_SERIAL_DMA is set that cdcacm uart_ops is initalized
with correct functions in correct slots.
This was detected only with PX4 build flags
2) C&P error from F7 would prevent CONFIG_STM32_SERIALBRK_BSDCOMPAT ifdefed
code from being included.