[JITLink] Update BuildingAJIT tutorials to account for API changes in r358818.

DynamicLibrarySearchGenerator::GetForCurrentProcess now takes a char (the global
prefix) rather than a DataLayout reference.

llvm-svn: 358820
This commit is contained in:
Lang Hames 2019-04-20 17:35:28 +00:00
parent 6dfb930f8e
commit 14f7b1d72a
2 changed files with 4 additions and 2 deletions

View File

@ -47,7 +47,8 @@ public:
DL(std::move(DL)), Mangle(ES, this->DL),
Ctx(llvm::make_unique<LLVMContext>()) {
ES.getMainJITDylib().setGenerator(
cantFail(DynamicLibrarySearchGenerator::GetForCurrentProcess(DL)));
cantFail(DynamicLibrarySearchGenerator::GetForCurrentProcess(
DL.getGlobalPrefix())));
}
static Expected<std::unique_ptr<KaleidoscopeJIT>> Create() {

View File

@ -54,7 +54,8 @@ public:
DL(std::move(DL)), Mangle(ES, this->DL),
Ctx(llvm::make_unique<LLVMContext>()) {
ES.getMainJITDylib().setGenerator(
cantFail(DynamicLibrarySearchGenerator::GetForCurrentProcess(DL)));
cantFail(DynamicLibrarySearchGenerator::GetForCurrentProcess(
DL.getGlobalPrefix())));
}
const DataLayout &getDataLayout() const { return DL; }