add debug mode for compiling