herrgahr/qling

Compile errors on qlinq.cpp

Opened this issue · 1 comments

Hi,

I wasn't sure if this was still active, but I get a compilation error on qling.cpp

After first assembling ( as qatomic... ) , I am able to run the build after the following:

export LLVM_INSTALL=/usr/local
qmake-qt4
make

g++ -c -m64 -pipe -I/usr/local/include -D_DEBUG -D_GNU_SOURCE -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS -O3 -fomit-frame-pointer -std=c++11 -fvisibility-inlines-hidden -fno-exceptions -fno-rtti -fPIC -ffunction-sections -fdata-sections -Wcast-qual -Wno-unused-parameter -Wno-strict-aliasing -std=c++11 -O2 -fno-omit-frame-pointer -g -Wall -W -D_REENTRANT -DLLVM_INSTALL="/usr/local/" -DQLING_BASE_DIR="/media/jdamon/Development/Documents/Projects/build_cling/qling-master" -DQT_NO_DEBUG -DQT_WEBKIT_LIB -DQT_GUI_LIB -DQT_CORE_LIB -I/usr/share/qt4/mkspecs/linux-g++-64 -I. -I/usr/include/qt4/QtCore -I/usr/include/qt4/QtGui -I/usr/include/qt4/QtWebKit -I/usr/include/qt4 -I/usr/local//../llvm/tools -I. -o main.o main.cpp
... (more with no problems)

g++ -c -m64 -pipe -I/usr/local/include -D_DEBUG -D_GNU_SOURCE -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS -O3 -fomit-frame-pointer -std=c++11 -fvisibility-inlines-hidden -fno-exceptions -fno-rtti -fPIC -ffunction-sections -fdata-sections -Wcast-qual -Wno-unused-parameter -Wno-strict-aliasing -std=c++11 -O2 -fno-omit-frame-pointer -g -Wall -W -D_REENTRANT -DLLVM_INSTALL="/usr/local/" -DQLING_BASE_DIR="/media/jdamon/Development/Documents/Projects/build_cling/qling-master" -DQT_NO_DEBUG -DQT_WEBKIT_LIB -DQT_GUI_LIB -DQT_CORE_LIB -I/usr/share/qt4/mkspecs/linux-g++-64 -I. -I/usr/include/qt4/QtCore -I/usr/include/qt4/QtGui -I/usr/include/qt4/QtWebKit -I/usr/include/qt4 -I/usr/local//../llvm/tools -I. -o qling.o qling/qling.cpp
qling/qling.cpp:48:44: fatal error: cling/Interpreter/ValuePrinter.h: No such file or directory
#include "cling/Interpreter/ValuePrinter.h"

If I correct these by commenting them out, I get another error which is

qling/qling.cpp:100:19: error: 'class cling::Interpreter' has no member named 'getExecutionEngine'
m_interpreter.getExecutionEngine()->RegisterJITEventListener(&m_jitEventListener);
^
qling/qling.cpp: In member function 'void Qling::exportToInterpreter(const QObject&, const QString&)':
qling/qling.cpp:204:33: warning: cast from type 'const QObject_' to type 'void_' casts away qualifiers -Wcast-qual&obj, name);

I thought I would send this to you first before digging into it too much,

I was able to get this to compile by commenting out two header include lines

// #include "cling/Interpreter/ValuePrinter.h"
// #include "cling/Interpreter/ValuePrinterInfo.h"

as well as commenting out this line

// m_interpreter.getExecutionEngine()->RegisterJITEventListener(&m_jitEventListener);

I tried looking through the cling code, but I can't find any method for getExecutionEngine, unless you want
m_interpreter to subclass from llvm.