aboutsummaryrefslogtreecommitdiffstats
path: root/demos
diff options
context:
space:
mode:
authorGiovanni Di Sirio <gdisirio@gmail.com>2018-10-21 17:30:00 +0000
committerGiovanni Di Sirio <gdisirio@gmail.com>2018-10-21 17:30:00 +0000
commit7fa69f45182056cc0bdbaa0d3666a36af8f88f07 (patch)
treee8f7e8fd90a3a5624489da6105de104d867f278a /demos
parent7dd779520635144a79181c0383f1c4be3e06b38e (diff)
downloadChibiOS-7fa69f45182056cc0bdbaa0d3666a36af8f88f07.tar.gz
ChibiOS-7fa69f45182056cc0bdbaa0d3666a36af8f88f07.tar.bz2
ChibiOS-7fa69f45182056cc0bdbaa0d3666a36af8f88f07.zip
More demos updated.
git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@12383 110e8d01-0319-4d1e-a829-52ad28d1bb01
Diffstat (limited to 'demos')
-rw-r--r--demos/STM32/RT-STM32F401C-DISCOVERY/Makefile115
-rw-r--r--demos/STM32/RT-STM32F401C-DISCOVERY/cfg/chconf.h (renamed from demos/STM32/RT-STM32F401C-DISCOVERY/chconf.h)0
-rw-r--r--demos/STM32/RT-STM32F401C-DISCOVERY/cfg/halconf.h (renamed from demos/STM32/RT-STM32F401C-DISCOVERY/halconf.h)0
-rw-r--r--demos/STM32/RT-STM32F401C-DISCOVERY/cfg/mcuconf.h (renamed from demos/STM32/RT-STM32F401C-DISCOVERY/mcuconf.h)0
-rw-r--r--demos/STM32/RT-STM32F401RE-NUCLEO64/Makefile2
-rw-r--r--demos/STM32/RT-STM32F407-DISCOVERY-G++/Makefile112
-rw-r--r--demos/STM32/RT-STM32F407-DISCOVERY-G++/cfg/chconf.h (renamed from demos/STM32/RT-STM32F407-DISCOVERY-G++/chconf.h)0
-rw-r--r--demos/STM32/RT-STM32F407-DISCOVERY-G++/cfg/halconf.h (renamed from demos/STM32/RT-STM32F407-DISCOVERY-G++/halconf.h)0
-rw-r--r--demos/STM32/RT-STM32F407-DISCOVERY-G++/cfg/mcuconf.h (renamed from demos/STM32/RT-STM32F407-DISCOVERY-G++/mcuconf.h)0
-rw-r--r--demos/STM32/RT-STM32F407-DISCOVERY/Makefile113
-rw-r--r--demos/STM32/RT-STM32F407-DISCOVERY/cfg/chconf.h (renamed from demos/STM32/RT-STM32F407-DISCOVERY/chconf.h)0
-rw-r--r--demos/STM32/RT-STM32F407-DISCOVERY/cfg/halconf.h (renamed from demos/STM32/RT-STM32F407-DISCOVERY/halconf.h)0
-rw-r--r--demos/STM32/RT-STM32F407-DISCOVERY/cfg/mcuconf.h (renamed from demos/STM32/RT-STM32F407-DISCOVERY/mcuconf.h)0
-rw-r--r--demos/STM32/RT-STM32F410RB-NUCLEO64/Makefile113
-rw-r--r--demos/STM32/RT-STM32F410RB-NUCLEO64/cfg/chconf.h (renamed from demos/STM32/RT-STM32F410RB-NUCLEO64/chconf.h)0
-rw-r--r--demos/STM32/RT-STM32F410RB-NUCLEO64/cfg/halconf.h (renamed from demos/STM32/RT-STM32F410RB-NUCLEO64/halconf.h)0
-rw-r--r--demos/STM32/RT-STM32F410RB-NUCLEO64/cfg/mcuconf.h (renamed from demos/STM32/RT-STM32F410RB-NUCLEO64/mcuconf.h)0
-rw-r--r--demos/STM32/RT-STM32F411RE-NUCLEO64/Makefile113
-rw-r--r--demos/STM32/RT-STM32F411RE-NUCLEO64/cfg/chconf.h (renamed from demos/STM32/RT-STM32F411RE-NUCLEO64/chconf.h)0
-rw-r--r--demos/STM32/RT-STM32F411RE-NUCLEO64/cfg/halconf.h (renamed from demos/STM32/RT-STM32F411RE-NUCLEO64/halconf.h)0
-rw-r--r--demos/STM32/RT-STM32F411RE-NUCLEO64/cfg/mcuconf.h (renamed from demos/STM32/RT-STM32F411RE-NUCLEO64/mcuconf.h)0
-rw-r--r--demos/STM32/RT-STM32F412ZG-NUCLEO144/Makefile114
-rw-r--r--demos/STM32/RT-STM32F412ZG-NUCLEO144/cfg/chconf.h (renamed from demos/STM32/RT-STM32F412ZG-NUCLEO144/chconf.h)0
-rw-r--r--demos/STM32/RT-STM32F412ZG-NUCLEO144/cfg/halconf.h (renamed from demos/STM32/RT-STM32F412ZG-NUCLEO144/halconf.h)0
-rw-r--r--demos/STM32/RT-STM32F412ZG-NUCLEO144/cfg/mcuconf.h (renamed from demos/STM32/RT-STM32F412ZG-NUCLEO144/mcuconf.h)0
-rw-r--r--demos/STM32/RT-STM32F413ZH-NUCLEO144/Makefile115
-rw-r--r--demos/STM32/RT-STM32F413ZH-NUCLEO144/cfg/chconf.h (renamed from demos/STM32/RT-STM32F413ZH-NUCLEO144/chconf.h)0
-rw-r--r--demos/STM32/RT-STM32F413ZH-NUCLEO144/cfg/halconf.h (renamed from demos/STM32/RT-STM32F413ZH-NUCLEO144/halconf.h)0
-rw-r--r--demos/STM32/RT-STM32F413ZH-NUCLEO144/cfg/mcuconf.h (renamed from demos/STM32/RT-STM32F413ZH-NUCLEO144/mcuconf.h)0
-rw-r--r--demos/STM32/RT-STM32F429-DISCOVERY/Makefile115
-rw-r--r--demos/STM32/RT-STM32F429-DISCOVERY/cfg/chconf.h (renamed from demos/STM32/RT-STM32F429-DISCOVERY/chconf.h)0
-rw-r--r--demos/STM32/RT-STM32F429-DISCOVERY/cfg/halconf.h (renamed from demos/STM32/RT-STM32F429-DISCOVERY/halconf.h)0
-rw-r--r--demos/STM32/RT-STM32F429-DISCOVERY/cfg/mcuconf.h (renamed from demos/STM32/RT-STM32F429-DISCOVERY/mcuconf.h)0
-rw-r--r--demos/STM32/RT-STM32F429-DISCOVERY/source/usbcfg.c (renamed from demos/STM32/RT-STM32F429-DISCOVERY/usbcfg.c)0
-rw-r--r--demos/STM32/RT-STM32F429-DISCOVERY/source/usbcfg.h (renamed from demos/STM32/RT-STM32F429-DISCOVERY/usbcfg.h)0
-rw-r--r--demos/STM32/RT-STM32F429ZI-NUCLEO144/Makefile114
-rw-r--r--demos/STM32/RT-STM32F429ZI-NUCLEO144/cfg/chconf.h (renamed from demos/STM32/RT-STM32F429ZI-NUCLEO144/chconf.h)0
-rw-r--r--demos/STM32/RT-STM32F429ZI-NUCLEO144/cfg/halconf.h (renamed from demos/STM32/RT-STM32F429ZI-NUCLEO144/halconf.h)0
-rw-r--r--demos/STM32/RT-STM32F429ZI-NUCLEO144/cfg/mcuconf.h (renamed from demos/STM32/RT-STM32F429ZI-NUCLEO144/mcuconf.h)0
-rw-r--r--demos/STM32/RT-STM32F446RE-NUCLEO64/Makefile114
-rw-r--r--demos/STM32/RT-STM32F446RE-NUCLEO64/cfg/chconf.h (renamed from demos/STM32/RT-STM32F446RE-NUCLEO64/chconf.h)0
-rw-r--r--demos/STM32/RT-STM32F446RE-NUCLEO64/cfg/halconf.h (renamed from demos/STM32/RT-STM32F446RE-NUCLEO64/halconf.h)0
-rw-r--r--demos/STM32/RT-STM32F446RE-NUCLEO64/cfg/mcuconf.h (renamed from demos/STM32/RT-STM32F446RE-NUCLEO64/mcuconf.h)0
-rw-r--r--demos/STM32/RT-STM32F446ZE-NUCLEO144/Makefile114
-rw-r--r--demos/STM32/RT-STM32F446ZE-NUCLEO144/cfg/chconf.h (renamed from demos/STM32/RT-STM32F446ZE-NUCLEO144/chconf.h)0
-rw-r--r--demos/STM32/RT-STM32F446ZE-NUCLEO144/cfg/halconf.h (renamed from demos/STM32/RT-STM32F446ZE-NUCLEO144/halconf.h)0
-rw-r--r--demos/STM32/RT-STM32F446ZE-NUCLEO144/cfg/mcuconf.h (renamed from demos/STM32/RT-STM32F446ZE-NUCLEO144/mcuconf.h)0
-rw-r--r--demos/STM32/RT-STM32F469I-DISCOVERY/Makefile113
-rw-r--r--demos/STM32/RT-STM32F469I-DISCOVERY/cfg/chconf.h (renamed from demos/STM32/RT-STM32F469I-DISCOVERY/chconf.h)0
-rw-r--r--demos/STM32/RT-STM32F469I-DISCOVERY/cfg/halconf.h (renamed from demos/STM32/RT-STM32F469I-DISCOVERY/halconf.h)0
-rw-r--r--demos/STM32/RT-STM32F469I-DISCOVERY/cfg/mcuconf.h (renamed from demos/STM32/RT-STM32F469I-DISCOVERY/mcuconf.h)0
-rw-r--r--demos/STM32/RT-STM32F722ZE-NUCLEO144/Makefile110
-rw-r--r--demos/STM32/RT-STM32F722ZE-NUCLEO144/cfg/chconf.h (renamed from demos/STM32/RT-STM32F722ZE-NUCLEO144/chconf.h)0
-rw-r--r--demos/STM32/RT-STM32F722ZE-NUCLEO144/cfg/halconf.h (renamed from demos/STM32/RT-STM32F722ZE-NUCLEO144/halconf.h)0
-rw-r--r--demos/STM32/RT-STM32F722ZE-NUCLEO144/cfg/mcuconf.h (renamed from demos/STM32/RT-STM32F722ZE-NUCLEO144/mcuconf.h)0
-rw-r--r--demos/STM32/RT-STM32F746G-DISCOVERY/Makefile93
-rw-r--r--demos/STM32/RT-STM32F746ZG-NUCLEO144/Makefile110
-rw-r--r--demos/STM32/RT-STM32F746ZG-NUCLEO144/cfg/chconf.h (renamed from demos/STM32/RT-STM32F746ZG-NUCLEO144/chconf.h)0
-rw-r--r--demos/STM32/RT-STM32F746ZG-NUCLEO144/cfg/halconf.h (renamed from demos/STM32/RT-STM32F746ZG-NUCLEO144/halconf.h)0
-rw-r--r--demos/STM32/RT-STM32F746ZG-NUCLEO144/cfg/mcuconf.h (renamed from demos/STM32/RT-STM32F746ZG-NUCLEO144/mcuconf.h)0
-rw-r--r--demos/STM32/RT-STM32F756ZG-NUCLEO144/Makefile110
-rw-r--r--demos/STM32/RT-STM32F756ZG-NUCLEO144/cfg/chconf.h (renamed from demos/STM32/RT-STM32F756ZG-NUCLEO144/chconf.h)0
-rw-r--r--demos/STM32/RT-STM32F756ZG-NUCLEO144/cfg/halconf.h (renamed from demos/STM32/RT-STM32F756ZG-NUCLEO144/halconf.h)0
-rw-r--r--demos/STM32/RT-STM32F756ZG-NUCLEO144/cfg/mcuconf.h (renamed from demos/STM32/RT-STM32F756ZG-NUCLEO144/mcuconf.h)0
-rw-r--r--demos/STM32/RT-STM32F767ZI-NUCLEO144/Makefile108
-rw-r--r--demos/STM32/RT-STM32F767ZI-NUCLEO144/cfg/chconf.h (renamed from demos/STM32/RT-STM32F767ZI-NUCLEO144/chconf.h)0
-rw-r--r--demos/STM32/RT-STM32F767ZI-NUCLEO144/cfg/halconf.h (renamed from demos/STM32/RT-STM32F767ZI-NUCLEO144/halconf.h)0
-rw-r--r--demos/STM32/RT-STM32F767ZI-NUCLEO144/cfg/mcuconf.h (renamed from demos/STM32/RT-STM32F767ZI-NUCLEO144/mcuconf.h)0
-rw-r--r--demos/STM32/RT-STM32F769I-DISCOVERY/Makefile108
-rw-r--r--demos/STM32/RT-STM32F769I-DISCOVERY/cfg/chconf.h (renamed from demos/STM32/RT-STM32F769I-DISCOVERY/chconf.h)0
-rw-r--r--demos/STM32/RT-STM32F769I-DISCOVERY/cfg/halconf.h (renamed from demos/STM32/RT-STM32F769I-DISCOVERY/halconf.h)0
-rw-r--r--demos/STM32/RT-STM32F769I-DISCOVERY/cfg/mcuconf.h (renamed from demos/STM32/RT-STM32F769I-DISCOVERY/mcuconf.h)0
-rw-r--r--demos/STM32/RT-STM32H743I-NUCLEO144/Makefile99
-rw-r--r--demos/STM32/RT-STM32H743I-NUCLEO144/cfg/chconf.h (renamed from demos/STM32/RT-STM32H743I-NUCLEO144/chconf.h)0
-rw-r--r--demos/STM32/RT-STM32H743I-NUCLEO144/cfg/halconf.h (renamed from demos/STM32/RT-STM32H743I-NUCLEO144/halconf.h)0
-rw-r--r--demos/STM32/RT-STM32H743I-NUCLEO144/cfg/mcuconf.h (renamed from demos/STM32/RT-STM32H743I-NUCLEO144/mcuconf.h)0
76 files changed, 792 insertions, 1313 deletions
diff --git a/demos/STM32/RT-STM32F401C-DISCOVERY/Makefile b/demos/STM32/RT-STM32F401C-DISCOVERY/Makefile
index 06e20a8f8..6165d0b74 100644
--- a/demos/STM32/RT-STM32F401C-DISCOVERY/Makefile
+++ b/demos/STM32/RT-STM32F401C-DISCOVERY/Makefile
@@ -18,7 +18,7 @@ ifeq ($(USE_CPPOPT),)
USE_CPPOPT = -fno-rtti
endif
-# Enable this if you want the linker to remove unused code and data
+# Enable this if you want the linker to remove unused code and data.
ifeq ($(USE_LINK_GC),)
USE_LINK_GC = yes
endif
@@ -28,16 +28,11 @@ ifeq ($(USE_LDOPT),)
USE_LDOPT =
endif
-# Enable this if you want link time optimizations (LTO)
+# Enable this if you want link time optimizations (LTO).
ifeq ($(USE_LTO),)
USE_LTO = yes
endif
-# If enabled, this option allows to compile the application in THUMB mode.
-ifeq ($(USE_THUMB),)
- USE_THUMB = yes
-endif
-
# Enable this if you want to see the full log while compiling.
ifeq ($(USE_VERBOSE_COMPILE),)
USE_VERBOSE_COMPILE = no
@@ -71,7 +66,12 @@ endif
# Enables the use of FPU (no, softfp, hard).
ifeq ($(USE_FPU),)
- USE_FPU = hard
+ USE_FPU = no
+endif
+
+# FPU-related options.
+ifeq ($(USE_FPU_OPT),)
+ USE_FPU_OPT = -mfloat-abi=$(USE_FPU) -mfpu=fpv4-sp-d16
endif
#
@@ -79,14 +79,20 @@ endif
##############################################################################
##############################################################################
-# Project, sources and paths
+# Project, target, sources and paths
#
# Define project name here
PROJECT = ch
-# Imported source files and paths
-CHIBIOS = ../../..
+# Target settings.
+MCU = cortex-m4
+
+# Imported source files and paths.
+CHIBIOS := ../../..
+CONFDIR := ./cfg
+BUILDDIR := ./build
+DEPDIR := ./.dep
# Licensing files.
include $(CHIBIOS)/os/license/license.mk
@@ -100,6 +106,8 @@ include $(CHIBIOS)/os/hal/osal/rt/osal.mk
# RTOS files (optional).
include $(CHIBIOS)/os/rt/rt.mk
include $(CHIBIOS)/os/common/ports/ARMCMx/compilers/GCC/mk/port_v7m.mk
+# Auto-build files in ./source recursively.
+include $(CHIBIOS)/tools/mk/autobuild.mk
# Other files (optional).
include $(CHIBIOS)/test/lib/test.mk
include $(CHIBIOS)/test/rt/rt_test.mk
@@ -118,73 +126,23 @@ CSRC = $(ALLCSRC) \
# setting.
CPPSRC = $(ALLCPPSRC)
-# C sources to be compiled in ARM mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-ACSRC =
-
-# C++ sources to be compiled in ARM mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-ACPPSRC =
-
-# C sources to be compiled in THUMB mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-TCSRC =
-
-# C sources to be compiled in THUMB mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-TCPPSRC =
-
-# List ASM source files here
+# List ASM source files here.
ASMSRC = $(ALLASMSRC)
-ASMXSRC = $(ALLXASMSRC)
-
-INCDIR = $(ALLINC) $(TESTINC)
-#
-# Project, sources and paths
-##############################################################################
-
-##############################################################################
-# Compiler settings
-#
+# List ASM with preprocessor source files here.
+ASMXSRC = $(ALLXASMSRC)
-MCU = cortex-m4
+# Inclusion directories.
+INCDIR = $(CONFDIR) $(ALLINC) $(TESTINC)
-#TRGT = arm-elf-
-TRGT = arm-none-eabi-
-CC = $(TRGT)gcc
-CPPC = $(TRGT)g++
-# Enable loading with g++ only if you need C++ runtime support.
-# NOTE: You can use C++ even without C++ support if you are careful. C++
-# runtime support makes code size explode.
-LD = $(TRGT)gcc
-#LD = $(TRGT)g++
-CP = $(TRGT)objcopy
-AS = $(TRGT)gcc -x assembler-with-cpp
-AR = $(TRGT)ar
-OD = $(TRGT)objdump
-SZ = $(TRGT)size
-HEX = $(CP) -O ihex
-BIN = $(CP) -O binary
-
-# ARM-specific options here
-AOPT =
-
-# THUMB-specific options here
-TOPT = -mthumb -DTHUMB
-
-# Define C warning options here
+# Define C warning options here.
CWARN = -Wall -Wextra -Wundef -Wstrict-prototypes
-# Define C++ warning options here
+# Define C++ warning options here.
CPPWARN = -Wall -Wextra -Wundef
#
-# Compiler settings
+# Project, target, sources and paths
##############################################################################
##############################################################################
@@ -207,8 +165,25 @@ ULIBDIR =
ULIBS =
#
-# End of user defines
+# End of user section
+##############################################################################
+
##############################################################################
+# Common rules
+#
RULESPATH = $(CHIBIOS)/os/common/startup/ARMCMx/compilers/GCC/mk
+include $(RULESPATH)/arm-none-eabi.mk
include $(RULESPATH)/rules.mk
+
+#
+# Common rules
+##############################################################################
+
+##############################################################################
+# Custom rules
+#
+
+#
+# Custom rules
+##############################################################################
diff --git a/demos/STM32/RT-STM32F401C-DISCOVERY/chconf.h b/demos/STM32/RT-STM32F401C-DISCOVERY/cfg/chconf.h
index a7343edc2..a7343edc2 100644
--- a/demos/STM32/RT-STM32F401C-DISCOVERY/chconf.h
+++ b/demos/STM32/RT-STM32F401C-DISCOVERY/cfg/chconf.h
diff --git a/demos/STM32/RT-STM32F401C-DISCOVERY/halconf.h b/demos/STM32/RT-STM32F401C-DISCOVERY/cfg/halconf.h
index 89be0946a..89be0946a 100644
--- a/demos/STM32/RT-STM32F401C-DISCOVERY/halconf.h
+++ b/demos/STM32/RT-STM32F401C-DISCOVERY/cfg/halconf.h
diff --git a/demos/STM32/RT-STM32F401C-DISCOVERY/mcuconf.h b/demos/STM32/RT-STM32F401C-DISCOVERY/cfg/mcuconf.h
index 649a12fb8..649a12fb8 100644
--- a/demos/STM32/RT-STM32F401C-DISCOVERY/mcuconf.h
+++ b/demos/STM32/RT-STM32F401C-DISCOVERY/cfg/mcuconf.h
diff --git a/demos/STM32/RT-STM32F401RE-NUCLEO64/Makefile b/demos/STM32/RT-STM32F401RE-NUCLEO64/Makefile
index 3251b9d72..34439f1e8 100644
--- a/demos/STM32/RT-STM32F401RE-NUCLEO64/Makefile
+++ b/demos/STM32/RT-STM32F401RE-NUCLEO64/Makefile
@@ -89,7 +89,7 @@ PROJECT = ch
MCU = cortex-m4
# Imported source files and paths.
-CHIBIOS = ../../..
+CHIBIOS := ../../..
CONFDIR := ./cfg
BUILDDIR := ./build
DEPDIR := ./.dep
diff --git a/demos/STM32/RT-STM32F407-DISCOVERY-G++/Makefile b/demos/STM32/RT-STM32F407-DISCOVERY-G++/Makefile
index 87612adc8..55ba4ca55 100644
--- a/demos/STM32/RT-STM32F407-DISCOVERY-G++/Makefile
+++ b/demos/STM32/RT-STM32F407-DISCOVERY-G++/Makefile
@@ -18,7 +18,7 @@ ifeq ($(USE_CPPOPT),)
USE_CPPOPT = -std=gnu++11 -fno-exceptions -fno-rtti
endif
-# Enable this if you want the linker to remove unused code and data
+# Enable this if you want the linker to remove unused code and data.
ifeq ($(USE_LINK_GC),)
USE_LINK_GC = yes
endif
@@ -28,14 +28,9 @@ ifeq ($(USE_LDOPT),)
USE_LDOPT =
endif
-# Enable this if you want link time optimizations (LTO)
+# Enable this if you want link time optimizations (LTO).
ifeq ($(USE_LTO),)
- USE_LTO = no
-endif
-
-# If enabled, this option allows to compile the application in THUMB mode.
-ifeq ($(USE_THUMB),)
- USE_THUMB = yes
+ USE_LTO = yes
endif
# Enable this if you want to see the full log while compiling.
@@ -74,19 +69,30 @@ ifeq ($(USE_FPU),)
USE_FPU = no
endif
+# FPU-related options.
+ifeq ($(USE_FPU_OPT),)
+ USE_FPU_OPT = -mfloat-abi=$(USE_FPU) -mfpu=fpv4-sp-d16
+endif
+
#
# Architecture or project specific options
##############################################################################
##############################################################################
-# Project, sources and paths
+# Project, target, sources and paths
#
# Define project name here
PROJECT = ch
-# Imported source files and paths
-CHIBIOS = ../../..
+# Target settings.
+MCU = cortex-m4
+
+# Imported source files and paths.
+CHIBIOS := ../../..
+CONFDIR := ./cfg
+BUILDDIR := ./build
+DEPDIR := ./.dep
# Licensing files.
include $(CHIBIOS)/os/license/license.mk
@@ -100,6 +106,8 @@ include $(CHIBIOS)/os/hal/osal/rt/osal.mk
# RTOS files (optional).
include $(CHIBIOS)/os/rt/rt.mk
include $(CHIBIOS)/os/common/ports/ARMCMx/compilers/GCC/mk/port_v7m.mk
+# Auto-build files in ./source recursively.
+include $(CHIBIOS)/tools/mk/autobuild.mk
# Other files (optional).
include $(CHIBIOS)/test/lib/test.mk
include $(CHIBIOS)/test/rt/rt_test.mk
@@ -119,70 +127,23 @@ CSRC = $(ALLCSRC) \
CPPSRC = $(ALLCPPSRC) \
main.cpp
-# C sources to be compiled in ARM mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-ACSRC =
-
-# C++ sources to be compiled in ARM mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-ACPPSRC =
-
-# C sources to be compiled in THUMB mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-TCSRC =
-
-# C sources to be compiled in THUMB mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-TCPPSRC =
-
-# List ASM source files here
+# List ASM source files here.
ASMSRC = $(ALLASMSRC)
-ASMXSRC = $(ALLXASMSRC)
-
-INCDIR = $(ALLINC) $(TESTINC)
-#
-# Project, sources and paths
-##############################################################################
-
-##############################################################################
-# Compiler settings
-#
+# List ASM with preprocessor source files here.
+ASMXSRC = $(ALLXASMSRC)
-MCU = cortex-m4
+# Inclusion directories.
+INCDIR = $(CONFDIR) $(ALLINC) $(TESTINC)
-#TRGT = arm-elf-
-TRGT = arm-none-eabi-
-CC = $(TRGT)gcc
-CPPC = $(TRGT)g++
-#LD = $(TRGT)gcc
-LD = $(TRGT)g++
-CP = $(TRGT)objcopy
-AS = $(TRGT)gcc -x assembler-with-cpp
-AR = $(TRGT)ar
-OD = $(TRGT)objdump
-SZ = $(TRGT)size
-HEX = $(CP) -O ihex
-BIN = $(CP) -O binary
-
-# ARM-specific options here
-AOPT =
-
-# THUMB-specific options here
-TOPT = -mthumb -DTHUMB
-
-# Define C warning options here
+# Define C warning options here.
CWARN = -Wall -Wextra -Wundef -Wstrict-prototypes
-# Define C++ warning options here
+# Define C++ warning options here.
CPPWARN = -Wall -Wextra -Wundef
#
-# Compiler settings
+# Project, target, sources and paths
##############################################################################
##############################################################################
@@ -205,8 +166,25 @@ ULIBDIR =
ULIBS =
#
-# End of user defines
+# End of user section
+##############################################################################
+
##############################################################################
+# Common rules
+#
RULESPATH = $(CHIBIOS)/os/common/startup/ARMCMx/compilers/GCC/mk
+include $(RULESPATH)/arm-none-eabi.mk
include $(RULESPATH)/rules.mk
+
+#
+# Common rules
+##############################################################################
+
+##############################################################################
+# Custom rules
+#
+
+#
+# Custom rules
+##############################################################################
diff --git a/demos/STM32/RT-STM32F407-DISCOVERY-G++/chconf.h b/demos/STM32/RT-STM32F407-DISCOVERY-G++/cfg/chconf.h
index 8834a80c0..8834a80c0 100644
--- a/demos/STM32/RT-STM32F407-DISCOVERY-G++/chconf.h
+++ b/demos/STM32/RT-STM32F407-DISCOVERY-G++/cfg/chconf.h
diff --git a/demos/STM32/RT-STM32F407-DISCOVERY-G++/halconf.h b/demos/STM32/RT-STM32F407-DISCOVERY-G++/cfg/halconf.h
index b10dccbb4..b10dccbb4 100644
--- a/demos/STM32/RT-STM32F407-DISCOVERY-G++/halconf.h
+++ b/demos/STM32/RT-STM32F407-DISCOVERY-G++/cfg/halconf.h
diff --git a/demos/STM32/RT-STM32F407-DISCOVERY-G++/mcuconf.h b/demos/STM32/RT-STM32F407-DISCOVERY-G++/cfg/mcuconf.h
index 882e515c7..882e515c7 100644
--- a/demos/STM32/RT-STM32F407-DISCOVERY-G++/mcuconf.h
+++ b/demos/STM32/RT-STM32F407-DISCOVERY-G++/cfg/mcuconf.h
diff --git a/demos/STM32/RT-STM32F407-DISCOVERY/Makefile b/demos/STM32/RT-STM32F407-DISCOVERY/Makefile
index 05a217d2b..b1555e3d3 100644
--- a/demos/STM32/RT-STM32F407-DISCOVERY/Makefile
+++ b/demos/STM32/RT-STM32F407-DISCOVERY/Makefile
@@ -18,7 +18,7 @@ ifeq ($(USE_CPPOPT),)
USE_CPPOPT = -fno-rtti
endif
-# Enable this if you want the linker to remove unused code and data
+# Enable this if you want the linker to remove unused code and data.
ifeq ($(USE_LINK_GC),)
USE_LINK_GC = yes
endif
@@ -28,16 +28,11 @@ ifeq ($(USE_LDOPT),)
USE_LDOPT =
endif
-# Enable this if you want link time optimizations (LTO)
+# Enable this if you want link time optimizations (LTO).
ifeq ($(USE_LTO),)
USE_LTO = yes
endif
-# If enabled, this option allows to compile the application in THUMB mode.
-ifeq ($(USE_THUMB),)
- USE_THUMB = yes
-endif
-
# Enable this if you want to see the full log while compiling.
ifeq ($(USE_VERBOSE_COMPILE),)
USE_VERBOSE_COMPILE = no
@@ -74,19 +69,30 @@ ifeq ($(USE_FPU),)
USE_FPU = no
endif
+# FPU-related options.
+ifeq ($(USE_FPU_OPT),)
+ USE_FPU_OPT = -mfloat-abi=$(USE_FPU) -mfpu=fpv4-sp-d16
+endif
+
#
# Architecture or project specific options
##############################################################################
##############################################################################
-# Project, sources and paths
+# Project, target, sources and paths
#
# Define project name here
PROJECT = ch
-# Imported source files and paths
-CHIBIOS = ../../..
+# Target settings.
+MCU = cortex-m4
+
+# Imported source files and paths.
+CHIBIOS := ../../..
+CONFDIR := ./cfg
+BUILDDIR := ./build
+DEPDIR := ./.dep
# Licensing files.
include $(CHIBIOS)/os/license/license.mk
@@ -100,6 +106,8 @@ include $(CHIBIOS)/os/hal/osal/rt/osal.mk
# RTOS files (optional).
include $(CHIBIOS)/os/rt/rt.mk
include $(CHIBIOS)/os/common/ports/ARMCMx/compilers/GCC/mk/port_v7m.mk
+# Auto-build files in ./source recursively.
+include $(CHIBIOS)/tools/mk/autobuild.mk
# Other files (optional).
include $(CHIBIOS)/test/lib/test.mk
include $(CHIBIOS)/test/rt/rt_test.mk
@@ -118,73 +126,23 @@ CSRC = $(ALLCSRC) \
# setting.
CPPSRC = $(ALLCPPSRC)
-# C sources to be compiled in ARM mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-ACSRC =
-
-# C++ sources to be compiled in ARM mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-ACPPSRC =
-
-# C sources to be compiled in THUMB mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-TCSRC =
-
-# C sources to be compiled in THUMB mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-TCPPSRC =
-
-# List ASM source files here
+# List ASM source files here.
ASMSRC = $(ALLASMSRC)
-ASMXSRC = $(ALLXASMSRC)
-
-INCDIR = $(ALLINC) $(TESTINC)
-#
-# Project, sources and paths
-##############################################################################
-
-##############################################################################
-# Compiler settings
-#
+# List ASM with preprocessor source files here.
+ASMXSRC = $(ALLXASMSRC)
-MCU = cortex-m4
+# Inclusion directories.
+INCDIR = $(CONFDIR) $(ALLINC) $(TESTINC)
-#TRGT = arm-elf-
-TRGT = arm-none-eabi-
-CC = $(TRGT)gcc
-CPPC = $(TRGT)g++
-# Enable loading with g++ only if you need C++ runtime support.
-# NOTE: You can use C++ even without C++ support if you are careful. C++
-# runtime support makes code size explode.
-LD = $(TRGT)gcc
-#LD = $(TRGT)g++
-CP = $(TRGT)objcopy
-AS = $(TRGT)gcc -x assembler-with-cpp
-AR = $(TRGT)ar
-OD = $(TRGT)objdump
-SZ = $(TRGT)size
-HEX = $(CP) -O ihex
-BIN = $(CP) -O binary
-
-# ARM-specific options here
-AOPT =
-
-# THUMB-specific options here
-TOPT = -mthumb -DTHUMB
-
-# Define C warning options here
+# Define C warning options here.
CWARN = -Wall -Wextra -Wundef -Wstrict-prototypes
-# Define C++ warning options here
+# Define C++ warning options here.
CPPWARN = -Wall -Wextra -Wundef
#
-# Compiler settings
+# Project, target, sources and paths
##############################################################################
##############################################################################
@@ -207,8 +165,25 @@ ULIBDIR =
ULIBS =
#
-# End of user defines
+# End of user section
+##############################################################################
+
##############################################################################
+# Common rules
+#
RULESPATH = $(CHIBIOS)/os/common/startup/ARMCMx/compilers/GCC/mk
+include $(RULESPATH)/arm-none-eabi.mk
include $(RULESPATH)/rules.mk
+
+#
+# Common rules
+##############################################################################
+
+##############################################################################
+# Custom rules
+#
+
+#
+# Custom rules
+##############################################################################
diff --git a/demos/STM32/RT-STM32F407-DISCOVERY/chconf.h b/demos/STM32/RT-STM32F407-DISCOVERY/cfg/chconf.h
index a7343edc2..a7343edc2 100644
--- a/demos/STM32/RT-STM32F407-DISCOVERY/chconf.h
+++ b/demos/STM32/RT-STM32F407-DISCOVERY/cfg/chconf.h
diff --git a/demos/STM32/RT-STM32F407-DISCOVERY/halconf.h b/demos/STM32/RT-STM32F407-DISCOVERY/cfg/halconf.h
index 89be0946a..89be0946a 100644
--- a/demos/STM32/RT-STM32F407-DISCOVERY/halconf.h
+++ b/demos/STM32/RT-STM32F407-DISCOVERY/cfg/halconf.h
diff --git a/demos/STM32/RT-STM32F407-DISCOVERY/mcuconf.h b/demos/STM32/RT-STM32F407-DISCOVERY/cfg/mcuconf.h
index d04cdfa77..d04cdfa77 100644
--- a/demos/STM32/RT-STM32F407-DISCOVERY/mcuconf.h
+++ b/demos/STM32/RT-STM32F407-DISCOVERY/cfg/mcuconf.h
diff --git a/demos/STM32/RT-STM32F410RB-NUCLEO64/Makefile b/demos/STM32/RT-STM32F410RB-NUCLEO64/Makefile
index bc9e8bfba..14a8a8558 100644
--- a/demos/STM32/RT-STM32F410RB-NUCLEO64/Makefile
+++ b/demos/STM32/RT-STM32F410RB-NUCLEO64/Makefile
@@ -18,7 +18,7 @@ ifeq ($(USE_CPPOPT),)
USE_CPPOPT = -fno-rtti
endif
-# Enable this if you want the linker to remove unused code and data
+# Enable this if you want the linker to remove unused code and data.
ifeq ($(USE_LINK_GC),)
USE_LINK_GC = yes
endif
@@ -28,16 +28,11 @@ ifeq ($(USE_LDOPT),)
USE_LDOPT =
endif
-# Enable this if you want link time optimizations (LTO)
+# Enable this if you want link time optimizations (LTO).
ifeq ($(USE_LTO),)
USE_LTO = yes
endif
-# If enabled, this option allows to compile the application in THUMB mode.
-ifeq ($(USE_THUMB),)
- USE_THUMB = yes
-endif
-
# Enable this if you want to see the full log while compiling.
ifeq ($(USE_VERBOSE_COMPILE),)
USE_VERBOSE_COMPILE = no
@@ -74,19 +69,30 @@ ifeq ($(USE_FPU),)
USE_FPU = no
endif
+# FPU-related options.
+ifeq ($(USE_FPU_OPT),)
+ USE_FPU_OPT = -mfloat-abi=$(USE_FPU) -mfpu=fpv4-sp-d16
+endif
+
#
# Architecture or project specific options
##############################################################################
##############################################################################
-# Project, sources and paths
+# Project, target, sources and paths
#
# Define project name here
PROJECT = ch
-# Imported source files and paths
-CHIBIOS = ../../..
+# Target settings.
+MCU = cortex-m4
+
+# Imported source files and paths.
+CHIBIOS := ../../..
+CONFDIR := ./cfg
+BUILDDIR := ./build
+DEPDIR := ./.dep
# Licensing files.
include $(CHIBIOS)/os/license/license.mk
@@ -100,6 +106,8 @@ include $(CHIBIOS)/os/hal/osal/rt/osal.mk
# RTOS files (optional).
include $(CHIBIOS)/os/rt/rt.mk
include $(CHIBIOS)/os/common/ports/ARMCMx/compilers/GCC/mk/port_v7m.mk
+# Auto-build files in ./source recursively.
+include $(CHIBIOS)/tools/mk/autobuild.mk
# Other files (optional).
include $(CHIBIOS)/test/lib/test.mk
include $(CHIBIOS)/test/rt/rt_test.mk
@@ -118,73 +126,23 @@ CSRC = $(ALLCSRC) \
# setting.
CPPSRC = $(ALLCPPSRC)
-# C sources to be compiled in ARM mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-ACSRC =
-
-# C++ sources to be compiled in ARM mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-ACPPSRC =
-
-# C sources to be compiled in THUMB mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-TCSRC =
-
-# C sources to be compiled in THUMB mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-TCPPSRC =
-
-# List ASM source files here
+# List ASM source files here.
ASMSRC = $(ALLASMSRC)
-ASMXSRC = $(ALLXASMSRC)
-
-INCDIR = $(ALLINC) $(TESTINC)
-#
-# Project, sources and paths
-##############################################################################
-
-##############################################################################
-# Compiler settings
-#
+# List ASM with preprocessor source files here.
+ASMXSRC = $(ALLXASMSRC)
-MCU = cortex-m4
+# Inclusion directories.
+INCDIR = $(CONFDIR) $(ALLINC) $(TESTINC)
-#TRGT = arm-elf-
-TRGT = arm-none-eabi-
-CC = $(TRGT)gcc
-CPPC = $(TRGT)g++
-# Enable loading with g++ only if you need C++ runtime support.
-# NOTE: You can use C++ even without C++ support if you are careful. C++
-# runtime support makes code size explode.
-LD = $(TRGT)gcc
-#LD = $(TRGT)g++
-CP = $(TRGT)objcopy
-AS = $(TRGT)gcc -x assembler-with-cpp
-AR = $(TRGT)ar
-OD = $(TRGT)objdump
-SZ = $(TRGT)size
-HEX = $(CP) -O ihex
-BIN = $(CP) -O binary
-
-# ARM-specific options here
-AOPT =
-
-# THUMB-specific options here
-TOPT = -mthumb -DTHUMB
-
-# Define C warning options here
+# Define C warning options here.
CWARN = -Wall -Wextra -Wundef -Wstrict-prototypes
-# Define C++ warning options here
+# Define C++ warning options here.
CPPWARN = -Wall -Wextra -Wundef
#
-# Compiler settings
+# Project, target, sources and paths
##############################################################################
##############################################################################
@@ -207,8 +165,25 @@ ULIBDIR =
ULIBS =
#
-# End of user defines
+# End of user section
+##############################################################################
+
##############################################################################
+# Common rules
+#
RULESPATH = $(CHIBIOS)/os/common/startup/ARMCMx/compilers/GCC/mk
+include $(RULESPATH)/arm-none-eabi.mk
include $(RULESPATH)/rules.mk
+
+#
+# Common rules
+##############################################################################
+
+##############################################################################
+# Custom rules
+#
+
+#
+# Custom rules
+##############################################################################
diff --git a/demos/STM32/RT-STM32F410RB-NUCLEO64/chconf.h b/demos/STM32/RT-STM32F410RB-NUCLEO64/cfg/chconf.h
index a7343edc2..a7343edc2 100644
--- a/demos/STM32/RT-STM32F410RB-NUCLEO64/chconf.h
+++ b/demos/STM32/RT-STM32F410RB-NUCLEO64/cfg/chconf.h
diff --git a/demos/STM32/RT-STM32F410RB-NUCLEO64/halconf.h b/demos/STM32/RT-STM32F410RB-NUCLEO64/cfg/halconf.h
index 89be0946a..89be0946a 100644
--- a/demos/STM32/RT-STM32F410RB-NUCLEO64/halconf.h
+++ b/demos/STM32/RT-STM32F410RB-NUCLEO64/cfg/halconf.h
diff --git a/demos/STM32/RT-STM32F410RB-NUCLEO64/mcuconf.h b/demos/STM32/RT-STM32F410RB-NUCLEO64/cfg/mcuconf.h
index 67262893f..67262893f 100644
--- a/demos/STM32/RT-STM32F410RB-NUCLEO64/mcuconf.h
+++ b/demos/STM32/RT-STM32F410RB-NUCLEO64/cfg/mcuconf.h
diff --git a/demos/STM32/RT-STM32F411RE-NUCLEO64/Makefile b/demos/STM32/RT-STM32F411RE-NUCLEO64/Makefile
index 4f593937f..d16f208a5 100644
--- a/demos/STM32/RT-STM32F411RE-NUCLEO64/Makefile
+++ b/demos/STM32/RT-STM32F411RE-NUCLEO64/Makefile
@@ -18,7 +18,7 @@ ifeq ($(USE_CPPOPT),)
USE_CPPOPT = -fno-rtti
endif
-# Enable this if you want the linker to remove unused code and data
+# Enable this if you want the linker to remove unused code and data.
ifeq ($(USE_LINK_GC),)
USE_LINK_GC = yes
endif
@@ -28,16 +28,11 @@ ifeq ($(USE_LDOPT),)
USE_LDOPT =
endif
-# Enable this if you want link time optimizations (LTO)
+# Enable this if you want link time optimizations (LTO).
ifeq ($(USE_LTO),)
USE_LTO = yes
endif
-# If enabled, this option allows to compile the application in THUMB mode.
-ifeq ($(USE_THUMB),)
- USE_THUMB = yes
-endif
-
# Enable this if you want to see the full log while compiling.
ifeq ($(USE_VERBOSE_COMPILE),)
USE_VERBOSE_COMPILE = no
@@ -74,19 +69,30 @@ ifeq ($(USE_FPU),)
USE_FPU = no
endif
+# FPU-related options.
+ifeq ($(USE_FPU_OPT),)
+ USE_FPU_OPT = -mfloat-abi=$(USE_FPU) -mfpu=fpv4-sp-d16
+endif
+
#
# Architecture or project specific options
##############################################################################
##############################################################################
-# Project, sources and paths
+# Project, target, sources and paths
#
# Define project name here
PROJECT = ch
-# Imported source files and paths
-CHIBIOS = ../../..
+# Target settings.
+MCU = cortex-m4
+
+# Imported source files and paths.
+CHIBIOS := ../../..
+CONFDIR := ./cfg
+BUILDDIR := ./build
+DEPDIR := ./.dep
# Licensing files.
include $(CHIBIOS)/os/license/license.mk
@@ -100,6 +106,8 @@ include $(CHIBIOS)/os/hal/osal/rt/osal.mk
# RTOS files (optional).
include $(CHIBIOS)/os/rt/rt.mk
include $(CHIBIOS)/os/common/ports/ARMCMx/compilers/GCC/mk/port_v7m.mk
+# Auto-build files in ./source recursively.
+include $(CHIBIOS)/tools/mk/autobuild.mk
# Other files (optional).
include $(CHIBIOS)/test/lib/test.mk
include $(CHIBIOS)/test/rt/rt_test.mk
@@ -118,73 +126,23 @@ CSRC = $(ALLCSRC) \
# setting.
CPPSRC = $(ALLCPPSRC)
-# C sources to be compiled in ARM mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-ACSRC =
-
-# C++ sources to be compiled in ARM mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-ACPPSRC =
-
-# C sources to be compiled in THUMB mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-TCSRC =
-
-# C sources to be compiled in THUMB mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-TCPPSRC =
-
-# List ASM source files here
+# List ASM source files here.
ASMSRC = $(ALLASMSRC)
-ASMXSRC = $(ALLXASMSRC)
-
-INCDIR = $(ALLINC) $(TESTINC)
-#
-# Project, sources and paths
-##############################################################################
-
-##############################################################################
-# Compiler settings
-#
+# List ASM with preprocessor source files here.
+ASMXSRC = $(ALLXASMSRC)
-MCU = cortex-m4
+# Inclusion directories.
+INCDIR = $(CONFDIR) $(ALLINC) $(TESTINC)
-#TRGT = arm-elf-
-TRGT = arm-none-eabi-
-CC = $(TRGT)gcc
-CPPC = $(TRGT)g++
-# Enable loading with g++ only if you need C++ runtime support.
-# NOTE: You can use C++ even without C++ support if you are careful. C++
-# runtime support makes code size explode.
-LD = $(TRGT)gcc
-#LD = $(TRGT)g++
-CP = $(TRGT)objcopy
-AS = $(TRGT)gcc -x assembler-with-cpp
-AR = $(TRGT)ar
-OD = $(TRGT)objdump
-SZ = $(TRGT)size
-HEX = $(CP) -O ihex
-BIN = $(CP) -O binary
-
-# ARM-specific options here
-AOPT =
-
-# THUMB-specific options here
-TOPT = -mthumb -DTHUMB
-
-# Define C warning options here
+# Define C warning options here.
CWARN = -Wall -Wextra -Wundef -Wstrict-prototypes
-# Define C++ warning options here
+# Define C++ warning options here.
CPPWARN = -Wall -Wextra -Wundef
#
-# Compiler settings
+# Project, target, sources and paths
##############################################################################
##############################################################################
@@ -207,8 +165,25 @@ ULIBDIR =
ULIBS =
#
-# End of user defines
+# End of user section
+##############################################################################
+
##############################################################################
+# Common rules
+#
RULESPATH = $(CHIBIOS)/os/common/startup/ARMCMx/compilers/GCC/mk
+include $(RULESPATH)/arm-none-eabi.mk
include $(RULESPATH)/rules.mk
+
+#
+# Common rules
+##############################################################################
+
+##############################################################################
+# Custom rules
+#
+
+#
+# Custom rules
+##############################################################################
diff --git a/demos/STM32/RT-STM32F411RE-NUCLEO64/chconf.h b/demos/STM32/RT-STM32F411RE-NUCLEO64/cfg/chconf.h
index a7343edc2..a7343edc2 100644
--- a/demos/STM32/RT-STM32F411RE-NUCLEO64/chconf.h
+++ b/demos/STM32/RT-STM32F411RE-NUCLEO64/cfg/chconf.h
diff --git a/demos/STM32/RT-STM32F411RE-NUCLEO64/halconf.h b/demos/STM32/RT-STM32F411RE-NUCLEO64/cfg/halconf.h
index 89be0946a..89be0946a 100644
--- a/demos/STM32/RT-STM32F411RE-NUCLEO64/halconf.h
+++ b/demos/STM32/RT-STM32F411RE-NUCLEO64/cfg/halconf.h
diff --git a/demos/STM32/RT-STM32F411RE-NUCLEO64/mcuconf.h b/demos/STM32/RT-STM32F411RE-NUCLEO64/cfg/mcuconf.h
index a32d69f55..a32d69f55 100644
--- a/demos/STM32/RT-STM32F411RE-NUCLEO64/mcuconf.h
+++ b/demos/STM32/RT-STM32F411RE-NUCLEO64/cfg/mcuconf.h
diff --git a/demos/STM32/RT-STM32F412ZG-NUCLEO144/Makefile b/demos/STM32/RT-STM32F412ZG-NUCLEO144/Makefile
index 355a302d7..66e04b397 100644
--- a/demos/STM32/RT-STM32F412ZG-NUCLEO144/Makefile
+++ b/demos/STM32/RT-STM32F412ZG-NUCLEO144/Makefile
@@ -18,7 +18,7 @@ ifeq ($(USE_CPPOPT),)
USE_CPPOPT = -fno-rtti
endif
-# Enable this if you want the linker to remove unused code and data
+# Enable this if you want the linker to remove unused code and data.
ifeq ($(USE_LINK_GC),)
USE_LINK_GC = yes
endif
@@ -28,16 +28,11 @@ ifeq ($(USE_LDOPT),)
USE_LDOPT =
endif
-# Enable this if you want link time optimizations (LTO)
+# Enable this if you want link time optimizations (LTO).
ifeq ($(USE_LTO),)
USE_LTO = yes
endif
-# If enabled, this option allows to compile the application in THUMB mode.
-ifeq ($(USE_THUMB),)
- USE_THUMB = yes
-endif
-
# Enable this if you want to see the full log while compiling.
ifeq ($(USE_VERBOSE_COMPILE),)
USE_VERBOSE_COMPILE = no
@@ -74,19 +69,30 @@ ifeq ($(USE_FPU),)
USE_FPU = no
endif
+# FPU-related options.
+ifeq ($(USE_FPU_OPT),)
+ USE_FPU_OPT = -mfloat-abi=$(USE_FPU) -mfpu=fpv4-sp-d16
+endif
+
#
# Architecture or project specific options
##############################################################################
##############################################################################
-# Project, sources and paths
+# Project, target, sources and paths
#
# Define project name here
PROJECT = ch
-# Imported source files and paths
-CHIBIOS = ../../..
+# Target settings.
+MCU = cortex-m4
+
+# Imported source files and paths.
+CHIBIOS := ../../..
+CONFDIR := ./cfg
+BUILDDIR := ./build
+DEPDIR := ./.dep
# Licensing files.
include $(CHIBIOS)/os/license/license.mk
@@ -100,11 +106,12 @@ include $(CHIBIOS)/os/hal/osal/rt/osal.mk
# RTOS files (optional).
include $(CHIBIOS)/os/rt/rt.mk
include $(CHIBIOS)/os/common/ports/ARMCMx/compilers/GCC/mk/port_v7m.mk
+# Auto-build files in ./source recursively.
+include $(CHIBIOS)/tools/mk/autobuild.mk
# Other files (optional).
include $(CHIBIOS)/test/lib/test.mk
include $(CHIBIOS)/test/rt/rt_test.mk
include $(CHIBIOS)/test/oslib/oslib_test.mk
-include $(CHIBIOS)/os/hal/lib/streams/streams.mk
# Define linker script file here
LDSCRIPT= $(STARTUPLD)/STM32F412xG.ld
@@ -119,73 +126,23 @@ CSRC = $(ALLCSRC) \
# setting.
CPPSRC = $(ALLCPPSRC)
-# C sources to be compiled in ARM mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-ACSRC =
-
-# C++ sources to be compiled in ARM mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-ACPPSRC =
-
-# C sources to be compiled in THUMB mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-TCSRC =
-
-# C sources to be compiled in THUMB mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-TCPPSRC =
-
-# List ASM source files here
+# List ASM source files here.
ASMSRC = $(ALLASMSRC)
-ASMXSRC = $(ALLXASMSRC)
-
-INCDIR = $(ALLINC) $(TESTINC)
-#
-# Project, sources and paths
-##############################################################################
-
-##############################################################################
-# Compiler settings
-#
+# List ASM with preprocessor source files here.
+ASMXSRC = $(ALLXASMSRC)
-MCU = cortex-m4
+# Inclusion directories.
+INCDIR = $(CONFDIR) $(ALLINC) $(TESTINC)
-#TRGT = arm-elf-
-TRGT = arm-none-eabi-
-CC = $(TRGT)gcc
-CPPC = $(TRGT)g++
-# Enable loading with g++ only if you need C++ runtime support.
-# NOTE: You can use C++ even without C++ support if you are careful. C++
-# runtime support makes code size explode.
-LD = $(TRGT)gcc
-#LD = $(TRGT)g++
-CP = $(TRGT)objcopy
-AS = $(TRGT)gcc -x assembler-with-cpp
-AR = $(TRGT)ar
-OD = $(TRGT)objdump
-SZ = $(TRGT)size
-HEX = $(CP) -O ihex
-BIN = $(CP) -O binary
-
-# ARM-specific options here
-AOPT =
-
-# THUMB-specific options here
-TOPT = -mthumb -DTHUMB
-
-# Define C warning options here
+# Define C warning options here.
CWARN = -Wall -Wextra -Wundef -Wstrict-prototypes
-# Define C++ warning options here
+# Define C++ warning options here.
CPPWARN = -Wall -Wextra -Wundef
#
-# Compiler settings
+# Project, target, sources and paths
##############################################################################
##############################################################################
@@ -208,8 +165,25 @@ ULIBDIR =
ULIBS =
#
-# End of user defines
+# End of user section
+##############################################################################
+
##############################################################################
+# Common rules
+#
RULESPATH = $(CHIBIOS)/os/common/startup/ARMCMx/compilers/GCC/mk
+include $(RULESPATH)/arm-none-eabi.mk
include $(RULESPATH)/rules.mk
+
+#
+# Common rules
+##############################################################################
+
+##############################################################################
+# Custom rules
+#
+
+#
+# Custom rules
+##############################################################################
diff --git a/demos/STM32/RT-STM32F412ZG-NUCLEO144/chconf.h b/demos/STM32/RT-STM32F412ZG-NUCLEO144/cfg/chconf.h
index a7343edc2..a7343edc2 100644
--- a/demos/STM32/RT-STM32F412ZG-NUCLEO144/chconf.h
+++ b/demos/STM32/RT-STM32F412ZG-NUCLEO144/cfg/chconf.h
diff --git a/demos/STM32/RT-STM32F412ZG-NUCLEO144/halconf.h b/demos/STM32/RT-STM32F412ZG-NUCLEO144/cfg/halconf.h
index 89be0946a..89be0946a 100644
--- a/demos/STM32/RT-STM32F412ZG-NUCLEO144/halconf.h
+++ b/demos/STM32/RT-STM32F412ZG-NUCLEO144/cfg/halconf.h
diff --git a/demos/STM32/RT-STM32F412ZG-NUCLEO144/mcuconf.h b/demos/STM32/RT-STM32F412ZG-NUCLEO144/cfg/mcuconf.h
index 19a9b5c8c..19a9b5c8c 100644
--- a/demos/STM32/RT-STM32F412ZG-NUCLEO144/mcuconf.h
+++ b/demos/STM32/RT-STM32F412ZG-NUCLEO144/cfg/mcuconf.h
diff --git a/demos/STM32/RT-STM32F413ZH-NUCLEO144/Makefile b/demos/STM32/RT-STM32F413ZH-NUCLEO144/Makefile
index 750be46a8..5ffb16bb6 100644
--- a/demos/STM32/RT-STM32F413ZH-NUCLEO144/Makefile
+++ b/demos/STM32/RT-STM32F413ZH-NUCLEO144/Makefile
@@ -18,7 +18,7 @@ ifeq ($(USE_CPPOPT),)
USE_CPPOPT = -fno-rtti
endif
-# Enable this if you want the linker to remove unused code and data
+# Enable this if you want the linker to remove unused code and data.
ifeq ($(USE_LINK_GC),)
USE_LINK_GC = yes
endif
@@ -28,16 +28,11 @@ ifeq ($(USE_LDOPT),)
USE_LDOPT =
endif
-# Enable this if you want link time optimizations (LTO)
+# Enable this if you want link time optimizations (LTO).
ifeq ($(USE_LTO),)
USE_LTO = yes
endif
-# If enabled, this option allows to compile the application in THUMB mode.
-ifeq ($(USE_THUMB),)
- USE_THUMB = yes
-endif
-
# Enable this if you want to see the full log while compiling.
ifeq ($(USE_VERBOSE_COMPILE),)
USE_VERBOSE_COMPILE = no
@@ -74,19 +69,31 @@ ifeq ($(USE_FPU),)
USE_FPU = no
endif
+# FPU-related options.
+ifeq ($(USE_FPU_OPT),)
+ USE_FPU_OPT = -mfloat-abi=$(USE_FPU) -mfpu=fpv4-sp-d16
+endif
+
#
# Architecture or project specific options
##############################################################################
##############################################################################
-# Project, sources and paths
+# Project, target, sources and paths
#
# Define project name here
PROJECT = ch
-# Imported source files and paths
-CHIBIOS = ../../..
+# Target settings.
+MCU = cortex-m4
+
+# Imported source files and paths.
+CHIBIOS := ../../..
+CONFDIR := ./cfg
+BUILDDIR := ./build
+DEPDIR := ./.dep
+
# Licensing files.
include $(CHIBIOS)/os/license/license.mk
# Startup files.
@@ -99,11 +106,12 @@ include $(CHIBIOS)/os/hal/osal/rt/osal.mk
# RTOS files (optional).
include $(CHIBIOS)/os/rt/rt.mk
include $(CHIBIOS)/os/common/ports/ARMCMx/compilers/GCC/mk/port_v7m.mk
+# Auto-build files in ./source recursively.
+include $(CHIBIOS)/tools/mk/autobuild.mk
# Other files (optional).
include $(CHIBIOS)/test/lib/test.mk
include $(CHIBIOS)/test/rt/rt_test.mk
include $(CHIBIOS)/test/oslib/oslib_test.mk
-include $(CHIBIOS)/os/hal/lib/streams/streams.mk
# Define linker script file here
LDSCRIPT= $(STARTUPLD)/STM32F413xH.ld
@@ -118,73 +126,23 @@ CSRC = $(ALLCSRC) \
# setting.
CPPSRC = $(ALLCPPSRC)
-# C sources to be compiled in ARM mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-ACSRC =
-
-# C++ sources to be compiled in ARM mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-ACPPSRC =
-
-# C sources to be compiled in THUMB mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-TCSRC =
-
-# C sources to be compiled in THUMB mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-TCPPSRC =
-
-# List ASM source files here
+# List ASM source files here.
ASMSRC = $(ALLASMSRC)
-ASMXSRC = $(ALLXASMSRC)
-
-INCDIR = $(ALLINC) $(TESTINC)
-
-#
-# Project, sources and paths
-##############################################################################
-##############################################################################
-# Compiler settings
-#
+# List ASM with preprocessor source files here.
+ASMXSRC = $(ALLXASMSRC)
-MCU = cortex-m4
+# Inclusion directories.
+INCDIR = $(CONFDIR) $(ALLINC) $(TESTINC)
-#TRGT = arm-elf-
-TRGT = arm-none-eabi-
-CC = $(TRGT)gcc
-CPPC = $(TRGT)g++
-# Enable loading with g++ only if you need C++ runtime support.
-# NOTE: You can use C++ even without C++ support if you are careful. C++
-# runtime support makes code size explode.
-LD = $(TRGT)gcc
-#LD = $(TRGT)g++
-CP = $(TRGT)objcopy
-AS = $(TRGT)gcc -x assembler-with-cpp
-AR = $(TRGT)ar
-OD = $(TRGT)objdump
-SZ = $(TRGT)size
-HEX = $(CP) -O ihex
-BIN = $(CP) -O binary
-
-# ARM-specific options here
-AOPT =
-
-# THUMB-specific options here
-TOPT = -mthumb -DTHUMB
-
-# Define C warning options here
+# Define C warning options here.
CWARN = -Wall -Wextra -Wundef -Wstrict-prototypes
-# Define C++ warning options here
+# Define C++ warning options here.
CPPWARN = -Wall -Wextra -Wundef
#
-# Compiler settings
+# Project, target, sources and paths
##############################################################################
##############################################################################
@@ -207,8 +165,25 @@ ULIBDIR =
ULIBS =
#
-# End of user defines
+# End of user section
##############################################################################
+##############################################################################
+# Common rules
+#
+
RULESPATH = $(CHIBIOS)/os/common/startup/ARMCMx/compilers/GCC/mk
+include $(RULESPATH)/arm-none-eabi.mk
include $(RULESPATH)/rules.mk
+
+#
+# Common rules
+##############################################################################
+
+##############################################################################
+# Custom rules
+#
+
+#
+# Custom rules
+##############################################################################
diff --git a/demos/STM32/RT-STM32F413ZH-NUCLEO144/chconf.h b/demos/STM32/RT-STM32F413ZH-NUCLEO144/cfg/chconf.h
index a7343edc2..a7343edc2 100644
--- a/demos/STM32/RT-STM32F413ZH-NUCLEO144/chconf.h
+++ b/demos/STM32/RT-STM32F413ZH-NUCLEO144/cfg/chconf.h
diff --git a/demos/STM32/RT-STM32F413ZH-NUCLEO144/halconf.h b/demos/STM32/RT-STM32F413ZH-NUCLEO144/cfg/halconf.h
index 89be0946a..89be0946a 100644
--- a/demos/STM32/RT-STM32F413ZH-NUCLEO144/halconf.h
+++ b/demos/STM32/RT-STM32F413ZH-NUCLEO144/cfg/halconf.h
diff --git a/demos/STM32/RT-STM32F413ZH-NUCLEO144/mcuconf.h b/demos/STM32/RT-STM32F413ZH-NUCLEO144/cfg/mcuconf.h
index 99f2dc624..99f2dc624 100644
--- a/demos/STM32/RT-STM32F413ZH-NUCLEO144/mcuconf.h
+++ b/demos/STM32/RT-STM32F413ZH-NUCLEO144/cfg/mcuconf.h
diff --git a/demos/STM32/RT-STM32F429-DISCOVERY/Makefile b/demos/STM32/RT-STM32F429-DISCOVERY/Makefile
index e98928f71..3087bd276 100644
--- a/demos/STM32/RT-STM32F429-DISCOVERY/Makefile
+++ b/demos/STM32/RT-STM32F429-DISCOVERY/Makefile
@@ -18,7 +18,7 @@ ifeq ($(USE_CPPOPT),)
USE_CPPOPT = -fno-rtti
endif
-# Enable this if you want the linker to remove unused code and data
+# Enable this if you want the linker to remove unused code and data.
ifeq ($(USE_LINK_GC),)
USE_LINK_GC = yes
endif
@@ -28,16 +28,11 @@ ifeq ($(USE_LDOPT),)
USE_LDOPT =
endif
-# Enable this if you want link time optimizations (LTO)
+# Enable this if you want link time optimizations (LTO).
ifeq ($(USE_LTO),)
USE_LTO = yes
endif
-# If enabled, this option allows to compile the application in THUMB mode.
-ifeq ($(USE_THUMB),)
- USE_THUMB = yes
-endif
-
# Enable this if you want to see the full log while compiling.
ifeq ($(USE_VERBOSE_COMPILE),)
USE_VERBOSE_COMPILE = no
@@ -74,19 +69,30 @@ ifeq ($(USE_FPU),)
USE_FPU = no
endif
+# FPU-related options.
+ifeq ($(USE_FPU_OPT),)
+ USE_FPU_OPT = -mfloat-abi=$(USE_FPU) -mfpu=fpv4-sp-d16
+endif
+
#
# Architecture or project specific options
##############################################################################
##############################################################################
-# Project, sources and paths
+# Project, target, sources and paths
#
# Define project name here
PROJECT = ch
-# Imported source files and paths
-CHIBIOS = ../../..
+# Target settings.
+MCU = cortex-m4
+
+# Imported source files and paths.
+CHIBIOS := ../../..
+CONFDIR := ./cfg
+BUILDDIR := ./build
+DEPDIR := ./.dep
# Licensing files.
include $(CHIBIOS)/os/license/license.mk
@@ -100,6 +106,8 @@ include $(CHIBIOS)/os/hal/osal/rt/osal.mk
# RTOS files (optional).
include $(CHIBIOS)/os/rt/rt.mk
include $(CHIBIOS)/os/common/ports/ARMCMx/compilers/GCC/mk/port_v7m.mk
+# Auto-build files in ./source recursively.
+include $(CHIBIOS)/tools/mk/autobuild.mk
# Other files (optional).
include $(CHIBIOS)/test/lib/test.mk
include $(CHIBIOS)/test/rt/rt_test.mk
@@ -114,79 +122,29 @@ LDSCRIPT= $(STARTUPLD)/STM32F429xI.ld
# setting.
CSRC = $(ALLCSRC) \
$(TESTSRC) \
- usbcfg.c main.c
+ main.c
# C++ sources that can be compiled in ARM or THUMB mode depending on the global
# setting.
CPPSRC = $(ALLCPPSRC)
-# C sources to be compiled in ARM mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-ACSRC =
-
-# C++ sources to be compiled in ARM mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-ACPPSRC =
-
-# C sources to be compiled in THUMB mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-TCSRC =
-
-# C sources to be compiled in THUMB mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-TCPPSRC =
-
-# List ASM source files here
+# List ASM source files here.
ASMSRC = $(ALLASMSRC)
-ASMXSRC = $(ALLXASMSRC)
-
-INCDIR = $(ALLINC) $(TESTINC)
-#
-# Project, sources and paths
-##############################################################################
-
-##############################################################################
-# Compiler settings
-#
+# List ASM with preprocessor source files here.
+ASMXSRC = $(ALLXASMSRC)
-MCU = cortex-m4
+# Inclusion directories.
+INCDIR = $(CONFDIR) $(ALLINC) $(TESTINC)
-#TRGT = arm-elf-
-TRGT = arm-none-eabi-
-CC = $(TRGT)gcc
-CPPC = $(TRGT)g++
-# Enable loading with g++ only if you need C++ runtime support.
-# NOTE: You can use C++ even without C++ support if you are careful. C++
-# runtime support makes code size explode.
-LD = $(TRGT)gcc
-#LD = $(TRGT)g++
-CP = $(TRGT)objcopy
-AS = $(TRGT)gcc -x assembler-with-cpp
-AR = $(TRGT)ar
-OD = $(TRGT)objdump
-SZ = $(TRGT)size
-HEX = $(CP) -O ihex
-BIN = $(CP) -O binary
-
-# ARM-specific options here
-AOPT =
-
-# THUMB-specific options here
-TOPT = -mthumb -DTHUMB
-
-# Define C warning options here
+# Define C warning options here.
CWARN = -Wall -Wextra -Wundef -Wstrict-prototypes
-# Define C++ warning options here
+# Define C++ warning options here.
CPPWARN = -Wall -Wextra -Wundef
#
-# Compiler settings
+# Project, target, sources and paths
##############################################################################
##############################################################################
@@ -209,8 +167,25 @@ ULIBDIR =
ULIBS =
#
-# End of user defines
+# End of user section
+##############################################################################
+
##############################################################################
+# Common rules
+#
RULESPATH = $(CHIBIOS)/os/common/startup/ARMCMx/compilers/GCC/mk
+include $(RULESPATH)/arm-none-eabi.mk
include $(RULESPATH)/rules.mk
+
+#
+# Common rules
+##############################################################################
+
+##############################################################################
+# Custom rules
+#
+
+#
+# Custom rules
+##############################################################################
diff --git a/demos/STM32/RT-STM32F429-DISCOVERY/chconf.h b/demos/STM32/RT-STM32F429-DISCOVERY/cfg/chconf.h
index a7343edc2..a7343edc2 100644
--- a/demos/STM32/RT-STM32F429-DISCOVERY/chconf.h
+++ b/demos/STM32/RT-STM32F429-DISCOVERY/cfg/chconf.h
diff --git a/demos/STM32/RT-STM32F429-DISCOVERY/halconf.h b/demos/STM32/RT-STM32F429-DISCOVERY/cfg/halconf.h
index 86d17e425..86d17e425 100644
--- a/demos/STM32/RT-STM32F429-DISCOVERY/halconf.h
+++ b/demos/STM32/RT-STM32F429-DISCOVERY/cfg/halconf.h
diff --git a/demos/STM32/RT-STM32F429-DISCOVERY/mcuconf.h b/demos/STM32/RT-STM32F429-DISCOVERY/cfg/mcuconf.h
index 05810d0d9..05810d0d9 100644
--- a/demos/STM32/RT-STM32F429-DISCOVERY/mcuconf.h
+++ b/demos/STM32/RT-STM32F429-DISCOVERY/cfg/mcuconf.h
diff --git a/demos/STM32/RT-STM32F429-DISCOVERY/usbcfg.c b/demos/STM32/RT-STM32F429-DISCOVERY/source/usbcfg.c
index e35ff0925..e35ff0925 100644
--- a/demos/STM32/RT-STM32F429-DISCOVERY/usbcfg.c
+++ b/demos/STM32/RT-STM32F429-DISCOVERY/source/usbcfg.c
diff --git a/demos/STM32/RT-STM32F429-DISCOVERY/usbcfg.h b/demos/STM32/RT-STM32F429-DISCOVERY/source/usbcfg.h
index 886cd0222..886cd0222 100644
--- a/demos/STM32/RT-STM32F429-DISCOVERY/usbcfg.h
+++ b/demos/STM32/RT-STM32F429-DISCOVERY/source/usbcfg.h
diff --git a/demos/STM32/RT-STM32F429ZI-NUCLEO144/Makefile b/demos/STM32/RT-STM32F429ZI-NUCLEO144/Makefile
index 5b51d0c95..f1a77729d 100644
--- a/demos/STM32/RT-STM32F429ZI-NUCLEO144/Makefile
+++ b/demos/STM32/RT-STM32F429ZI-NUCLEO144/Makefile
@@ -18,7 +18,7 @@ ifeq ($(USE_CPPOPT),)
USE_CPPOPT = -fno-rtti
endif
-# Enable this if you want the linker to remove unused code and data
+# Enable this if you want the linker to remove unused code and data.
ifeq ($(USE_LINK_GC),)
USE_LINK_GC = yes
endif
@@ -28,16 +28,11 @@ ifeq ($(USE_LDOPT),)
USE_LDOPT =
endif
-# Enable this if you want link time optimizations (LTO)
+# Enable this if you want link time optimizations (LTO).
ifeq ($(USE_LTO),)
USE_LTO = yes
endif
-# If enabled, this option allows to compile the application in THUMB mode.
-ifeq ($(USE_THUMB),)
- USE_THUMB = yes
-endif
-
# Enable this if you want to see the full log while compiling.
ifeq ($(USE_VERBOSE_COMPILE),)
USE_VERBOSE_COMPILE = no
@@ -74,19 +69,30 @@ ifeq ($(USE_FPU),)
USE_FPU = no
endif
+# FPU-related options.
+ifeq ($(USE_FPU_OPT),)
+ USE_FPU_OPT = -mfloat-abi=$(USE_FPU) -mfpu=fpv4-sp-d16
+endif
+
#
# Architecture or project specific options
##############################################################################
##############################################################################
-# Project, sources and paths
+# Project, target, sources and paths
#
# Define project name here
PROJECT = ch
-# Imported source files and paths
-CHIBIOS = ../../..
+# Target settings.
+MCU = cortex-m4
+
+# Imported source files and paths.
+CHIBIOS := ../../..
+CONFDIR := ./cfg
+BUILDDIR := ./build
+DEPDIR := ./.dep
# Licensing files.
include $(CHIBIOS)/os/license/license.mk
@@ -100,11 +106,12 @@ include $(CHIBIOS)/os/hal/osal/rt/osal.mk
# RTOS files (optional).
include $(CHIBIOS)/os/rt/rt.mk
include $(CHIBIOS)/os/common/ports/ARMCMx/compilers/GCC/mk/port_v7m.mk
+# Auto-build files in ./source recursively.
+include $(CHIBIOS)/tools/mk/autobuild.mk
# Other files (optional).
include $(CHIBIOS)/test/lib/test.mk
include $(CHIBIOS)/test/rt/rt_test.mk
include $(CHIBIOS)/test/oslib/oslib_test.mk
-include $(CHIBIOS)/os/hal/lib/streams/streams.mk
# Define linker script file here
LDSCRIPT= $(STARTUPLD)/STM32F429xI.ld
@@ -119,73 +126,23 @@ CSRC = $(ALLCSRC) \
# setting.
CPPSRC = $(ALLCPPSRC)
-# C sources to be compiled in ARM mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-ACSRC =
-
-# C++ sources to be compiled in ARM mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-ACPPSRC =
-
-# C sources to be compiled in THUMB mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-TCSRC =
-
-# C sources to be compiled in THUMB mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-TCPPSRC =
-
-# List ASM source files here
+# List ASM source files here.
ASMSRC = $(ALLASMSRC)
-ASMXSRC = $(ALLXASMSRC)
-
-INCDIR = $(ALLINC) $(TESTINC)
-#
-# Project, sources and paths
-##############################################################################
-
-##############################################################################
-# Compiler settings
-#
+# List ASM with preprocessor source files here.
+ASMXSRC = $(ALLXASMSRC)
-MCU = cortex-m4
+# Inclusion directories.
+INCDIR = $(CONFDIR) $(ALLINC) $(TESTINC)
-#TRGT = arm-elf-
-TRGT = arm-none-eabi-
-CC = $(TRGT)gcc
-CPPC = $(TRGT)g++
-# Enable loading with g++ only if you need C++ runtime support.
-# NOTE: You can use C++ even without C++ support if you are careful. C++
-# runtime support makes code size explode.
-LD = $(TRGT)gcc
-#LD = $(TRGT)g++
-CP = $(TRGT)objcopy
-AS = $(TRGT)gcc -x assembler-with-cpp
-AR = $(TRGT)ar
-OD = $(TRGT)objdump
-SZ = $(TRGT)size
-HEX = $(CP) -O ihex
-BIN = $(CP) -O binary
-
-# ARM-specific options here
-AOPT =
-
-# THUMB-specific options here
-TOPT = -mthumb -DTHUMB
-
-# Define C warning options here
+# Define C warning options here.
CWARN = -Wall -Wextra -Wundef -Wstrict-prototypes
-# Define C++ warning options here
+# Define C++ warning options here.
CPPWARN = -Wall -Wextra -Wundef
#
-# Compiler settings
+# Project, target, sources and paths
##############################################################################
##############################################################################
@@ -208,8 +165,25 @@ ULIBDIR =
ULIBS =
#
-# End of user defines
+# End of user section
+##############################################################################
+
##############################################################################
+# Common rules
+#
RULESPATH = $(CHIBIOS)/os/common/startup/ARMCMx/compilers/GCC/mk
+include $(RULESPATH)/arm-none-eabi.mk
include $(RULESPATH)/rules.mk
+
+#
+# Common rules
+##############################################################################
+
+##############################################################################
+# Custom rules
+#
+
+#
+# Custom rules
+##############################################################################
diff --git a/demos/STM32/RT-STM32F429ZI-NUCLEO144/chconf.h b/demos/STM32/RT-STM32F429ZI-NUCLEO144/cfg/chconf.h
index a7343edc2..a7343edc2 100644
--- a/demos/STM32/RT-STM32F429ZI-NUCLEO144/chconf.h
+++ b/demos/STM32/RT-STM32F429ZI-NUCLEO144/cfg/chconf.h
diff --git a/demos/STM32/RT-STM32F429ZI-NUCLEO144/halconf.h b/demos/STM32/RT-STM32F429ZI-NUCLEO144/cfg/halconf.h
index 89be0946a..89be0946a 100644
--- a/demos/STM32/RT-STM32F429ZI-NUCLEO144/halconf.h
+++ b/demos/STM32/RT-STM32F429ZI-NUCLEO144/cfg/halconf.h
diff --git a/demos/STM32/RT-STM32F429ZI-NUCLEO144/mcuconf.h b/demos/STM32/RT-STM32F429ZI-NUCLEO144/cfg/mcuconf.h
index b71823e01..b71823e01 100644
--- a/demos/STM32/RT-STM32F429ZI-NUCLEO144/mcuconf.h
+++ b/demos/STM32/RT-STM32F429ZI-NUCLEO144/cfg/mcuconf.h
diff --git a/demos/STM32/RT-STM32F446RE-NUCLEO64/Makefile b/demos/STM32/RT-STM32F446RE-NUCLEO64/Makefile
index 42c20acfc..3fdfd3c7b 100644
--- a/demos/STM32/RT-STM32F446RE-NUCLEO64/Makefile
+++ b/demos/STM32/RT-STM32F446RE-NUCLEO64/Makefile
@@ -18,7 +18,7 @@ ifeq ($(USE_CPPOPT),)
USE_CPPOPT = -fno-rtti
endif
-# Enable this if you want the linker to remove unused code and data
+# Enable this if you want the linker to remove unused code and data.
ifeq ($(USE_LINK_GC),)
USE_LINK_GC = yes
endif
@@ -28,16 +28,11 @@ ifeq ($(USE_LDOPT),)
USE_LDOPT =
endif
-# Enable this if you want link time optimizations (LTO)
+# Enable this if you want link time optimizations (LTO).
ifeq ($(USE_LTO),)
USE_LTO = yes
endif
-# If enabled, this option allows to compile the application in THUMB mode.
-ifeq ($(USE_THUMB),)
- USE_THUMB = yes
-endif
-
# Enable this if you want to see the full log while compiling.
ifeq ($(USE_VERBOSE_COMPILE),)
USE_VERBOSE_COMPILE = no
@@ -74,19 +69,30 @@ ifeq ($(USE_FPU),)
USE_FPU = no
endif
+# FPU-related options.
+ifeq ($(USE_FPU_OPT),)
+ USE_FPU_OPT = -mfloat-abi=$(USE_FPU) -mfpu=fpv4-sp-d16
+endif
+
#
# Architecture or project specific options
##############################################################################
##############################################################################
-# Project, sources and paths
+# Project, target, sources and paths
#
# Define project name here
PROJECT = ch
-# Imported source files and paths
-CHIBIOS = ../../..
+# Target settings.
+MCU = cortex-m4
+
+# Imported source files and paths.
+CHIBIOS := ../../..
+CONFDIR := ./cfg
+BUILDDIR := ./build
+DEPDIR := ./.dep
# Licensing files.
include $(CHIBIOS)/os/license/license.mk
@@ -100,11 +106,12 @@ include $(CHIBIOS)/os/hal/osal/rt/osal.mk
# RTOS files (optional).
include $(CHIBIOS)/os/rt/rt.mk
include $(CHIBIOS)/os/common/ports/ARMCMx/compilers/GCC/mk/port_v7m.mk
+# Auto-build files in ./source recursively.
+include $(CHIBIOS)/tools/mk/autobuild.mk
# Other files (optional).
include $(CHIBIOS)/test/lib/test.mk
include $(CHIBIOS)/test/rt/rt_test.mk
include $(CHIBIOS)/test/oslib/oslib_test.mk
-include $(CHIBIOS)/os/hal/lib/streams/streams.mk
# Define linker script file here
LDSCRIPT= $(STARTUPLD)/STM32F446xE.ld
@@ -119,73 +126,23 @@ CSRC = $(ALLCSRC) \
# setting.
CPPSRC = $(ALLCPPSRC)
-# C sources to be compiled in ARM mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-ACSRC =
-
-# C++ sources to be compiled in ARM mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-ACPPSRC =
-
-# C sources to be compiled in THUMB mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-TCSRC =
-
-# C sources to be compiled in THUMB mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-TCPPSRC =
-
-# List ASM source files here
+# List ASM source files here.
ASMSRC = $(ALLASMSRC)
-ASMXSRC = $(ALLXASMSRC)
-
-INCDIR = $(ALLINC) $(TESTINC)
-#
-# Project, sources and paths
-##############################################################################
-
-##############################################################################
-# Compiler settings
-#
+# List ASM with preprocessor source files here.
+ASMXSRC = $(ALLXASMSRC)
-MCU = cortex-m4
+# Inclusion directories.
+INCDIR = $(CONFDIR) $(ALLINC) $(TESTINC)
-#TRGT = arm-elf-
-TRGT = arm-none-eabi-
-CC = $(TRGT)gcc
-CPPC = $(TRGT)g++
-# Enable loading with g++ only if you need C++ runtime support.
-# NOTE: You can use C++ even without C++ support if you are careful. C++
-# runtime support makes code size explode.
-LD = $(TRGT)gcc
-#LD = $(TRGT)g++
-CP = $(TRGT)objcopy
-AS = $(TRGT)gcc -x assembler-with-cpp
-AR = $(TRGT)ar
-OD = $(TRGT)objdump
-SZ = $(TRGT)size
-HEX = $(CP) -O ihex
-BIN = $(CP) -O binary
-
-# ARM-specific options here
-AOPT =
-
-# THUMB-specific options here
-TOPT = -mthumb -DTHUMB
-
-# Define C warning options here
+# Define C warning options here.
CWARN = -Wall -Wextra -Wundef -Wstrict-prototypes
-# Define C++ warning options here
+# Define C++ warning options here.
CPPWARN = -Wall -Wextra -Wundef
#
-# Compiler settings
+# Project, target, sources and paths
##############################################################################
##############################################################################
@@ -208,8 +165,25 @@ ULIBDIR =
ULIBS =
#
-# End of user defines
+# End of user section
+##############################################################################
+
##############################################################################
+# Common rules
+#
RULESPATH = $(CHIBIOS)/os/common/startup/ARMCMx/compilers/GCC/mk
+include $(RULESPATH)/arm-none-eabi.mk
include $(RULESPATH)/rules.mk
+
+#
+# Common rules
+##############################################################################
+
+##############################################################################
+# Custom rules
+#
+
+#
+# Custom rules
+##############################################################################
diff --git a/demos/STM32/RT-STM32F446RE-NUCLEO64/chconf.h b/demos/STM32/RT-STM32F446RE-NUCLEO64/cfg/chconf.h
index a7343edc2..a7343edc2 100644
--- a/demos/STM32/RT-STM32F446RE-NUCLEO64/chconf.h
+++ b/demos/STM32/RT-STM32F446RE-NUCLEO64/cfg/chconf.h
diff --git a/demos/STM32/RT-STM32F446RE-NUCLEO64/halconf.h b/demos/STM32/RT-STM32F446RE-NUCLEO64/cfg/halconf.h
index 89be0946a..89be0946a 100644
--- a/demos/STM32/RT-STM32F446RE-NUCLEO64/halconf.h
+++ b/demos/STM32/RT-STM32F446RE-NUCLEO64/cfg/halconf.h
diff --git a/demos/STM32/RT-STM32F446RE-NUCLEO64/mcuconf.h b/demos/STM32/RT-STM32F446RE-NUCLEO64/cfg/mcuconf.h
index d592c5664..d592c5664 100644
--- a/demos/STM32/RT-STM32F446RE-NUCLEO64/mcuconf.h
+++ b/demos/STM32/RT-STM32F446RE-NUCLEO64/cfg/mcuconf.h
diff --git a/demos/STM32/RT-STM32F446ZE-NUCLEO144/Makefile b/demos/STM32/RT-STM32F446ZE-NUCLEO144/Makefile
index c0dedf418..d1c3e332b 100644
--- a/demos/STM32/RT-STM32F446ZE-NUCLEO144/Makefile
+++ b/demos/STM32/RT-STM32F446ZE-NUCLEO144/Makefile
@@ -18,7 +18,7 @@ ifeq ($(USE_CPPOPT),)
USE_CPPOPT = -fno-rtti
endif
-# Enable this if you want the linker to remove unused code and data
+# Enable this if you want the linker to remove unused code and data.
ifeq ($(USE_LINK_GC),)
USE_LINK_GC = yes
endif
@@ -28,16 +28,11 @@ ifeq ($(USE_LDOPT),)
USE_LDOPT =
endif
-# Enable this if you want link time optimizations (LTO)
+# Enable this if you want link time optimizations (LTO).
ifeq ($(USE_LTO),)
USE_LTO = yes
endif
-# If enabled, this option allows to compile the application in THUMB mode.
-ifeq ($(USE_THUMB),)
- USE_THUMB = yes
-endif
-
# Enable this if you want to see the full log while compiling.
ifeq ($(USE_VERBOSE_COMPILE),)
USE_VERBOSE_COMPILE = no
@@ -74,19 +69,30 @@ ifeq ($(USE_FPU),)
USE_FPU = no
endif
+# FPU-related options.
+ifeq ($(USE_FPU_OPT),)
+ USE_FPU_OPT = -mfloat-abi=$(USE_FPU) -mfpu=fpv4-sp-d16
+endif
+
#
# Architecture or project specific options
##############################################################################
##############################################################################
-# Project, sources and paths
+# Project, target, sources and paths
#
# Define project name here
PROJECT = ch
-# Imported source files and paths
-CHIBIOS = ../../..
+# Target settings.
+MCU = cortex-m4
+
+# Imported source files and paths.
+CHIBIOS := ../../..
+CONFDIR := ./cfg
+BUILDDIR := ./build
+DEPDIR := ./.dep
# Licensing files.
include $(CHIBIOS)/os/license/license.mk
@@ -100,11 +106,12 @@ include $(CHIBIOS)/os/hal/osal/rt/osal.mk
# RTOS files (optional).
include $(CHIBIOS)/os/rt/rt.mk
include $(CHIBIOS)/os/common/ports/ARMCMx/compilers/GCC/mk/port_v7m.mk
+# Auto-build files in ./source recursively.
+include $(CHIBIOS)/tools/mk/autobuild.mk
# Other files (optional).
include $(CHIBIOS)/test/lib/test.mk
include $(CHIBIOS)/test/rt/rt_test.mk
include $(CHIBIOS)/test/oslib/oslib_test.mk
-include $(CHIBIOS)/os/hal/lib/streams/streams.mk
# Define linker script file here
LDSCRIPT= $(STARTUPLD)/STM32F446xE.ld
@@ -119,73 +126,23 @@ CSRC = $(ALLCSRC) \
# setting.
CPPSRC = $(ALLCPPSRC)
-# C sources to be compiled in ARM mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-ACSRC =
-
-# C++ sources to be compiled in ARM mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-ACPPSRC =
-
-# C sources to be compiled in THUMB mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-TCSRC =
-
-# C sources to be compiled in THUMB mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-TCPPSRC =
-
-# List ASM source files here
+# List ASM source files here.
ASMSRC = $(ALLASMSRC)
-ASMXSRC = $(ALLXASMSRC)
-
-INCDIR = $(ALLINC) $(TESTINC)
-#
-# Project, sources and paths
-##############################################################################
-
-##############################################################################
-# Compiler settings
-#
+# List ASM with preprocessor source files here.
+ASMXSRC = $(ALLXASMSRC)
-MCU = cortex-m4
+# Inclusion directories.
+INCDIR = $(CONFDIR) $(ALLINC) $(TESTINC)
-#TRGT = arm-elf-
-TRGT = arm-none-eabi-
-CC = $(TRGT)gcc
-CPPC = $(TRGT)g++
-# Enable loading with g++ only if you need C++ runtime support.
-# NOTE: You can use C++ even without C++ support if you are careful. C++
-# runtime support makes code size explode.
-LD = $(TRGT)gcc
-#LD = $(TRGT)g++
-CP = $(TRGT)objcopy
-AS = $(TRGT)gcc -x assembler-with-cpp
-AR = $(TRGT)ar
-OD = $(TRGT)objdump
-SZ = $(TRGT)size
-HEX = $(CP) -O ihex
-BIN = $(CP) -O binary
-
-# ARM-specific options here
-AOPT =
-
-# THUMB-specific options here
-TOPT = -mthumb -DTHUMB
-
-# Define C warning options here
+# Define C warning options here.
CWARN = -Wall -Wextra -Wundef -Wstrict-prototypes
-# Define C++ warning options here
+# Define C++ warning options here.
CPPWARN = -Wall -Wextra -Wundef
#
-# Compiler settings
+# Project, target, sources and paths
##############################################################################
##############################################################################
@@ -208,8 +165,25 @@ ULIBDIR =
ULIBS =
#
-# End of user defines
+# End of user section
+##############################################################################
+
##############################################################################
+# Common rules
+#
RULESPATH = $(CHIBIOS)/os/common/startup/ARMCMx/compilers/GCC/mk
+include $(RULESPATH)/arm-none-eabi.mk
include $(RULESPATH)/rules.mk
+
+#
+# Common rules
+##############################################################################
+
+##############################################################################
+# Custom rules
+#
+
+#
+# Custom rules
+##############################################################################
diff --git a/demos/STM32/RT-STM32F446ZE-NUCLEO144/chconf.h b/demos/STM32/RT-STM32F446ZE-NUCLEO144/cfg/chconf.h
index a7343edc2..a7343edc2 100644
--- a/demos/STM32/RT-STM32F446ZE-NUCLEO144/chconf.h
+++ b/demos/STM32/RT-STM32F446ZE-NUCLEO144/cfg/chconf.h
diff --git a/demos/STM32/RT-STM32F446ZE-NUCLEO144/halconf.h b/demos/STM32/RT-STM32F446ZE-NUCLEO144/cfg/halconf.h
index 89be0946a..89be0946a 100644
--- a/demos/STM32/RT-STM32F446ZE-NUCLEO144/halconf.h
+++ b/demos/STM32/RT-STM32F446ZE-NUCLEO144/cfg/halconf.h
diff --git a/demos/STM32/RT-STM32F446ZE-NUCLEO144/mcuconf.h b/demos/STM32/RT-STM32F446ZE-NUCLEO144/cfg/mcuconf.h
index 8172bd54a..8172bd54a 100644
--- a/demos/STM32/RT-STM32F446ZE-NUCLEO144/mcuconf.h
+++ b/demos/STM32/RT-STM32F446ZE-NUCLEO144/cfg/mcuconf.h
diff --git a/demos/STM32/RT-STM32F469I-DISCOVERY/Makefile b/demos/STM32/RT-STM32F469I-DISCOVERY/Makefile
index 6f0abe359..988dc1e3e 100644
--- a/demos/STM32/RT-STM32F469I-DISCOVERY/Makefile
+++ b/demos/STM32/RT-STM32F469I-DISCOVERY/Makefile
@@ -18,7 +18,7 @@ ifeq ($(USE_CPPOPT),)
USE_CPPOPT = -fno-rtti
endif
-# Enable this if you want the linker to remove unused code and data
+# Enable this if you want the linker to remove unused code and data.
ifeq ($(USE_LINK_GC),)
USE_LINK_GC = yes
endif
@@ -28,16 +28,11 @@ ifeq ($(USE_LDOPT),)
USE_LDOPT =
endif
-# Enable this if you want link time optimizations (LTO)
+# Enable this if you want link time optimizations (LTO).
ifeq ($(USE_LTO),)
USE_LTO = yes
endif
-# If enabled, this option allows to compile the application in THUMB mode.
-ifeq ($(USE_THUMB),)
- USE_THUMB = yes
-endif
-
# Enable this if you want to see the full log while compiling.
ifeq ($(USE_VERBOSE_COMPILE),)
USE_VERBOSE_COMPILE = no
@@ -74,19 +69,30 @@ ifeq ($(USE_FPU),)
USE_FPU = no
endif
+# FPU-related options.
+ifeq ($(USE_FPU_OPT),)
+ USE_FPU_OPT = -mfloat-abi=$(USE_FPU) -mfpu=fpv4-sp-d16
+endif
+
#
# Architecture or project specific options
##############################################################################
##############################################################################
-# Project, sources and paths
+# Project, target, sources and paths
#
# Define project name here
PROJECT = ch
-# Imported source files and paths
-CHIBIOS = ../../..
+# Target settings.
+MCU = cortex-m4
+
+# Imported source files and paths.
+CHIBIOS := ../../..
+CONFDIR := ./cfg
+BUILDDIR := ./build
+DEPDIR := ./.dep
# Licensing files.
include $(CHIBIOS)/os/license/license.mk
@@ -100,6 +106,8 @@ include $(CHIBIOS)/os/hal/osal/rt/osal.mk
# RTOS files (optional).
include $(CHIBIOS)/os/rt/rt.mk
include $(CHIBIOS)/os/common/ports/ARMCMx/compilers/GCC/mk/port_v7m.mk
+# Auto-build files in ./source recursively.
+include $(CHIBIOS)/tools/mk/autobuild.mk
# Other files (optional).
include $(CHIBIOS)/test/lib/test.mk
include $(CHIBIOS)/test/rt/rt_test.mk
@@ -120,73 +128,23 @@ CSRC = $(ALLCSRC) \
# setting.
CPPSRC = $(ALLCPPSRC)
-# C sources to be compiled in ARM mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-ACSRC =
-
-# C++ sources to be compiled in ARM mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-ACPPSRC =
-
-# C sources to be compiled in THUMB mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-TCSRC =
-
-# C sources to be compiled in THUMB mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-TCPPSRC =
-
-# List ASM source files here
+# List ASM source files here.
ASMSRC = $(ALLASMSRC)
-ASMXSRC = $(ALLXASMSRC)
-
-INCDIR = $(ALLINC) $(TESTINC)
-#
-# Project, sources and paths
-##############################################################################
-
-##############################################################################
-# Compiler settings
-#
+# List ASM with preprocessor source files here.
+ASMXSRC = $(ALLXASMSRC)
-MCU = cortex-m4
+# Inclusion directories.
+INCDIR = $(CONFDIR) $(ALLINC) $(TESTINC)
-#TRGT = arm-elf-
-TRGT = arm-none-eabi-
-CC = $(TRGT)gcc
-CPPC = $(TRGT)g++
-# Enable loading with g++ only if you need C++ runtime support.
-# NOTE: You can use C++ even without C++ support if you are careful. C++
-# runtime support makes code size explode.
-LD = $(TRGT)gcc
-#LD = $(TRGT)g++
-CP = $(TRGT)objcopy
-AS = $(TRGT)gcc -x assembler-with-cpp
-AR = $(TRGT)ar
-OD = $(TRGT)objdump
-SZ = $(TRGT)size
-HEX = $(CP) -O ihex
-BIN = $(CP) -O binary
-
-# ARM-specific options here
-AOPT =
-
-# THUMB-specific options here
-TOPT = -mthumb -DTHUMB
-
-# Define C warning options here
+# Define C warning options here.
CWARN = -Wall -Wextra -Wundef -Wstrict-prototypes
-# Define C++ warning options here
+# Define C++ warning options here.
CPPWARN = -Wall -Wextra -Wundef
#
-# Compiler settings
+# Project, target, sources and paths
##############################################################################
##############################################################################
@@ -209,8 +167,25 @@ ULIBDIR =
ULIBS =
#
-# End of user defines
+# End of user section
+##############################################################################
+
##############################################################################
+# Common rules
+#
RULESPATH = $(CHIBIOS)/os/common/startup/ARMCMx/compilers/GCC/mk
+include $(RULESPATH)/arm-none-eabi.mk
include $(RULESPATH)/rules.mk
+
+#
+# Common rules
+##############################################################################
+
+##############################################################################
+# Custom rules
+#
+
+#
+# Custom rules
+##############################################################################
diff --git a/demos/STM32/RT-STM32F469I-DISCOVERY/chconf.h b/demos/STM32/RT-STM32F469I-DISCOVERY/cfg/chconf.h
index 6f7e309c7..6f7e309c7 100644
--- a/demos/STM32/RT-STM32F469I-DISCOVERY/chconf.h
+++ b/demos/STM32/RT-STM32F469I-DISCOVERY/cfg/chconf.h
diff --git a/demos/STM32/RT-STM32F469I-DISCOVERY/halconf.h b/demos/STM32/RT-STM32F469I-DISCOVERY/cfg/halconf.h
index 89be0946a..89be0946a 100644
--- a/demos/STM32/RT-STM32F469I-DISCOVERY/halconf.h
+++ b/demos/STM32/RT-STM32F469I-DISCOVERY/cfg/halconf.h
diff --git a/demos/STM32/RT-STM32F469I-DISCOVERY/mcuconf.h b/demos/STM32/RT-STM32F469I-DISCOVERY/cfg/mcuconf.h
index 44f0b055f..44f0b055f 100644
--- a/demos/STM32/RT-STM32F469I-DISCOVERY/mcuconf.h
+++ b/demos/STM32/RT-STM32F469I-DISCOVERY/cfg/mcuconf.h
diff --git a/demos/STM32/RT-STM32F722ZE-NUCLEO144/Makefile b/demos/STM32/RT-STM32F722ZE-NUCLEO144/Makefile
index d50a9abbb..aca95dce7 100644
--- a/demos/STM32/RT-STM32F722ZE-NUCLEO144/Makefile
+++ b/demos/STM32/RT-STM32F722ZE-NUCLEO144/Makefile
@@ -18,7 +18,7 @@ ifeq ($(USE_CPPOPT),)
USE_CPPOPT = -fno-rtti
endif
-# Enable this if you want the linker to remove unused code and data
+# Enable this if you want the linker to remove unused code and data.
ifeq ($(USE_LINK_GC),)
USE_LINK_GC = yes
endif
@@ -28,16 +28,11 @@ ifeq ($(USE_LDOPT),)
USE_LDOPT =
endif
-# Enable this if you want link time optimizations (LTO)
+# Enable this if you want link time optimizations (LTO).
ifeq ($(USE_LTO),)
USE_LTO = yes
endif
-# If enabled, this option allows to compile the application in THUMB mode.
-ifeq ($(USE_THUMB),)
- USE_THUMB = yes
-endif
-
# Enable this if you want to see the full log while compiling.
ifeq ($(USE_VERBOSE_COMPILE),)
USE_VERBOSE_COMPILE = no
@@ -76,7 +71,7 @@ endif
# FPU-related options.
ifeq ($(USE_FPU_OPT),)
- USE_FPU_OPT = -mfloat-abi=$(USE_FPU) -mfpu=fpv5-sp-d16 -fsingle-precision-constant
+ USE_FPU_OPT = -mfloat-abi=$(USE_FPU) -mfpu=fpv5-sp-d16
endif
#
@@ -84,14 +79,20 @@ endif
##############################################################################
##############################################################################
-# Project, sources and paths
+# Project, target, sources and paths
#
# Define project name here
PROJECT = ch
-# Imported source files and paths
-CHIBIOS = ../../..
+# Target settings.
+MCU = cortex-m4
+
+# Imported source files and paths.
+CHIBIOS := ../../..
+CONFDIR := ./cfg
+BUILDDIR := ./build
+DEPDIR := ./.dep
# Licensing files.
include $(CHIBIOS)/os/license/license.mk
@@ -105,6 +106,8 @@ include $(CHIBIOS)/os/hal/osal/rt/osal.mk
# RTOS files (optional).
include $(CHIBIOS)/os/rt/rt.mk
include $(CHIBIOS)/os/common/ports/ARMCMx/compilers/GCC/mk/port_v7m.mk
+# Auto-build files in ./source recursively.
+include $(CHIBIOS)/tools/mk/autobuild.mk
# Other files (optional).
include $(CHIBIOS)/test/lib/test.mk
include $(CHIBIOS)/test/rt/rt_test.mk
@@ -123,73 +126,23 @@ CSRC = $(ALLCSRC) \
# setting.
CPPSRC = $(ALLCPPSRC)
-# C sources to be compiled in ARM mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-ACSRC =
-
-# C++ sources to be compiled in ARM mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-ACPPSRC =
-
-# C sources to be compiled in THUMB mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-TCSRC =
-
-# C sources to be compiled in THUMB mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-TCPPSRC =
-
-# List ASM source files here
+# List ASM source files here.
ASMSRC = $(ALLASMSRC)
-ASMXSRC = $(ALLXASMSRC)
-
-INCDIR = $(ALLINC) $(TESTINC)
-#
-# Project, sources and paths
-##############################################################################
+# List ASM with preprocessor source files here.
+ASMXSRC = $(ALLXASMSRC)
-##############################################################################
-# Compiler settings
-#
+# Inclusion directories.
+INCDIR = $(CONFDIR) $(ALLINC) $(TESTINC)
-MCU = cortex-m7
-
-#TRGT = arm-elf-
-TRGT = arm-none-eabi-
-CC = $(TRGT)gcc
-CPPC = $(TRGT)g++
-# Enable loading with g++ only if you need C++ runtime support.
-# NOTE: You can use C++ even without C++ support if you are careful. C++
-# runtime support makes code size explode.
-LD = $(TRGT)gcc
-#LD = $(TRGT)g++
-CP = $(TRGT)objcopy
-AS = $(TRGT)gcc -x assembler-with-cpp
-AR = $(TRGT)ar
-OD = $(TRGT)objdump
-SZ = $(TRGT)size
-HEX = $(CP) -O ihex
-BIN = $(CP) -O binary
-
-# ARM-specific options here
-AOPT =
-
-# THUMB-specific options here
-TOPT = -mthumb -DTHUMB
-
-# Define C warning options here
+# Define C warning options here.
CWARN = -Wall -Wextra -Wundef -Wstrict-prototypes
-# Define C++ warning options here
+# Define C++ warning options here.
CPPWARN = -Wall -Wextra -Wundef
#
-# Compiler settings
+# Project, target, sources and paths
##############################################################################
##############################################################################
@@ -212,8 +165,25 @@ ULIBDIR =
ULIBS =
#
-# End of user defines
+# End of user section
+##############################################################################
+
##############################################################################
+# Common rules
+#
RULESPATH = $(CHIBIOS)/os/common/startup/ARMCMx/compilers/GCC/mk
+include $(RULESPATH)/arm-none-eabi.mk
include $(RULESPATH)/rules.mk
+
+#
+# Common rules
+##############################################################################
+
+##############################################################################
+# Custom rules
+#
+
+#
+# Custom rules
+##############################################################################
diff --git a/demos/STM32/RT-STM32F722ZE-NUCLEO144/chconf.h b/demos/STM32/RT-STM32F722ZE-NUCLEO144/cfg/chconf.h
index a7343edc2..a7343edc2 100644
--- a/demos/STM32/RT-STM32F722ZE-NUCLEO144/chconf.h
+++ b/demos/STM32/RT-STM32F722ZE-NUCLEO144/cfg/chconf.h
diff --git a/demos/STM32/RT-STM32F722ZE-NUCLEO144/halconf.h b/demos/STM32/RT-STM32F722ZE-NUCLEO144/cfg/halconf.h
index 89be0946a..89be0946a 100644
--- a/demos/STM32/RT-STM32F722ZE-NUCLEO144/halconf.h
+++ b/demos/STM32/RT-STM32F722ZE-NUCLEO144/cfg/halconf.h
diff --git a/demos/STM32/RT-STM32F722ZE-NUCLEO144/mcuconf.h b/demos/STM32/RT-STM32F722ZE-NUCLEO144/cfg/mcuconf.h
index 74b252f7a..74b252f7a 100644
--- a/demos/STM32/RT-STM32F722ZE-NUCLEO144/mcuconf.h
+++ b/demos/STM32/RT-STM32F722ZE-NUCLEO144/cfg/mcuconf.h
diff --git a/demos/STM32/RT-STM32F746G-DISCOVERY/Makefile b/demos/STM32/RT-STM32F746G-DISCOVERY/Makefile
index 67f123758..2f214843d 100644
--- a/demos/STM32/RT-STM32F746G-DISCOVERY/Makefile
+++ b/demos/STM32/RT-STM32F746G-DISCOVERY/Makefile
@@ -33,11 +33,6 @@ ifeq ($(USE_LTO),)
USE_LTO = yes
endif
-# If enabled, this option allows to compile the application in THUMB mode.
-ifeq ($(USE_THUMB),)
- USE_THUMB = yes
-endif
-
# Enable this if you want to see the full log while compiling.
ifeq ($(USE_VERBOSE_COMPILE),)
USE_VERBOSE_COMPILE = no
@@ -76,7 +71,7 @@ endif
# FPU-related options.
ifeq ($(USE_FPU_OPT),)
- USE_FPU_OPT = -mfloat-abi=$(USE_FPU) -mfpu=fpv5-sp-d16 -fsingle-precision-constant
+ USE_FPU_OPT = -mfloat-abi=$(USE_FPU) -mfpu=fpv5-sp-d16
endif
#
@@ -84,14 +79,17 @@ endif
##############################################################################
##############################################################################
-# Project, sources and paths
+# Project, target, sources and paths
#
# Define project name here
PROJECT = ch
-# Imported source files and paths
-CHIBIOS = ../../..
+# Target settings.
+MCU = cortex-m4
+
+# Imported source files and paths.
+CHIBIOS := ../../..
CONFDIR := ./cfg
BUILDDIR := ./build
DEPDIR := ./.dep
@@ -128,34 +126,23 @@ CSRC = $(ALLCSRC) \
# setting.
CPPSRC = $(ALLCPPSRC)
-# C sources to be compiled in ARM mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-ACSRC =
-
-# C++ sources to be compiled in ARM mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-ACPPSRC =
-
-# C sources to be compiled in THUMB mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-TCSRC =
-
-# C sources to be compiled in THUMB mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-TCPPSRC =
-
# List ASM source files here.
ASMSRC = $(ALLASMSRC)
+
+# List ASM with preprocessor source files here.
ASMXSRC = $(ALLXASMSRC)
+# Inclusion directories.
INCDIR = $(CONFDIR) $(ALLINC) $(TESTINC)
+# Define C warning options here.
+CWARN = -Wall -Wextra -Wundef -Wstrict-prototypes
+
+# Define C++ warning options here.
+CPPWARN = -Wall -Wextra -Wundef
+
#
-# Project, sources and paths
+# Project, target, sources and paths
##############################################################################
##############################################################################
@@ -182,43 +169,21 @@ ULIBS =
##############################################################################
##############################################################################
-# Compiler settings
+# Common rules
#
-MCU = cortex-m7
-
-#TRGT = arm-elf-
-TRGT = arm-none-eabi-
-CC = $(TRGT)gcc
-CPPC = $(TRGT)g++
-# Enable loading with g++ only if you need C++ runtime support.
-# NOTE: You can use C++ even without C++ support if you are careful. C++
-# runtime support makes code size explode.
-LD = $(TRGT)gcc
-#LD = $(TRGT)g++
-CP = $(TRGT)objcopy
-AS = $(TRGT)gcc -x assembler-with-cpp
-AR = $(TRGT)ar
-OD = $(TRGT)objdump
-SZ = $(TRGT)size
-HEX = $(CP) -O ihex
-BIN = $(CP) -O binary
-
-# ARM-specific options here
-AOPT =
-
-# THUMB-specific options here
-TOPT = -mthumb -DTHUMB
-
-# Define C warning options here
-CWARN = -Wall -Wextra -Wundef -Wstrict-prototypes
-
-# Define C++ warning options here
-CPPWARN = -Wall -Wextra -Wundef
+RULESPATH = $(CHIBIOS)/os/common/startup/ARMCMx/compilers/GCC/mk
+include $(RULESPATH)/arm-none-eabi.mk
+include $(RULESPATH)/rules.mk
#
-# Compiler settings
+# Common rules
##############################################################################
-RULESPATH = $(CHIBIOS)/os/common/startup/ARMCMx/compilers/GCC/mk
-include $(RULESPATH)/rules.mk
+##############################################################################
+# Custom rules
+#
+
+#
+# Custom rules
+##############################################################################
diff --git a/demos/STM32/RT-STM32F746ZG-NUCLEO144/Makefile b/demos/STM32/RT-STM32F746ZG-NUCLEO144/Makefile
index f698cdda1..a64a649ca 100644
--- a/demos/STM32/RT-STM32F746ZG-NUCLEO144/Makefile
+++ b/demos/STM32/RT-STM32F746ZG-NUCLEO144/Makefile
@@ -18,7 +18,7 @@ ifeq ($(USE_CPPOPT),)
USE_CPPOPT = -fno-rtti
endif
-# Enable this if you want the linker to remove unused code and data
+# Enable this if you want the linker to remove unused code and data.
ifeq ($(USE_LINK_GC),)
USE_LINK_GC = yes
endif
@@ -28,16 +28,11 @@ ifeq ($(USE_LDOPT),)
USE_LDOPT =
endif
-# Enable this if you want link time optimizations (LTO)
+# Enable this if you want link time optimizations (LTO).
ifeq ($(USE_LTO),)
USE_LTO = yes
endif
-# If enabled, this option allows to compile the application in THUMB mode.
-ifeq ($(USE_THUMB),)
- USE_THUMB = yes
-endif
-
# Enable this if you want to see the full log while compiling.
ifeq ($(USE_VERBOSE_COMPILE),)
USE_VERBOSE_COMPILE = no
@@ -76,7 +71,7 @@ endif
# FPU-related options.
ifeq ($(USE_FPU_OPT),)
- USE_FPU_OPT = -mfloat-abi=$(USE_FPU) -mfpu=fpv5-sp-d16 -fsingle-precision-constant
+ USE_FPU_OPT = -mfloat-abi=$(USE_FPU) -mfpu=fpv5-sp-d16
endif
#
@@ -84,14 +79,20 @@ endif
##############################################################################
##############################################################################
-# Project, sources and paths
+# Project, target, sources and paths
#
# Define project name here
PROJECT = ch
-# Imported source files and paths
-CHIBIOS = ../../..
+# Target settings.
+MCU = cortex-m4
+
+# Imported source files and paths.
+CHIBIOS := ../../..
+CONFDIR := ./cfg
+BUILDDIR := ./build
+DEPDIR := ./.dep
# Licensing files.
include $(CHIBIOS)/os/license/license.mk
@@ -105,6 +106,8 @@ include $(CHIBIOS)/os/hal/osal/rt/osal.mk
# RTOS files (optional).
include $(CHIBIOS)/os/rt/rt.mk
include $(CHIBIOS)/os/common/ports/ARMCMx/compilers/GCC/mk/port_v7m.mk
+# Auto-build files in ./source recursively.
+include $(CHIBIOS)/tools/mk/autobuild.mk
# Other files (optional).
include $(CHIBIOS)/test/lib/test.mk
include $(CHIBIOS)/test/rt/rt_test.mk
@@ -123,73 +126,23 @@ CSRC = $(ALLCSRC) \
# setting.
CPPSRC = $(ALLCPPSRC)
-# C sources to be compiled in ARM mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-ACSRC =
-
-# C++ sources to be compiled in ARM mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-ACPPSRC =
-
-# C sources to be compiled in THUMB mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-TCSRC =
-
-# C sources to be compiled in THUMB mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-TCPPSRC =
-
-# List ASM source files here
+# List ASM source files here.
ASMSRC = $(ALLASMSRC)
-ASMXSRC = $(ALLXASMSRC)
-
-INCDIR = $(ALLINC) $(TESTINC)
-#
-# Project, sources and paths
-##############################################################################
+# List ASM with preprocessor source files here.
+ASMXSRC = $(ALLXASMSRC)
-##############################################################################
-# Compiler settings
-#
+# Inclusion directories.
+INCDIR = $(CONFDIR) $(ALLINC) $(TESTINC)
-MCU = cortex-m7
-
-#TRGT = arm-elf-
-TRGT = arm-none-eabi-
-CC = $(TRGT)gcc
-CPPC = $(TRGT)g++
-# Enable loading with g++ only if you need C++ runtime support.
-# NOTE: You can use C++ even without C++ support if you are careful. C++
-# runtime support makes code size explode.
-LD = $(TRGT)gcc
-#LD = $(TRGT)g++
-CP = $(TRGT)objcopy
-AS = $(TRGT)gcc -x assembler-with-cpp
-AR = $(TRGT)ar
-OD = $(TRGT)objdump
-SZ = $(TRGT)size
-HEX = $(CP) -O ihex
-BIN = $(CP) -O binary
-
-# ARM-specific options here
-AOPT =
-
-# THUMB-specific options here
-TOPT = -mthumb -DTHUMB
-
-# Define C warning options here
+# Define C warning options here.
CWARN = -Wall -Wextra -Wundef -Wstrict-prototypes
-# Define C++ warning options here
+# Define C++ warning options here.
CPPWARN = -Wall -Wextra -Wundef
#
-# Compiler settings
+# Project, target, sources and paths
##############################################################################
##############################################################################
@@ -212,8 +165,25 @@ ULIBDIR =
ULIBS =
#
-# End of user defines
+# End of user section
+##############################################################################
+
##############################################################################
+# Common rules
+#
RULESPATH = $(CHIBIOS)/os/common/startup/ARMCMx/compilers/GCC/mk
+include $(RULESPATH)/arm-none-eabi.mk
include $(RULESPATH)/rules.mk
+
+#
+# Common rules
+##############################################################################
+
+##############################################################################
+# Custom rules
+#
+
+#
+# Custom rules
+##############################################################################
diff --git a/demos/STM32/RT-STM32F746ZG-NUCLEO144/chconf.h b/demos/STM32/RT-STM32F746ZG-NUCLEO144/cfg/chconf.h
index a7343edc2..a7343edc2 100644
--- a/demos/STM32/RT-STM32F746ZG-NUCLEO144/chconf.h
+++ b/demos/STM32/RT-STM32F746ZG-NUCLEO144/cfg/chconf.h
diff --git a/demos/STM32/RT-STM32F746ZG-NUCLEO144/halconf.h b/demos/STM32/RT-STM32F746ZG-NUCLEO144/cfg/halconf.h
index 89be0946a..89be0946a 100644
--- a/demos/STM32/RT-STM32F746ZG-NUCLEO144/halconf.h
+++ b/demos/STM32/RT-STM32F746ZG-NUCLEO144/cfg/halconf.h
diff --git a/demos/STM32/RT-STM32F746ZG-NUCLEO144/mcuconf.h b/demos/STM32/RT-STM32F746ZG-NUCLEO144/cfg/mcuconf.h
index ac85ea28c..ac85ea28c 100644
--- a/demos/STM32/RT-STM32F746ZG-NUCLEO144/mcuconf.h
+++ b/demos/STM32/RT-STM32F746ZG-NUCLEO144/cfg/mcuconf.h
diff --git a/demos/STM32/RT-STM32F756ZG-NUCLEO144/Makefile b/demos/STM32/RT-STM32F756ZG-NUCLEO144/Makefile
index 2bc493c2d..603d34ea5 100644
--- a/demos/STM32/RT-STM32F756ZG-NUCLEO144/Makefile
+++ b/demos/STM32/RT-STM32F756ZG-NUCLEO144/Makefile
@@ -18,7 +18,7 @@ ifeq ($(USE_CPPOPT),)
USE_CPPOPT = -fno-rtti
endif
-# Enable this if you want the linker to remove unused code and data
+# Enable this if you want the linker to remove unused code and data.
ifeq ($(USE_LINK_GC),)
USE_LINK_GC = yes
endif
@@ -28,16 +28,11 @@ ifeq ($(USE_LDOPT),)
USE_LDOPT =
endif
-# Enable this if you want link time optimizations (LTO)
+# Enable this if you want link time optimizations (LTO).
ifeq ($(USE_LTO),)
USE_LTO = yes
endif
-# If enabled, this option allows to compile the application in THUMB mode.
-ifeq ($(USE_THUMB),)
- USE_THUMB = yes
-endif
-
# Enable this if you want to see the full log while compiling.
ifeq ($(USE_VERBOSE_COMPILE),)
USE_VERBOSE_COMPILE = no
@@ -76,7 +71,7 @@ endif
# FPU-related options.
ifeq ($(USE_FPU_OPT),)
- USE_FPU_OPT = -mfloat-abi=$(USE_FPU) -mfpu=fpv5-sp-d16 -fsingle-precision-constant
+ USE_FPU_OPT = -mfloat-abi=$(USE_FPU) -mfpu=fpv5-sp-d16
endif
#
@@ -84,14 +79,20 @@ endif
##############################################################################
##############################################################################
-# Project, sources and paths
+# Project, target, sources and paths
#
# Define project name here
PROJECT = ch
-# Imported source files and paths
-CHIBIOS = ../../..
+# Target settings.
+MCU = cortex-m4
+
+# Imported source files and paths.
+CHIBIOS := ../../..
+CONFDIR := ./cfg
+BUILDDIR := ./build
+DEPDIR := ./.dep
# Licensing files.
include $(CHIBIOS)/os/license/license.mk
@@ -105,6 +106,8 @@ include $(CHIBIOS)/os/hal/osal/rt/osal.mk
# RTOS files (optional).
include $(CHIBIOS)/os/rt/rt.mk
include $(CHIBIOS)/os/common/ports/ARMCMx/compilers/GCC/mk/port_v7m.mk
+# Auto-build files in ./source recursively.
+include $(CHIBIOS)/tools/mk/autobuild.mk
# Other files (optional).
include $(CHIBIOS)/test/lib/test.mk
include $(CHIBIOS)/test/rt/rt_test.mk
@@ -123,73 +126,23 @@ CSRC = $(ALLCSRC) \
# setting.
CPPSRC = $(ALLCPPSRC)
-# C sources to be compiled in ARM mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-ACSRC =
-
-# C++ sources to be compiled in ARM mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-ACPPSRC =
-
-# C sources to be compiled in THUMB mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-TCSRC =
-
-# C sources to be compiled in THUMB mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-TCPPSRC =
-
-# List ASM source files here
+# List ASM source files here.
ASMSRC = $(ALLASMSRC)
-ASMXSRC = $(ALLXASMSRC)
-
-INCDIR = $(ALLINC) $(TESTINC)
-#
-# Project, sources and paths
-##############################################################################
+# List ASM with preprocessor source files here.
+ASMXSRC = $(ALLXASMSRC)
-##############################################################################
-# Compiler settings
-#
+# Inclusion directories.
+INCDIR = $(CONFDIR) $(ALLINC) $(TESTINC)
-MCU = cortex-m7
-
-#TRGT = arm-elf-
-TRGT = arm-none-eabi-
-CC = $(TRGT)gcc
-CPPC = $(TRGT)g++
-# Enable loading with g++ only if you need C++ runtime support.
-# NOTE: You can use C++ even without C++ support if you are careful. C++
-# runtime support makes code size explode.
-LD = $(TRGT)gcc
-#LD = $(TRGT)g++
-CP = $(TRGT)objcopy
-AS = $(TRGT)gcc -x assembler-with-cpp
-AR = $(TRGT)ar
-OD = $(TRGT)objdump
-SZ = $(TRGT)size
-HEX = $(CP) -O ihex
-BIN = $(CP) -O binary
-
-# ARM-specific options here
-AOPT =
-
-# THUMB-specific options here
-TOPT = -mthumb -DTHUMB
-
-# Define C warning options here
+# Define C warning options here.
CWARN = -Wall -Wextra -Wundef -Wstrict-prototypes
-# Define C++ warning options here
+# Define C++ warning options here.
CPPWARN = -Wall -Wextra -Wundef
#
-# Compiler settings
+# Project, target, sources and paths
##############################################################################
##############################################################################
@@ -212,8 +165,25 @@ ULIBDIR =
ULIBS =
#
-# End of user defines
+# End of user section
+##############################################################################
+
##############################################################################
+# Common rules
+#
RULESPATH = $(CHIBIOS)/os/common/startup/ARMCMx/compilers/GCC/mk
+include $(RULESPATH)/arm-none-eabi.mk
include $(RULESPATH)/rules.mk
+
+#
+# Common rules
+##############################################################################
+
+##############################################################################
+# Custom rules
+#
+
+#
+# Custom rules
+##############################################################################
diff --git a/demos/STM32/RT-STM32F756ZG-NUCLEO144/chconf.h b/demos/STM32/RT-STM32F756ZG-NUCLEO144/cfg/chconf.h
index a7343edc2..a7343edc2 100644
--- a/demos/STM32/RT-STM32F756ZG-NUCLEO144/chconf.h
+++ b/demos/STM32/RT-STM32F756ZG-NUCLEO144/cfg/chconf.h
diff --git a/demos/STM32/RT-STM32F756ZG-NUCLEO144/halconf.h b/demos/STM32/RT-STM32F756ZG-NUCLEO144/cfg/halconf.h
index 89be0946a..89be0946a 100644
--- a/demos/STM32/RT-STM32F756ZG-NUCLEO144/halconf.h
+++ b/demos/STM32/RT-STM32F756ZG-NUCLEO144/cfg/halconf.h
diff --git a/demos/STM32/RT-STM32F756ZG-NUCLEO144/mcuconf.h b/demos/STM32/RT-STM32F756ZG-NUCLEO144/cfg/mcuconf.h
index ac85ea28c..ac85ea28c 100644
--- a/demos/STM32/RT-STM32F756ZG-NUCLEO144/mcuconf.h
+++ b/demos/STM32/RT-STM32F756ZG-NUCLEO144/cfg/mcuconf.h
diff --git a/demos/STM32/RT-STM32F767ZI-NUCLEO144/Makefile b/demos/STM32/RT-STM32F767ZI-NUCLEO144/Makefile
index 62715b9cd..d5788905e 100644
--- a/demos/STM32/RT-STM32F767ZI-NUCLEO144/Makefile
+++ b/demos/STM32/RT-STM32F767ZI-NUCLEO144/Makefile
@@ -18,7 +18,7 @@ ifeq ($(USE_CPPOPT),)
USE_CPPOPT = -fno-rtti
endif
-# Enable this if you want the linker to remove unused code and data
+# Enable this if you want the linker to remove unused code and data.
ifeq ($(USE_LINK_GC),)
USE_LINK_GC = yes
endif
@@ -28,16 +28,11 @@ ifeq ($(USE_LDOPT),)
USE_LDOPT =
endif
-# Enable this if you want link time optimizations (LTO)
+# Enable this if you want link time optimizations (LTO).
ifeq ($(USE_LTO),)
USE_LTO = yes
endif
-# If enabled, this option allows to compile the application in THUMB mode.
-ifeq ($(USE_THUMB),)
- USE_THUMB = yes
-endif
-
# Enable this if you want to see the full log while compiling.
ifeq ($(USE_VERBOSE_COMPILE),)
USE_VERBOSE_COMPILE = no
@@ -84,14 +79,20 @@ endif
##############################################################################
##############################################################################
-# Project, sources and paths
+# Project, target, sources and paths
#
# Define project name here
PROJECT = ch
-# Imported source files and paths
-CHIBIOS = ../../..
+# Target settings.
+MCU = cortex-m4
+
+# Imported source files and paths.
+CHIBIOS := ../../..
+CONFDIR := ./cfg
+BUILDDIR := ./build
+DEPDIR := ./.dep
# Licensing files.
include $(CHIBIOS)/os/license/license.mk
@@ -105,6 +106,8 @@ include $(CHIBIOS)/os/hal/osal/rt/osal.mk
# RTOS files (optional).
include $(CHIBIOS)/os/rt/rt.mk
include $(CHIBIOS)/os/common/ports/ARMCMx/compilers/GCC/mk/port_v7m.mk
+# Auto-build files in ./source recursively.
+include $(CHIBIOS)/tools/mk/autobuild.mk
# Other files (optional).
include $(CHIBIOS)/test/lib/test.mk
include $(CHIBIOS)/test/rt/rt_test.mk
@@ -123,73 +126,23 @@ CSRC = $(ALLCSRC) \
# setting.
CPPSRC = $(ALLCPPSRC)
-# C sources to be compiled in ARM mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-ACSRC =
-
-# C++ sources to be compiled in ARM mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-ACPPSRC =
-
-# C sources to be compiled in THUMB mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-TCSRC =
-
-# C sources to be compiled in THUMB mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-TCPPSRC =
-
-# List ASM source files here
+# List ASM source files here.
ASMSRC = $(ALLASMSRC)
-ASMXSRC = $(ALLXASMSRC)
-
-INCDIR = $(ALLINC) $(TESTINC)
-#
-# Project, sources and paths
-##############################################################################
+# List ASM with preprocessor source files here.
+ASMXSRC = $(ALLXASMSRC)
-##############################################################################
-# Compiler settings
-#
+# Inclusion directories.
+INCDIR = $(CONFDIR) $(ALLINC) $(TESTINC)
-MCU = cortex-m7
-
-#TRGT = arm-elf-
-TRGT = arm-none-eabi-
-CC = $(TRGT)gcc
-CPPC = $(TRGT)g++
-# Enable loading with g++ only if you need C++ runtime support.
-# NOTE: You can use C++ even without C++ support if you are careful. C++
-# runtime support makes code size explode.
-LD = $(TRGT)gcc
-#LD = $(TRGT)g++
-CP = $(TRGT)objcopy
-AS = $(TRGT)gcc -x assembler-with-cpp
-AR = $(TRGT)ar
-OD = $(TRGT)objdump
-SZ = $(TRGT)size
-HEX = $(CP) -O ihex
-BIN = $(CP) -O binary
-
-# ARM-specific options here
-AOPT =
-
-# THUMB-specific options here
-TOPT = -mthumb -DTHUMB
-
-# Define C warning options here
+# Define C warning options here.
CWARN = -Wall -Wextra -Wundef -Wstrict-prototypes
-# Define C++ warning options here
+# Define C++ warning options here.
CPPWARN = -Wall -Wextra -Wundef
#
-# Compiler settings
+# Project, target, sources and paths
##############################################################################
##############################################################################
@@ -212,8 +165,25 @@ ULIBDIR =
ULIBS =
#
-# End of user defines
+# End of user section
+##############################################################################
+
##############################################################################
+# Common rules
+#
RULESPATH = $(CHIBIOS)/os/common/startup/ARMCMx/compilers/GCC/mk
+include $(RULESPATH)/arm-none-eabi.mk
include $(RULESPATH)/rules.mk
+
+#
+# Common rules
+##############################################################################
+
+##############################################################################
+# Custom rules
+#
+
+#
+# Custom rules
+##############################################################################
diff --git a/demos/STM32/RT-STM32F767ZI-NUCLEO144/chconf.h b/demos/STM32/RT-STM32F767ZI-NUCLEO144/cfg/chconf.h
index a7343edc2..a7343edc2 100644
--- a/demos/STM32/RT-STM32F767ZI-NUCLEO144/chconf.h
+++ b/demos/STM32/RT-STM32F767ZI-NUCLEO144/cfg/chconf.h
diff --git a/demos/STM32/RT-STM32F767ZI-NUCLEO144/halconf.h b/demos/STM32/RT-STM32F767ZI-NUCLEO144/cfg/halconf.h
index 89be0946a..89be0946a 100644
--- a/demos/STM32/RT-STM32F767ZI-NUCLEO144/halconf.h
+++ b/demos/STM32/RT-STM32F767ZI-NUCLEO144/cfg/halconf.h
diff --git a/demos/STM32/RT-STM32F767ZI-NUCLEO144/mcuconf.h b/demos/STM32/RT-STM32F767ZI-NUCLEO144/cfg/mcuconf.h
index a0f6a6c75..a0f6a6c75 100644
--- a/demos/STM32/RT-STM32F767ZI-NUCLEO144/mcuconf.h
+++ b/demos/STM32/RT-STM32F767ZI-NUCLEO144/cfg/mcuconf.h
diff --git a/demos/STM32/RT-STM32F769I-DISCOVERY/Makefile b/demos/STM32/RT-STM32F769I-DISCOVERY/Makefile
index f8cd3e2ab..959e80407 100644
--- a/demos/STM32/RT-STM32F769I-DISCOVERY/Makefile
+++ b/demos/STM32/RT-STM32F769I-DISCOVERY/Makefile
@@ -18,7 +18,7 @@ ifeq ($(USE_CPPOPT),)
USE_CPPOPT = -fno-rtti
endif
-# Enable this if you want the linker to remove unused code and data
+# Enable this if you want the linker to remove unused code and data.
ifeq ($(USE_LINK_GC),)
USE_LINK_GC = yes
endif
@@ -28,16 +28,11 @@ ifeq ($(USE_LDOPT),)
USE_LDOPT =
endif
-# Enable this if you want link time optimizations (LTO)
+# Enable this if you want link time optimizations (LTO).
ifeq ($(USE_LTO),)
USE_LTO = yes
endif
-# If enabled, this option allows to compile the application in THUMB mode.
-ifeq ($(USE_THUMB),)
- USE_THUMB = yes
-endif
-
# Enable this if you want to see the full log while compiling.
ifeq ($(USE_VERBOSE_COMPILE),)
USE_VERBOSE_COMPILE = no
@@ -84,14 +79,20 @@ endif
##############################################################################
##############################################################################
-# Project, sources and paths
+# Project, target, sources and paths
#
# Define project name here
PROJECT = ch
-# Imported source files and paths
-CHIBIOS = ../../..
+# Target settings.
+MCU = cortex-m4
+
+# Imported source files and paths.
+CHIBIOS := ../../..
+CONFDIR := ./cfg
+BUILDDIR := ./build
+DEPDIR := ./.dep
# Licensing files.
include $(CHIBIOS)/os/license/license.mk
@@ -105,6 +106,8 @@ include $(CHIBIOS)/os/hal/osal/rt/osal.mk
# RTOS files (optional).
include $(CHIBIOS)/os/rt/rt.mk
include $(CHIBIOS)/os/common/ports/ARMCMx/compilers/GCC/mk/port_v7m.mk
+# Auto-build files in ./source recursively.
+include $(CHIBIOS)/tools/mk/autobuild.mk
# Other files (optional).
include $(CHIBIOS)/test/lib/test.mk
include $(CHIBIOS)/test/rt/rt_test.mk
@@ -123,73 +126,23 @@ CSRC = $(ALLCSRC) \
# setting.
CPPSRC = $(ALLCPPSRC)
-# C sources to be compiled in ARM mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-ACSRC =
-
-# C++ sources to be compiled in ARM mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-ACPPSRC =
-
-# C sources to be compiled in THUMB mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-TCSRC =
-
-# C sources to be compiled in THUMB mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-TCPPSRC =
-
-# List ASM source files here
+# List ASM source files here.
ASMSRC = $(ALLASMSRC)
-ASMXSRC = $(ALLXASMSRC)
-
-INCDIR = $(ALLINC) $(TESTINC)
-#
-# Project, sources and paths
-##############################################################################
+# List ASM with preprocessor source files here.
+ASMXSRC = $(ALLXASMSRC)
-##############################################################################
-# Compiler settings
-#
+# Inclusion directories.
+INCDIR = $(CONFDIR) $(ALLINC) $(TESTINC)
-MCU = cortex-m7
-
-#TRGT = arm-elf-
-TRGT = arm-none-eabi-
-CC = $(TRGT)gcc
-CPPC = $(TRGT)g++
-# Enable loading with g++ only if you need C++ runtime support.
-# NOTE: You can use C++ even without C++ support if you are careful. C++
-# runtime support makes code size explode.
-LD = $(TRGT)gcc
-#LD = $(TRGT)g++
-CP = $(TRGT)objcopy
-AS = $(TRGT)gcc -x assembler-with-cpp
-AR = $(TRGT)ar
-OD = $(TRGT)objdump
-SZ = $(TRGT)size
-HEX = $(CP) -O ihex
-BIN = $(CP) -O binary
-
-# ARM-specific options here
-AOPT =
-
-# THUMB-specific options here
-TOPT = -mthumb -DTHUMB
-
-# Define C warning options here
+# Define C warning options here.
CWARN = -Wall -Wextra -Wundef -Wstrict-prototypes
-# Define C++ warning options here
+# Define C++ warning options here.
CPPWARN = -Wall -Wextra -Wundef
#
-# Compiler settings
+# Project, target, sources and paths
##############################################################################
##############################################################################
@@ -212,8 +165,25 @@ ULIBDIR =
ULIBS =
#
-# End of user defines
+# End of user section
+##############################################################################
+
##############################################################################
+# Common rules
+#
RULESPATH = $(CHIBIOS)/os/common/startup/ARMCMx/compilers/GCC/mk
+include $(RULESPATH)/arm-none-eabi.mk
include $(RULESPATH)/rules.mk
+
+#
+# Common rules
+##############################################################################
+
+##############################################################################
+# Custom rules
+#
+
+#
+# Custom rules
+##############################################################################
diff --git a/demos/STM32/RT-STM32F769I-DISCOVERY/chconf.h b/demos/STM32/RT-STM32F769I-DISCOVERY/cfg/chconf.h
index a7343edc2..a7343edc2 100644
--- a/demos/STM32/RT-STM32F769I-DISCOVERY/chconf.h
+++ b/demos/STM32/RT-STM32F769I-DISCOVERY/cfg/chconf.h
diff --git a/demos/STM32/RT-STM32F769I-DISCOVERY/halconf.h b/demos/STM32/RT-STM32F769I-DISCOVERY/cfg/halconf.h
index 89be0946a..89be0946a 100644
--- a/demos/STM32/RT-STM32F769I-DISCOVERY/halconf.h
+++ b/demos/STM32/RT-STM32F769I-DISCOVERY/cfg/halconf.h
diff --git a/demos/STM32/RT-STM32F769I-DISCOVERY/mcuconf.h b/demos/STM32/RT-STM32F769I-DISCOVERY/cfg/mcuconf.h
index 5e65ced87..5e65ced87 100644
--- a/demos/STM32/RT-STM32F769I-DISCOVERY/mcuconf.h
+++ b/demos/STM32/RT-STM32F769I-DISCOVERY/cfg/mcuconf.h
diff --git a/demos/STM32/RT-STM32H743I-NUCLEO144/Makefile b/demos/STM32/RT-STM32H743I-NUCLEO144/Makefile
index 611d26147..d64af803d 100644
--- a/demos/STM32/RT-STM32H743I-NUCLEO144/Makefile
+++ b/demos/STM32/RT-STM32H743I-NUCLEO144/Makefile
@@ -18,7 +18,7 @@ ifeq ($(USE_CPPOPT),)
USE_CPPOPT = -fno-rtti
endif
-# Enable this if you want the linker to remove unused code and data
+# Enable this if you want the linker to remove unused code and data.
ifeq ($(USE_LINK_GC),)
USE_LINK_GC = yes
endif
@@ -28,16 +28,11 @@ ifeq ($(USE_LDOPT),)
USE_LDOPT =
endif
-# Enable this if you want link time optimizations (LTO)
+# Enable this if you want link time optimizations (LTO).
ifeq ($(USE_LTO),)
USE_LTO = yes
endif
-# If enabled, this option allows to compile the application in THUMB mode.
-ifeq ($(USE_THUMB),)
- USE_THUMB = yes
-endif
-
# Enable this if you want to see the full log while compiling.
ifeq ($(USE_VERBOSE_COMPILE),)
USE_VERBOSE_COMPILE = no
@@ -76,7 +71,7 @@ endif
# FPU-related options.
ifeq ($(USE_FPU_OPT),)
- USE_FPU_OPT = -mfloat-abi=$(USE_FPU) -mfpu=fpv5-sp-d16
+ USE_FPU_OPT = -mfloat-abi=$(USE_FPU) -mfpu=fpv5-d16
endif
#
@@ -84,15 +79,18 @@ endif
##############################################################################
##############################################################################
-# Project, sources and paths
+# Project, target, sources and paths
#
# Define project name here
PROJECT = ch
-# Imported source files and paths
+# Target settings.
+MCU = cortex-m4
+
+# Imported source files and paths.
CHIBIOS := ../../..
-CONFDIR := .
+CONFDIR := ./cfg
BUILDDIR := ./build
DEPDIR := ./.dep
@@ -128,34 +126,23 @@ CSRC = $(ALLCSRC) \
# setting.
CPPSRC = $(ALLCPPSRC)
-# C sources to be compiled in ARM mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-ACSRC =
+# List ASM source files here.
+ASMSRC = $(ALLASMSRC)
-# C++ sources to be compiled in ARM mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-ACPPSRC =
-
-# C sources to be compiled in THUMB mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-TCSRC =
+# List ASM with preprocessor source files here.
+ASMXSRC = $(ALLXASMSRC)
-# C sources to be compiled in THUMB mode regardless of the global setting.
-# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
-# option that results in lower performance and larger code size.
-TCPPSRC =
+# Inclusion directories.
+INCDIR = $(CONFDIR) $(ALLINC) $(TESTINC)
-# List ASM source files here
-ASMSRC = $(ALLASMSRC) $(ALLASMSRC)
-ASMXSRC = $(ALLXASMSRC)
+# Define C warning options here.
+CWARN = -Wall -Wextra -Wundef -Wstrict-prototypes
-INCDIR = $(ALLINC) $(TESTINC)
+# Define C++ warning options here.
+CPPWARN = -Wall -Wextra -Wundef
#
-# Project, sources and paths
+# Project, target, sources and paths
##############################################################################
##############################################################################
@@ -182,43 +169,21 @@ ULIBS =
##############################################################################
##############################################################################
-# Compiler settings
+# Common rules
#
-MCU = cortex-m7
-
-#TRGT = arm-elf-
-TRGT = arm-none-eabi-
-CC = $(TRGT)gcc
-CPPC = $(TRGT)g++
-# Enable loading with g++ only if you need C++ runtime support.
-# NOTE: You can use C++ even without C++ support if you are careful. C++
-# runtime support makes code size explode.
-LD = $(TRGT)gcc
-#LD = $(TRGT)g++
-CP = $(TRGT)objcopy
-AS = $(TRGT)gcc -x assembler-with-cpp
-AR = $(TRGT)ar
-OD = $(TRGT)objdump
-SZ = $(TRGT)size
-HEX = $(CP) -O ihex
-BIN = $(CP) -O binary
-
-# ARM-specific options here
-AOPT =
-
-# THUMB-specific options here
-TOPT = -mthumb -DTHUMB
-
-# Define C warning options here
-CWARN = -Wall -Wextra -Wundef -Wstrict-prototypes
-
-# Define C++ warning options here
-CPPWARN = -Wall -Wextra -Wundef
+RULESPATH = $(CHIBIOS)/os/common/startup/ARMCMx/compilers/GCC/mk
+include $(RULESPATH)/arm-none-eabi.mk
+include $(RULESPATH)/rules.mk
#
-# Compiler settings
+# Common rules
##############################################################################
-RULESPATH = $(CHIBIOS)/os/common/startup/ARMCMx/compilers/GCC/mk
-include $(RULESPATH)/rules.mk
+##############################################################################
+# Custom rules
+#
+
+#
+# Custom rules
+##############################################################################
diff --git a/demos/STM32/RT-STM32H743I-NUCLEO144/chconf.h b/demos/STM32/RT-STM32H743I-NUCLEO144/cfg/chconf.h
index 6f7e309c7..6f7e309c7 100644
--- a/demos/STM32/RT-STM32H743I-NUCLEO144/chconf.h
+++ b/demos/STM32/RT-STM32H743I-NUCLEO144/cfg/chconf.h
diff --git a/demos/STM32/RT-STM32H743I-NUCLEO144/halconf.h b/demos/STM32/RT-STM32H743I-NUCLEO144/cfg/halconf.h
index 3974e6114..3974e6114 100644
--- a/demos/STM32/RT-STM32H743I-NUCLEO144/halconf.h
+++ b/demos/STM32/RT-STM32H743I-NUCLEO144/cfg/halconf.h
diff --git a/demos/STM32/RT-STM32H743I-NUCLEO144/mcuconf.h b/demos/STM32/RT-STM32H743I-NUCLEO144/cfg/mcuconf.h
index 1b9b3272d..1b9b3272d 100644
--- a/demos/STM32/RT-STM32H743I-NUCLEO144/mcuconf.h
+++ b/demos/STM32/RT-STM32H743I-NUCLEO144/cfg/mcuconf.h