Tool/software: TI C/C++ Compiler
In trying to compile a SimpleLink TI-RTOS example for the CC2652R1 development board to be MISRA compliant (empty, with tirtos ccs), the following is produced:
Invoking: ARM Compiler
"C:/ti/ccsv8/tools/compiler/ti-cgt-arm_18.1.5.LTS/bin/armcl" -mv7M4 --code_state=16 --float_support=FPv4SPD16 -me --include_path="C:/Users/lcoburn/workspace_v8_first/empty_CC26X2R1_LAUNCHXL_tirtos_ccs" --include_path="C:/ti/simplelink_cc26x2_sdk_2_30_00_34/source/ti/posix/ccs" --include_path="C:/ti/ccsv8/tools/compiler/ti-cgt-arm_18.1.5.LTS/include" --define=DeviceFamily_CC26X2 -g --diag_warning=225 --diag_warning=255 --diag_wrap=off --display_error_number --gen_func_subsections=on --check_misra="all" --preproc_with_compile --preproc_dependency="CC26X2R1_LAUNCHXL.d_raw" --cmd_file="C:/Users/lcoburn/workspace_v8_first/tirtos_builds_CC26X2R1_LAUNCHXL_release_ccs/Debug/configPkg/compiler.opt" "../CC26X2R1_LAUNCHXL.c"
>> Compilation failure
subdir_rules.mk:9: recipe for target 'CC26X2R1_LAUNCHXL.obj' failed
Command-line error #1046: invalid macro definition: xdc_target_types__=ti/targets/arm/elf/std.h
1 catastrophic error detected in the compilation of "../CC26X2R1_LAUNCHXL.c".
Compilation terminated.
gmake: *** [CC26X2R1_LAUNCHXL.obj] Error 1
...
...
Several more such errors occur which leads to a catastrophic error:
>> Compilation failure
subdir_rules.mk:9: recipe for target 'main_tirtos.obj' failed
Command-line error #1046: invalid macro definition: xdc_target_types__=ti/targets/arm/elf/std.h
1 catastrophic error detected in the compilation of "../main_tirtos.c".
Compilation terminated.
gmake: *** [main_tirtos.obj] Error 1
gmake: Target 'all' not remade because of errors.
**** Build Finished ****
I can reduce the level of MISRA support (don't choose all for the compilation flag) which lessens the errors/warnings but still has 'MISRA' issues. Removing MISRA support from the compilation steps allows executable code to be produced.
My question: Is there a MISRA supported SimpleLink "stack" (support files used by the applications we write) that is available? Or I am doing something completely or partially wrong? (my apologies if so :-) )
Thank you,
Lawernce