Browse Source

AP_HAL: fixed build on g++ 7.3 for stm32

the system maths headers don't like our maths defines, but are happy
if we include math.h first
master
Andrew Tridgell 5 years ago
parent
commit
81711eb28e
  1. 3
      libraries/AP_HAL/AP_HAL_Macros.h

3
libraries/AP_HAL/AP_HAL_Macros.h

@ -13,6 +13,9 @@ @@ -13,6 +13,9 @@
#define ALLOW_DOUBLE_MATH_FUNCTIONS
#endif
// we need to include math.h here for newer compilers (eg. g++ 7.3.1 for stm32)
#include <math.h>
#if !defined(ALLOW_DOUBLE_MATH_FUNCTIONS)
/* give warnings if we use double precision maths functions without
specifying ALLOW_DOUBLE_TRIG_FUNCTIONS. Code should use the

Loading…
Cancel
Save