create cached directory if it does not exist