blob: 47c7b8aa40ee34202b1ee53f2a1eeec27e691f11 [file] [log] [blame]
Christophe Favergeond3551bf2019-09-26 08:48:51 +01001include(CMakePrintHelpers)
2
Christophe Favergeon26c2f682019-09-06 14:43:32 +01003
Christophe Favergeonaa3cdc52019-09-25 11:31:39 +02004
5include(configLib)
Christophe Favergeonec574202019-08-09 06:54:05 +01006SET(PLATFORMFOLDER ${ROOT}/CMSIS/DSP/Platforms/FVP)
Christophe Favergeon3b2a0ee2019-06-12 13:29:14 +02007include(configPlatform)
8include(configBoot)
Christophe Favergeon6b604eb2019-05-17 13:46:33 +02009
Christophe Favergeon3b2a0ee2019-06-12 13:29:14 +020010define_property(TARGET
11 PROPERTY DISABLEOPTIMIZATION
12 BRIEF_DOCS "Force disabling of optimizations"
13 FULL_DOCS "Force disabling of optimizations")
Christophe Favergeon6b604eb2019-05-17 13:46:33 +020014
Christophe Favergeon3b2a0ee2019-06-12 13:29:14 +020015# Config core settings
16# Configure platform (semihosting etc ...)
17# May be required for some compiler
18function(disableOptimization project)
19 set_target_properties(${project} PROPERTIES DISABLEOPTIMIZATION ON)
20endfunction()
Christophe Favergeon6b604eb2019-05-17 13:46:33 +020021
Christophe Favergeon6b604eb2019-05-17 13:46:33 +020022
Christophe Favergeon3b2a0ee2019-06-12 13:29:14 +020023# Config app
24function (configApp project cmsisRoot)
25 configcore(${project} ${cmsisRoot})
Christophe Favergeonec574202019-08-09 06:54:05 +010026 configboot(${project} ${cmsisRoot} ${PLATFORMFOLDER})
Christophe Favergeon3b2a0ee2019-06-12 13:29:14 +020027 set_platform_core()
28 core_includes(${project})
29 SET(PLATFORMID ${PLATFORMID} PARENT_SCOPE)
30 SET(COREID ${COREID} PARENT_SCOPE)
Christophe Favergeone0181322019-05-20 13:25:14 +020031endfunction()