I started using the Lumberjack logging framework. It requires an integer variable called ddLogLevel
to be defined wherever I call one of the log macros. I could write
static const int ddLogLevel = LOG_LEVEL_INFO
at the top of every file to achieve this. However I'd prefer not to write anything, except the log macros, just as I would with NSLog
. I can do this by defining the above variable in the prefix header of my project. The problem with this approach is, that if I want to use a different log level in some of my files, then I can't redeclare that static variable.