proper debug flag support