Getting LLVM_HOSTTRIPLE or something similar

Hi!

I’m adapting my code to the latest trunk version of Clang, and I’ve noticed that this new version doesn’t have anymore the constant LLVM_HOSTTRIPLE, that represented a triplet for the architecture, vendor and OS of the machine LLVM has been built.

That’s a problem for me, since I’m not generating the LLVM-IR representation of my code, just doing some source-to-source transformation and, in my opinion, target info should be irrelevant for my program. Unfortunately, Clang asks everytime me for an instance of TargetInfo when I try to instantiate a Preprocessor, and, at least, this TargetInfo must specify the Triple for the target.

Any solution? Thanks in advance.

Jorge.

Look for LLVM_DEFAULT_TARGET_TRIPLE.

Joerg