nasa / fprime

F´ - A flight software and embedded systems framework
https://fprime.jpl.nasa.gov
Apache License 2.0
10.02k stars 1.3k forks source link

Fail to build UTs for PolyType when disabling FW_SERIALIZABLE_TO_STRING #1727

Open kevin-f-ortega opened 1 year ago

kevin-f-ortega commented 1 year ago
F´ Version e47cc1abc8e83f763861291919c9f6b63e8aeaa2
Affected Component

Problem Description

Fail to build UTs for PolyType when disabling FW_SERIALIZABLE_TO_STRING

How to Reproduce

  1. Disable FW_SERIALIZABLE_TO_STRING in config/FpConfig.hpp
  2. Run fprime-util check --all -j 4

Expected Behavior

I expect UTs to build correctly.

LeStarch commented 8 months ago

There are several issues. These need to be fixed in hand-code and FPP code.

  1. #include of string.hpp does not use || BUILD_UT
  2. BUILD_UT should likely be (defined(BUILD_UT) && BUILD_UT) as BUILD_UT is not always set
  3. FW_SERIALIZABLE_TO_STRING_BUFFER_SIZE is used when it is only defined by FW_SERIALIZABLE_TO_STRING=1

All three issues need to be fixed.

Related to #1705, #1766

LeStarch commented 8 months ago

Blocked by: https://github.com/fprime-community/fpp/issues/369