Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to remove auto-discovered paths after compiling on Linux from Eclipse CDT project?

I have compiled my project on Linux and now Eclipse CDT has added some paths to includes that of course don't exist on Windows. Eclipse gives me warnings about this and it's annoying. How do I get rid of them?

C/C++ Build / Discovery Options / Clear discovery entries now doesn't help. It doesn't remove any paths.

Description Resource    Path    Location    Type
Invalid project path: Include path not found (\usr\include\x86_64-linux-gnu).   UMCC        pathentry   Path Entry Problem
Invalid project path: Include path not found (\usr\include).    UMCC        pathentry   Path Entry Problem
Invalid project path: Include path not found (\usr\include\x86_64-linux-gnu\c++\4.7).   UMCC        pathentry   Path Entry Problem
Invalid project path: Include path not found (\usr\include\c++\4.7).    UMCC        pathentry   Path Entry Problem
Invalid project path: Include path not found (\usr\lib\gcc\x86_64-linux-gnu\4.7\include-fixed). UMCC        pathentry   Path Entry Problem
Invalid project path: Include path not found (\usr\local\include).  UMCC        pathentry   Path Entry Problem
Invalid project path: Include path not found (\usr\lib\gcc\x86_64-linux-gnu\4.7\include).   UMCC        pathentry   Path Entry Problem
Invalid project path: Include path not found (\usr\include\c++\4.7\backward).   UMCC        pathentry   Path Entry Problem
like image 581
Scintillo Avatar asked Aug 25 '13 09:08

Scintillo


2 Answers

I found this where a user solved a similar problem by doing the following:

Close your project and remove file $WORKSPACE/.metadata/.plugins/org.eclipse.cdt.make.core/$YOUR-PROJECT.sc

I haven't tested this though so I'm not sure if it will work.

like image 71
Christian Wilkie Avatar answered Oct 12 '22 23:10

Christian Wilkie


If it still doesn't work after using the accepted answer remove the following directory (after backing it up...):

$WORKSPACE/.metadata/.plugins/org.eclipse.cdt.core/

After this Eclipse has to reindex all the CDT projects but in turn it also updates the paths.

like image 33
Shirky Avatar answered Oct 12 '22 23:10

Shirky