Change -ferror-limit

Dear All,

I am using ROOT 6.02/10 and trying to compile my macro with gROOT->LoadMacro(“Util.C++”). For debugging purpose, I want to see ALL the errors during compilation, but there is a limit on number of errors to be printed out. How do I change this limit which is set by -ferror-limit? I found suggestion to use -ferror-limit=0 to get all error to print, but I don’t know how to pass this option to Root. Below is the error print out which is stopped when error limit is reach.

Util.C:80:26: error: no member named
’nallMuons’ in 'TSelector’
for (int i = 0; i < r->nallMuons; i++) {
~ ^
fatal error: too many errors emitted, stopping now [-ferror-limit=]

Thank you,


You can use gSystem->GetMakeSharedLib() … 778b9c87a1 to get the invocation used by ROOT for building the library. Then modify the string (adding the compiler flag you want) and pass it back in through gSystem->SetMakeSharedLib().

Cheers, Axel.