summaryrefslogtreecommitdiff
path: root/tools/cmake/cpu/cortex-m3.cmake
diff options
context:
space:
mode:
Diffstat (limited to 'tools/cmake/cpu/cortex-m3.cmake')
-rw-r--r--tools/cmake/cpu/cortex-m3.cmake12
1 files changed, 9 insertions, 3 deletions
diff --git a/tools/cmake/cpu/cortex-m3.cmake b/tools/cmake/cpu/cortex-m3.cmake
index b740ee44c..f6f5a62f8 100644
--- a/tools/cmake/cpu/cortex-m3.cmake
+++ b/tools/cmake/cpu/cortex-m3.cmake
@@ -1,10 +1,16 @@
if (TOOLCHAIN STREQUAL "gcc")
- list(APPEND TOOLCHAIN_COMMON_FLAGS
+ set(TOOLCHAIN_COMMON_FLAGS
-mthumb
-mcpu=cortex-m3
)
set(FREERTOS_PORT GCC_ARM_CM3 CACHE INTERNAL "")
-else ()
- # TODO support IAR
+
+elseif (TOOLCHAIN STREQUAL "iar")
+ set(TOOLCHAIN_COMMON_FLAGS
+ --cpu cortex-m3
+ )
+
+ set(FREERTOS_PORT IAR_ARM_CM3 CACHE INTERNAL "")
+
endif ()