5

How to build a C project's indexes from command line? I am thinking to use it in a script so that I can build indexes every night with the latest code.(Our codebase is pretty big, usually it takes hours to build indexes). And, possibly share the index result within the team.

I found this prebuild indexes help doc: Pre-built indexes in CDT 4.0

But it seems to have limitations, for example, it doesn't respect my project settings, In my project, In the Paths and Symbols, I have Include Path, Macros, Source Locations set up. Especially I have some filter patterns set up in the source location. These project specific settings are all saved in .cproject file.

How do I make the command line indexer respect these settings? I guess basically I want the command-line indexer to generate the same result as I do it from GUI.

I am using 3.7.2, CDT 8.0.2

wei
  • 6,629
  • 7
  • 40
  • 52
  • has anyone figured this out yet? The best way that I've come up with to try this is to actually make my own equinox plugin. I'm trying to do this on a git repo as part of an automated job. I need to generate and update the index, then use it, then discard it, all while being headless (truly headless, as in no command line as well), probably from a maven job or something. – searchengine27 Jan 11 '22 at 19:07

1 Answers1

0

Just found this: https://aholzner.wordpress.com/2010/09/26/generating-c-index-files-for-eclipse-from-the-command-line-linux/

Unfortunately no CDT version is specified.

Martin Gerhardy
  • 1,860
  • 22
  • 13
  • This question might add the missing pieces about specifying the project and stuff like that: http://stackoverflow.com/questions/344797/build-several-cdt-c-projects-from-commandline – Martin Gerhardy Oct 29 '15 at 16:26