Ensure install directory exists

Also fix bug in printing error message