Fix compile error of wamrc with llvm-13/llvm-14 (#2261)

This commit is contained in:
Wenyong Huang
2023-06-06 08:33:15 +08:00
committed by GitHub
parent 5fb5119239
commit 8ef09be604
2 changed files with 9 additions and 1 deletions

View File

@ -4,7 +4,11 @@
*/
#include <llvm-c/TargetMachine.h>
#if LLVM_VERSION_MAJOR >= 14
#include <llvm/MC/TargetRegistry.h>
#else
#include <llvm/Support/TargetRegistry.h>
#endif
#include <llvm/Target/TargetMachine.h>
#include "bh_assert.h"