nrf: Add more math sources to Makefile, and enable log2 implementation.
This commit adds a few math functions to the source list in the Makefile, and implements the log2f function, so that ulab can be compiled on the nrf boards. It also addresses part of #5162.
This commit is contained in:
parent
de2e081260
commit
8c02b94946
@ -160,8 +160,16 @@ SRC_LIB += $(addprefix lib/,\
|
||||
libm/sf_modf.c \
|
||||
libm/sf_ldexp.c \
|
||||
libm/asinfacosf.c \
|
||||
libm/acoshf.c \
|
||||
libm/asinhf.c \
|
||||
libm/atanf.c \
|
||||
libm/atan2f.c \
|
||||
libm/atanhf.c \
|
||||
libm/log1pf.c \
|
||||
libm/sf_erf.c \
|
||||
libm/erf_lgamma.c \
|
||||
libm/wf_lgamma.c \
|
||||
libm/wf_tgamma.c \
|
||||
libm/roundf.c \
|
||||
)
|
||||
|
||||
@ -186,8 +194,17 @@ SRC_LIB += $(addprefix lib/,\
|
||||
libm/sf_modf.c \
|
||||
libm/sf_ldexp.c \
|
||||
libm/asinfacosf.c \
|
||||
libm/acoshf.c \
|
||||
libm/asinhf.c \
|
||||
libm/atanf.c \
|
||||
libm/atan2f.c \
|
||||
libm/atanhf.c \
|
||||
libm/log1pf.c \
|
||||
libm/sf_erf.c \
|
||||
libm/erf_lgamma.c \
|
||||
libm/wf_lgamma.c \
|
||||
libm/wf_tgamma.c \
|
||||
libm/roundf.c \
|
||||
)
|
||||
|
||||
SRC_NRFX += $(addprefix lib/nrfx/drivers/src/,\
|
||||
@ -481,7 +498,7 @@ $(BUILD)/$(OUTPUT_FILENAME).elf: $(OBJ)
|
||||
$(Q)$(SIZE) $@
|
||||
|
||||
# List of sources for qstr extraction
|
||||
SRC_QSTR += $(SRC_C) $(SRC_LIB) $(DRIVERS_SRC_C) $(SRC_BOARD_MODULES) $(SRC_MOD)
|
||||
SRC_QSTR += $(SRC_C) $(SRC_LIB) $(DRIVERS_SRC_C) $(SRC_BOARD_MODULES) $(SRC_MOD)
|
||||
|
||||
# Append any auto-generated sources that are needed by sources listed in
|
||||
# SRC_QSTR
|
||||
|
@ -330,3 +330,7 @@ extern const struct _mp_obj_module_t ble_module;
|
||||
#include <alloca.h>
|
||||
|
||||
#define MICROPY_PIN_DEFS_PORT_H "pin_defs_nrf5.h"
|
||||
|
||||
#ifndef MP_NEED_LOG2
|
||||
#define MP_NEED_LOG2 (1)
|
||||
#endif
|
||||
|
Loading…
Reference in New Issue
Block a user