ROOT Version: 6.14/04
Platform: MacOS 10.14.1
Compiler: Apple LLVM version 10.0.0 (clang-1000.11.45.5)
The following commands workroom the root prompt:
root [0] .L DData.c++
Info in TMacOSXSystem::ACLiC: creating shared library /Users/schutz/work/delphi/data/./DData_c.so
root [1] DData data
(DData &) Name: DData Title:
Doing the same in a macro:
#include <TSystem.h>
#include <TROOT.h>
#include
#include “./DData.h”
extern TROOT *gROOT;
extern TSystem *gSystem;
void DAna()
{
const Int_t kVerbose = 0;
if (!TClass::GetDict(“DData”)) {
gROOT->ProcessLine(".L DData.c++");
}
std::cout << "DAna:......." << std::endl;
DData data;
}
fails with the following link error error:
root [0] .x DAna.C
IncrementalExecutor::executeFunction: symbol ‘_ZN5DDataC1EP5TTree’ unresolved while linking [cling interface function]!
You are probably missing the definition of DData::DData(TTree*)
Maybe you need to load the corresponding shared library?
IncrementalExecutor::executeFunction: symbol ‘_ZN5DDataD1Ev’ unresolved while linking [cling interface function]!
You are probably missing the definition of DData::~DData()
Maybe you need to load the corresponding shared library?
root [1]
It all works well on Linux. Any idea what went wrong ?
Thanks … Yves