gallivm: change sys::getHostTriple to sys::getDefaultTargetTriple for LLVM >= 0x0301

LLVM change r143502

Signed-off-by: José Fonseca <jose.r.fonseca@gmail.com>
This commit is contained in:
Christian Inci 2011-11-06 07:32:54 +00:00 committed by José Fonseca
parent adb7f1351e
commit 3031708e64
1 changed files with 4 additions and 0 deletions

View File

@ -186,7 +186,11 @@ lp_disassemble(const void* func)
* Initialize all used objects.
*/
#if HAVE_LLVM >= 0x0301
std::string Triple = sys::getDefaultTargetTriple();
#else
std::string Triple = sys::getHostTriple();
#endif
std::string Error;
const Target *T = TargetRegistry::lookupTarget(Triple, Error);