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.

CCSv5 - compiler can't open linked include file

I have a project that I created a Source directory and linked in all my .cpp, .c, and .asm files. If I add an include path to the project properties the virtual Includes directory shows every subdirectory and file in the directory, including .c and.cpp files that I have linked in the Source directory. It seems that since this virtual directory is called Includes that it should only show the files I have specified in my project properties as header files. There is no way to put any filtering on this virtual folder.

I tried creating a Headers folder in the project and then linked the header files I wanted. I then put the path to the Header folder in the project properties include paths. With this the compiler says it cannot open the header file. Is there anyway to get the compiler to open linked header files? I put the linked header file in the Source folder and it could not open it there either.

I've also tried adding a new linked folder and then adding a resource filter to exclued all folders and files except the desired header files and then adding the linked folder to the project properties include paths. This will work but is not preferred as all the excluded files show up greyed out but can still be opened when doubel clicked. I only want to see the header files that are part of the project. Is there any way to remove the excluded files from the project explorer view? When I press delete it wants to delete the excluded file from my file system (hard drive). Most other tools I have used have a remove from project only option.

  • I have not received any response or reply to questions and issues that I posed in the my original post.

    Is there any way to get the compiler to open linked header files?

    Is there any way to remove excluded files from the project explorer view without deleting them from my hard drive?

    Why does the auto-generated virtual Includes folder use a *.* filter rather than the project defined file extensions for header files?

    I am usingCCS version 5.1.0.2

  • Dave Saubers said:

    I have a project that I created a Source directory and linked in all my .cpp, .c, and .asm files. If I add an include path to the project properties the virtual Includes directory shows every subdirectory and file in the directory, including .c and.cpp files that I have linked in the Source directory.

    That is correct, this is currently how that Includes directory works.

    Dave Saubers said:

    I tried creating a Headers folder in the project and then linked the header files I wanted. I then put the path to the Header folder in the project properties include paths. With this the compiler says it cannot open the header file.

    This is likely because the header files are "linked" and not "copied". The path in the Project Properties should point to the header files' original location.

    Dave Saubers said:

    Is there any way to get the compiler to open linked header files?

    Have you tried creating a virtual folder and linking the header files to that folder? Virtual folders are folders that exist only in the CCS workspace tree, and have no physical file system location.

    That should allow you to open the file within CCS and also keep its original location specified in the Project Properties for the include path.

    To create a virtual folder, right-click on the project or folder where you want to create the virtual folder. Select  New->Folder. Specify the name of the folder. Click Advanced and select "Folder is not located in the file system (Virtual Folder)."

    Dave Saubers said:

    Is there any way to remove excluded files from the project explorer view without deleting them from my hard drive?

    If they are physically in the project folder, then no. But if they are linked resources, then yes, you can delete it from the project but not physically from its original location.