Skip to content

Commit

Permalink
Merge 693e739 into 8da40ba
Browse files Browse the repository at this point in the history
  • Loading branch information
rcolistete committed Jul 29, 2020
2 parents 8da40ba + 693e739 commit 7c015b8
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 0 deletions.
11 changes: 11 additions & 0 deletions ports/esp32/Makefile
Expand Up @@ -270,6 +270,17 @@ ifeq ($(ESPIDF_CURHASH),$(ESPIDF_SUPHASH_V4))
CFLAGS += -DMICROPY_ESP_IDF_4=1
endif

# Configure floating point support
ifeq ($(MICROPY_FLOAT_IMPL),double)
CFLAGS += -DMICROPY_FLOAT_IMPL=MICROPY_FLOAT_IMPL_DOUBLE
else
ifeq ($(MICROPY_FLOAT_IMPL),none)
CFLAGS += -DMICROPY_FLOAT_IMPL=MICROPY_FLOAT_IMPL_NONE
else
CFLAGS += -DMICROPY_FLOAT_IMPL=MICROPY_FLOAT_IMPL_FLOAT
endif
endif

# this is what ESPIDF uses for c++ compilation
CXXFLAGS = -std=gnu++11 $(CFLAGS_COMMON) $(INC) $(INC_ESPCOMP)

Expand Down
2 changes: 2 additions & 0 deletions ports/esp32/mpconfigport.h
Expand Up @@ -44,7 +44,9 @@
#define MICROPY_ENABLE_SOURCE_LINE (1)
#define MICROPY_ERROR_REPORTING (MICROPY_ERROR_REPORTING_NORMAL)
#define MICROPY_WARNINGS (1)
#ifndef MICROPY_FLOAT_IMPL // can be configured by each board via mpconfigboard.mk or by make option
#define MICROPY_FLOAT_IMPL (MICROPY_FLOAT_IMPL_FLOAT)
#endif
#define MICROPY_CPYTHON_COMPAT (1)
#define MICROPY_STREAMS_NON_BLOCK (1)
#define MICROPY_STREAMS_POSIX_API (1)
Expand Down

0 comments on commit 7c015b8

Please sign in to comment.