Ensure that var dir exists