ERROR libconfig++ related to namespace definition - ROOT v6

Hi,
i’ve a problem with root v6 (v6.08.00 and v6.10.08 releases), regard libconfig++. This is the error:

/usr/include/libconfig.h++:78:20: error: namespaces can only be defined in global or namespace scope
namespace libconfig{

inside the lib definition. Any solution? I use an UBUNTU 16.04 LTS pc.
I’ve no problem with root v5.34/10 in an other pc.
The problem is the clang compilator, cint compilator is ok.

HELP ME. THANKS IN ADVANCE.

Maybe @Axel can help…

What exactly are you trying to do - #include <some_header.h>? Which one?

In my shell script process.sh, I execute the command:
root -l “process.cc(0, “${path}”, ${nrun}, ${nevt})“
that use the process.cc root script. In this file, in process(), I include an other script “runme2.cc” using :
gROOT->ProcessLine(”.x runme2.cc”);
in which I load libconfig and new my classes:
gSystem->Load("/usr/include/libconfig.h++");
gROOT->ProcessLine(".L MyClass1.h");
gROOT->ProcessLine(".L MyClass2.h");

When i execute ./process.sh par1 par2 etc… root can’t find method of MyClass1…MyClassN, because it doesn’t execute the gROOT->ProcessLine(".x runme2.cc") presented in my process.cc root script.
So, how can i load correctly my class and a root script using root v6?
I’d like to underline that, using a root v5 version, there’s no problem.

Thanks for your help.

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.