make sure the custom dir exists, and create it otherwise, when custom dir is set