Added debug flag when building in debug mode