Skip to content
Permalink
Browse files

Forward-port Clang ResourceDir fix (#747) from Stefan Brüns

  • Loading branch information...
Michal Babej
Michal Babej committed Jul 30, 2019
1 parent 7b73be1 commit e535b17bac8e1316d5c39c344d2a09ba9f95e643
Showing with 8 additions and 1 deletion.
  1. +1 −0 CREDITS
  2. +7 −1 lib/CL/pocl_llvm_build.cc
@@ -68,3 +68,4 @@ Wilfried Holzke <github@holzke.net>
Maxim Eremenko <moeryomenko@gmail.com>
Andrew Gozillon <andrew.gozillon@yahoo.com>
Jan Solanti <jan.solanti@tuni.fi>
Stefan Brüns <stefan.bruens@rwth-aachen.de>
@@ -425,7 +425,13 @@ int pocl_llvm_build_program(cl_program program,
#ifdef ENABLE_POCL_BUILDING
if (pocl_get_bool_option("POCL_BUILDING", 0)) {
IncludeRoot = SRCDIR;
ClangResourceDir = CLANG_RESOURCE_DIR;
#ifndef LLVM_OLDER_THAN_9_0
ClangResourceDir = driver::Driver::GetResourcesPath(CLANG);
#else
DiagnosticsEngine Diags{new DiagnosticIDs, new DiagnosticOptions};
driver::Driver TheDriver(CLANG, "", Diags);
ClangResourceDir = TheDriver.ResourceDir;
#endif
#else
if (0) {
#endif

0 comments on commit e535b17

Please sign in to comment.
You can’t perform that action at this time.