corrected makedist script