Move DEBUG flag out of library