| From 2d0f9e77a1165aa78f78436a2f5c185cc65ad6c1 Mon Sep 17 00:00:00 2001 |
| From: TTornblom <thomas.tornblom@iar.com> |
| Date: Thu, 16 Apr 2020 13:53:38 +0200 |
| Subject: [PATCH 4/4] BUILD: Update IAR support in CMakeLists.txt |
| |
| Applied the same change as in mbed-crypto for using this as a sub |
| project with the IAR toolchain. |
| |
| Signed-off-by: TTornblom <thomas.tornblom@iar.com> |
| --- |
| CMakeLists.txt | 5 ++++- |
| 1 file changed, 4 insertions(+), 1 deletion(-) |
| |
| diff --git a/CMakeLists.txt b/CMakeLists.txt |
| index a671575b7..3e59a47ba 100644 |
| --- a/CMakeLists.txt |
| +++ b/CMakeLists.txt |
| @@ -193,7 +193,10 @@ if(CMAKE_COMPILER_IS_CLANG) |
| endif(CMAKE_COMPILER_IS_CLANG) |
| |
| if(CMAKE_COMPILER_IS_IAR) |
| - set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} --warn_about_c_style_casts --warnings_are_errors -Ohz") |
| + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} --warn_about_c_style_casts") |
| + set(CMAKE_C_FLAGS_RELEASE "-Ohz") |
| + set(CMAKE_C_FLAGS_DEBUG "--debug -On") |
| + set(CMAKE_C_FLAGS_CHECK "--warnings_are_errors") |
| endif(CMAKE_COMPILER_IS_IAR) |
| |
| if(CMAKE_COMPILER_IS_MSVC) |
| -- |
| 2.20.1 |
| |