mirror of
https://github.com/ArduPilot/ardupilot
synced 2025-01-22 08:38:36 -04:00
AP_Progmem: check for PX4FMU_BUILD explicitly
This commit is contained in:
parent
3a2e138994
commit
28353cd683
@ -6,8 +6,10 @@
|
||||
#include "AP_Progmem_AVR.h"
|
||||
#elif defined(DESKTOP_BUILD)
|
||||
#include "AP_Progmem_DesktopBuild.h"
|
||||
#else
|
||||
#elif defined(PX4FMU_BUILD)
|
||||
#include "AP_Progmem_Identity.h"
|
||||
#else
|
||||
#error "this build type is unknown"
|
||||
#endif
|
||||
|
||||
#define PROGMEM_STRING(_v, _s) static const char _v[] PROGMEM = _s
|
||||
|
@ -6,9 +6,10 @@
|
||||
|
||||
#define SITL_debug(fmt, args ...)
|
||||
|
||||
typedef prog_char_t char;
|
||||
typedef char prog_char_t;
|
||||
typedef char prog_char;
|
||||
|
||||
#define PSTR(s) s;
|
||||
#define PSTR(s) s
|
||||
|
||||
static inline int strcasecmp_P(const char *str1, const prog_char_t *pstr)
|
||||
{
|
||||
@ -40,7 +41,7 @@ static inline char *strncpy_P(char *buffer, const prog_char_t *pstr, size_t buff
|
||||
// read something the size of a pointer. This makes the menu code more
|
||||
// portable
|
||||
static inline uintptr_t pgm_read_pointer(const void *s) {
|
||||
return &((uintptr_t*)s)
|
||||
return *(const uintptr_t *)s;
|
||||
}
|
||||
|
||||
#endif // __AP_PROGMEM_IDENTITY__
|
||||
|
Loading…
Reference in New Issue
Block a user