lib/logging: use __debug__() from misc/pragma