How do i initialize headersearch ?

Can someone guide me as to how to initialize my HeaderSearch and HeaderSearchOptions so that my program is able to parse included files when needed ?

Thanks and Regards,
Parijat

Have you seen this?
http://amnoid.de/tmp/clangtut/tut.html
I believe the “Tutorial 1” and “Tutorial 3” sections cover enough of HeaderSearch to probably give you some good direction?
Hope this helps,
Cheers,
– Larisse.

This tutorial is outdated ( some of the functions were removed with branch 2.7 and later …like InitHeaderSearch and InitPreprocessor …it has been replaced by HeaderSearchOptions ) . I had gone through this tutorial initially to realize many of the function syntaxes and files were different . :slight_smile:

I havent been able to find a proper guide on how to use HeaderSearchOptions with HeaderSearch yet :frowning: . It would be great if someone can give me some headway into this .

Thanks though Larisse !

Regards
Parijat

Hey. I tried. I’m only new to this as well. :slight_smile: – though the link definitely helped me get started, despite its old-age…
I’d certainly be interested in the right answer or pointers from the real experts out there…

– Larisse.

Did you ever get an answer to this ( I didn’t see anything else in this thread).

I’ve put this out there because I went through the exact same thing. This should work for the most part (builds and runs as expected on my Ubuntu and OS X boxes).
http://clangtutorial.codeplex.com/

It took a fair amount of code groveling and debugging to understand what changed where and why to recreate that tutorial.

This tutorial is outdated ( some of the functions were removed with branch
2.7 and later ...like InitHeaderSearch and InitPreprocessor ....it has been
replaced by HeaderSearchOptions ) . I had gone through this tutorial
initially to realize many of the function syntaxes and files were different
. :slight_smile:

I started updating it to llvm2.8 last week. The HeaderSearch part is
done: https://github.com/nico/clangtut/blob/master/tut03_pp.cpp