Skip to content

Commit

Permalink
[cling] Do not try to find runtime headers in ./:
Browse files Browse the repository at this point in the history
These headers are part of cling, not user code, so starting
with the current directory is pointless and can actually be
counterproductive.

This helps with root-project#12409
but not enough; any dictionary header will still try to access "./".

(cherry picked from commit e660b0b)
  • Loading branch information
Axel-Naumann committed Mar 6, 2023
1 parent ccc8df1 commit 04f3820
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions interpreter/cling/lib/Interpreter/Interpreter.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -439,13 +439,13 @@ namespace cling {
const char* Linkage = LangOpts.CPlusPlus ? "extern \"C\"" : "";
if (!NoRuntime) {
if (LangOpts.CPlusPlus) {
Strm << "#include \"cling/Interpreter/RuntimeUniverse.h\"\n";
Strm << "#include <cling/Interpreter/RuntimeUniverse.h>\n";
if (EmitDefinitions)
Strm << "namespace cling { class Interpreter; namespace runtime { "
"Interpreter* gCling=(Interpreter*)" << ThisP << ";\n"
"RuntimeOptions* gClingOpts=(RuntimeOptions*)" << &this->m_RuntimeOptions << ";}}\n";
} else {
Strm << "#include \"cling/Interpreter/CValuePrinter.h\"\n"
Strm << "#include <cling/Interpreter/CValuePrinter.h>\n"
<< "void* gCling";
if (EmitDefinitions)
Strm << "=(void*)" << ThisP;
Expand Down Expand Up @@ -1692,7 +1692,7 @@ namespace cling {
if (!m_DynamicLookupDeclared && value) {
// No dynlookup for the dynlookup header!
m_DynamicLookupEnabled = false;
declare("#include \"cling/Interpreter/DynamicLookupRuntimeUniverse.h\"");
declare("#include <cling/Interpreter/DynamicLookupRuntimeUniverse.h>");
}
m_DynamicLookupDeclared = true;

Expand Down

0 comments on commit 04f3820

Please sign in to comment.