summaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
authorDamien <damien.p.george@gmail.com>2013-11-01 23:25:37 +0000
committerDamien <damien.p.george@gmail.com>2013-11-01 23:25:37 +0000
commit4c51cbdc0b41cfe4a9193e8afd89f0584afb4446 (patch)
tree190c53d6d767662784da8f6d4e45b5514c5f3584
parente8217c2a9b82f50d4718fd9f02f54c21cb9b512c (diff)
downloadmicropython-4c51cbdc0b41cfe4a9193e8afd89f0584afb4446.tar.gz
micropython-4c51cbdc0b41cfe4a9193e8afd89f0584afb4446.zip
Add proper FPU compile flags; disable Python float support.
-rw-r--r--stm/Makefile2
-rw-r--r--stm/mpyconfig.h2
2 files changed, 2 insertions, 2 deletions
diff --git a/stm/Makefile b/stm/Makefile
index b6bf665510..9e5ba14fad 100644
--- a/stm/Makefile
+++ b/stm/Makefile
@@ -6,7 +6,7 @@ BUILD=build
AS = arm-none-eabi-as
CC = arm-none-eabi-gcc
LD = arm-none-eabi-ld
-CFLAGS_CORTEX_M4 = -mthumb -mtune=cortex-m4 -mabi=aapcs-linux -mcpu=cortex-m4 -mfloat-abi=hard -DSTM32F40XX -DHSE_VALUE=8000000
+CFLAGS_CORTEX_M4 = -mthumb -mtune=cortex-m4 -mabi=aapcs-linux -mcpu=cortex-m4 -mfpu=fpv4-sp-d16 -mfloat-abi=hard -fsingle-precision-constant -Wdouble-promotion -DSTM32F40XX -DHSE_VALUE=8000000
CFLAGS = -I. -I$(PYSRC) -I$(FATFSSRC) -I$(STMSRC) -Wall -ansi -std=gnu99 -Os -DNDEBUG $(CFLAGS_CORTEX_M4)
LDFLAGS = --nostdlib -T stm32f405.ld
diff --git a/stm/mpyconfig.h b/stm/mpyconfig.h
index 06a4bd8e02..388ad1cc4d 100644
--- a/stm/mpyconfig.h
+++ b/stm/mpyconfig.h
@@ -1,6 +1,6 @@
// options to control how Micro Python is built
-#define MICROPY_ENABLE_FLOAT (1)
+#define MICROPY_ENABLE_FLOAT (0)
#define MICROPY_EMIT_CPYTHON (0)
#define MICROPY_EMIT_X64 (0)
#define MICROPY_EMIT_THUMB (1)