diff --git a/qemu-arm/Makefile b/qemu-arm/Makefile index 03cc7db9e0..9005380809 100644 --- a/qemu-arm/Makefile +++ b/qemu-arm/Makefile @@ -14,7 +14,7 @@ INC += -I$(PY_SRC) INC += -I$(BUILD) CFLAGS_CORTEX_M3 = -mthumb -mcpu=cortex-m3 -CFLAGS = $(INC) -Wall -Werror -ansi -std=gnu99 $(CFLAGS_CORTEX_M3) $(COPT) \ +CFLAGS = $(INC) -Wall -Wpointer-arith -Werror -ansi -std=gnu99 $(CFLAGS_CORTEX_M3) $(COPT) \ -flto -ffunction-sections -fdata-sections #Debugging/Optimization diff --git a/stmhal/Makefile b/stmhal/Makefile index 878e6ca10b..f444f00458 100644 --- a/stmhal/Makefile +++ b/stmhal/Makefile @@ -42,7 +42,7 @@ INC += -I$(USBDEV_DIR)/core/inc -I$(USBDEV_DIR)/class/cdc_msc_hid/inc INC += -I$(FATFS_DIR)/src 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 -CFLAGS = $(INC) -Wall -Werror -ansi -std=gnu99 -nostdlib $(CFLAGS_MOD) $(CFLAGS_CORTEX_M4) $(COPT) +CFLAGS = $(INC) -Wall -Wpointer-arith -Werror -ansi -std=gnu99 -nostdlib $(CFLAGS_MOD) $(CFLAGS_CORTEX_M4) $(COPT) CFLAGS += -Iboards/$(BOARD) LDFLAGS = -nostdlib -T stm32f405.ld -Map=$(@:.elf=.map) --cref diff --git a/teensy/Makefile b/teensy/Makefile index 5746f6c432..5ea4c9dad2 100644 --- a/teensy/Makefile +++ b/teensy/Makefile @@ -35,7 +35,7 @@ INC += -I../stmhal INC += -I$(BUILD) INC += -Icore -CFLAGS = $(INC) -Wall -ansi -std=gnu99 -nostdlib $(CFLAGS_CORTEX_M4) +CFLAGS = $(INC) -Wall -Wpointer-arith -ansi -std=gnu99 -nostdlib $(CFLAGS_CORTEX_M4) LDFLAGS = -nostdlib -T mk20dx256.ld -msoft-float -mfloat-abi=soft ifeq ($(USE_ARDUINO_TOOLCHAIN),1) diff --git a/unix-cpy/Makefile b/unix-cpy/Makefile index 0376932d6a..eb4088861c 100644 --- a/unix-cpy/Makefile +++ b/unix-cpy/Makefile @@ -11,7 +11,7 @@ INC += -I$(PY_SRC) INC += -I$(BUILD) # compiler settings -CFLAGS = $(INC) -Wall -Werror -ansi -std=gnu99 -DUNIX +CFLAGS = $(INC) -Wall -Wpointer-arith -Werror -ansi -std=gnu99 -DUNIX LDFLAGS = -lm # Debugging/Optimization diff --git a/unix/Makefile b/unix/Makefile index 8ee2319828..d8b51d0b0f 100644 --- a/unix/Makefile +++ b/unix/Makefile @@ -18,7 +18,7 @@ INC += -I$(PY_SRC) INC += -I$(BUILD) # compiler settings -CWARN = -Wall -Werror +CWARN = -Wall -Wpointer-arith -Werror CFLAGS = $(INC) $(CWARN) -ansi -std=gnu99 -DUNIX $(CFLAGS_MOD) $(COPT) $(CFLAGS_EXTRA) # Debugging/Optimization diff --git a/windows/Makefile b/windows/Makefile index 44029c028f..d83a5d46f6 100644 --- a/windows/Makefile +++ b/windows/Makefile @@ -15,7 +15,7 @@ INC += -I$(PY_SRC) INC += -I$(BUILD) # compiler settings -CFLAGS = $(INC) -Wall -Werror -ansi -std=gnu99 -DUNIX $(CFLAGS_MOD) $(COPT) +CFLAGS = $(INC) -Wall -Wpointer-arith -Werror -ansi -std=gnu99 -DUNIX $(CFLAGS_MOD) $(COPT) LDFLAGS = $(LDFLAGS_MOD) -lm ifeq ($(CROSS_COMPILE),i686-w64-mingw32-) CFLAGS += -D__USE_MINGW_ANSI_STDIO=1