This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

CODECOMPOSER: CCS Indexer not working when integrating CMake project with CodeComposerStudio

Part Number: CODECOMPOSER
Other Parts Discussed in Thread: AM3359, CCSTUDIO

Hi,

we are using a CMake based built process for our application.

We do not use CodeComposerStudio to build our project we use a specific build command that starts a batch file that launches the CMake build process.

The batch file contains: 

cd %1
mkdir Release
cd Release
cmake .. --preset=TI_armcl
gmake

The only reason for us using CCS now is to be able to use the Blackhawk debugger (USB560 v2 System Trace) we want to load the project files to CodeComposerStudio (V12.2) to run the debugger.

Therefore, we do following steps:

1. Start CCS
2. Open new workspace
3. In CCS click on File->Import->General->Existing Projects into Workspace
4. Next
5. Browse for our sitara-project repository folder and then click Finish
Then, we manually load our target configuration file and can then connect to the CPU (AM3359) and start the debugging.
Now we face following issues:
- With this configuration the build works and we are able to debug but the CCS indexer is not always working, that is for example if using ctrl+right-click (or pressing F3) on a function name often does not browse to the function definition 
Can you help us solving the indexer issue, or do you have a better solution of integrating a CMake project to CCS?
Regards
Timo
  • Hello Timo,

    Please describe what software you are trying to debug.

    Regards,

    Nick

  • Hi Nick,

    thanks for your reply!

    The software we are debugging is our application but debugging is working, this is not the problem, I just wanted to describe the whole process.

    The problem is that navigating through the code for example by pressing F3 key (that is binded to 'Open Declaration') is not working proberly. In many cases (but not always) Code Composer Studio cannot find the corresponding declarations.

    Where does CCS gets this information?

    Regards

    Timo

  • Hello Timo,

    I mean,

    1) is this a Linux userspace application? A TI_RTOS application? etc

    2) Are you running into a specific issue that you are trying to debug with CCS? If so, what is that issue?

    Regards,

    Nick

  • Hi Nick,

    1) It is a TI_RTOS application

    2) No there is no debug issue: debugging works fine

    The issue:

    When the curser is on a funtion name (for example readData()) in CCS and then clicking 'F3' or Ctrl+Left-Mouse-Button following message is shown in CCS:

     'Could not find symbol 'readData' in index'

    and CCS cannot show the declaration of this function (readData()).

    I assume it has to do with the Indexer but also Index->Rebuild does not solve the issue. See following picture that shows the key bindings which do not work:

    Regards

    Timo

  • Hello Timo,

    Ahh, ok. Please keep in mind that we can no longer offer design support for AM335x TI_RTOS on the forums, as per the processor SDK page and this notice on e2e. The notice on e2e has links to a bunch of TI_RTOS resources that may be helpful to you in the future.

    However, I understand now that your question is more about using CCS itself, not specifically about the AM335x. I am sending your thread over to the CCS team to comment.

    Regards,

    Nick

  • Hi Timo,

    The issue:

    When the curser is on a funtion name (for example readData()) in CCS and then clicking 'F3' or Ctrl+Left-Mouse-Button following message is shown in CCS:

     'Could not find symbol 'readData' in index'

    and CCS cannot show the declaration of this function (readData()).

    I assume it has to do with the Indexer but also Index->Rebuild does not solve the issue.

    You are correct, this functionality relies on indexed data via the Indexer. You mentioned that you are importing a project into the workspace. Is this a standard Eclipse managed make project? Is the source file that defines "readData" part of the imported project?

    Thanks

    ki

  • Hi Ki,

    It is not a standard Eclipse managed make project, we are importing the project into the workspace as shown here:

    We use this importing option because we build our sources using a CMake / Make process but use CCS for debugging. 

    Yes, function readData() and its definition is part of the imported project.

    Timo  

  • Can you zip up the project and attach the zip to this thread?

    I don't need the full project. You can strip out much of the content. I just need some sample project that reproduces the issue.

    Thanks

    ki

  • I assume it has to do with the Indexer but also Index->Rebuild does not solve the issue.

    In the CCS project explorer, right-click on one problematic source file and select Index -> Create Parser Log file. Select a file to create for the log file. The parse log file may identify what the problem for indexer is. E.g. failure to find an include file.

    In case it helps, https://github.com/Chester-Gillon/AM3352-SOM-EVB_bare_metal is a project which used CMake to build, and CCS to edit / browse / debug. The project was last used with CCS 8. From memory:

    1. setup_cmake.bat and setup_cmake.sh were the Windows / Linux scripts to set up the CMake build environment. These scripts also created a launch_ccstudio.bat or launch_ccstudio.sh script designed to launch CCS with some environment variables set to allow the Eclipse project to locate the compiler and AM335x StarterWare include files by the Eclipse indexer.
    2. .project and .cproject were the CCS Eclipse project files which allowed the indexer to parse and browse the project. Manually edited the project properties under C/C++ General -> Paths and Symbols to set include directories and Symbols used by the CMake build. The include directories made use of environment variables set by the launch_ccstudio.bat or launch_ccstudio.sh script. The C/C++ Build in the CCS Eclipse project files were selected to run the CMake created make files.
  • CMakeProjectSitaraMinimalExample.zip

    Hi Ki,

    here is an example project showing the issue.

  • Hi Chester Gillon,

    thanks for your reply, I'll take a look at the files.

  • Hi Chester Gillon,

    thanks for your reply, I'll take a look at the files.

    Chester raises an excellent point. Please provide the parser log files also.

    Thank

    ki

  • Hi Ki,

    hi Chester,

    we cloned the repo from Chester Gillon to test if it would be a solution for our issue:

    From our understanding, when executing the batch file

    - there are generated symlinks to the c-compiler so that it can be found in the CCS environment.

    - the starterware root path is added to the CCS start batch so the starterware is available when opening CCS.

    - CMake release and debug makefile are generated

    We still have the same problems in this repo as in our project, that several files cannot be found by the indexer (see attached log file).

    Project:               source
    File:                  file:/C:/src/AM3352-SOM-EVB_bare_metal/source/quick_mmu_enable/quick_mmu_enable.c
    Language:              GNU C
    Index Version:         211.0
    Build Configuration:   Debug
    Context:               none
    Versions in Index:     0
    
    Include Search Path (option -I):
       C:\src\AM3352-SOM-EVB_bare_metal\gcc-arm-none-eabi\lib\gcc\arm-none-eabi\7.2.1\include
       C:\src\AM3352-SOM-EVB_bare_metal\gcc-arm-none-eabi\lib\gcc\arm-none-eabi\7.2.1\include-fixed
       C:\src\AM3352-SOM-EVB_bare_metal\gcc-arm-none-eabi\arm-none-eabi\include
       c:\ti\AM335X_StarterWare_02_00_01_01\include
       c:\ti\AM335X_StarterWare_02_00_01_01\include\hw
       c:\ti\AM335X_StarterWare_02_00_01_01\include\armv7a
       c:\ti\AM335X_StarterWare_02_00_01_01\include\armv7a\am335x
       c:\ti\AM335X_StarterWare_02_00_01_01\bootloader\include
       c:\ti\AM335X_StarterWare_02_00_01_01\third_party\fatfs\src
       c:\ti\AM335X_StarterWare_02_00_01_01\mmcsdlib\include
    
    Macro definitions (option -D):
       am3352=
       AM3352_SOM=
       am335x=
       gcc=
       MMCSD=
       __ACCUM_EPSILON__=0x1P-15K
       __ACCUM_FBIT__=15
       __ACCUM_IBIT__=16
       __ACCUM_MAX__=0X7FFFFFFFP-15K
       __ACCUM_MIN__=(-0X1P15K-0X1P15K)
       __APCS_32__=1
       __ARMEL__=1
       __ARM_32BIT_STATE=1
       __ARM_ARCH=4
       __ARM_ARCH_4T__=1
       __ARM_ARCH_ISA_ARM=1
       __ARM_ARCH_ISA_THUMB=1
       __ARM_EABI__=1
       __ARM_FEATURE_COPROC=1
       __ARM_PCS=1
       __ARM_SIZEOF_MINIMAL_ENUM=1
       __ARM_SIZEOF_WCHAR_T=4
       __arm__=1
       __ATOMIC_ACQUIRE=2
       __ATOMIC_ACQ_REL=4
       __ATOMIC_CONSUME=1
       __ATOMIC_RELAXED=0
       __ATOMIC_RELEASE=3
       __ATOMIC_SEQ_CST=5
       __BIGGEST_ALIGNMENT__=8
       __BYTE_ORDER__=__ORDER_LITTLE_ENDIAN__
       __CHAR16_TYPE__=short unsigned int
       __CHAR32_TYPE__=long unsigned int
       __CHAR_BIT__=8
       __CHAR_UNSIGNED__=1
       __DA_FBIT__=31
       __DA_IBIT__=32
       __DBL_DECIMAL_DIG__=17
       __DBL_DENORM_MIN__=((double)4.9406564584124654e-324L)
       __DBL_DIG__=15
       __DBL_EPSILON__=((double)2.2204460492503131e-16L)
       __DBL_HAS_DENORM__=1
       __DBL_HAS_INFINITY__=1
       __DBL_HAS_QUIET_NAN__=1
       __DBL_MANT_DIG__=53
       __DBL_MAX_10_EXP__=308
       __DBL_MAX_EXP__=1024
       __DBL_MAX__=((double)1.7976931348623157e+308L)
       __DBL_MIN_10_EXP__=(-307)
       __DBL_MIN_EXP__=(-1021)
       __DBL_MIN__=((double)2.2250738585072014e-308L)
       __DEC128_EPSILON__=1E-33DL
       __DEC128_MANT_DIG__=34
       __DEC128_MAX_EXP__=6145
       __DEC128_MAX__=9.999999999999999999999999999999999E6144DL
       __DEC128_MIN_EXP__=(-6142)
       __DEC128_MIN__=1E-6143DL
       __DEC128_SUBNORMAL_MIN__=0.000000000000000000000000000000001E-6143DL
       __DEC32_EPSILON__=1E-6DF
       __DEC32_MANT_DIG__=7
       __DEC32_MAX_EXP__=97
       __DEC32_MAX__=9.999999E96DF
       __DEC32_MIN_EXP__=(-94)
       __DEC32_MIN__=1E-95DF
       __DEC32_SUBNORMAL_MIN__=0.000001E-95DF
       __DEC64_EPSILON__=1E-15DD
       __DEC64_MANT_DIG__=16
       __DEC64_MAX_EXP__=385
       __DEC64_MAX__=9.999999999999999E384DD
       __DEC64_MIN_EXP__=(-382)
       __DEC64_MIN__=1E-383DD
       __DEC64_SUBNORMAL_MIN__=0.000000000000001E-383DD
       __DECIMAL_DIG__=17
       __DEC_EVAL_METHOD__=2
       __DQ_FBIT__=63
       __DQ_IBIT__=0
       __ELF__=1
       __FINITE_MATH_ONLY__=0
       __FLOAT_WORD_ORDER__=__ORDER_LITTLE_ENDIAN__
       __FLT32X_DECIMAL_DIG__=17
       __FLT32X_DENORM_MIN__=4.9406564584124654e-324F32x
       __FLT32X_DIG__=15
       __FLT32X_EPSILON__=2.2204460492503131e-16F32x
       __FLT32X_HAS_DENORM__=1
       __FLT32X_HAS_INFINITY__=1
       __FLT32X_HAS_QUIET_NAN__=1
       __FLT32X_MANT_DIG__=53
       __FLT32X_MAX_10_EXP__=308
       __FLT32X_MAX_EXP__=1024
       __FLT32X_MAX__=1.7976931348623157e+308F32x
       __FLT32X_MIN_10_EXP__=(-307)
       __FLT32X_MIN_EXP__=(-1021)
       __FLT32X_MIN__=2.2250738585072014e-308F32x
       __FLT32_DECIMAL_DIG__=9
       __FLT32_DENORM_MIN__=1.4012984643248171e-45F32
       __FLT32_DIG__=6
       __FLT32_EPSILON__=1.1920928955078125e-7F32
       __FLT32_HAS_DENORM__=1
       __FLT32_HAS_INFINITY__=1
       __FLT32_HAS_QUIET_NAN__=1
       __FLT32_MANT_DIG__=24
       __FLT32_MAX_10_EXP__=38
       __FLT32_MAX_EXP__=128
       __FLT32_MAX__=3.4028234663852886e+38F32
       __FLT32_MIN_10_EXP__=(-37)
       __FLT32_MIN_EXP__=(-125)
       __FLT32_MIN__=1.1754943508222875e-38F32
       __FLT64_DECIMAL_DIG__=17
       __FLT64_DENORM_MIN__=4.9406564584124654e-324F64
       __FLT64_DIG__=15
       __FLT64_EPSILON__=2.2204460492503131e-16F64
       __FLT64_HAS_DENORM__=1
       __FLT64_HAS_INFINITY__=1
       __FLT64_HAS_QUIET_NAN__=1
       __FLT64_MANT_DIG__=53
       __FLT64_MAX_10_EXP__=308
       __FLT64_MAX_EXP__=1024
       __FLT64_MAX__=1.7976931348623157e+308F64
       __FLT64_MIN_10_EXP__=(-307)
       __FLT64_MIN_EXP__=(-1021)
       __FLT64_MIN__=2.2250738585072014e-308F64
       __FLT_DECIMAL_DIG__=9
       __FLT_DENORM_MIN__=1.4012984643248171e-45F
       __FLT_DIG__=6
       __FLT_EPSILON__=1.1920928955078125e-7F
       __FLT_EVAL_METHOD_TS_18661_3__=0
       __FLT_EVAL_METHOD__=0
       __FLT_HAS_DENORM__=1
       __FLT_HAS_INFINITY__=1
       __FLT_HAS_QUIET_NAN__=1
       __FLT_MANT_DIG__=24
       __FLT_MAX_10_EXP__=38
       __FLT_MAX_EXP__=128
       __FLT_MAX__=3.4028234663852886e+38F
       __FLT_MIN_10_EXP__=(-37)
       __FLT_MIN_EXP__=(-125)
       __FLT_MIN__=1.1754943508222875e-38F
       __FLT_RADIX__=2
       __FRACT_EPSILON__=0x1P-15R
       __FRACT_FBIT__=15
       __FRACT_IBIT__=0
       __FRACT_MAX__=0X7FFFP-15R
       __FRACT_MIN__=(-0.5R-0.5R)
       __GCC_ATOMIC_BOOL_LOCK_FREE=1
       __GCC_ATOMIC_CHAR16_T_LOCK_FREE=1
       __GCC_ATOMIC_CHAR32_T_LOCK_FREE=1
       __GCC_ATOMIC_CHAR_LOCK_FREE=1
       __GCC_ATOMIC_INT_LOCK_FREE=1
       __GCC_ATOMIC_LLONG_LOCK_FREE=1
       __GCC_ATOMIC_LONG_LOCK_FREE=1
       __GCC_ATOMIC_POINTER_LOCK_FREE=1
       __GCC_ATOMIC_SHORT_LOCK_FREE=1
       __GCC_ATOMIC_TEST_AND_SET_TRUEVAL=1
       __GCC_ATOMIC_WCHAR_T_LOCK_FREE=1
       __GCC_IEC_559=0
       __GCC_IEC_559_COMPLEX=0
       __GNUC_MINOR__=2
       __GNUC_PATCHLEVEL__=1
       __GNUC_STDC_INLINE__=1
       __GNUC__=7
       __GXX_ABI_VERSION=1011
       __GXX_TYPEINFO_EQUALITY_INLINE=0
       __has_include(STR)=__has_include__(STR)
       __has_include_next(STR)=__has_include_next__(STR)
       __HA_FBIT__=7
       __HA_IBIT__=8
       __HQ_FBIT__=15
       __HQ_IBIT__=0
       __INT16_C(c)=c
       __INT16_MAX__=0x7fff
       __INT16_TYPE__=short int
       __INT32_C(c)=c ## L
       __INT32_MAX__=0x7fffffffL
       __INT32_TYPE__=long int
       __INT64_C(c)=c ## LL
       __INT64_MAX__=0x7fffffffffffffffLL
       __INT64_TYPE__=long long int
       __INT8_C(c)=c
       __INT8_MAX__=0x7f
       __INT8_TYPE__=signed char
       __INTMAX_C(c)=c ## LL
       __INTMAX_MAX__=0x7fffffffffffffffLL
       __INTMAX_TYPE__=long long int
       __INTMAX_WIDTH__=64
       __INTPTR_MAX__=0x7fffffff
       __INTPTR_TYPE__=int
       __INTPTR_WIDTH__=32
       __INT_FAST16_MAX__=0x7fffffff
       __INT_FAST16_TYPE__=int
       __INT_FAST16_WIDTH__=32
       __INT_FAST32_MAX__=0x7fffffff
       __INT_FAST32_TYPE__=int
       __INT_FAST32_WIDTH__=32
       __INT_FAST64_MAX__=0x7fffffffffffffffLL
       __INT_FAST64_TYPE__=long long int
       __INT_FAST64_WIDTH__=64
       __INT_FAST8_MAX__=0x7fffffff
       __INT_FAST8_TYPE__=int
       __INT_FAST8_WIDTH__=32
       __INT_LEAST16_MAX__=0x7fff
       __INT_LEAST16_TYPE__=short int
       __INT_LEAST16_WIDTH__=16
       __INT_LEAST32_MAX__=0x7fffffffL
       __INT_LEAST32_TYPE__=long int
       __INT_LEAST32_WIDTH__=32
       __INT_LEAST64_MAX__=0x7fffffffffffffffLL
       __INT_LEAST64_TYPE__=long long int
       __INT_LEAST64_WIDTH__=64
       __INT_LEAST8_MAX__=0x7f
       __INT_LEAST8_TYPE__=signed char
       __INT_LEAST8_WIDTH__=8
       __INT_MAX__=0x7fffffff
       __INT_WIDTH__=32
       __LACCUM_EPSILON__=0x1P-31LK
       __LACCUM_FBIT__=31
       __LACCUM_IBIT__=32
       __LACCUM_MAX__=0X7FFFFFFFFFFFFFFFP-31LK
       __LACCUM_MIN__=(-0X1P31LK-0X1P31LK)
       __LDBL_DECIMAL_DIG__=17
       __LDBL_DENORM_MIN__=4.9406564584124654e-324L
       __LDBL_DIG__=15
       __LDBL_EPSILON__=2.2204460492503131e-16L
       __LDBL_HAS_DENORM__=1
       __LDBL_HAS_INFINITY__=1
       __LDBL_HAS_QUIET_NAN__=1
       __LDBL_MANT_DIG__=53
       __LDBL_MAX_10_EXP__=308
       __LDBL_MAX_EXP__=1024
       __LDBL_MAX__=1.7976931348623157e+308L
       __LDBL_MIN_10_EXP__=(-307)
       __LDBL_MIN_EXP__=(-1021)
       __LDBL_MIN__=2.2250738585072014e-308L
       __LFRACT_EPSILON__=0x1P-31LR
       __LFRACT_FBIT__=31
       __LFRACT_IBIT__=0
       __LFRACT_MAX__=0X7FFFFFFFP-31LR
       __LFRACT_MIN__=(-0.5LR-0.5LR)
       __LLACCUM_EPSILON__=0x1P-31LLK
       __LLACCUM_FBIT__=31
       __LLACCUM_IBIT__=32
       __LLACCUM_MAX__=0X7FFFFFFFFFFFFFFFP-31LLK
       __LLACCUM_MIN__=(-0X1P31LLK-0X1P31LLK)
       __LLFRACT_EPSILON__=0x1P-63LLR
       __LLFRACT_FBIT__=63
       __LLFRACT_IBIT__=0
       __LLFRACT_MAX__=0X7FFFFFFFFFFFFFFFP-63LLR
       __LLFRACT_MIN__=(-0.5LLR-0.5LLR)
       __LONG_LONG_MAX__=0x7fffffffffffffffLL
       __LONG_LONG_WIDTH__=64
       __LONG_MAX__=0x7fffffffL
       __LONG_WIDTH__=32
       __NO_INLINE__=1
       __ORDER_BIG_ENDIAN__=4321
       __ORDER_LITTLE_ENDIAN__=1234
       __ORDER_PDP_ENDIAN__=3412
       __PRAGMA_REDEFINE_EXTNAME=1
       __PTRDIFF_MAX__=0x7fffffff
       __PTRDIFF_TYPE__=int
       __PTRDIFF_WIDTH__=32
       __QQ_FBIT__=7
       __QQ_IBIT__=0
       __REGISTER_PREFIX__=
       __SACCUM_EPSILON__=0x1P-7HK
       __SACCUM_FBIT__=7
       __SACCUM_IBIT__=8
       __SACCUM_MAX__=0X7FFFP-7HK
       __SACCUM_MIN__=(-0X1P7HK-0X1P7HK)
       __SA_FBIT__=15
       __SA_IBIT__=16
       __SCHAR_MAX__=0x7f
       __SCHAR_WIDTH__=8
       __SFRACT_EPSILON__=0x1P-7HR
       __SFRACT_FBIT__=7
       __SFRACT_IBIT__=0
       __SFRACT_MAX__=0X7FP-7HR
       __SFRACT_MIN__=(-0.5HR-0.5HR)
       __SHRT_MAX__=0x7fff
       __SHRT_WIDTH__=16
       __SIG_ATOMIC_MAX__=0x7fffffff
       __SIG_ATOMIC_MIN__=(-__SIG_ATOMIC_MAX__ - 1)
       __SIG_ATOMIC_TYPE__=int
       __SIG_ATOMIC_WIDTH__=32
       __SIZEOF_DOUBLE__=8
       __SIZEOF_FLOAT__=4
       __SIZEOF_INT__=4
       __SIZEOF_LONG_DOUBLE__=8
       __SIZEOF_LONG_LONG__=8
       __SIZEOF_LONG__=4
       __SIZEOF_POINTER__=4
       __SIZEOF_PTRDIFF_T__=4
       __SIZEOF_SHORT__=2
       __SIZEOF_SIZE_T__=4
       __SIZEOF_WCHAR_T__=4
       __SIZEOF_WINT_T__=4
       __SIZE_MAX__=0xffffffffU
       __SIZE_TYPE__=unsigned int
       __SIZE_WIDTH__=32
       __SOFTFP__=1
       __SQ_FBIT__=31
       __SQ_IBIT__=0
       __STDC_HOSTED__=1
       __STDC_UTF_16__=1
       __STDC_UTF_32__=1
       __STDC_VERSION__=201112L
       __STDC__=1
       __TA_FBIT__=63
       __TA_IBIT__=64
       __THUMB_INTERWORK__=1
       __TQ_FBIT__=127
       __TQ_IBIT__=0
       __UACCUM_EPSILON__=0x1P-16UK
       __UACCUM_FBIT__=16
       __UACCUM_IBIT__=16
       __UACCUM_MAX__=0XFFFFFFFFP-16UK
       __UACCUM_MIN__=0.0UK
       __UDA_FBIT__=32
       __UDA_IBIT__=32
       __UDQ_FBIT__=64
       __UDQ_IBIT__=0
       __UFRACT_EPSILON__=0x1P-16UR
       __UFRACT_FBIT__=16
       __UFRACT_IBIT__=0
       __UFRACT_MAX__=0XFFFFP-16UR
       __UFRACT_MIN__=0.0UR
       __UHA_FBIT__=8
       __UHA_IBIT__=8
       __UHQ_FBIT__=16
       __UHQ_IBIT__=0
       __UINT16_C(c)=c
       __UINT16_MAX__=0xffff
       __UINT16_TYPE__=short unsigned int
       __UINT32_C(c)=c ## UL
       __UINT32_MAX__=0xffffffffUL
       __UINT32_TYPE__=long unsigned int
       __UINT64_C(c)=c ## ULL
       __UINT64_MAX__=0xffffffffffffffffULL
       __UINT64_TYPE__=long long unsigned int
       __UINT8_C(c)=c
       __UINT8_MAX__=0xff
       __UINT8_TYPE__=unsigned char
       __UINTMAX_C(c)=c ## ULL
       __UINTMAX_MAX__=0xffffffffffffffffULL
       __UINTMAX_TYPE__=long long unsigned int
       __UINTPTR_MAX__=0xffffffffU
       __UINTPTR_TYPE__=unsigned int
       __UINT_FAST16_MAX__=0xffffffffU
       __UINT_FAST16_TYPE__=unsigned int
       __UINT_FAST32_MAX__=0xffffffffU
       __UINT_FAST32_TYPE__=unsigned int
       __UINT_FAST64_MAX__=0xffffffffffffffffULL
       __UINT_FAST64_TYPE__=long long unsigned int
       __UINT_FAST8_MAX__=0xffffffffU
       __UINT_FAST8_TYPE__=unsigned int
       __UINT_LEAST16_MAX__=0xffff
       __UINT_LEAST16_TYPE__=short unsigned int
       __UINT_LEAST32_MAX__=0xffffffffUL
       __UINT_LEAST32_TYPE__=long unsigned int
       __UINT_LEAST64_MAX__=0xffffffffffffffffULL
       __UINT_LEAST64_TYPE__=long long unsigned int
       __UINT_LEAST8_MAX__=0xff
       __UINT_LEAST8_TYPE__=unsigned char
       __ULACCUM_EPSILON__=0x1P-32ULK
       __ULACCUM_FBIT__=32
       __ULACCUM_IBIT__=32
       __ULACCUM_MAX__=0XFFFFFFFFFFFFFFFFP-32ULK
       __ULACCUM_MIN__=0.0ULK
       __ULFRACT_EPSILON__=0x1P-32ULR
       __ULFRACT_FBIT__=32
       __ULFRACT_IBIT__=0
       __ULFRACT_MAX__=0XFFFFFFFFP-32ULR
       __ULFRACT_MIN__=0.0ULR
       __ULLACCUM_EPSILON__=0x1P-32ULLK
       __ULLACCUM_FBIT__=32
       __ULLACCUM_IBIT__=32
       __ULLACCUM_MAX__=0XFFFFFFFFFFFFFFFFP-32ULLK
       __ULLACCUM_MIN__=0.0ULLK
       __ULLFRACT_EPSILON__=0x1P-64ULLR
       __ULLFRACT_FBIT__=64
       __ULLFRACT_IBIT__=0
       __ULLFRACT_MAX__=0XFFFFFFFFFFFFFFFFP-64ULLR
       __ULLFRACT_MIN__=0.0ULLR
       __UQQ_FBIT__=8
       __UQQ_IBIT__=0
       __USACCUM_EPSILON__=0x1P-8UHK
       __USACCUM_FBIT__=8
       __USACCUM_IBIT__=8
       __USACCUM_MAX__=0XFFFFP-8UHK
       __USACCUM_MIN__=0.0UHK
       __USA_FBIT__=16
       __USA_IBIT__=16
       __USER_LABEL_PREFIX__=
       __USES_INITFINI__=1
       __USFRACT_EPSILON__=0x1P-8UHR
       __USFRACT_FBIT__=8
       __USFRACT_IBIT__=0
       __USFRACT_MAX__=0XFFP-8UHR
       __USFRACT_MIN__=0.0UHR
       __USQ_FBIT__=32
       __USQ_IBIT__=0
       __UTA_FBIT__=64
       __UTA_IBIT__=64
       __UTQ_FBIT__=128
       __UTQ_IBIT__=0
       __VERSION__="7.2.1 20170904 (release) [ARM/embedded-7-branch revision 255204]"
       __VFP_FP__=1
       __WCHAR_MAX__=0xffffffffU
       __WCHAR_MIN__=0U
       __WCHAR_TYPE__=unsigned int
       __WCHAR_WIDTH__=32
       __WINT_MAX__=0xffffffffU
       __WINT_MIN__=0U
       __WINT_TYPE__=unsigned int
       __WINT_WIDTH__=32
    
    Macro definitions (from language + headers in index):
       __builtin_offsetof(T,m)=((size_t) &((T *)0)->m)
       __builtin_types_compatible_p(x,y)=__builtin_types_compatible_p(sizeof(x),sizeof(y))
       __builtin_va_arg(ap,type)=*(typeof(type) *)ap
       __CDT_PARSER__=90403
       __complex__=_Complex
       __COUNTER__=0
       __DATE__="Apr. 26 2023"
       __extension__=
       __FILE__="file"
       __imag__=(int)
       __LINE__=1
       __null=(void *)0
       __offsetof__(x)=(x)
       __real__=(int)
       __stdcall=
       __thread=
       __TIME__="13:04:50"
    
    Macro definitions (from files actually parsed):
       NUM_SECTIONS_DEV=(960)
       NUM_SECTIONS_IRAM=(1)
       START_ADDR_DEV=(0x44000000)
       START_ADDR_IRAM=(0x40300000)
    
    Unresolved includes (from headers in index):
       file:/C:/src/AM3352-SOM-EVB_bare_metal/gcc-arm-none-eabi/lib/gcc/arm-none-eabi/7.2.1/include/stdint.h is not indexed
       file:/C:/src/AM3352-SOM-EVB_bare_metal/gcc-arm-none-eabi/arm-none-eabi/include/string.h is not indexed
       file:/C:/ti/AM335X_StarterWare_02_00_01_01/include/hw/hw_types.h is not indexed
       file:/C:/ti/AM335X_StarterWare_02_00_01_01/include/hw/soc_AM335x.h is not indexed
       file:/C:/src/AM3352-SOM-EVB_bare_metal/source/AM3352_SOM_platform/AM3352_SOM.h is not indexed
       file:/C:/ti/AM335X_StarterWare_02_00_01_01/include/hw/hw_cm_wkup.h is not indexed
       file:/C:/ti/AM335X_StarterWare_02_00_01_01/include/uartStdio.h is not indexed
       file:/C:/ti/AM335X_StarterWare_02_00_01_01/include/consoleUtils.h is not indexed
       file:/C:/ti/AM335X_StarterWare_02_00_01_01/include/armv7a/mmu.h is not indexed
    
    Unresolved names:
       Attempt to use symbol failed: REGION in file C:\src\AM3352-SOM-EVB_bare_metal\source\quick_mmu_enable\quick_mmu_enable.c:56
       Attempt to use symbol failed: MMU_PGTYPE_SECTION in file C:\src\AM3352-SOM-EVB_bare_metal\source\quick_mmu_enable\quick_mmu_enable.c:57
       Attempt to use symbol failed: MMU_CACHE_WT_NOWA in file C:\src\AM3352-SOM-EVB_bare_metal\source\quick_mmu_enable\quick_mmu_enable.c:58
       Attempt to use symbol failed: MMU_CACHE_WB_WA in file C:\src\AM3352-SOM-EVB_bare_metal\source\quick_mmu_enable\quick_mmu_enable.c:59
       Attempt to use symbol failed: MMU_REGION_NON_SECURE in file C:\src\AM3352-SOM-EVB_bare_metal\source\quick_mmu_enable\quick_mmu_enable.c:60
       Attempt to use symbol failed: MMU_AP_PRV_RW_USR_RW in file C:\src\AM3352-SOM-EVB_bare_metal\source\quick_mmu_enable\quick_mmu_enable.c:60
       Attempt to use symbol failed: REGION in file C:\src\AM3352-SOM-EVB_bare_metal\source\quick_mmu_enable\quick_mmu_enable.c:69
       Attempt to use symbol failed: MMU_PGTYPE_SECTION in file C:\src\AM3352-SOM-EVB_bare_metal\source\quick_mmu_enable\quick_mmu_enable.c:70
       Attempt to use symbol failed: MMU_MEMTYPE_DEVICE_SHAREABLE in file C:\src\AM3352-SOM-EVB_bare_metal\source\quick_mmu_enable\quick_mmu_enable.c:71
       Attempt to use symbol failed: MMU_REGION_NON_SECURE in file C:\src\AM3352-SOM-EVB_bare_metal\source\quick_mmu_enable\quick_mmu_enable.c:72
       Attempt to use symbol failed: MMU_AP_PRV_RW_USR_RW in file C:\src\AM3352-SOM-EVB_bare_metal\source\quick_mmu_enable\quick_mmu_enable.c:73
       Attempt to use symbol failed: MMU_SECTION_EXEC_NEVER in file C:\src\AM3352-SOM-EVB_bare_metal\source\quick_mmu_enable\quick_mmu_enable.c:73
    
    Written on Wed Apr 26 13:04:50 CEST 2023
    

    Also, manually adding include paths is not a valid solution for us since our projects are rather big and we don't want a required manual build step in our pipeline.

    Regarding the zip-project I send above we tried following solution (from Chester Gillon) to solve the indexer problem:

    Manually edited the project properties under C/C++ General -> Paths and Symbols to set include directories and Symbols, for example for the local-adder.

    Doing so didn't change anything in the indexer, although inside the index_zip.log file we see the include (line 10) but still it is not found by the indexer (line 35).

    Project:               CMakeProjectMinimalExample
    File:                  file:/C:/src/CMakeProjectSitaraMinimalExample/application/mainApplication.c
    Language:              GNU C
    Index Version:         211.0
    Build Configuration:   Release
    Context:               none
    Versions in Index:     0
    
    Include Search Path (option -I):
       C:\src\CMakeProjectSitaraMinimalExample\application\local-adder\include
    
    Macro definitions (from language + headers in index):
       __builtin_offsetof(T,m)=((size_t) &((T *)0)->m)
       __builtin_types_compatible_p(x,y)=__builtin_types_compatible_p(sizeof(x),sizeof(y))
       __builtin_va_arg(ap,type)=*(typeof(type) *)ap
       __CDT_PARSER__=90403
       __complex__=_Complex
       __COUNTER__=0
       __DATE__="Apr. 26 2023"
       __extension__=
       __FILE__="file"
       __imag__=(int)
       __LINE__=1
       __null=(void *)0
       __offsetof__(x)=(x)
       __real__=(int)
       __stdcall=
       __STDC_HOSTED__=1
       __STDC_VERSION__=199901L
       __STDC__=1
       __thread=
       __TIME__="13:16:45"
    
    Unresolved includes (from headers in index):
       file:/C:/src/CMakeProjectSitaraMinimalExample/application/local-adder/include/local-adder/local-adder.h is not indexed
       file:/C:/src/CMakeProjectSitaraMinimalExample/application/local-sub/include/local-sub/local-sub.h is not indexed
       file:/C:/src/CMakeProjectSitaraMinimalExample/application/local-pow/include/local-pow/local-pow.h is not indexed
       file:/C:/src/CMakeProjectSitaraMinimalExample/application/local-something/something.h is not indexed
       file:/C:/src/CMakeProjectSitaraMinimalExample/application/local-assembler/cp15.h is not indexed
    
    Written on Wed Apr 26 13:16:45 CEST 2023
    

    Regards

    Timo

  • CMakeProjectSitaraMinimalExample.zip

    Hi Ki,

    here is an example project showing the issue.

    I have been experimenting with the project and so far I have not seen any issues. The Open Declaration (F3) feature has been working well on the things I have tried. Is there a particular file and function in this example that you have an issue with?

    Thanks

    ki

  • This is very interesting!

    Indeed using CCS Version 12.2.0 the indexer seems to find the declarations inside the project:

    Project:               CMakeProjectMinimalExample
    File:                  file:/C:/GIT/PlaygroundForTISupport/Playground_CMake/CMakeProjectSitaraMinimalExample/application/mainApplication.c
    Language:              TI GNU C
    Index Version:         220.0
    Build Configuration:   Release
    Context:               file:/C:/GIT/PlaygroundForTISupport/Playground_CMake/CMakeProjectSitaraMinimalExample/application/mainApplication.c
       C, {}
    Versions in Index:     1
       C: {}; 0 macros, 5 includes, 6 names;
    
    Macro definitions (from language + headers in index):
       CP15_CONTROL_ACCESSFLAG=(0x20000000)
       CP15_CONTROL_ALIGN_CHCK=(0x00000002)
       CP15_CONTROL_MMU=(0x00000001)
       CP15_CONTROL_TEXREMAP=(0x10000000)
       LOCAL_ADDER_H_=
       LOCAL_POW_H_=
       LOCAL_SOMETHING_H_=
       LOCAL_SUB_H_=
       __builtin_offsetof(T,m)=((size_t) &((T *)0)->m)
       __builtin_types_compatible_p(x,y)=__builtin_types_compatible_p(sizeof(x),sizeof(y))
       __builtin_va_arg(ap,type)=*(typeof(type) *)ap
       __CDT_PARSER__=100600
       __complex__=_Complex
       __COUNTER__=0
       __CP15_H=
       __DATE__="Apr. 27 2023"
       __extension__=
       __FILE__="file"
       __has_include=
       __has_include_next=
       __imag__=(int)
       __LINE__=1
       __null=(void *)0
       __offsetof__(x)=(x)
       __real__=(int)
       __stdcall=
       __STDC_HOSTED__=1
       __STDC_VERSION__=199901L
       __STDC__=1
       __thread=
       __TIME__="07:58:51"
    
    Written on Thu Apr 27 07:58:51 CEST 2023
    

    But using CCS Version 8.3.1 there is a problem with the indexer analyzing the same project:

    Project:               CMakeProjectMinimalExample
    File:                  file:/C:/GIT/PlaygroundForTISupport/Playground_CMake/CMakeProjectSitaraMinimalExample/application/mainApplication.c
    Language:              GNU C
    Index Version:         211.0
    Build Configuration:   Release
    Context:               none
    Versions in Index:     0
    
    Macro definitions (from language + headers in index):
       __builtin_offsetof(T,m)=((size_t) &((T *)0)->m)
       __builtin_types_compatible_p(x,y)=__builtin_types_compatible_p(sizeof(x),sizeof(y))
       __builtin_va_arg(ap,type)=*(typeof(type) *)ap
       __CDT_PARSER__=90403
       __complex__=_Complex
       __COUNTER__=0
       __DATE__="Apr. 27 2023"
       __extension__=
       __FILE__="file"
       __imag__=(int)
       __LINE__=1
       __null=(void *)0
       __offsetof__(x)=(x)
       __real__=(int)
       __stdcall=
       __STDC_HOSTED__=1
       __STDC_VERSION__=199901L
       __STDC__=1
       __thread=
       __TIME__="08:02:07"
    
    Unresolved includes (from headers in index):
       file:/C:/GIT/PlaygroundForTISupport/Playground_CMake/CMakeProjectSitaraMinimalExample/application/local-adder/include/local-adder/local-adder.h is not indexed
       file:/C:/GIT/PlaygroundForTISupport/Playground_CMake/CMakeProjectSitaraMinimalExample/application/local-sub/include/local-sub/local-sub.h is not indexed
       file:/C:/GIT/PlaygroundForTISupport/Playground_CMake/CMakeProjectSitaraMinimalExample/application/local-pow/include/local-pow/local-pow.h is not indexed
       file:/C:/GIT/PlaygroundForTISupport/Playground_CMake/CMakeProjectSitaraMinimalExample/application/local-something/something.h is not indexed
       file:/C:/GIT/PlaygroundForTISupport/Playground_CMake/CMakeProjectSitaraMinimalExample/application/local-assembler/cp15.h is not indexed
    
    Written on Thu Apr 27 08:02:07 CEST 2023
    

    But then I modified the code a little bit so that it can still be build but the indexer cannot find symbols declared in <stdint.h> also using CCS12. I attached the modified project:

    CMakeProjectSitaraMinimalExampleSTDINT.zip

    And also the indexer log file:

    Project:               CMakeProjectMinimalExample
    File:                  file:/C:/GIT/PlaygroundForTISupport/Playground_CMake/CMakeProjectSitaraMinimalExample/application/mainApplication.c
    Language:              TI GNU C
    Index Version:         220.0
    Build Configuration:   Release
    Context:               file:/C:/GIT/PlaygroundForTISupport/Playground_CMake/CMakeProjectSitaraMinimalExample/application/mainApplication.c
       C, {}
    Versions in Index:     1
       C: {}; 0 macros, 6 includes, 6 names;
    
    Macro definitions (from language + headers in index):
       CP15_CONTROL_ACCESSFLAG=(0x20000000)
       CP15_CONTROL_ALIGN_CHCK=(0x00000002)
       CP15_CONTROL_MMU=(0x00000001)
       CP15_CONTROL_TEXREMAP=(0x10000000)
       LOCAL_ADDER_H_=
       LOCAL_POW_H_=
       LOCAL_SOMETHING_H_=
       LOCAL_SUB_H_=
       __builtin_offsetof(T,m)=((size_t) &((T *)0)->m)
       __builtin_types_compatible_p(x,y)=__builtin_types_compatible_p(sizeof(x),sizeof(y))
       __builtin_va_arg(ap,type)=*(typeof(type) *)ap
       __CDT_PARSER__=100600
       __complex__=_Complex
       __COUNTER__=0
       __CP15_H=
       __DATE__="Apr. 27 2023"
       __extension__=
       __FILE__="file"
       __has_include=
       __has_include_next=
       __imag__=(int)
       __LINE__=1
       __null=(void *)0
       __offsetof__(x)=(x)
       __real__=(int)
       __stdcall=
       __STDC_HOSTED__=1
       __STDC_VERSION__=199901L
       __STDC__=1
       __thread=
       __TIME__="08:50:12"
    
    Scanner problems:
       Unresolved inclusion: <stdint.h> in file: C:\GIT\PlaygroundForTISupport\Playground_CMake\CMakeProjectSitaraMinimalExample\application\mainApplication.c:14
    
    Unresolved names:
       Attempt to use symbol failed: int16_t in file C:\GIT\PlaygroundForTISupport\Playground_CMake\CMakeProjectSitaraMinimalExample\application\mainApplication.c:18
       Attempt to use symbol failed: int32_t in file C:\GIT\PlaygroundForTISupport\Playground_CMake\CMakeProjectSitaraMinimalExample\application\mainApplication.c:19
       Attempt to use symbol failed: int32_t in file C:\GIT\PlaygroundForTISupport\Playground_CMake\CMakeProjectSitaraMinimalExample\application\mainApplication.c:20
       Attempt to use symbol failed: int32_t in file C:\GIT\PlaygroundForTISupport\Playground_CMake\CMakeProjectSitaraMinimalExample\application\mainApplication.c:21
    
    Written on Thu Apr 27 08:50:12 CEST 2023
    

  • indexer cannot find symbols declared in <stdint.h> also using CCS12.

    yes, this typically happens with system header files and files outside the project folder. Please see:

    https://www.eclipse.org/community/eclipse_newsletter/2013/october/article4.php

    Thanks

    ki

  • Hi Ki,

    using CCS12 and integrating the compiler header files solved the Indexer issue.

    Thanks for your help!