diff options
| -rw-r--r-- | ports/zephyr/mpconfigport.h | 7 | ||||
| -rw-r--r-- | ports/zephyr/mpconfigport_minimal.h | 7 | ||||
| -rw-r--r-- | ports/zephyr/prj.conf | 1 | ||||
| -rw-r--r-- | ports/zephyr/prj_minimal.conf | 1 |
4 files changed, 12 insertions, 4 deletions
diff --git a/ports/zephyr/mpconfigport.h b/ports/zephyr/mpconfigport.h index 6f55b0d78..c853530c7 100644 --- a/ports/zephyr/mpconfigport.h +++ b/ports/zephyr/mpconfigport.h @@ -61,7 +61,6 @@ #define MICROPY_PY_BUILTINS_HELP_TEXT zephyr_help_text #define MICROPY_PY_ARRAY_SLICE_ASSIGN (1) #define MICROPY_PY_MICROPYTHON_MEM_INFO (1) -#define MICROPY_PY_MATH_POW_FIX_NAN (1) #define MICROPY_PY_MACHINE (1) #define MICROPY_PY_MACHINE_INCLUDEFILE "ports/zephyr/modmachine.c" #define MICROPY_PY_MACHINE_I2C (1) @@ -173,3 +172,9 @@ typedef long mp_off_t; k_msleep(1); \ } while (0); #endif + +// Compatibility switches + +#ifdef CONFIG_NEWLIB_LIBC +#define MICROPY_PY_MATH_POW_FIX_NAN (1) +#endif diff --git a/ports/zephyr/mpconfigport_minimal.h b/ports/zephyr/mpconfigport_minimal.h index 274411920..6486480af 100644 --- a/ports/zephyr/mpconfigport_minimal.h +++ b/ports/zephyr/mpconfigport_minimal.h @@ -50,7 +50,6 @@ #define MICROPY_LONGINT_IMPL (MICROPY_LONGINT_IMPL_LONGLONG) #define MICROPY_FLOAT_IMPL (MICROPY_FLOAT_IMPL_FLOAT) #define MICROPY_PY_BUILTINS_COMPLEX (0) -#define MICROPY_PY_MATH_POW_FIX_NAN (1) // These features are enabled to get the test suite passing. #define MICROPY_FULL_CHECKS (1) @@ -80,3 +79,9 @@ typedef long mp_off_t; #define MP_STATE_PORT MP_STATE_VM #define MICROPY_EVENT_POLL_HOOK + +// Compatibility switches + +#ifdef CONFIG_NEWLIB_LIBC +#define MICROPY_PY_MATH_POW_FIX_NAN (1) +#endif diff --git a/ports/zephyr/prj.conf b/ports/zephyr/prj.conf index 0939e226c..c13caa8fd 100644 --- a/ports/zephyr/prj.conf +++ b/ports/zephyr/prj.conf @@ -6,7 +6,6 @@ CONFIG_STDOUT_CONSOLE=y CONFIG_CONSOLE_HANDLER=y CONFIG_UART_CONSOLE_DEBUG_SERVER_HOOKS=y -CONFIG_NEWLIB_LIBC=y CONFIG_FPU=y CONFIG_MAIN_STACK_SIZE=4736 CONFIG_POLL=y diff --git a/ports/zephyr/prj_minimal.conf b/ports/zephyr/prj_minimal.conf index f58c932ce..6fb5eadd5 100644 --- a/ports/zephyr/prj_minimal.conf +++ b/ports/zephyr/prj_minimal.conf @@ -1,4 +1,3 @@ -CONFIG_NEWLIB_LIBC=y CONFIG_FPU=y CONFIG_MAIN_STACK_SIZE=4096 CONFIG_POLL=y |
