We have a project that is linking to ROOT libraries. Our cmake system generates ROOT dictionary headers. And places everything at `/project/path/to/installation/lib/` and /project/path/to/installation/include/`. `.../lib/` directory contains also `pcm` generated files during the compilation process.
Everything works fine as soon as the user loading our libraries in ROOT has rights access to the initial source directory.
If, for example, I remove the source directory we get the following error message when loading the library inside ROOT interface using `gSystem->Load("ourLibrary.so");`
I found at some post at root-forum that defining ROOT_INCLUDE_PATH might help to solve the problem. But this did not solve the problem.
My question is why cling is trying to search for that header at our source directory? At which point this is hard-coded in the .so library?
It is not clear to me if this is a bug related to ROOT or to our cmake building system. I attach the macro we use to generate ROOT dictionary headers and compile the library.
I created the bug report after reporting my problem to the root-forum